Re: [PATCH v4 02/10] ufs: sysfs: device descriptor

2018-02-01 Thread gre...@linuxfoundation.org
On Fri, Feb 02, 2018 at 12:25:46AM +, Bart Van Assche wrote: > On Thu, 2018-02-01 at 18:15 +0200, Stanislav Nijnikov wrote: > > +enum ufs_desc_param_size { > > + UFS_PARAM_BYTE_SIZE = 1, > > + UFS_PARAM_WORD_SIZE = 2, > > + UFS_PARAM_DWORD_SIZE= 4, > > +

Re: [PATCH 1/1] scsi: ufs: make sure all interrupts are processed

2018-02-01 Thread Asutosh Das (asd)
On 1/31/2018 1:09 PM, Avri Altman wrote: Hi, Can you elaborate how this can even happen? Isn't the interrupt aggregation capability should attend for those cases? Thanks, Avri -Original Message- From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi- ow...@vger.kernel.org] On

Re: [LSF/MM TOPIC] irq affinity handling for high CPU count machines

2018-02-01 Thread Ming Lei
Hello Kashyap, On Thu, Feb 01, 2018 at 10:29:22PM +0530, Kashyap Desai wrote: > > -Original Message- > > From: Hannes Reinecke [mailto:h...@suse.de] > > Sent: Thursday, February 1, 2018 9:50 PM > > To: Ming Lei > > Cc: lsf...@lists.linux-foundation.org; linux-scsi@vger.kernel.org; linux-

Re: [LSF/MM TOPIC] irq affinity handling for high CPU count machines

2018-02-01 Thread Ming Lei
Hello Hannes, On Thu, Feb 01, 2018 at 05:20:26PM +0100, Hannes Reinecke wrote: > On 02/01/2018 04:05 PM, Ming Lei wrote: > > Hello Hannes, > > > > On Mon, Jan 29, 2018 at 10:08:43AM +0100, Hannes Reinecke wrote: > >> Hi all, > >> > >> here's a topic which came up on the SCSI ML (cf thread '[RFC

Re: [dm-devel] [PATCH V4] blk-mq: introduce BLK_STS_DEV_RESOURCE

2018-02-01 Thread Bart Van Assche
On Thu, 2018-02-01 at 19:26 -0500, John Stoffel wrote: > Doesn't this argue that you really want some sort of completions to be > run in this case instead? Instead of busy looping or waiting for a > set amount of time, just fire off a callback to run once you have the > resources available, no?

Re: [PATCH v4 08/10] ufs: sysfs: unit descriptor

2018-02-01 Thread Bart Van Assche
On Thu, 2018-02-01 at 18:15 +0200, Stanislav Nijnikov wrote: > diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c > index cbc0fe2..69a6a1f 100644 > --- a/drivers/scsi/scsi_sysfs.c > +++ b/drivers/scsi/scsi_sysfs.c > @@ -1309,6 +1309,14 @@ int scsi_sysfs_add_sdev(struct scsi_device

Re: [dm-devel] [PATCH V4] blk-mq: introduce BLK_STS_DEV_RESOURCE

2018-02-01 Thread John Stoffel
> "Bart" == Bart Van Assche writes: Bart> On Mon, 2018-01-29 at 16:44 -0500, Mike Snitzer wrote: >> But regardless of which wins the race, the queue will have been run. >> Which is all we care about right? Bart> Running the queue is not sufficient. With this patch

Re: [PATCH v4 02/10] ufs: sysfs: device descriptor

2018-02-01 Thread Bart Van Assche
On Thu, 2018-02-01 at 18:15 +0200, Stanislav Nijnikov wrote: > +ssize_t ufs_sysfs_read_desc_param(struct ufs_hba *hba, > + enum desc_idn desc_id, > + u8 desc_index, > + u8 param_offset, > +

Re: [PATCH v4 02/10] ufs: sysfs: device descriptor

2018-02-01 Thread Bart Van Assche
On Thu, 2018-02-01 at 18:15 +0200, Stanislav Nijnikov wrote: > +enum ufs_desc_param_size { > + UFS_PARAM_BYTE_SIZE = 1, > + UFS_PARAM_WORD_SIZE = 2, > + UFS_PARAM_DWORD_SIZE= 4, > + UFS_PARAM_QWORD_SIZE= 8, > +}; Please do not copy bad naming choices from the

test results

2018-02-01 Thread Mauricio Faria de Oliveira
The test-case results with PATCH v2. scsih_abort() = Without patch: [ 362.669743] setting logging_level(0x1000) [ 362.705074] mpt3sas_cm0: skip free_smid/scsi_done scmd(c01fd4f2bd40) [ 363.956579] sd 16:0:1:0: [sdf] Synchronizing SCSI cache [ 363.956844]

[PATCH v2] scsi: mpt3sas: fix oops in error handlers after shutdown/unload

2018-02-01 Thread Mauricio Faria de Oliveira
This patch adds checks for 'ioc->remove_host' in the SCSI error handlers, so not to access pointers/resources potentially freed in the PCI shutdown/module unload path. The error handlers may be invoked after shutdown/unload, depending on other components. This problem was observed with kexec on

Re: [LSF/MM TOPIC] KPTI effect on IO performance

2018-02-01 Thread Bart Van Assche
On 01/31/18 00:23, Ming Lei wrote: After KPTI is merged, there is extra load introduced to context switch between user space and kernel space. It is observed on my laptop that one syscall takes extra ~0.15us[1] compared with 'nopti'. IO performance is affected too, it is observed that IOPS

Re: [PATCH] test-case

2018-02-01 Thread Mauricio Faria de Oliveira
On 01/31/2018 08:50 PM, Bart Van Assche wrote: I think it would be useful to have some variant of the above code in the kernel tree. Are you familiar with the fault injection framework (see also and Documentation/fault-injection/fault-injection.txt)? No, not yet. That's very interesting.

Re: [PATCH] scsi: mpt3sas: fix oops in error handlers after shutdown/unload

2018-02-01 Thread Mauricio Faria de Oliveira
On 01/31/2018 08:59 PM, Bart Van Assche wrote: On Wed, 2018-01-31 at 17:48 -0200, Mauricio Faria de Oliveira wrote: On 01/31/2018 05:06 PM, Bart Van Assche wrote: Sorry but I think this patch introduces new race conditions. Have you Can you detail the race conditions? As far as I can see,

[PATCH 1/2] qla2xxx: Fix double free bug after firmware timeout

2018-02-01 Thread Himanshu Madhani
From: Quinn Tran This patch is based on Max's original patch. When the qla2xxx firmware is unavailable, eventually qla2x00_sp_timeout() is reached, which calls the timeout function and frees the srb_t instance. The timeout function always resolves to

[PATCH 2/2] qla2xxx: Fix incorrect handle for abort IOCB

2018-02-01 Thread Himanshu Madhani
This patch fixes incorrect handle used for abort IOCB. Fixes: b027a5ace443 ("scsi: qla2xxx: Fix queue ID for async abort with Multiqueue") Signed-off-by: Darren Trapp Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/qla_iocb.c | 7

[PATCH 0/2] qla2xxx: Bug fixes for driver

2018-02-01 Thread Himanshu Madhani
Hi Martin, These are couple of bug fixes for the driver. Patch#1 is the issue reported by Max using KASAN tool. Patch#2 fixes use of wrong queue handle for abort IOCB. Please apply them to 4.16/scsi-fixes at your earliest convenience. Thanks, Himanshu Himanshu Madhani (1): qla2xxx: Fix

Re: [PATCH v4 10/10] ufs: sysfs: attributes

2018-02-01 Thread Greg KH
On Thu, Feb 01, 2018 at 06:15:46PM +0200, Stanislav Nijnikov wrote: > +#define UFS_LUN_ATTRIBUTE(_name, _uname) > \ > +static ssize_t _name##_attribute_show(struct device *dev, > \ > + struct device_attribute *attr, char *buf)

Re: [PATCH v4 03/10] ufs: sysfs: interconnect descriptor

2018-02-01 Thread Greg KH
On Thu, Feb 01, 2018 at 06:15:39PM +0200, Stanislav Nijnikov wrote: > This patch introduces a sysfs group entry for the UFS interconnect > descriptor parameters. The group adds "interconnect_descriptor" folder > under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). > The

Re: [PATCH v4 02/10] ufs: sysfs: device descriptor

2018-02-01 Thread Greg KH
On Thu, Feb 01, 2018 at 06:15:38PM +0200, Stanislav Nijnikov wrote: > +#define UFS_DESC_PARAM(_name, _puname, _duname, _size) > \ > +static ssize_t _name##_show(struct device *dev, > \ > + struct device_attribute *attr, char *buf)

Re: [PATCH v4 01/10] ufs: sysfs: attribute group for existing sysfs entries.

2018-02-01 Thread Greg KH
On Thu, Feb 01, 2018 at 06:15:37PM +0200, Stanislav Nijnikov wrote: > This patch introduces attribute group to show existing sysfs entries. > > Signed-off-by: Stanislav Nijnikov > --- > drivers/scsi/ufs/Makefile| 3 +- > drivers/scsi/ufs/ufs-sysfs.c | 164 >

RE: [LSF/MM TOPIC] irq affinity handling for high CPU count machines

2018-02-01 Thread Kashyap Desai
> -Original Message- > From: Hannes Reinecke [mailto:h...@suse.de] > Sent: Thursday, February 1, 2018 9:50 PM > To: Ming Lei > Cc: lsf...@lists.linux-foundation.org; linux-scsi@vger.kernel.org; linux- > n...@lists.infradead.org; Kashyap Desai > Subject: Re: [LSF/MM TOPIC] irq affinity

Re: [PATCH v4 00/10] ufs: sysfs: read-only access to device descriptors, attributes and flags

2018-02-01 Thread Eric W. Biederman
Can you please clarify the naming, at least as far as saying scsi/ufs. Universal Flash Storage is not the same thing as all as the Unix File System which has been using the acronym ufs for much longer. I saw this patchset and I was wondering what in the world does a filesystem need with sysfs

Re: scsi: sg: assorted memory corruptions

2018-02-01 Thread Dmitry Vyukov
On Thu, Feb 1, 2018 at 5:17 PM, Ben Hutchings wrote: > On Thu, 2018-02-01 at 08:04 +0100, Dmitry Vyukov wrote: >> On Thu, Feb 1, 2018 at 7:03 AM, Douglas Gilbert >> wrote: >> > On 2018-01-30 07:22 AM, Dmitry Vyukov wrote: > [...] >> > >

Re: [LSF/MM TOPIC] irq affinity handling for high CPU count machines

2018-02-01 Thread Hannes Reinecke
On 02/01/2018 04:05 PM, Ming Lei wrote: > Hello Hannes, > > On Mon, Jan 29, 2018 at 10:08:43AM +0100, Hannes Reinecke wrote: >> Hi all, >> >> here's a topic which came up on the SCSI ML (cf thread '[RFC 0/2] >> mpt3sas/megaraid_sas: irq poll and load balancing of reply queue'). >> >> When doing

[PATCH v4 03/10] ufs: sysfs: interconnect descriptor

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS interconnect descriptor parameters. The group adds "interconnect_descriptor" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The parameters are shown as hexadecimal numbers. The full information about the

[PATCH v4 04/10] ufs: sysfs: geometry descriptor

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS geometry descriptor parameters. The group adds "geometry_descriptor" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The parameters are shown as hexadecimal numbers. The full information about the parameters could

[PATCH v4 01/10] ufs: sysfs: attribute group for existing sysfs entries.

2018-02-01 Thread Stanislav Nijnikov
This patch introduces attribute group to show existing sysfs entries. Signed-off-by: Stanislav Nijnikov --- drivers/scsi/ufs/Makefile| 3 +- drivers/scsi/ufs/ufs-sysfs.c | 164 +++ drivers/scsi/ufs/ufs-sysfs.h | 22

[PATCH v4 06/10] ufs: sysfs: power descriptor

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS power descriptor parameters. The group adds "power_descriptor" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The parameters are shown as hexadecimal numbers. The full information about the parameters could be

Re: scsi: sg: assorted memory corruptions

2018-02-01 Thread Ben Hutchings
On Thu, 2018-02-01 at 08:04 +0100, Dmitry Vyukov wrote: > On Thu, Feb 1, 2018 at 7:03 AM, Douglas Gilbert wrote: > > On 2018-01-30 07:22 AM, Dmitry Vyukov wrote: [...] > > > [1:0:0:0]cd/dvd  QEMU QEMU DVD-ROM 2.0.  /dev/sr0   /dev/sg1 > > > > > > # readlink

[PATCH v4 05/10] ufs: sysfs: health descriptor

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS health descriptor parameters. The group adds "health_descriptor" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The parameters are shown as hexadecimal numbers. The full information about the parameters could be

[PATCH v4 09/10] ufs: sysfs: flags

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS flags. The group adds "flags" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The flags are shown as boolean value ("true" or "false"). The full information about the UFS flags could be found at UFS specifications

[PATCH v4 07/10] ufs: sysfs: string descriptors

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS string descriptors. The group adds "string_descriptors" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The folder will contain 5 files that will show string values defined by the UFS spec: a manufacturer name, a

[PATCH v4 08/10] ufs: sysfs: unit descriptor

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS unit descriptor parameters. The group adds "unit_descriptor" folder under the corresponding SCSI device sysfs entry (/sys/class/scsi_device/*/device/). The parameters are shown as hexadecimal numbers. The full information about the parameters

[PATCH v4 10/10] ufs: sysfs: attributes

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS attributes. The group adds "attributes" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The attributes are shown as hexadecimal numbers. The full information about the attributes could be found at UFS

[PATCH v4 00/10] ufs: sysfs: read-only access to device descriptors, attributes and flags

2018-02-01 Thread Stanislav Nijnikov
This patch introduces sysfs entries that will provide read-only access to device management data that could be received with UFS query requests. User-space applications will be able to read UFS device descriptors, flags and attributes. This will allow to get full UFS device configuration and its

[PATCH v4 02/10] ufs: sysfs: device descriptor

2018-02-01 Thread Stanislav Nijnikov
This patch introduces a sysfs group entry for the UFS device descriptor parameters. The group adds "device_descriptor" folder under the UFS driver sysfs entry (/sys/bus/platform/drivers/ufshcd/*). The parameters are shown as hexadecimal numbers. The full information about the parameters could be

Re: [PATCH] qedi: Fix truncation of name and secret

2018-02-01 Thread Bart Van Assche
On Wed, 2018-01-31 at 22:57 -0800, Nilesh Javali wrote: > Adjust the NULL byte added by snprintf. Hello Nilesh, Sorry but neither the title nor the description of this patch make clear what the intention of this patch is. Please describe this more clearly. > @@ -1840,7 +1840,7 @@ static ssize_t

Re: [LSF/MM TOPIC] irq affinity handling for high CPU count machines

2018-02-01 Thread Ming Lei
Hello Hannes, On Mon, Jan 29, 2018 at 10:08:43AM +0100, Hannes Reinecke wrote: > Hi all, > > here's a topic which came up on the SCSI ML (cf thread '[RFC 0/2] > mpt3sas/megaraid_sas: irq poll and load balancing of reply queue'). > > When doing I/O tests on a machine with more CPUs than MSIx

Re: [PATCH 0/2] genirq/affinity: try to make sure online CPU is assgined to irq vector

2018-02-01 Thread Ming Lei
On Thu, Feb 01, 2018 at 02:53:35PM +, Don Brace wrote: > > -Original Message- > > From: Ming Lei [mailto:ming@redhat.com] > > Sent: Thursday, February 01, 2018 4:37 AM > > To: Don Brace > > Cc: Laurence Oberman ; Thomas Gleixner > >

Re: [PATCH v3] scsi: sd: add new match array for cache_type

2018-02-01 Thread Weiping Zhang
2018-01-31 11:22 GMT+08:00 Martin K. Petersen : > > Weiping, > >> add user friendly command strings sd_wr_cache to enable/disable >> write cache. user can enable both write and read cache by one of >> the following commands: > > I remain unconvinced that introducing