[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error
From: |
Xie Xianshan |
Subject: |
Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error |
Date: |
Wed, 11 Sep 2013 16:12:31 +0800 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN; rv:1.9.2.28) Gecko/20120306 Thunderbird/3.1.20 |
Hi Max,
Thanks for your reply.
And I am sorry for my unclear description.
I want to add a new device "fpga" for e500, and trigger an interrupt
IRQ3 while the register BB_INTR_REG which belongs to device "fpga" is
wrote by the device driver of "fpga".
For e500, IRQ3 is an external interrupt irq.
According the debug log, the disabling error is encoutered during
writing BB_INTR_REG register.
- write BB_INTR_REG register
- qemu_irq_raise() is called.
- after serval minutes,
the error message about disabling irq is displayed.
- continue the next execution without error(with poll?)
My sample code is as follows:
----------------------------------------------
hw/ppce500_fpga.c
----------------------------------------------
typedef struct FPGAState {
SysBusDevice busdev;
MemoryRegion iomem;
qemu_irq irq;
}FPGAState;
static void fpga_write(FPGAState *s, unsigned int offset, uint32_t
value, unsigned size) {
switch(offset) {
case BB_INTR_REG:
qemu_irq_raise(s->irq);
break;
}
}
static int ppce500_fpga_initfn(SysBusDevice *dev) {
FPGAState *s;
s = FROM_SYSBUS(FPGAState, SYS_BUS_DEVICE(dev));
sysbus_init_irq(dev, &s->irq);
...
}
----------------------------------------------
hw/ppc/e500.c
----------------------------------------------
void ppce500_init(PPCE500Params *params) {
...
qemu_irq *mpic;
for (i = 0; i < 256; i++) {
mpic[i] = qdev_get_gpio_in(dev, i);
}
...
/* add for FPGA */
dev_fpga = qdev_create(NULL, "fpga");
dev_fpga->id = "fpga";
qdev_init_nofail(dev_fpga);
s = SYS_BUS_DEVICE(dev_fpga);
memory_region_add_subregion(fpga_space, FPGA_REGS_OFFSET,
sysbus_mmio_get_region(s, 0));
sysbus_connect_irq(s, 0, mpic[3]);
....
}
Thanks
Simen
δΊ 2013/09/10 16:23, Max Filippov ει:
On Tue, Sep 10, 2013 at 11:25 AM, Xie Xianshan<address@hidden> wrote:
hi everyone,
I`m getting the nobody cared disabling IRQ error, when i raised external
interrupts IRQ3 to the Openpic in QEMU.
(Actually, any external interrupts irq i raised can reproduce this error,
but internal interrupts work fine)
And this IRQ3 is sharing irq with usb card.
Could you please explain what you mean by "I raised external interrupt",
what you generally try to achieve and what behaviour you expected?
Your description reminds me of this thread:
https://lists.gnu.org/archive/html/qemu-devel/2013-08/msg04063.html
--
Best Regards
Xie Xianshan
--------------------------------------------------
Xie Xianshan
Development Dept.I
Nanjing Fujitsu Nanda Software Tech. Co., Ltd.(FNST)
No. 6 Wenzhu Road, Nanjing, 210012, China
PHONE: +86+25-86630566-9555
FUJITSU INTERNAL: 7998-9555
MAIL: address@hidden
--------------------------------------------------
This communication is for use by the intended recipient(s) only and may
contain information that is privileged, confidential and exempt from
disclosure under applicable law. If you are not an intended recipient of
this communication, you are hereby notified that any dissemination,
distribution or copying hereof is strictly prohibited. If you have
received this communication in error, please notify me by reply e-mail,
permanently delete this communication from your system, and destroy any
hard copies you may have printed
- [Qemu-ppc] Disabling IRQ error, Xie Xianshan, 2013/09/10
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error, Max Filippov, 2013/09/10
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error,
Xie Xianshan <=
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error, Max Filippov, 2013/09/11
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error, Xie Xianshan, 2013/09/12
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error, Max Filippov, 2013/09/12
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error, Xie Xianshan, 2013/09/12
- Re: [Qemu-ppc] [Qemu-devel] Disabling IRQ error, Max Filippov, 2013/09/12