op. It is not necessary for these
commands to run in series.
To reduce latency of parallel "delete" requests, this patch unlock
shost->scan_mutex before long latency commands and relock the mutex
after the command.
Signed-off-by: Song Liu
---
drivers/scsi/sd.c | 6 ++
1 file changed, 6
op. It is not necessary for these
commands to run in series.
To reduce latency of parallel "delete" requests, this patch unlock
shost->scan_mutex before long latency commands and relock the mutex
after the command.
Fixed bug from previous version.
Reported-by: kernel test robot
Signed-off-
> On Feb 8, 2017, at 1:02 PM, Christoph Hellwig wrote:
>
> On Wed, Feb 08, 2017 at 12:42:40PM -0800, Song Liu wrote:
>> When a device is deleted through sysfs handle "delete", the code
>> locks shost->scan_mutex. If multiple devices are deleted at the
>>
op. It is not necessary for these
commands to run in series.
To reduce latency of parallel "delete" requests, this patch unlock
shost->scan_mutex before long latency commands and relock the mutex
after the command.
Fixed bug from previous version.
Reported-by: kernel test robot
Signed-off-
> On Feb 8, 2017, at 2:53 PM, Song Liu wrote:
>
> When a device is deleted through sysfs handle "delete", the code
> locks shost->scan_mutex. If multiple devices are deleted at the
> same time, these deletes will be handled in series.
>
> On the other hand, s
> On Feb 8, 2017, at 2:58 PM, Bart Van Assche
> wrote:
>
> On Wed, 2017-02-08 at 14:53 -0800, Song Liu wrote:
>> +try_lock_scan_mutex = mutex_trylock(&shost->scan_mutex);
>
> This is at least as bad as the approach of your previous patch because
> whethe
op. It is not necessary for these
commands to run in series.
To reduce latency of parallel "delete" requests, this patch unlock
shost->scan_mutex before calling sd_shutdown(), relock the mutex
afterwards.
Fixed bug from previous version.
Reported-by: kernel test robot
Signed-off-by: Song
Hi Christoph,
IMHO, scan_mutex maybe still needed for other part of scsi_remove_device().
For example, device_del() in sd_remove() and scsi_sysfs_add_devices() in
scsi_finish_async_scan() should not run in parallel?
On the other hand, other parts of sd_remove(), including sd_shutdown(),
do
From: Song Liu [mailto:songliubrav...@fb.com]
Sent: Monday, August 25, 2014 10:26 AM
To: Song Liu
Cc: Dan Williams; Hannes Reinecke
Subject: [PATCH 2/5] SES: generate KOBJ_CHANGE on enclosure attach
From: Dan Williams
In support of a /dev/disk/by-slot populated with data from the enclosure and
From: Song Liu [mailto:songliubrav...@fb.com]
Sent: Monday, August 25, 2014 10:26 AM
To: Song Liu
Cc: Dan Williams; Hannes Reinecke
Subject: [PATCH 4/5] SES: add reliable slot attribute
From: Dan Williams
The name provided by firmware is in a vendor specific format, publish the slot
number to
From: Song Liu [mailto:songliubrav...@fb.com]
Sent: Monday, August 25, 2014 10:26 AM
To: Song Liu
Cc: Hannes Reinecke
Subject: [PATCH 5/5] SES: Add power_status to SES enclosure component
Add power_status to SES enclosure component, so we can power on/off the HDDs
behind the enclosure.
Check
From: Song Liu [mailto:songliubrav...@fb.com]
Sent: Monday, August 25, 2014 10:26 AM
To: Song Liu
Subject: [PATCH 0/5] Feature enhancements for ses module
These patches include a few enhancements to ses module:
1: close potential race condition by at enclosure race condition
2,3,4: add
From: Song Liu [mailto:songliubrav...@fb.com]
Sent: Monday, August 25, 2014 10:26 AM
To: Song Liu
Cc: Dan Williams; Hannes Reinecke
Subject: [PATCH 1/5] SES: close potential registration race
From: Dan Williams
The slot and address fields have a small window of instability when userspace
can
From: Song Liu [mailto:songliubrav...@fb.com]
Sent: Monday, August 25, 2014 10:26 AM
To: Song Liu
Cc: Dan Williams; Hannes Reinecke
Subject: [PATCH 3/5] SES: add enclosure logical id
From: Dan Williams
Export the NAA logical id for the enclosure. This is optionally available from
the
ore initialization. Separate
enclosure_component
allocation from registration.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
---
drivers/misc/enclosure.c | 36 +---
drivers/scsi/ses.c|
eds notification when the new interface
files/links are available. Otherwise, any udev rules specified for the
disk cannot assume that the enclosure topology has settled.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Reviewed-by: Hannes Reinecke
---
drivers/s
ned-off-by: Song Liu
Reviewed-by: Jens Axboe
Reviewed-by: Hannes Reinecke
---
drivers/misc/enclosure.c | 20 +++-
drivers/scsi/ses.c| 17 -
include/linux/enclosure.h | 1 +
3 files changed, 32 insertions(+), 6 deletions(-)
diff --git a/drivers/m
is really a property of
the enclosure.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
---
drivers/misc/enclosure.c | 13 +
drivers/scsi/ses.c| 9 +
include/linux/enclosure.h | 1 +
3 files changed, 23 inserti
necke [mailto:h...@suse.de]
> Sent: Thursday, September 4, 2014 12:59 AM
> To: Song Liu; linux-scsi@vger.kernel.org
> Cc: Dan Williams; Jens Axboe
> Subject: Re: [PATCH 5/5] SES: Add power_status to SES enclosure component
>
> On 08/25/2014 07:34 PM, Song Liu wrote:
> > From
>From 53549716d9f965e59f3a84feb5ebae9d18232b52 Mon Sep 17 00:00:00 2001
From: Song Liu
Date: Tue, 19 Aug 2014 23:58:58 -0700
Subject: [PATCH 5/5] SES: Add power_status to SES enclosure component
Add power_status to SES enclosure component, so we can power on/off the
HDDs behind the enclos
> On May 18, 2017, at 11:14 AM, Song Liu wrote:
>
> This change is to follow up our discussion on event log for media
> management during LSF/MM 2017.
>
> I have included feedbacks from Hannes Reinecke, Ewan D. Milne, and
> Benjamin Block.
>
> Please kindly let me
> On Jun 6, 2017, at 6:22 AM, Ewan D. Milne wrote:
>
> On Thu, 2017-05-18 at 11:14 -0700, Song Liu wrote:
>> This patch adds rate limits to SCSI sense code uevets. Currently,
>> the rate limit is hard-coded to 16 events per second.
>>
>> The code tracks nano s
the difference is smaller than one
second, the new event is dropped.
Signed-off-by: Song Liu
---
drivers/scsi/hosts.c | 4
drivers/scsi/scsi_error.c | 16
include/scsi/scsi_host.h | 13 +
3 files changed, 33 insertions(+)
diff --git a/drivers/scsi
This change is to follow up our discussion on event log for media
management during LSF/MM 2017.
Changes from RFC v2:
1. change rate limit of events from per device to per SCSI host
2. fix bugs from feedbacks
Please kindly let me know your thoughts on this.
Thanks,
Song
Song Liu (2):
scsi
UBSYSTEM=scsi
Signed-off-by: Song Liu
---
drivers/scsi/Kconfig | 14 +++
drivers/scsi/scsi_error.c | 43 ++
drivers/scsi/scsi_lib.c| 58 +-
drivers/scsi/scsi_
This change is to follow up our discussion on event log for media
management during LSF/MM 2017.
Changes from RFC v3:
Incorporate feedback by Johannes Thumshirn
Thanks,
Song
Song Liu (2):
scsi: generate uevent for SCSI sense code
scsi: add rate limit to scsi sense code uevent
drivers
the difference is smaller than one
second, the new event is dropped.
Signed-off-by: Song Liu
---
drivers/scsi/hosts.c | 4
drivers/scsi/scsi_error.c | 16
include/scsi/scsi_host.h | 13 +
3 files changed, 33 insertions(+)
diff --git a/drivers/scsi
UBSYSTEM=scsi
Signed-off-by: Song Liu
---
drivers/scsi/Kconfig | 14 +++
drivers/scsi/scsi_error.c | 42 +
drivers/scsi/scsi_lib.c| 58 +-
drivers/scsi/scsi_sysfs.c | 51
Hi all,
Could you please share your feedback on this version of the change?
Thanks in advance,
Song
>> On 7/21/17, 3:58 PM, "Song Liu" wrote:
This change is to follow up our discussion on event log for media
management during LSF/MM 2017.
Cha
Dear Hannes and James,
Could you please kindly review this patch and let me know what do we
need to move forward with this?
Thanks and Regards,
Song
> On Aug 4, 2017, at 10:18 AM, Song Liu wrote:
>
> Hi all,
>
> Could you please share your feedback on this versio
;= 0xde;
+ dest_desc[3] &= 0x3c;
Would this work for device that rejects request with 1 in RESERVED areas?
Thanks,
Song
> -Original Message-
> From: Douglas Gilbert [mailto:dgilb...@interlog.com]
> Sent: Wednesday, October 22, 2014 3:29 PM
> To: Jens Axboe; Song Liu; linux-sc
inal Message-
> From: Douglas Gilbert [mailto:dgilb...@interlog.com]
> Sent: Wednesday, October 22, 2014 6:17 PM
> To: Song Liu; Jens Axboe; linux-scsi@vger.kernel.org
> Cc: Hannes Reinecke; Dan Williams; Christoph Hellwig
> Subject: Re: [PATCH 0/5] Feature enhancements for ses
ate, active, and power_status of each HDD
without issue.
Please let me know your suggestion on this.
Thanks,
Song
> -Original Message-
> From: Song Liu
> Sent: Wednesday, October 22, 2014 8:42 PM
> To: 'dgilb...@interlog.com'; Jens Axboe; linux-scsi@vger.kern
.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Reviewed-by: Hannes Reinecke
---
drivers/scsi/ses.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/scsi/ses.c b/drivers/scsi/ses.c index c52fd98..87cf970b
100644
--- a/drivers/scsi/ses.c
+++ b
From: Dan Williams
Export the NAA logical id for the enclosure. This is optionally available from
the sas_transport_class, but it is really a property of the enclosure.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
---
drivers/misc
unique, and usually mirrors the slot
number.
Cleaned up the unused ses_component.desc in the process.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Reviewed-by: Hannes Reinecke
---
drivers/misc/enclosure.c | 20 +++-
drivers/scsi/ses.c| 17
id
SES: add reliable slot attribute
Song Liu (1):
SES: Add power_status to SES enclosure component
drivers/misc/enclosure.c | 107 +
drivers/scsi/ses.c| 148 +++---
include/linux/enclosure.h | 13 +++-
3 files chan
Add power_status to SES enclosure component, so we can power on/off the HDDs
behind the enclosure.
Check firmware status in ses_set_* before sending control pages to firmware.
Signed-off-by: Song Liu
Acked-by: Dan Williams
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
---
drivers/misc
From: Dan Williams
The slot and address fields have a small window of instability when userspace
can read them before initialization. Separate enclosure_component allocation
from registration.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
unique,
and usually mirrors the slot number.
Cleaned up the unused ses_component.desc in the process.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Reviewed-by: Hannes Reinecke
---
drivers/misc/enclosure.c | 20 +++-
drivers/scsi/ses.c| 17
From: Dan Williams
The slot and address fields have a small window of instability when
userspace can read them before initialization. Separate
enclosure_component
allocation from registration.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
Add power_status to SES device slot, so we can power on/off the
HDDs behind the enclosure.
Check firmware status in ses_set_* before sending control pages to
firmware.
Signed-off-by: Song Liu
Acked-by: Dan Williams
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
---
drivers/misc/enclosure.c
ful for systems like Cold Storage, where HDDs are being powered
\
on/off frequently
Dan Williams (4):
ses: close potential registration race
ses: generate KOBJ_CHANGE on enclosure attach
ses: add enclosure logical id
ses: add reliable slot attribute
Song Liu (1):
ses: Add power_status
From: Dan Williams
Export the NAA logical id for the enclosure. This is optionally
available from the sas_transport_class, but it is really a property of
the enclosure.
Signed-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Cc: Hannes Reinecke
---
drivers/misc
-off-by: Dan Williams
Signed-off-by: Song Liu
Reviewed-by: Jens Axboe
Reviewed-by: Hannes Reinecke
---
drivers/scsi/ses.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/scsi/ses.c b/drivers/scsi/ses.c
index 7dd9cf5..6662b0c 100644
--- a/drivers/scsi/ses.c
+++ b
Hi Christoph,
I just send the patches (http://marc.info/?l=linux-scsi&m=141997962124647&w=2).
Thanks,
Song
> -Original Message-
> From: Christoph Hellwig [mailto:h...@infradead.org]
> Sent: Tuesday, December 30, 2014 4:45 AM
> To: Song Liu
> Cc: linux-sc
sed-variable]
int err, i;
^
Signed-off-by: Song Liu
Acked-by: Dan Williams
Reported-by: kbuild test robot
---
drivers/misc/enclosure.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/misc/enclosure.c b/drivers/misc/enclosure.c
index 3289d4d..38552a3 1006
,7 +548,6 @@ static void ses_enclosure_data_process(struct
> enclosure_device *edev,
> ecomp = &edev->component[components++];
>
> if (!IS_ERR(ecomp)) {
> - ses_get_power_status(edev, ecomp);
> if (addl_desc_ptr)
> ses_process_descriptor(
> ecomp,
> --
> 1.8.3.1
>
Reviewed-by: Song Liu
fore, the protection of scan_mutex is only necessary for this
function.
Signed-off-by: Song Liu
---
drivers/scsi/scsi_sysfs.c | 13 ++---
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c
index 82dfe07..e7a9e28 10
> On Apr 21, 2017, at 2:17 PM, Bart Van Assche
> wrote:
>
> On Fri, 2017-04-21 at 14:13 -0700, Song Liu wrote:
>> When a device is deleted through sysfs handle "delete", [ ... ]
>
> If I try to use that sysfs attribute then I encounter a deadlock (see
&
> On Apr 21, 2017, at 2:20 PM, Bart Van Assche
> wrote:
>
> On Fri, 2017-04-21 at 14:13 -0700, Song Liu wrote:
>> On the other hand, some devices do long latency IO during deletion,
>> for example, sd_shutdown() may do sync cache and/or start_stop.
>> It is not n
> On Apr 25, 2017, at 10:23 AM, Bart Van Assche
> wrote:
>
> On Fri, 2017-04-21 at 14:13 -0700, Song Liu wrote:
>> When a device is deleted through sysfs handle "delete", the code
>> locks shost->scan_mutex. If multiple devices are deleted at the
>>
> On Apr 25, 2017, at 10:52 AM, Bart Van Assche
> wrote:
>
> On Tue, 2017-04-25 at 17:42 +0000, Song Liu wrote:
>> I have been studying the code recently. I am wondering whether the following
>> would work:
>>
>> 1. Introduce a new mutex for scsi_devi
> On Apr 25, 2017, at 1:59 PM, Bart Van Assche
> wrote:
>
> On Fri, 2017-04-21 at 22:31 +0000, Song Liu wrote:
>> On Apr 21, 2017, at 2:20 PM, Bart Van Assche
>> wrote:
>>> On Fri, 2017-04-21 at 14:13 -0700, Song Liu wrote:
>>>> On the other
> On Apr 25, 2017, at 3:17 PM, Bart Van Assche
> wrote:
>
> On Tue, 2017-04-25 at 21:17 +0000, Song Liu wrote:
>> I am not sure I fully understand the problem here. If I understand the logic
>> correctly, when a device is being removed, it will stay in
>> scsi_
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
XXX
DEVTYPE=scsi_device
DRIVER=sd
LBA=0
MODALIAS=scsi:t-0x00
SDEV_UA=SCSI_SENSE
SENSE_CODE=3/11/14
SEQNUM=4536
SIZE=4096
SUBSYSTEM=scsi
Signed-off-by: Song Liu
---
drivers/scsi/Kconfig | 14 +++
drivers/scsi/scsi_error.c | 26
drivers/scsi/scsi_lib.c|
> On May 3, 2017, at 5:50 PM, Song Liu wrote:
>
> 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 ent
> On May 14, 2017, at 11:04 PM, Hannes Reinecke wrote:
>
> On 05/12/2017 09:02 PM, Song Liu wrote:
>>
>>> On May 3, 2017, at 5:50 PM, Song Liu wrote:
>>>
>>> This patch adds capability for SCSI layer to generate uevent for SCSI
>>> sense cod
> On May 15, 2017, at 5:31 AM, Ewan D. Milne wrote:
>
> On Mon, 2017-05-15 at 08:04 +0200, Hannes Reinecke wrote:
>> In general I like the idea; however, the 'filter' thingie is somewhat
>> odd. I could somewhat buy into the idea of filtering for sense keys, but
>> then I would have expected to
> On May 16, 2017, at 10:00 AM, Benjamin Block
> wrote:
>
> Hello,
>
> On Wed, May 03, 2017 at 05:50:13PM -0700, Song Liu wrote:
>> This patch adds capability for SCSI layer to generate uevent for SCSI
>> sense code. The feature is gated by CONFIG_SCSI_SENSE_U
This change is to follow up our discussion on event log for media
management during LSF/MM 2017.
I have included feedbacks from Hannes Reinecke, Ewan D. Milne, and
Benjamin Block.
Please kindly let me know your thoughts on this.
Thanks,
Song
Song Liu (2):
scsi: generate uevent for SCSI sense
difference is smaller than one
second, the new event is dropped.
Signed-off-by: Song Liu
---
drivers/scsi/scsi_error.c | 15 +++
drivers/scsi/scsi_scan.c | 4
include/scsi/scsi_device.h | 12 +++-
3 files changed, 30 insertions(+), 1 deletion(-)
diff --git a/drivers/scsi
UBSYSTEM=scsi
Signed-off-by: Song Liu
---
drivers/scsi/Kconfig | 14 +++
drivers/scsi/scsi_error.c | 43 ++
drivers/scsi/scsi_lib.c| 58 +-
drivers/scsi/scsi_
64 matches
Mail list logo