This is the boot message of the virtual machine related to IRQ.

[    0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0

[    0.000000] GICv3: 224 SPIs implemented

[    0.000000] GICv3: 0 Extended SPIs implemented

[    0.000000] GICv3: Distributor has no Range Selector support

[    0.000000] GICv3: 16 PPIs implemented

[    0.000000] GICv3: no VLPI support, no direct LPI support

[    0.000000] GICv3: CPU0: found redistributor 0 region 0:0x00000000080a0000

Somehow the NR_IRQS is 64.

So I tried using SPI 15 which was not assigned. (32 internal IRQs + 15 < 64) and now request_irq returns 0.

So this irq_desc problem was solved(?) for now. (I dont know why this is so small when CONFIG_SPARSE_IRQS=y).

And still the handler is not called even when I set qemu_set_irq.