Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

scsi: smartpqi: Speed up RAID 10 sequential reads

Use all data disks for sequential read operations.

Testing discovered inconsistent performance on RAID 10 volumes when
performing 256K sequential reads. The driver was only using a single
tracker to determine which physical drive to send a request to for AIO
requests.

Change the single tracker (next_bypass_group) to an array of trackers based
on the number of data disks in a row of the RAID map.

Link: https://lore.kernel.org/r/164375212842.440833.6733971458765002128.stgit@brunhilda.pdev.net
Reviewed-by: Kevin Barnett <kevin.barnett@microchip.com>
Reviewed-by: Mike McGowen <mike.mcgowen@microchip.com>
Reviewed-by: Scott Benesh <scott.benesh@microchip.com>
Reviewed-by: Scott Teel <scott.teel@microchip.com>
Signed-off-by: Mike McGowen <Mike.McGowen@microchip.com>
Signed-off-by: Don Brace <don.brace@microchip.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Mike McGowen and committed by
Martin K. Petersen
5d8fbce0 3ada501d

+6 -5
+3 -2
drivers/scsi/smartpqi/smartpqi.h
··· 918 918 #define PQI_MAX_TRANSFER_SIZE (1024U * 1024U) 919 919 #define PQI_MAX_TRANSFER_SIZE_KDUMP (512 * 1024U) 920 920 921 - #define RAID_MAP_MAX_ENTRIES 1024 921 + #define RAID_MAP_MAX_ENTRIES 1024 922 + #define RAID_MAP_MAX_DATA_DISKS_PER_ROW 128 922 923 923 924 #define PQI_PHYSICAL_DEVICE_BUS 0 924 925 #define PQI_RAID_VOLUME_BUS 1 ··· 1126 1125 u8 ncq_prio_support; 1127 1126 bool raid_bypass_configured; /* RAID bypass configured */ 1128 1127 bool raid_bypass_enabled; /* RAID bypass enabled */ 1129 - u32 next_bypass_group; 1128 + u32 next_bypass_group[RAID_MAP_MAX_DATA_DISKS_PER_ROW]; 1130 1129 struct raid_map *raid_map; /* RAID bypass map */ 1131 1130 u32 max_transfer_encrypted; 1132 1131
+3 -3
drivers/scsi/smartpqi/smartpqi_init.c
··· 2058 2058 sizeof(existing_device->box)); 2059 2059 memcpy(existing_device->phys_connector, new_device->phys_connector, 2060 2060 sizeof(existing_device->phys_connector)); 2061 - existing_device->next_bypass_group = 0; 2061 + memset(existing_device->next_bypass_group, 0, sizeof(existing_device->next_bypass_group)); 2062 2062 kfree(existing_device->raid_map); 2063 2063 existing_device->raid_map = new_device->raid_map; 2064 2064 existing_device->raid_bypass_configured = ··· 2963 2963 if (rmd.is_write) { 2964 2964 pqi_calc_aio_r1_nexus(raid_map, &rmd); 2965 2965 } else { 2966 - group = device->next_bypass_group; 2966 + group = device->next_bypass_group[rmd.map_index]; 2967 2967 next_bypass_group = group + 1; 2968 2968 if (next_bypass_group >= rmd.layout_map_count) 2969 2969 next_bypass_group = 0; 2970 - device->next_bypass_group = next_bypass_group; 2970 + device->next_bypass_group[rmd.map_index] = next_bypass_group; 2971 2971 rmd.map_index += group * rmd.data_disks_per_row; 2972 2972 } 2973 2973 } else if ((device->raid_level == SA_RAID_5 ||