~mreed8855/ubuntu/+source/linux/+git/jammy:mpi3mr_bsg_support_1

Last commit made on 2023-01-18
Get this branch:
git clone -b mpi3mr_bsg_support_1 https://git.launchpad.net/~mreed8855/ubuntu/+source/linux/+git/jammy
Only Michael Reed can upload to this branch. If you are Michael Reed please log in for upload directions.

Branch merges

Branch information

Name:
mpi3mr_bsg_support_1
Repository:
lp:~mreed8855/ubuntu/+source/linux/+git/jammy

Recent commits

0296206... by Michael Reed

UBUNTU: SAUCE: (no-up) mpi3mr -- Adjustments had to be made for two patches to build.

mpi3mr: Add management application interface(BSG) support

BugLink: https://bugs.launchpad.net/bugs/1971151

The first patch "256bd4f23d9c scsi: mpi3mr: Return I/Os to an unrecoverable HBA with DID_ERROR"
introduces the issue with scsi_done(scmd) where it should be scmd->scsi_done(scmd);

The second patch "986d6bad2103 scsi: mpi3mr: Expose adapter state to sysfs"
adds this line .shost_groups = mpi3mr_host_groups and has to be removed

063c865... by Jiapeng Chong <email address hidden>

scsi: mpi3mr: Fix kernel-doc

Fix the following W=1 kernel warnings:

drivers/scsi/mpi3mr/mpi3mr_app.c:1706: warning: expecting prototype for
adapter_state_show(). Prototype was for adp_state_show() instead.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Reported-by: Abaci Robot <email address hidden>
Signed-off-by: Jiapeng Chong <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit 1fcbe4c490396c5a0d4588cfb84923ad6076b62a)
Signed-off-by: Michael Reed <email address hidden>

bc05d0d... by Sumit Saxena

scsi: mpi3mr: Rework mrioc->bsg_device model to fix warnings

During driver unload, mrioc->bsg_device reference count becomes
negative. Also, as reported in [1], the driver's bsg_device model had few
more bugs. Fix all these up.

[1] https://marc.info/?l=linux-scsi&m=165183971411991&w=2

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Fixes: 4268fa751365 ("scsi: mpi3mr: Add bsg device support")
Reported-by: Dan Carpenter <email address hidden>
Tested-by: Tomas Henzl <email address hidden>
Signed-off-by: Sumit Saxena <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit 4094981db7b6ed6ebe3ebe398d8d9136ac5c44c8)
Signed-off-by: Michael Reed <email address hidden>

3bf123c... by Sreekanth Reddy

scsi: mpi3mr: Add target device related sysfs attributes

Add sysfs attributes for exposing target device details such as SAS
address, firmware device handle, and persistent ID for the
controller-attached devices and RAID volumes.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Reviewed-by: Himanshu Madhani <email address hidden>
Signed-off-by: Sreekanth Reddy <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit 9feb5c4c3f95ec42fc12dc92f7216c2603b1a571)
Signed-off-by: Michael Reed <email address hidden>

ddf1c37... by Sreekanth Reddy

scsi: mpi3mr: Add shost related sysfs attributes

Add shost related sysfs attributes to display the controller's firmware
version, queue depth, number of requests, and number of reply queues. Also
add an attribute to set & get the logging_level.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Reviewed-by: Himanshu Madhani <email address hidden>
Signed-off-by: Sreekanth Reddy <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit e51e76edddb10867f95df0c24a9769d6d97afeb0)
Signed-off-by: Michael Reed <email address hidden>

5d86171... by Dan Carpenter <email address hidden>

scsi: mpi3mr: Return error if dma_alloc_coherent() fails

Return -ENOMEM instead of success if dma_alloc_coherent() fails.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://lore.kernel.org/r/YnOmMGHqCOtUCYQ1@kili
Fixes: 43ca11005098 ("scsi: mpi3mr: Add support for PEL commands")
Signed-off-by: Dan Carpenter <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit bc7896d31a922ee9caabb10dc07509f65d41dc0e)
Signed-off-by: Michael Reed <email address hidden>

0322f15... by Dan Carpenter <email address hidden>

scsi: mpi3mr: Fix a NULL vs IS_ERR() bug in mpi3mr_bsg_init()

The bsg_setup_queue() function does not return NULL. It returns error
pointers. Fix the check accordingly.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://lore.kernel.org/r/YnUf7RQl+A3tigWh@kili
Fixes: 4268fa751365 ("scsi: mpi3mr: Add bsg device support")
Signed-off-by: Dan Carpenter <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit a25eafd13e5f79d9bbada5a4a4a4224cc5f6d14c)
Signed-off-by: Michael Reed <email address hidden>

e4ad4a0... by Sreekanth Reddy

scsi: mpi3mr: Return I/Os to an unrecoverable HBA with DID_ERROR

Complete all new I/O requests issued to an unrecoverable controller with
DID_ERROR status instead of returning the I/O requests with
SCSI_MLQUEUE_HOST_BUSY. This will prevent the infinite retries of the new
I/Os when a controller is in an unrecoverable state.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Signed-off-by: Sreekanth Reddy <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit 256bd4f23d9cecaba2e6795f0058fa9c2362698c)
Signed-off-by: Michael Reed <email address hidden>

6eebbe3... by Sreekanth Reddy

scsi: mpi3mr: Hidden drives not removed during soft reset

If any drive is missing during reset, the driver checks whether the device
is exposed to the OS. If it is, then it removes the device from the OS and
its own internal list. For hidden devices, even if they are found as
missing during reset, the driver is not removing them from its internal
list.

Modify driver to remove hidden devices from the driver's target device list
if they are missing during soft reset.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Signed-off-by: Sreekanth Reddy <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit 2dd8389f96d6d00a24816888262e33a85d414c05)
Signed-off-by: Michael Reed <email address hidden>

66e2995... by Sreekanth Reddy

scsi: mpi3mr: Increase I/O timeout value to 60s

Set each SCSI device's default I/O timeout and default error handling I/O
timeout to 60s.

BugLink: https://bugs.launchpad.net/bugs/1971151

Link: https://<email address hidden>
Signed-off-by: Sreekanth Reddy <email address hidden>
Signed-off-by: Martin K. Petersen <email address hidden>
(cherry picked from commit 1aa529d400253eda76733dbb95b62f6cca7b274a)
Signed-off-by: Michael Reed <email address hidden>