linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] scsi_dh_alua: Enable STPG for unavailable ports
@ 2012-08-24  9:08 Bart Van Assche
  2012-08-24 16:37 ` Michael Christie
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Bart Van Assche @ 2012-08-24  9:08 UTC (permalink / raw)
  To: linux-scsi, Hannes Reinecke, Mike Christie, Mike Snitzer,
	Babu Moger

A quote from SPC-4: "While in the unavailable primary target port
asymmetric access state, the device server shall support those of
the following commands that it supports while in the active/optimized
state: [ ... ] d) SET TARGET PORT GROUPS; [ ... ]". Hence enable
sending STPG to a target port group that is in the unavailable state.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Cc: Hannes Reinecke <hare@suse.de>
Cc: Mike Christie <michaelc@cs.wisc.edu>
Cc: Mike Snitzer <snitzer@redhat.com>
Cc: Babu Moger <babu.moger@netapp.com>
Cc: <stable@vger.kernel.org>
---
 drivers/scsi/device_handler/scsi_dh_alua.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c b/drivers/scsi/device_handler/scsi_dh_alua.c
index 08d80a6..a05d469 100644
--- a/drivers/scsi/device_handler/scsi_dh_alua.c
+++ b/drivers/scsi/device_handler/scsi_dh_alua.c
@@ -641,8 +641,7 @@ static int alua_rtpg(struct scsi_device *sdev, struct alua_dh_data *h)
 		h->state = TPGS_STATE_STANDBY;
 		break;
 	case TPGS_STATE_OFFLINE:
-	case TPGS_STATE_UNAVAILABLE:
-		/* Path unusable for unavailable/offline */
+		/* Path unusable */
 		err = SCSI_DH_DEV_OFFLINED;
 		break;
 	default:
-- 
1.7.7


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] scsi_dh_alua: Enable STPG for unavailable ports
  2012-08-24  9:08 [PATCH] scsi_dh_alua: Enable STPG for unavailable ports Bart Van Assche
@ 2012-08-24 16:37 ` Michael Christie
  2012-09-19 15:49 ` Mike Christie
  2012-09-19 17:36 ` Mike Snitzer
  2 siblings, 0 replies; 5+ messages in thread
From: Michael Christie @ 2012-08-24 16:37 UTC (permalink / raw)
  To: Bart Van Assche; +Cc: linux-scsi, Hannes Reinecke, Mike Snitzer, Babu Moger


On Aug 24, 2012, at 4:08 AM, Bart Van Assche <bvanassche@acm.org> wrote:
> diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c b/drivers/scsi/device_handler/scsi_dh_alua.c
> index 08d80a6..a05d469 100644
> --- a/drivers/scsi/device_handler/scsi_dh_alua.c
> +++ b/drivers/scsi/device_handler/scsi_dh_alua.c
> @@ -641,8 +641,7 @@ static int alua_rtpg(struct scsi_device *sdev, struct alua_dh_data *h)
> 		h->state = TPGS_STATE_STANDBY;
> 		break;
> 	case TPGS_STATE_OFFLINE:
> -	case TPGS_STATE_UNAVAILABLE:
> -		/* Path unusable for unavailable/offline */
> +		/* Path unusable */
> 		err = SCSI_DH_DEV_OFFLINED;
> 		break;
> 	default:

We must not have tested unavailable state very much. 3rd bug in a short time. Looks ok to me.

Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] scsi_dh_alua: Enable STPG for unavailable ports
  2012-08-24  9:08 [PATCH] scsi_dh_alua: Enable STPG for unavailable ports Bart Van Assche
  2012-08-24 16:37 ` Michael Christie
@ 2012-09-19 15:49 ` Mike Christie
  2012-09-20  5:28   ` Hannes Reinecke
  2012-09-19 17:36 ` Mike Snitzer
  2 siblings, 1 reply; 5+ messages in thread
From: Mike Christie @ 2012-09-19 15:49 UTC (permalink / raw)
  To: Bart Van Assche; +Cc: linux-scsi, Hannes Reinecke, Mike Snitzer, Babu Moger

On 08/24/2012 04:08 AM, Bart Van Assche wrote:
> A quote from SPC-4: "While in the unavailable primary target port
> asymmetric access state, the device server shall support those of
> the following commands that it supports while in the active/optimized
> state: [ ... ] d) SET TARGET PORT GROUPS; [ ... ]". Hence enable
> sending STPG to a target port group that is in the unavailable state.
> 
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> Cc: Hannes Reinecke <hare@suse.de>
> Cc: Mike Christie <michaelc@cs.wisc.edu>
> Cc: Mike Snitzer <snitzer@redhat.com>
> Cc: Babu Moger <babu.moger@netapp.com>
> Cc: <stable@vger.kernel.org>
> ---
>  drivers/scsi/device_handler/scsi_dh_alua.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c b/drivers/scsi/device_handler/scsi_dh_alua.c
> index 08d80a6..a05d469 100644
> --- a/drivers/scsi/device_handler/scsi_dh_alua.c
> +++ b/drivers/scsi/device_handler/scsi_dh_alua.c
> @@ -641,8 +641,7 @@ static int alua_rtpg(struct scsi_device *sdev, struct alua_dh_data *h)
>  		h->state = TPGS_STATE_STANDBY;
>  		break;
>  	case TPGS_STATE_OFFLINE:
> -	case TPGS_STATE_UNAVAILABLE:
> -		/* Path unusable for unavailable/offline */
> +		/* Path unusable */
>  		err = SCSI_DH_DEV_OFFLINED;
>  		break;
>  	default:
> 

