OSDN Git Service

scsi: megaraid_sas: Use irq_set_affinity_and_hint()
authorNitesh Narayan Lal <nitesh@redhat.com>
Fri, 3 Sep 2021 15:24:20 +0000 (11:24 -0400)
committerThomas Gleixner <tglx@linutronix.de>
Fri, 10 Dec 2021 19:47:38 +0000 (20:47 +0100)
commit8049da6f3943d0ac51931b8064b2e4769a69a967
treed9cd804b23d37f774f341cf9091b2ec1335a5673
parentd34c54d1739c2cdf2e4437b74e6da269147f4987
scsi: megaraid_sas: Use irq_set_affinity_and_hint()

The driver uses irq_set_affinity_hint() specifically for the high IOPS
queue interrupts for two purposes:

 - To set the affinity_hint which is consumed by the userspace for
   distributing the interrupts

 - To apply an affinity that it provides

The driver enforces its own affinity to bind the high IOPS queue interrupts
to the local NUMA node. However, irq_set_affinity_hint() applying the
provided cpumask as an affinity for the interrupt is an undocumented side
effect.

To remove this side effect irq_set_affinity_hint() has been marked
as deprecated and new interfaces have been introduced. Hence, replace the
irq_set_affinity_hint() with the new interface irq_set_affinity_and_hint()
where the provided mask needs to be applied as the affinity and
affinity_hint pointer needs to be set and replace with
irq_update_affinity_hint() where only affinity_hint needs to be updated.

Change the megasas_set_high_iops_queue_affinity_hint function name to
megasas_set_high_iops_queue_affinity_and_hint to clearly indicate that the
function is setting both affinity and affinity_hint.

Signed-off-by: Nitesh Narayan Lal <nitesh@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Sumit Saxena <sumit.saxena@broadcom.com>
Link: https://lore.kernel.org/r/20210903152430.244937-5-nitesh@redhat.com
drivers/scsi/megaraid/megaraid_sas_base.c