mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-15 22:21:57 -06:00
aspeed/smc: remove call to aspeed_smc_update_cs() in reset function
Instead, we can simply set the irq level when unselecting the slave devices. This change prepares ground for a subsequent cleanup of the aspeed_smc_update_cs() routine which uselessly loops on all slaves to update their status. Signed-off-by: Cédric Le Goater <clg@kaod.org> Message-id: 1483979087-32663-3-git-send-email-clg@kaod.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
eafbafa32f
commit
1d247bd079
1 changed files with 1 additions and 2 deletions
|
@ -424,6 +424,7 @@ static void aspeed_smc_reset(DeviceState *d)
|
||||||
/* Unselect all slaves */
|
/* Unselect all slaves */
|
||||||
for (i = 0; i < s->num_cs; ++i) {
|
for (i = 0; i < s->num_cs; ++i) {
|
||||||
s->regs[s->r_ctrl0 + i] |= CTRL_CE_STOP_ACTIVE;
|
s->regs[s->r_ctrl0 + i] |= CTRL_CE_STOP_ACTIVE;
|
||||||
|
qemu_set_irq(s->cs_lines[i], true);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* setup default segment register values for all */
|
/* setup default segment register values for all */
|
||||||
|
@ -431,8 +432,6 @@ static void aspeed_smc_reset(DeviceState *d)
|
||||||
s->regs[R_SEG_ADDR0 + i] =
|
s->regs[R_SEG_ADDR0 + i] =
|
||||||
aspeed_smc_segment_to_reg(&s->ctrl->segments[i]);
|
aspeed_smc_segment_to_reg(&s->ctrl->segments[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
aspeed_smc_update_cs(s);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static uint64_t aspeed_smc_read(void *opaque, hwaddr addr, unsigned int size)
|
static uint64_t aspeed_smc_read(void *opaque, hwaddr addr, unsigned int size)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue