Re: [PATCH 17/23] scsi_dh_alua: use unique device id

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Use scsi_vpd_lun_id() to assign a unique device identification > to the alua port group structure. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 70 >

Re: [PATCH 01/23] scsi_dh_alua: Disable ALUA handling for non-disk devices

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:40 +0200, Hannes Reinecke wrote: > Non-disk devices might support ALUA, but the firmware > implementation is untested and frequently broken. > As we're don't actually need it disable ALUA support > for non-disk device for now. > > Signed-off-by: Hannes Reinecke

Re: [PATCH 04/23] scsi_dh_alua: use standard logging functions

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Use standard logging functions instead of hand-crafted ones. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 34 > +- > 1 file changed, 15

Re: [PATCH 08/23] scsi_dh_alua: use flag for RTPG extended header

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > We should be using a flag when RTPG extended header is not > supported, that saves us sending RTPG twice for older arrays. > > Reviewed-by: Bart Van Assche > Reviewed-by: Christoph Hellwig >

Re: [PATCH 19/23] scsi_dh_alua: Use workqueue for RTPG

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > The current ALUA device_handler has two drawbacks: > - We're sending a 'SET TARGET PORT GROUP' command to every LUN, > disregarding the fact that several LUNs might be in a port group > and will be automatically switched whenever

Re: [PATCH 09/23] scsi_dh_alua: use unaligned access macros

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Use 'get_unaligned_XX' and 'put_unaligned_XX' instead of > open-coding it. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 23 --- > 1 file changed, 8

Re: [PATCH 11/23] scsi_dh_alua: Make stpg synchronous

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > We should be issuing STPG synchronously as we need to > evaluate the return code on failure. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 179 > + >

Re: [PATCH 16/23] scsi: Add scsi_vpd_lun_id()

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Add a function scsi_vpd_lun_id() to return a unique device > identifcation based on the designation descriptors of > VPD page 0x83. > > As devices might implement several descriptors the order > of preference is: > - NAA IEE Registered

Re: [PATCH 18/23] revert "scsi_dh_alua: ALUA hander attach should succeed while TPG is transitioning"

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > This reverts commit a8e5a2d593cbfccf530c3382c2c328d2edaa7b66 > > Obsoleted by the next patch. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 29 +++-- > 1

Re: [PATCH 13/23] scsi_dh_alua: Use separate alua_port_group structure

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > The port group needs to be a separate structure as several > LUNs might belong to the same group. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 211 >

Re: [PATCH 20/23] scsi_dh_alua: Recheck state on unit attention

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > When we receive a unit attention code of 'ALUA state changed' > we should recheck the state, as it might be due to an implicit > ALUA state transition. > At the same time a workqueue item might already be queued, which > should be started

Re: [PATCH 22/23] scsi_dh_alua: Send TEST UNIT READY to poll for transitioning

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Sending a 'REPORT TARGET PORT GROUP' command is a costly operation, > as the array has to gather information about all ports. > So instead of using RTPG to poll for a status update when a port > is in transitioning we should be sending a

Re: [PATCH 23/23] scsi_dh_alua: Update version to 2.0

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c >

Re: [PATCH 02/23] scsi_dh_alua: Use vpd_pg83 information

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > The SCSI device now has the VPD page 0x83 information attached, > so there is no need to query it again. > > Reviewed-by: Christoph Hellwig > Signed-off-by: Hannes Reinecke > --- >

Re: [PATCH 05/23] scsi_dh_alua: return standard SCSI return codes in submit_rtpg

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Fixup submit_rtpg() to always return a standard SCSI return code. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 38 > +- > 1 file changed, 22

Re: [PATCH 06/23] scsi_dh_alua: fixup description of stpg_endio()

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Fixup copy-and-paste error in the description of stpg_endio(). > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff

Re: [PATCH 10/23] scsi_dh_alua: Pass buffer as function argument

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Pass in the buffer as a function argument for submit_rtpg(). > > Reviewed-by: Bart Van Assche > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c | 20

Re: [PATCH 07/23] scsi: remove scsi_show_sense_hdr()

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Last caller is gone, so remove it. > > Reviewed-by: Bart Van Assche > Reviewed-by: Reviewed-by: Christoph Hellwig > Signed-off-by: Hannes Reinecke > --- > include/scsi/scsi_dbg.h

Re: [PATCH 14/23] scsi_dh_alua: allocate RTPG buffer separately

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > The RTPG buffer will only evaluated within alua_rtpg(), > so we can allocate it locally there and avoid having to > put it into the global structure. > > Reviewed-by: Christoph Hellwig > Signed-off-by: Hannes Reinecke

