This patch adds capability for SCSI layer to generate uevent for SCSI
sense code. The feature is gated by CONFIG_SCSI_SENSE_UEVENT.
We can configure which sense keys generate uevent for each device
through sysfs entry sense_event_filter. For example, the following
enables uevent for MEDIUM_ERROR (
This change is to follow up our discussion on event log for media
management during LSF/MM 2017.
Please kindly let me know your thoughts on this.
Thanks,
Song
Song Liu (1):
scsi: generate uevent for SCSI sense code
drivers/scsi/Kconfig | 14 +++
drivers/scsi/scsi_error.c | 26
From: Kevin Barnett
- make all references to RAID bypass consistent throughout driver.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h | 13
drivers/scsi/smartpqi/smartpqi_init.c | 56 ++--
From: Kevin Barnett
Reviewed-by: Scott Benesh
Reviewed-by: Gerry Morong
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 15 ---
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/drivers/scsi/smartpqi/smartpqi_init.c
From: Corentin Labbe
Instead of rewriting write/readq, use existing functions
Reviewed-by: Scott Benesh
Signed-off-by: Corentin Labbe
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h | 31 ++-
1 file changed, 2 insertio
From: Kevin Barnett
Display the RAID level via sysfs
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 30 +-
1 file changed, 29 insertions(+), 1 deletion(-)
diff --git a/drivers/scsi/sma
From: Kevin Barnett
Add module parameters to disable heartbeat support and to disable
shutting down the controller when a controller is taken offline.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 29
From: Kevin Barnett
Better initialization of linked list heads.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 11 +++
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/drivers/scsi/smartpqi/sm
From: Kevin Barnett
Improved formatting of information displayed when devices
are added/removed from the system.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 90 +
1 file changed,
From: Kevin Barnett
Increase the timeout on admin commands from 3 seconds to 60
seconds and added a check for controller crash in the loop
where the driver polls for admin command completion.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/sma
From: Kevin Barnett
enhance mapping of RAID path errors to Linux SCSI host
error codes.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 32 +++-
1 file changed, 31 insertions(+), 1 delet
From: Kevin Barnett
- Improve handling of offline devices.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 30 +-
1 file changed, 21 insertions(+), 9 deletions(-)
diff --git a/drivers/s
From: Kevin Barnett
- Improve controller branding support.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 18 +++---
1 file changed, 3 insertions(+), 15 deletions(-)
diff --git a/drivers/scsi/smartpqi
From: Kevin Barnett
improve support for taking controller offline.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |2
drivers/scsi/smartpqi/smartpqi_init.c | 141 ++---
2 files change
From: Kevin Barnett
set the internal flag that causes I/O to be sent down the
RAID path when the AIO path is disabled
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |8 +
drivers/scsi/smartpqi/smartpqi_init.c | 3
From: Kevin Barnett
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |2 +-
drivers/scsi/smartpqi/smartpqi_init.c |2 +-
drivers/scsi/smartpqi/smartpqi_sas_transport.c |2 +-
drivers/scsi/sm
From: Kevin Barnett
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 134 +++--
1 file changed, 109 insertions(+), 25 deletions(-)
diff --git a/drivers/scsi/smartpqi/smartpqi_init.c
b/dri
From: Kevin Barnett
add support for actions to take when controller goes offline.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 121 +
1 file changed, 121 insertions(+)
diff --git
From: Kevin Barnett
change return value for controller offline to be consistent
with the rest of the driver.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
dif
From: Kevin Barnett
constrain resource usage during kdump to avoid kdump failures
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |6 +++-
drivers/scsi/smartpqi/smartpqi_init.c | 45 +++---
From: Kevin Barnett
add support for PTRAID devices
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |8 --
drivers/scsi/smartpqi/smartpqi_init.c | 43 -
2 files changed, 41 inse
From: Kevin Barnett
- improve some error messages.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 41 ++---
drivers/scsi/smartpqi/smartpqi_sis.c |3 ++
2 files changed, 20 insertio
From: Kevin Barnett
make the queue depth for LVs the same as the maximum
I/Os supported by the controller
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |6 -
drivers/scsi/smartpqi/smartpqi_init.c | 140 ++---
From: Kevin Barnett
- remove debug code that is no longer necessary.
- Some WARN_ON checks were removed because the driver continues
to function when the conditions are met.
- remove a MACRO that is no longer used.
- remove unnecessary multi-line statements.
Reviewed-by: Scott Benesh
From: Kevin Barnett
correct the BMIC Identify Physical Device structure
- missing 2 fields
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h | 20
drivers/scsi/smartpqi/smartpqi_init.c | 16
From: Kevin Barnett
eliminate redundant error message during initialization
if the controller has crashed.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c |5 +
drivers/scsi/smartpqi/smartpqi_sis.c |5
From: Kevin Barnett
make all variable names for pointers to struct pci_dev consistent
throughout the driver.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 41 +
1 file changed, 21
From: Kevin Barnett
Add check for controller lockup during waits for synchronous
controller commands.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 33 -
1 file changed, 32 inserti
From: Kevin Barnett
add workaround for BDMA hardware bug that can cause
hw to read up to 12 SGL elements (192 bytes) beyond the
last element in the list. This fix avoids IOMMU violations
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi
From: Kevin Barnett
add support for ACPI S3 (suspend) and S4 (hibernate)
system power states.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h | 12 +
drivers/scsi/smartpqi/smartpqi_init.c | 425 +
From: Kevin Barnett
tell smartpqi controller to generate a checkpoint for rare lockup
conditions.
Reviewed-by: Scott Benesh
Reviewed-by: Scott Teel
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |2 +-
drivers/scsi/smartpqi/smartpqi_init.
From: Kevin Barnett
- Block all I/O targeted at LUN reset device.
- Wait until all I/O targeted at LUN reset device has been
consumed by the controller.
- Issue LUN reset request.
- Wait until all outstanding I/Os and LUN reset completion
have been received by the host.
- Return to OS results
From: Kevin Barnett
add support for setting PCIe completion timeout.
Reviewed-by: Scott Benesh
Reviewed-by: Scott Teel
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 18 ++
1 file changed, 18 insertions(+)
diff --git a/dr
From: Kevin Barnett
put in SIS mode during initialization.
support kexec/kdump
Reviewed-by: Scott Benesh
Reviewed-by: Scott Teel
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h |2 +
drivers/scsi/smartpqi/smartpqi_init.c | 60 +++
From: Kevin Barnett
check for controller lockups
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h | 60 ++--
drivers/scsi/smartpqi/smartpqi_init.c | 126 ++---
drivers/scsi/sma
From: Kevin Barnett
Only register for controller events that driver supports
cleanup event handling.
Reviewed-by: Scott Benesh
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi.h | 11 +--
drivers/scsi/smartpqi/smartpqi_init.c | 110
From: Kevin Barnett
minor cleanup of interrupt initialization and tear-down.
Reviewed-by: Scott Benesh
Reviewed-by: Scott Teel
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 43 ++---
1 file changed, 29 inserti
From: Kevin Barnett
correct a problem caused by holding a spinlock during device deletion.
Reviewed-by: Scott Benesh
Reviewed-by: Scott Teel
Signed-off-by: Kevin Barnett
Signed-off-by: Don Brace
---
drivers/scsi/smartpqi/smartpqi_init.c | 20 +---
1 file changed, 13 insert
These patches are based on Linus's tree
The changes are:
- correct remove SCSI devices
- Remove spin-lock
- cleanup interrupt management
- minor cleanup to align with in-house driver
- set PCI completion timeout
- add in controller checkpoint for controller lockups.
- helps debug ra
This update includes the usual round of major driver updates (hisi_sas,
ufs, fnic, cxlflash, be2iscsi, ipr, stex). There's also the usual
amount of cosmetic and spelling stuff.
The major thing you should be aware of is that there's a clash between
a char dev change in the char-misc tree (adding t
On 5/3/2017 2:22 PM, Dan Carpenter wrote:
There is a double lock bug here so this will deadlock instead of
unlocking.
Fixes: 1c5b12f76301 ("Fix implicit logo and RSCN handling for NVMET")
Signed-off-by: Dan Carpenter
diff --git a/drivers/scsi/lpfc/lpfc_ct.c b/drivers/scsi/lpfc/lpfc_ct.c
Yep.
We store sc_cmd->cmnd[0] which is an unsigned char in io_log->op so
this should also be unsigned char. The other thing is that this is
displayed in the debugfs:
seq_printf(s, "0x%02x:", io_log->op);
Smatch complains that the formatting won't work for negative values so
changing it to uns
There is a double lock bug here so this will deadlock instead of
unlocking.
Fixes: 1c5b12f76301 ("Fix implicit logo and RSCN handling for NVMET")
Signed-off-by: Dan Carpenter
diff --git a/drivers/scsi/lpfc/lpfc_ct.c b/drivers/scsi/lpfc/lpfc_ct.c
index 1487406aea77..c7962dae4dab 100644
--- a/driv
Hello James Smart,
This is a semi-automatic email about new static checker warnings.
The patch a0f2d3ef374f: "scsi: lpfc: NVME Initiator: Merge into FC
discovery" from Feb 12, 2017, leads to the following Smatch complaint:
drivers/scsi/lpfc/lpfc_ct.c:982 lpfc_cmpl_ct_cmd_gft_id()
error:
> -Original Message-
> From: Bart Van Assche [mailto:bart.vanass...@sandisk.com]
> Sent: Tuesday, April 25, 2017 3:13 PM
> To: h...@infradead.org; Viswas G ; Gerry
> Morong ; Mahesh Rajashekhara
> ; posw...@suse.com; Scott
> Benesh ; Don Brace
> ; Bader Ali - Saleh
> ; Kevin Barnett
> ; jos
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi-
> ow...@vger.kernel.org] On Behalf Of Bart Van Assche
> Sent: Tuesday, April 25, 2017 3:11 PM
> To: h...@infradead.org; Viswas G ; Gerry
> Morong ; Mahesh Rajashekhara
> ; posw...@suse.com; Scott
> Benesh ; Do
> -Original Message-
> From: Bart Van Assche [mailto:bart.vanass...@sandisk.com]
> Sent: Tuesday, April 25, 2017 3:10 PM
> To: h...@infradead.org; Viswas G ; Gerry
> Morong ; Mahesh Rajashekhara
> ; posw...@suse.com; Scott
> Benesh ; Don Brace
> ; Bader Ali - Saleh
> ; Kevin Barnett
> ; jos
Properly update the position of the arguments in function call.
Addresses-Coverity-ID: 1402010
Signed-off-by: Gustavo A. R. Silva
---
drivers/scsi/qedf/qedf_els.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/scsi/qedf/qedf_els.c b/drivers/scsi/qedf/qedf_els.c
index
> -Original Message-
> From: Bart Van Assche [mailto:bart.vanass...@sandisk.com]
> Sent: Tuesday, April 25, 2017 3:08 PM
> To: h...@infradead.org; Viswas G ; Gerry
> Morong ; Mahesh Rajashekhara
> ; posw...@suse.com; Scott
> Benesh ; Don Brace
> ; Bader Ali - Saleh
> ; Kevin Barnett
> ; jos
> -Original Message-
> On Tue, 2017-04-25 at 14:46 -0500, Don Brace wrote:
> > +static int pqi_device_wait_for_pending_io(struct pqi_ctrl_info *ctrl_info,
> > + struct pqi_scsi_dev *device)
> > +{
> > + while (atomic_read(&device->scsi_cmds_outstanding)) {
> > + pq
> -Original Message-
> On Tue, 2017-04-25 at 14:46 -0500, Don Brace wrote:
> > @@ -4655,23 +4860,46 @@ static int pqi_device_reset(struct pqi_ctrl_info
> *ctrl_info,
> > static int pqi_eh_device_reset_handler(struct scsi_cmnd *scmd)
> > {
> > int rc;
> > + struct Scsi_Host *shos
On 5/3/17 11:38 AM, Bryant G. Ly wrote:
Hi Nick,
On 5/2/17 10:43 PM, Nicholas A. Bellinger wrote:
On Tue, 2017-05-02 at 13:54 -0500, Bryant G. Ly wrote:
The driver is sending a response to the actual scsi op that was
aborted by an abort task TM, while LIO is sending a response to
the abort t
On Wed, 3 May 2017, 2:36pm, Randy Dunlap wrote:
> On 05/03/17 11:29, Chad Dupuis wrote:
> >
> > On Wed, 3 May 2017, 1:58pm, Gustavo A. R. Silva wrote:
> >
> >>
> >> Hello everybody,
> >>
> >> While looking into Coverity ID 1402011 I ran into the following piece of
> >> code
> >> at drivers/scs
On 05/03/17 11:29, Chad Dupuis wrote:
>
> On Wed, 3 May 2017, 1:58pm, Gustavo A. R. Silva wrote:
>
>>
>> Hello everybody,
>>
>> While looking into Coverity ID 1402011 I ran into the following piece of code
>> at drivers/scsi/qedf/qedf_io.c:2057:
>>
>> /* Fill FC header */
>> fc_hdr = &(tm_req->re
Hi Chad,
Quoting Chad Dupuis :
On Wed, 3 May 2017, 1:58pm, Gustavo A. R. Silva wrote:
Hello everybody,
While looking into Coverity ID 1402011 I ran into the following
piece of code
at drivers/scsi/qedf/qedf_io.c:2057:
/* Fill FC header */
fc_hdr = &(tm_req->req_fc_hdr);
sid = fcport->si
On Wed, 3 May 2017, 1:58pm, Gustavo A. R. Silva wrote:
>
> Hello everybody,
>
> While looking into Coverity ID 1402011 I ran into the following piece of code
> at drivers/scsi/qedf/qedf_io.c:2057:
>
> /* Fill FC header */
> fc_hdr = &(tm_req->req_fc_hdr);
> sid = fcport->sid;
> did = fcport->r
On Thu, 2017-03-16 at 17:48 +0100, Thierry Escande wrote:
> -static int sd_sync_cache(struct scsi_disk *sdkp)
> +static int sd_sync_cache(struct scsi_disk *sdkp, int *sense_key)
> {
> int retries, res;
> struct scsi_device *sdp = sdkp->device;
Hello Thierry,
Both in the SCSI spec and
Hello everybody,
While looking into Coverity ID 1402011 I ran into the following piece
of code at drivers/scsi/qedf/qedf_io.c:2057:
/* Fill FC header */
fc_hdr = &(tm_req->req_fc_hdr);
sid = fcport->sid;
did = fcport->rdata->ids.port_id;
__fc_fill_fc_hdr(fc_hdr, FC_RCTL_DD_UNSOL_CMD, sid, di
On Fri, 2017-04-28 at 15:48 +0800, Peng Tao wrote:
> We have a guest init programe trying to mount a device after doing scsi host
> scan
> at boot time. Occasionally it fails to find the device when mounting. After
> digging
> a bit, it seems the root cause is sd async_schedule probing.
>
> With
Dereferencing shost from scsi_exit_rq() is not safe because the
SCSI host may already have been freed when scsi_exit_rq() is
called. Increasing the shost reference count in scsi_init_rq()
and dropping that reference in scsi_exit_rq() is nontrivial since
scsi_host_dev_release() may sleep and since s
On Wed, May 3, 2017 at 1:08 PM, Boaz Harrosh wrote:
>
> On 05/02/2017 02:33 PM, Jeff Layton wrote:
> > On Tue, 2017-05-02 at 09:57 +0200, Christoph Hellwig wrote:
> >> The open-osd domain doesn't exist anymore, and mails to the list lead
> >> to really annoying bounced that repeat every day.
> >>
Hi Nick,
On 5/2/17 10:43 PM, Nicholas A. Bellinger wrote:
On Tue, 2017-05-02 at 13:54 -0500, Bryant G. Ly wrote:
The driver is sending a response to the actual scsi op that was
aborted by an abort task TM, while LIO is sending a response to
the abort task TM.
ibmvscsis_tgt does not send the r
From: Colin Ian King
The 2nd check to see if request_size is less than zero is redundant
because the first check takes error exit path on this condition. So,
since it is redundant, remove it.
Detected by CoverityScan, CID#146149 ("Logically Dead Code")
Signed-off-by: Colin Ian King
---
driver
On Wed, 2017-05-03 at 09:54 +0200, Jan Kara wrote:
> Hum, since this didn't quite work out, how about storing that one bit of
> information that scsi_exit_rq() needs from shost inside scsi_cmnd during
> scsi_init_rq()?
Hello Jan,
All what's missing from the patch I posted is a execute_in_process_
On Tue, 2017-05-02 at 17:00 -0600, Scott Bauer wrote:
> I've applied this on-top of Jens' For-Linus and re-ran the test. I get the
> following scheduling
> while atomic BUG() splat:
>
> [ 35.753764] BUG: scheduling while atomic: swapper/0/0/0x0100
> [ 35.754333] [ ... ]
> [ 35.765844]
> -Original Message-
> From: Bart Van Assche [mailto:bart.vanass...@sandisk.com]
> Sent: Tuesday, April 25, 2017 2:58 PM
> To: h...@infradead.org; Viswas G ; Gerry
> Morong ; Mahesh Rajashekhara
> ; posw...@suse.com; Scott
> Benesh ; Don Brace
> ; Bader Ali - Saleh
> ; Kevin Barnett
> ; jos
> -Original Message-
> From: Bart Van Assche [mailto:bart.vanass...@sandisk.com]
> Sent: Tuesday, April 25, 2017 2:55 PM
> To: h...@infradead.org; Viswas G ; Gerry
> Morong ; Mahesh Rajashekhara
> ; posw...@suse.com; Scott
> Benesh ; Don Brace
> ; Bader Ali - Saleh
> ; Kevin Barnett
> ; jos
On Tue, May 02 2017 at 11:33pm -0400,
Nicholas A. Bellinger wrote:
> On Tue, 2017-05-02 at 09:23 +0200, h...@lst.de wrote:
> > On Tue, May 02, 2017 at 12:16:13AM -0700, Nicholas A. Bellinger wrote:
> > > Or, another options is use bdev_write_zeroes_sectors() to determine when
> > > dev_attrib->un
On 05/02/2017 02:33 PM, Jeff Layton wrote:
> On Tue, 2017-05-02 at 09:57 +0200, Christoph Hellwig wrote:
>> The open-osd domain doesn't exist anymore, and mails to the list lead
>> to really annoying bounced that repeat every day.
>>
>> Also the primarydata address for Benny bounces, and while I ha
On Tue 02-05-17 10:43:30, Bart Van Assche wrote:
> This patch fixes the following KASAN complaint:
>
> ==
> BUG: KASAN: use-after-free in scsi_exit_rq+0xf3/0x120 at addr 8802b7fedf00
> Read of size 1 by task rcuos/5/53
> CPU: 7 PI
70 matches
Mail list logo