Re: [RFC,v2] scsi: scan: map PQ=1, PDT=other values to SCSI_SCAN_TARGET_PRESENT

2019-09-22 Thread Li Zhong
On Thu, Sep 12, 2019 at 8:37 PM Andrey Melnikov wrote: > > чт, 12 сент. 2019 г. в 07:56, Zhong Li : > > > > > > > On Aug 29, 2019, at 11:49 PM, Andrey Melnikov > > > wrote: > > > > > > Hello. > > > > > > This patch break exposing individual RAID disks from adaptec raid > > > controller. I need a

[RFC PATCH v2] target: tcmu: clean the nl_cmd of the udev when nl send fails

2019-08-04 Thread Li Zhong
off-by: Li Zhong --- drivers/target/target_core_user.c | 20 1 file changed, 20 insertions(+) diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c index 04eda111920e..68045cbca595 100644 --- a/drivers/target/target_core_user.c +++ b/drivers/

Re: [RFC PATCH] target: tcmu: clean the nl_cmd of the udev when nl send fails

2019-08-04 Thread Li Zhong
On Sat, Aug 3, 2019 at 12:58 AM Mike Christie wrote: > > On 08/02/2019 05:38 AM, Li Zhong wrote: > > If the userspace process crashes while we send the nl msg, it is possible > > that the cmd in curr_nl_cmd of tcmu_dev never gets reset to 0, and > > and returns busy for

[RFC PATCH] target: tcmu: clean the nl_cmd of the udev when nl send fails

2019-08-02 Thread Li Zhong
off-by: Li Zhong --- drivers/target/target_core_user.c | 21 + 1 file changed, 21 insertions(+) diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c index 04eda111920e..4ae3103e204c 100644 --- a/drivers/target/target_core_user.c +++ b/drivers/

[RFC PATCH v2] scsi: scan: map PQ=1, PDT=other values to SCSI_SCAN_TARGET_PRESENT

2019-04-14 Thread Li Zhong
ANSI SCSI revision: 06 $ lsscsi [0:0:0:0]diskIBM 2145 /dev/sdb [1:0:0:0]diskIBM 2145 /dev/sda [1:0:0:1]diskIBM 2145 0000 - Signed-off-by: Li Zhong --- drivers/scsi/scsi_scan.c | 7 --- 1 file chan

[PATCH] [RFC PATCH] scsi: scan: map PQ=1, PDT=other values to SCSI_SCAN_TARGET_PRESENT

2019-04-12 Thread Li Zhong
ANSI SCSI revision: 06 $ lsscsi [0:0:0:0]diskIBM 2145 /dev/sdb [1:0:0:0]diskIBM 2145 /dev/sda [1:0:0:1]diskIBM 2145 0000 - Signed-off-by: Li Zhong --- drivers/scsi/scsi_scan.c | 4 ++-- 1 file chan

[PATCH v2 scsi] Short the path length of scsi_cmd_to_driver()

2012-09-28 Thread Li Zhong
fixes a bug where you get different behaviors from REQ_TYPE_BLOCK_PC commands when a driver is and isn't attached. v2: mirror code != REQ_TYPE_BLOCK_PC in scsi.c, rather than == REQ_TYPE_FS Signed-off-by: Li Zhong --- drivers/scsi/scsi_error.c |8 +--- include/scsi/scsi_cmnd

Re: [PATCH scsi] Short the path length of scsi_cmd_to_driver()

2012-09-28 Thread Li Zhong
On Thu, 2012-09-27 at 13:43 -0400, Martin K. Petersen wrote: > >>>>> "Li" == Li Zhong writes: > > > @@ -845,8 +844,11 @@ static int scsi_send_eh_cmnd(struct scsi_cmnd *scmd, > > unsigned char *cmnd, > > > > scsi_eh_restore_cmn

[PATCH scsi] Short the path length of scsi_cmd_to_driver()

2012-09-27 Thread Li Zhong
PE_FS type only. Signed-off-by: Li Zhong --- drivers/scsi/scsi_error.c |8 +--- include/scsi/scsi_cmnd.h | 12 ++-- 2 files changed, 7 insertions(+), 13 deletions(-) diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c index de2337f..4001559 100644 --- a/dr

Re: [PATCH scsi] Add NULL checking of return value from scsi_cmd_to_driver()

2012-09-24 Thread Li Zhong
On Mon, 2012-09-24 at 11:35 +0400, James Bottomley wrote: > On Mon, 2012-09-24 at 15:03 +0800, Li Zhong wrote: > > On Mon, 2012-09-24 at 09:44 +0400, James Bottomley wrote: > > > On Mon, 2012-09-24 at 13:30 +0800, Li Zhong wrote: > > > > Just noticed that after commi

Re: [PATCH scsi] Add NULL checking of return value from scsi_cmd_to_driver()

2012-09-24 Thread Li Zhong
On Mon, 2012-09-24 at 09:44 +0400, James Bottomley wrote: > On Mon, 2012-09-24 at 13:30 +0800, Li Zhong wrote: > > Just noticed that after commit 919f797, it is possible that > > scsi_cmd_to_driver() returns NULL. This patch adds the NULL checking for > > drv > &

[PATCH scsi] Add NULL checking of return value from scsi_cmd_to_driver()

2012-09-23 Thread Li Zhong
is a delta of my previous patch [https://lkml.org/lkml/2012/4/11/814] and commit 919f797 Signed-off-by: Li Zhong --- diff --git a/drivers/scsi/scsi.c b/drivers/scsi/scsi.c index 2936b44..b9dd7f0 100644 --- a/drivers/scsi/scsi.c +++ b/drivers/scsi/scsi.c @@ -832,7 +832,7 @@ void scsi_finish_co