Re: [PATCH 12/23] scsi_dh_alua: switch to scsi_execute_req_flags()

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > All commands are issued synchronously, so no need to open-code > scsi_execute_req_flags() anymore. And we can get rid of the > static sense code structure element. > > Signed-off-by: Hannes Reinecke > --- >

Re: [PATCH 15/23] scsi_dh_alua: simplify sense code handling

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > Most sense code is already handled in the generic > code, so we shouldn't be adding special cases here. > However, when doing so we need to check for > unit attention whenever we're sending an internal > command. > > Reviewed-by:

Re: [PATCH 21/23] scsi_dh_alua: update all port states

2015-09-22 Thread Ewan Milne
On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: > When we read in the target port group state we should be > updating all affected port groups, otherwise we risk > running out of sync. > > Signed-off-by: Hannes Reinecke > --- > drivers/scsi/device_handler/scsi_dh_alua.c

[PATCH] storvsc: get rid of homegrown copy_{to,from}_bounce_buffer()

2015-09-22 Thread Vitaly Kuznetsov
Storvsc driver needs to ensure there are no 'holes' in the presented sg list (all segments in the middle of the list need to be of PAGE_SIZE). When a hole is detected storvsc driver creates a 'bounce sgl' without holes and copies data over with its own copy_{to,from}_bounce_buffer() functions.

Re: [PATCH 21/23] scsi_dh_alua: update all port states

2015-09-22 Thread Hannes Reinecke
On 09/22/2015 10:04 PM, Ewan Milne wrote: > On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: >> When we read in the target port group state we should be >> updating all affected port groups, otherwise we risk >> running out of sync. >> >> Signed-off-by: Hannes Reinecke >>

Re: [PATCH v2 22/30] cxlflash: Correct behavior in device reset handler following EEH

2015-09-22 Thread Brian King
Reviewed-by: Brian King -- Brian King Power Linux I/O IBM Linux Technology Center -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH v2 19/30] cxlflash: Fix AFU version access/storage and add check

2015-09-22 Thread Brian King
Reviewed-by: Brian King -- Brian King Power Linux I/O IBM Linux Technology Center -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH v2 24/30] cxlflash: Fix function prolog parameters and return codes

2015-09-22 Thread Brian King
Reviewed-by: Brian King -- Brian King Power Linux I/O IBM Linux Technology Center -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH] storvsc: get rid of homegrown copy_{to,from}_bounce_buffer()

2015-09-22 Thread Christoph Hellwig
On Tue, Sep 22, 2015 at 06:27:50PM +0200, Vitaly Kuznetsov wrote: > Storvsc driver needs to ensure there are no 'holes' in the presented > sg list (all segments in the middle of the list need to be of PAGE_SIZE). I think it should instead set a virt_boundary. That's what we added for the NVMe

Re: [PATCH v2 18/30] cxlflash: Remove dual port online dependency

2015-09-22 Thread Matthew R. Ochs
> On Sep 21, 2015, at 5:02 PM, Brian King wrote: > On 09/16/2015 04:30 PM, Matthew R. Ochs wrote: >> At present, both ports must be online for the device to >> configure properly. Remove this dependency and the unnecessary >> internal LUN override logic as well.

Re: [PATCH v2 23/30] cxlflash: Remove unnecessary scsi_block_requests

2015-09-22 Thread Brian King
Reviewed-by: Brian King -- Brian King Power Linux I/O IBM Linux Technology Center -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH v2 20/30] cxlflash: Correct usage of scsi_host_put()

2015-09-22 Thread Matthew R. Ochs
> On Sep 22, 2015, at 3:53 PM, Brian King wrote: > On 09/16/2015 04:30 PM, Matthew R. Ochs wrote: >> Currently, scsi_host_put() is being called prematurely in the >> remove path and is missing entirely in an error cleanup path. >> The former can lead to memory being

Re: [PATCH 19/23] scsi_dh_alua: Use workqueue for RTPG

2015-09-22 Thread Hannes Reinecke
On 09/22/2015 09:49 PM, Ewan Milne wrote: > On Thu, 2015-08-27 at 14:41 +0200, Hannes Reinecke wrote: >> The current ALUA device_handler has two drawbacks: >> - We're sending a 'SET TARGET PORT GROUP' command to every LUN, >> disregarding the fact that several LUNs might be in a port group >>

Re: [PATCH v2 18/30] cxlflash: Remove dual port online dependency

2015-09-22 Thread Brian King
On 09/22/2015 03:44 PM, Matthew R. Ochs wrote: >> On Sep 21, 2015, at 5:02 PM, Brian King wrote: >> On 09/16/2015 04:30 PM, Matthew R. Ochs wrote: >>> At present, both ports must be online for the device to >>> configure properly. Remove this dependency and the

Re: [RFT v3] eata: Convert eata driver as normal PCI and platform device drivers