Hey, was this patch ok Hannes and James and others?

I see bb2c94a3a6ad37fe7d34f369295bcdf5387e264f was merged, but this one
was not.

I was thinking this might have got missed because it has the same patch
description as  bb2c94a3a6ad37fe7d34f369295bcdf5387e264f, so it is
confusion, but they are different patches. One fixes alua_rtpg and one
fixes alua_activate, but both are needed.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: scsi_dh_alua: Enable STPG for unavailable ports
  2012-08-24  9:08 [PATCH] scsi_dh_alua: Enable STPG for unavailable ports Bart Van Assche
  2012-08-24 16:37 ` Michael Christie
  2012-09-19 15:49 ` Mike Christie
@ 2012-09-19 17:36 ` Mike Snitzer
  2 siblings, 0 replies; 5+ messages in thread
From: Mike Snitzer @ 2012-09-19 17:36 UTC (permalink / raw)
  To: Bart Van Assche; +Cc: linux-scsi, Hannes Reinecke, Mike Christie, Babu Moger

On Fri, Aug 24 2012 at  5:08am -0400,
Bart Van Assche <bvanassche@acm.org> wrote:

> A quote from SPC-4: "While in the unavailable primary target port
> asymmetric access state, the device server shall support those of
> the following commands that it supports while in the active/optimized
> state: [ ... ] d) SET TARGET PORT GROUPS; [ ... ]". Hence enable
> sending STPG to a target port group that is in the unavailable state.
> 
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> Cc: Hannes Reinecke <hare@suse.de>
> Cc: Mike Christie <michaelc@cs.wisc.edu>
> Cc: Mike Snitzer <snitzer@redhat.com>
> Cc: Babu Moger <babu.moger@netapp.com>
> Cc: <stable@vger.kernel.org>

Looks good to me.

Acked-by: Mike Snitzer <snitzer@redhat.com>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] scsi_dh_alua: Enable STPG for unavailable ports
  2012-09-19 15:49 ` Mike Christie
@ 2012-09-20  5:28   ` Hannes Reinecke
  0 siblings, 0 replies; 5+ messages in thread
From: Hannes Reinecke @ 2012-09-20  5:28 UTC (permalink / raw)
  To: Mike Christie; +Cc: Bart Van Assche, linux-scsi, Mike Snitzer, Babu Moger

On 09/19/2012 05:49 PM, Mike Christie wrote:
> On 08/24/2012 04:08 AM, Bart Van Assche wrote:
>> A quote from SPC-4: "While in the unavailable primary target port
>> asymmetric access state, the device server shall support those of
>> the following commands that it supports while in the active/optimized
>> state: [ ... ] d) SET TARGET PORT GROUPS; [ ... ]". Hence enable
>> sending STPG to a target port group that is in the unavailable state.
>>
>> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
>> Cc: Hannes Reinecke <hare@suse.de>
>> Cc: Mike Christie <michaelc@cs.wisc.edu>
>> Cc: Mike Snitzer <snitzer@redhat.com>
>> Cc: Babu Moger <babu.moger@netapp.com>
>> Cc: <stable@vger.kernel.org>
>> ---
>>  drivers/scsi/device_handler/scsi_dh_alua.c |    3 +--
>>  1 files changed, 1 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c b/drivers/scsi/device_handler/scsi_dh_alua.c
>> index 08d80a6..a05d469 100644
>> --- a/drivers/scsi/device_handler/scsi_dh_alua.c
>> +++ b/drivers/scsi/device_handler/scsi_dh_alua.c
>> @@ -641,8 +641,7 @@ static int alua_rtpg(struct scsi_device *sdev, struct alua_dh_data *h)
>>  		h->state = TPGS_STATE_STANDBY;
>>  		break;
>>  	case TPGS_STATE_OFFLINE:
>> -	case TPGS_STATE_UNAVAILABLE:
>> -		/* Path unusable for unavailable/offline */
>> +		/* Path unusable */
>>  		err = SCSI_DH_DEV_OFFLINED;
>>  		break;
>>  	default:
>>
> 
> Hey, was this patch ok Hannes and James and others?
> 
> I see bb2c94a3a6ad37fe7d34f369295bcdf5387e264f was merged, but this one
> was not.
> 
> I was thinking this might have got missed because it has the same patch
> description as  bb2c94a3a6ad37fe7d34f369295bcdf5387e264f, so it is
> confusion, but they are different patches. One fixes alua_rtpg and one
> fixes alua_activate, but both are needed.
> 
Yeah, patch's okay.

Acked-by: Hannes Reinecke <hare@suse.de>

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		      zSeries & Storage
hare@suse.de			      +49 911 74053 688
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: J. Hawn, J. Guild, F. Imendörffer, HRB 16746 (AG Nürnberg)


--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-09-20  5:28 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-24  9:08 [PATCH] scsi_dh_alua: Enable STPG for unavailable ports Bart Van Assche
2012-08-24 16:37 ` Michael Christie
2012-09-19 15:49 ` Mike Christie
2012-09-20  5:28   ` Hannes Reinecke
2012-09-19 17:36 ` Mike Snitzer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).