diff options
author | Ian Munsie <imunsie@au1.ibm.com> | 2014-10-08 19:54:53 +1100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2014-10-08 20:15:42 +1100 |
commit | b0345bbc6d0980e63b9730b487d4f4ccb8e5cd12 (patch) | |
tree | 82aba747d4a0c8161378f43caafb2b35ad6537bc /mm | |
parent | be3ebfe8215392b714349554c5138b8b6592fe20 (diff) |
powerpc/msi: Improve IRQ bitmap allocator
Currently msi_bitmap_alloc_hwirqs() will round up any IRQ allocation requests
to the nearest power of 2. eg. ask for 5 IRQs and you'll get 8. This wastes a
lot of IRQs which can be a scarce resource.
For cxl we may require multiple IRQs for every context that is attached to the
accelerator. There may be 1000s of contexts attached, hence we can easily run
out of IRQs, especially if we are needlessly wasting them.
This changes the msi_bitmap_alloc_hwirqs() to allocate only the required number
of IRQs, hence avoiding this wastage. It keeps the natural alignment
requirement though.
Signed-off-by: Ian Munsie <imunsie@au1.ibm.com>
Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'mm')
0 files changed, 0 insertions, 0 deletions