[PATCH] klist: Make it safe to use klists in atomic context

2018-06-22 Thread Bart Van Assche
In the scsi_transport_srp implementation it cannot be avoided to iterate over a klist from atomic context when using the legacy block layer instead of blk-mq. Hence this patch that makes it safe to use klists in atomic context. This patch avoids that lockdep reports the following: WARNING:

[PATCH 4/6] tcmu: misc nl code cleanup

2018-06-22 Thread Mike Christie
Some misc cleanup of the nl rework patches. 1. Fix space instead of tabs use and extra newline. 2. Drop initializing variables to 0 when not needed 3. Just pass the skb_buff and msg_header pointers to tcmu_netlink_event_send. Signed-off-by: Mike Christie --- drivers/target/target_core_user.c |

[PATCH 3/6] tcmu: simplify nl interface

2018-06-22 Thread Mike Christie
Just return EBUSY if a nl request comes in while processing one. The upper layers do not support sending multiple create/remove requests at the same time (you cannot have a create and remove at the same time or do multiple creates or removes at the same time) and doing a reconfig while a

[PATCH 6/6] target: remove target_find_device

2018-06-22 Thread Mike Christie
target_find_device is no longer used, so remove it. Signed-off-by: Mike Christie --- drivers/target/target_core_device.c | 24 include/target/target_core_backend.h | 2 -- 2 files changed, 26 deletions(-) diff --git a/drivers/target/target_core_device.c

[PATCH 5/6] tcmu: add module wide block/reset_netlink support

2018-06-22 Thread Mike Christie
This patch based on Xiubo's patches adds 2 tcmu attr to block and resetup the netlink interface. It's used during userspace daemon reinitialization after the daemon has crashed while there is outstanding nl requests. The daemon can block the nl interface, kill outstanding requests in the kernel

tcmu: fix hung netlink requests and nl related cleanup V2

2018-06-22 Thread Mike Christie
The following patches fix the issues where the userspace daemon has crashed and left netlink requests dangling. The daemon can now block the interface, kill outstanding requests, reopen the netlink socket and then unblock and execute new requests. The patches were made over Martin's for-next

[PATCH 2/6] tcmu: track nl commands

2018-06-22 Thread Mike Christie
The next patch is going to fix the hung nl command issue so this adds a list of outstanding nl commands that we can later abort when the daemon is restarted. Signed-off-by: Mike Christie --- drivers/target/target_core_user.c | 68 ++- 1 file changed, 39

[PATCH 1/6] tcmu: delete unused __wait

2018-06-22 Thread Mike Christie
When this code change this was never cleaned up. Signed-off-by: Mike Christie --- drivers/target/target_core_user.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c index e4a76f9..898a561 100644 ---

Re: [PATCH v1] mpt3sas: Fix calltrace observed while running IO & host reset

2018-06-22 Thread Bart Van Assche
On 06/22/18 09:38, Sreekanth Reddy wrote: In driver's .resume() callback function, driver is doing IOC reset operation. And as per your suggestion we tried using scsi_internal_device_block_nowait() to block the all the devices attached to the HBA before going for IOC reset operation. During

Re: qla2xxx and smatch warnings about uninitialized variables

2018-06-22 Thread Madhani, Himanshu
Hi Bart/Dan, > On Jun 22, 2018, at 2:08 PM, Bart Van Assche wrote: > > External Email > > On 06/22/18 14:06, Dan Carpenter wrote: >> On Fri, Jun 22, 2018 at 08:43:21AM -0700, Bart Van Assche wrote: >>> Hello Himanshu, >>> >>> The latest smatch version reports a large number of warnings

Re: qla2xxx and smatch warnings about uninitialized variables

2018-06-22 Thread Bart Van Assche
On 06/22/18 14:06, Dan Carpenter wrote: On Fri, Jun 22, 2018 at 08:43:21AM -0700, Bart Van Assche wrote: Hello Himanshu, The latest smatch version reports a large number of warnings about uninitialized variables for the qla2xxx driver. I think these warnings indicate real bugs. Can you have a

Re: qla2xxx and smatch warnings about uninitialized variables

2018-06-22 Thread Dan Carpenter
On Fri, Jun 22, 2018 at 08:43:21AM -0700, Bart Van Assche wrote: > Hello Himanshu, > > The latest smatch version reports a large number of warnings about > uninitialized variables for the qla2xxx driver. I think these warnings > indicate real bugs. Can you have a look at these warnings? > Or we

[PATCH] scsi: aacraid: Fix PD performance regression over incorrect qd being set

2018-06-22 Thread Raghava Aditya Renukunta
The driver fails to set the correct queue depth for native devices, due to failing to set the device type prior to calling aac_set_safw_target_qd(). This results in slave configure setting the queue depth to 1. This causes around 30% performance degradation. Fixed by setting the dev type before

Re: [PATCH v1] mpt3sas: Fix calltrace observed while running IO & host reset

2018-06-22 Thread Sreekanth Reddy
On Fri, Jun 22, 2018 at 8:22 PM, Bart Van Assche wrote: > On 06/21/18 22:35, Sreekanth Reddy wrote: >> >> No, lock_system_sleep() is not inserted in the interrupt context. we >> have inserted it in .resume() call back function just before issuing >> the IOC reset. > > > That's the wrong place to

[Bug 200003] Hardware Error with 40-wire PATA cable

2018-06-22 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=23 Brent (bzipiti...@gmail.com) changed: What|Removed |Added Summary|40-wire PATA cable causes |Hardware Error with

[Bug 200003] 40-wire PATA cable causes Hardware Error

2018-06-22 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=23 Brent (bzipiti...@gmail.com) changed: What|Removed |Added Summary|Memorex DVD burner Hardware |40-wire PATA cable causes

qla2xxx and smatch warnings about uninitialized variables

2018-06-22 Thread Bart Van Assche
Hello Himanshu, The latest smatch version reports a large number of warnings about uninitialized variables for the qla2xxx driver. I think these warnings indicate real bugs. Can you have a look at these warnings? Thanks, Bart. $ make M=drivers/scsi/qla2xxx C=2 CHECK="smatch -p=kernel"

Re: [PATCH v1] mpt3sas: Fix calltrace observed while running IO & host reset

2018-06-22 Thread Bart Van Assche
On 06/21/18 22:35, Sreekanth Reddy wrote: No, lock_system_sleep() is not inserted in the interrupt context. we have inserted it in .resume() call back function just before issuing the IOC reset. That's the wrong place to insert a lock_system_sleep() call. Please have a look at

[bug report] qedi: Add support for populating ethernet TLVs.

2018-06-22 Thread Dan Carpenter
Hello Manish Rangankar, The patch 534bbdf8832a: "qedi: Add support for populating ethernet TLVs." from May 22, 2018, leads to the following static checker warning: drivers/scsi/qedi/qedi_main.c:891 qedi_get_boot_tgt_info() error: snprintf() is printing too much 256 vs 255