Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
irqchip/mips-gic: Fix shifts to extract register fields
The MIPS GIC driver is incorrectly using __fls to shift registers, intending to shift to the least significant bit of a value based upon its mask but instead shifting off all but the value's top bit. It should actually be using __ffs to shift to the first, not last, bit of the value. Apparently the system I used when testing commit 3680746 ("irqchip: mips-gic: Convert remaining shared reg access to new accessors") and commit b2b2e58 ("irqchip: mips-gic: Clean up mti, reserved-cpu-vectors handling") managed to work correctly despite this issue, but not all systems do... Fixes: 3680746 ("irqchip: mips-gic: Convert remaining shared reg access to new accessors") Fixes: b2b2e58 ("irqchip: mips-gic: Clean up mti, reserved-cpu-vectors handling") Signed-off-by: Paul Burton <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Cc: Marc Zyngier <[email protected]> Cc: Jason Cooper <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
- Loading branch information