scsi: smartpqi: Improve accuracy/performance of raid-bypass-counter
authorKevin Barnett <kevin.barnett@microchip.com>
Thu, 11 Jul 2024 19:47:01 +0000 (14:47 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Sat, 3 Aug 2024 02:07:18 +0000 (22:07 -0400)
commitbb0f5445b27f4a8f8359cc0f36a59a397b4b5e0c
tree1c9f7194ae0682d62c687e2996a758c836269d36
parent0e21e73384d324f75ea16f3d622cfc433fa6209b
scsi: smartpqi: Improve accuracy/performance of raid-bypass-counter

The original implementation of this counter used an atomic variable.
However, this implementation negatively impacted performance in some
configurations.

Switch to using per_cpu variables.

Reviewed-by: Scott Benesh <scott.benesh@microchip.com>
Reviewed-by: Scott Teel <scott.teel@microchip.com>
Reviewed-by: Mike McGowen <mike.mcgowen@microchip.com>
Co-developed-by: Mahesh Rajashekhara <mahesh.rajashekhara@microchip.com>
Signed-off-by: Mahesh Rajashekhara <mahesh.rajashekhara@microchip.com>
Signed-off-by: Kevin Barnett <kevin.barnett@microchip.com>
Signed-off-by: Don Brace <don.brace@microchip.com>
Link: https://lore.kernel.org/r/20240711194704.982400-3-don.brace@microchip.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/smartpqi/smartpqi.h
drivers/scsi/smartpqi/smartpqi_init.c