ppc queue
[PULL 1/1] hw/ppc: sam460ex.c: store all GPIO lines in mal_irqs[]
In reply to Daniel Henrique BarbozaWe're not storing all GPIO lines we're retrieving with qdev_get_gpio_in() in mal_irqs[]. We're storing just the last one in the first index:
for (i = 0; i < ARRAY_SIZE(mal_irqs); i++) {
mal_irqs[0] = qdev_get_gpio_in(uic[2], 3 + i);
}
ppc4xx_mal_init(env, 4, 16, mal_irqs);mal_irqs is used in ppc4xx_mal_init() to assign the IRQs to MAL:
for (i = 0; i < 4; i++) {
mal->irqs[i] = irqs[i];
}Since only irqs[0] has been initialized, mal->irqs[1,2,3] are being zeroed.
This doesn´t seem to trigger any apparent issues at this moment, but Cedric's QOMification of the MAL device [1] is executing a sysbus_connect_irq() that will fail if we do not store all GPIO lines properly.
[1] https://lists.gnu.org/archive/html/qemu-devel/2022-08/msg00497.html
Message-Id: <[email protected]>
--- hw/ppc/sam460ex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
hw/ppc/sam460ex.c +1 -1
@@ -384,7 +384,7 @@ static void sam460ex_init(MachineState *machine)/* MAL */ for (i =0 ; i <ARRAY_SIZE (mal_irqs); i++) { - mal_irqs[0 ] =qdev_get_gpio_in (uic[2 ],3 + i); + mal_irqs[i] =qdev_get_gpio_in (uic[2 ],3 + i); }ppc4xx_mal_init (env,4 ,16 , mal_irqs);
Signature · 1 line
2.36.1
The following changes since commit 2480f3bbd03814b0651a1f74959f5c6631ee5819:
Merge tag 'linux-user-for-7.1-pull-request' of https://gitlab.com/laurent_vivier/qemu into staging (2022-08-03 08:32:44 -0700)
are available in the Git repository at:
https://gitlab.com/danielhb/qemu.git tags/pull-ppc-20220804
for you to fetch changes up to ed021daf2d6c19499ae406055156dc19c073228f:
hw/ppc: sam460ex.c: store all GPIO lines in mal_irqs[] (2022-08-04 15:20:14 -0300)
----------------------------------------------------------------
ppc patch queue for 2022-08-04:
In this short queue we have a fix in the sam460ex machine where we're not storing all GPIO lines in sam460ex_init().
This is not causing problems (as far as we're aware of) at this moment, but this is getting in the way of a ppc405 rework we want to do for 7.2, so let's fix it now.
----------------------------------------------------------------
Daniel Henrique Barboza (1):
hw/ppc: sam460ex.c: store all GPIO lines in mal_irqs[]
hw/ppc/sam460ex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Richard Henderson
AppliedQuoted 15 lines · Daniel Henrique Barboza
The following changes since commit
2480f3bbd03814b0651a1f74959f5c6631ee5819:Merge tag 'linux-user-for-7.1-pull-request' of https://gitlab.com/laurent_vivier/qemu into staging (2022-08-03 08:32:44 -0700)are available in the Git repository at:
https://gitlab.com/danielhb/qemu.git tags/pull-ppc-20220804for you to fetch changes up to
ed021daf2d6c19499ae406055156dc19c073228f:hw/ppc: sam460ex.c: store all GPIO lines in mal_irqs[] (2022-08-04 15:20:14 -0300)----------------------------------------------------------------
ppc patch queue for 2022-08-04:
Quoted 6 lines
In this short queue we have a fix in the sam460ex machine where we're not storing all GPIO lines in
sam460ex_init().This is not causing problems (as far as we're aware of) at this moment, but this is getting in the way of a ppc405 rework we want to do for 7.2, so let's fix it now.
Applied, thanks. Please update https://wiki.qemu.org/ChangeLog/7.1 as appropriate.
r~
Quoted 7 lines
----------------------------------------------------------------
Daniel Henrique Barboza (1):hw/ppc: sam460ex.c: store all GPIO lines in mal_irqs[]hw/ppc/sam460ex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)