scsi: ibmvfc: Add max_sectors module parameter
authorBrian King <brking@linux.ibm.com>
Tue, 3 Sep 2024 13:47:09 +0000 (08:47 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 13 Sep 2024 00:18:30 +0000 (20:18 -0400)
commite3684006945414153a33c5c4d1202dda2b80650f
tree49a6efd8358351ca57b872965a076370ae8e2c2d
parentb112947ffc30e9632d5c2acd0e9081e3e6bee01e
scsi: ibmvfc: Add max_sectors module parameter

There are some scenarios that can occur, such as performing an upgrade of
the virtual I/O server, where the supported max transfer of the backing
device for an ibmvfc HBA can change. If the max transfer of the backing
device decreases, this can cause issues with previously discovered
LUNs. This patch accomplishes two things.  First, it changes the default
ibmvfc max transfer value to 1MB.  This is generally supported by all
backing devices, which should mitigate this issue out of the box. Secondly,
it adds a module parameter, enabling a user to increase the max transfer
value to values that are larger than 1MB, as long as they have configured
these larger values on the virtual I/O server as well.

[mkp: fix checkpatch warnings]

Signed-off-by: Brian King <brking@linux.ibm.com>
Link: https://lore.kernel.org/r/20240903134708.139645-2-brking@linux.ibm.com
Reviewed-by: Martin Wilck <mwilck@suse.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/ibmvscsi/ibmvfc.c
drivers/scsi/ibmvscsi/ibmvfc.h