PCIe msi bitmap issue by split nr_irqs for 1 by 1
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi Dear linux-pci team,
I got some msi-irq bitmap issue when using PCIe NVMe SSD during resume/suspend.
First, we know now all the controller driver using "order_base_2()" to find the bitmap in alloc/free.
Then in my case, SSD request for 9 msi-irqs, and 16 bits is occupy in bitmap[31:16]. Eg. msi_bitmap from 00000001 to ffff0001.
When in suspend, msi-irqs will be free one by one, but not 9 in one time. This will cause bitmap cannot fully clear which was requested, bit[24:16] will be free, but bit[31:25] was residue. Eg. msi_bitmap from ffff0001 to fffe0001(1st) to fffc0001(2nd) to ... to fe000001(9th)
And I found that this "split" operation was push in below commit:4615fbc3788d ("genirq/irqdomain: Don't try to free an interrupt that has no mapping")
After i revert it, everything goes normal.
So at last, is there any solution to fix it?
Signature · 2 lines
Regards, Michael Wu
[+to Marc, author of 4615fbc3788d ("genirq/irqdomain: Don't try to free an interrupt that has no mapping");
+cc Thomas]
Quoted 18 lines · Michael Wu
Hi Dear linux-pci team,
I got some msi-irq bitmap issue when using PCIe NVMe SSD during resume/suspend.
First, we know now all the controller driver using "
order_base_2()" to find the bitmap in alloc/free.Then in my case, SSD request for 9 msi-irqs, and 16 bits is occupy in bitmap[31:16].
Eg.msi_bitmapfrom 00000001 toffff0001.When in suspend, msi-irqs will be free one by one, but not 9 in one time. This will cause bitmap cannot fully clear which was requested, bit[24:16] will be free, but bit[31:25] was residue.
Eg.msi_bitmapfromffff0001to fffe0001(1st) to fffc0001(2nd) to ... to fe000001(9th)
Quoted 5 lines
And I found that this "split" operation was push in below commit:
4615fbc3788d("genirq/irqdomain: Don't try to free an interrupt that has no mapping")After i revert it, everything goes normal.
Thanks for the report, Michael. Looks like the same issue reported here:
https://lore.kernel.org/all/[email protected]/
https://lore.kernel.org/all/[email protected]/
I see a workaround there, but it doesn't look like anything ever made it upstream.