2015-09-22 Thread Hannes Reinecke
On 09/22/2015 09:30 AM, Jiang Liu wrote: > Previously the eata driver just grabs and accesses eata PCI devices > without implementing a PCI device driver, that causes troubles with > latest IRQ related > > Commit 991de2e59090 ("PCI, x86: Implement pcibios_alloc_irq() and > pcibios_free_irq()")

Re: [PATCH v2 20/30] cxlflash: Correct usage of scsi_host_put()

2015-09-22 Thread Brian King
On 09/16/2015 04:30 PM, Matthew R. Ochs wrote: > Currently, scsi_host_put() is being called prematurely in the > remove path and is missing entirely in an error cleanup path. > The former can lead to memory being freed too early with > subsequent access potentially corrupting data whilst the

Re: [RFT v3] eata: Convert eata driver as normal PCI and platform device drivers

2015-09-22 Thread Jiang Liu
On 2015/9/23 7:36, Arthur Marsh wrote: > James Bottomley wrote on 23/09/15 08:15: >> On Wed, 2015-09-23 at 07:55 +0930, Arthur Marsh wrote: >> It looks to be some problem in shut down. Can you simply remove and >> re-insert the driver successfully? If it's your root disk driver, >> you'll have

Re: [RFT v3] eata: Convert eata driver as normal PCI and platform device drivers

2015-09-22 Thread Arthur Marsh
Jiang Liu wrote on 22/09/15 17:00: Previously the eata driver just grabs and accesses eata PCI devices without implementing a PCI device driver, that causes troubles with latest IRQ related Commit 991de2e59090 ("PCI, x86: Implement pcibios_alloc_irq() and pcibios_free_irq()") changes the way

Re: [RFT v3] eata: Convert eata driver as normal PCI and platform device drivers

2015-09-22 Thread Arthur Marsh
James Bottomley wrote on 23/09/15 08:15: On Wed, 2015-09-23 at 07:55 +0930, Arthur Marsh wrote: Jiang Liu wrote on 22/09/15 17:00: Previously the eata driver just grabs and accesses eata PCI devices without implementing a PCI device driver, that causes troubles with latest IRQ related

Re: [RFT v3] eata: Convert eata driver as normal PCI and platform device drivers

2015-09-22 Thread James Bottomley
On Wed, 2015-09-23 at 07:55 +0930, Arthur Marsh wrote: > > Jiang Liu wrote on 22/09/15 17:00: > > Previously the eata driver just grabs and accesses eata PCI devices > > without implementing a PCI device driver, that causes troubles with > > latest IRQ related > > > > Commit 991de2e59090 ("PCI,

[Announce] ZDM-Device-Mapper

2015-09-22 Thread Adrian Palmer
All; Seagate is release the much requested device mapper shim for SMR. In response to requests at Linux Plumber's Conference, we've make it available as soon as possible. We've held off releasing it to ensure stability and to remove frustration and reduce bring-up time to other developers who

[RFT v3] eata: Convert eata driver as normal PCI and platform device drivers

2015-09-22 Thread Jiang Liu
Previously the eata driver just grabs and accesses eata PCI devices without implementing a PCI device driver, that causes troubles with latest IRQ related Commit 991de2e59090 ("PCI, x86: Implement pcibios_alloc_irq() and pcibios_free_irq()") changes the way to allocate PCI legacy IRQ for PCI

Re: [patch] cxlflash: a couple off by one bugs

2015-09-22 Thread Manoj Kumar
Reviewed-by: Manoj Kumar --- Manoj Kumar On 9/22/2015 7:32 AM, Dan Carpenter wrote: The "> MAX_CONTEXT" should be ">= MAX_CONTEXT". Otherwise we go one step beyond the end of the cfg->ctx_tbl[] array. Signed-off-by: Dan Carpenter diff

[patch] cxlflash: a couple off by one bugs

2015-09-22 Thread Dan Carpenter
The "> MAX_CONTEXT" should be ">= MAX_CONTEXT". Otherwise we go one step beyond the end of the cfg->ctx_tbl[] array. Signed-off-by: Dan Carpenter diff --git a/drivers/scsi/cxlflash/superpipe.c b/drivers/scsi/cxlflash/superpipe.c index f1b62ce..05e0ecf 100644 ---

Re: [patch] cxlflash: a couple off by one bugs

2015-09-22 Thread Matthew R. Ochs
> On Sep 22, 2015, at 7:32 AM, Dan Carpenter wrote: > > The "> MAX_CONTEXT" should be ">= MAX_CONTEXT". Otherwise we go one > step beyond the end of the cfg->ctx_tbl[] array. Acked-by: Matthew R. Ochs > > Signed-off-by: Dan Carpenter