From: Muneendra Kumar M <muneendra.kumar@broadcom.com>
To: Mike Christie <michael.christie@oracle.com>,
linux-scsi@vger.kernel.org, hare@suse.de
Cc: jsmart2021@gmail.com, emilne@redhat.com, mkumar@redhat.com
Subject: RE: [patch v4 4/5] scsi_transport_fc: Added a new rport state FC_PORTSTATE_MARGINAL
Date: Thu, 29 Oct 2020 22:26:39 +0530 [thread overview]
Message-ID: <16b1982432ed23ef646130c94ed1e9db@mail.gmail.com> (raw)
In-Reply-To: <49b9b97c-bf84-e9ac-3b74-ffbf3352e2d5@oracle.com>
[-- Attachment #1: Type: text/plain, Size: 2457 bytes --]
Hi Mike,
> [Muneendra] I have to make sure the flag is set after the check for
> blocked state. If blocked, it's returning BLK_EH_RESET_TIMER, so it
> will restart the eh timer. The io will "sit out" like this, pending,
> until either the adapter fails it back due to logout or io completion,
> or fastio fail or rport devloss timesout and invokes the abort handler
> to force abort .
>Hey,
>I'm not sure if we are talking about the same thing. If port state is
>marginal above, then we set the NORETRIES bit then return BLK_EH_DONE which
>will start up the scsi eh_abort_handler and if that fails the rest of the
>scsi >eh_*_handlers.
>While we are calling the eh handlers, if the driver does a
>fc_remote_port_delete then fc_remote_port_add we still have the NORETRIES
>bit set, so when we return from the eh_*_handlers we will fail the IO
>upwards.
>I was trying to ask if you wanted the IO failed upwards in that case.
>Because the port state went to online, did you want the normal (cleared
>NOTRIES bit) cmd retry behavior? It sounds like below you want the cleared
>NORETRIED bit behavior, right?
[Muneendra]Yes we need the normal cmd behavior(clear noretries bit) when the
portstate went to normal.
I think to achieve this we can clear the noretries bit in fc_block_scsi_eh/
fc_block_rport .
As this is the last place where the individual abort_handler checks for
blocked state. Is this fine?
Regards,
Muneendra.
>
>> + (rport->port_state != FC_PORTSTATE_MARGINAL)) {
>> spin_unlock_irqrestore(shost->host_lock, flags);
>> return;
>
>> It looks like if fc_remote_port_delete is called, then we will allow
>> that function to set the port_state to blocked. If the problem is
>> resolved then fc_remote_port_add will set the state to online. So it
>> would look like the port state is >now ok in the kernel, but would
>> userspace still have it in the marginal port group?
>
>> Did you want this behavior or did you want it to stay in marginal
>> until your daemon marks it as online?
> [Muneendra] We need this behavior.User daemon should not depend on the
> rport_state to move a path from marginal path
> group.It should only depends on RSCN and LINKUP events/manual
> intervention. events that we look out (rscn for target-side cable
> bounces and link up/down for initiator cable bounces) will result in
> port state changes - so although we don't drive one from the other,
> they are correlated.
>
> Regards,
> Muneendra.
>
[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4177 bytes --]
next prev parent reply other threads:[~2020-10-29 16:56 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-22 12:34 [patch v4 0/5] scsi: Support to handle Intermittent errors Muneendra
2020-10-22 12:34 ` [patch v4 1/5] scsi: Added a new definition in scsi_cmnd.h Muneendra
2020-10-22 12:34 ` [patch v4 2/5] scsi: Added a new error code in scsi.h Muneendra
2020-10-26 11:45 ` Ewan D. Milne
2020-10-26 20:24 ` Muneendra Kumar M
2020-10-22 12:34 ` [patch v4 3/5] scsi: No retries on abort success Muneendra
2020-10-22 12:34 ` [patch v4 4/5] scsi_transport_fc: Added a new rport state FC_PORTSTATE_MARGINAL Muneendra
2020-10-26 11:48 ` Ewan D. Milne
2020-10-26 20:24 ` Muneendra Kumar M
2020-10-26 17:14 ` Mike Christie
2020-10-29 11:53 ` Muneendra Kumar M
2020-10-29 16:20 ` Mike Christie
2020-10-29 16:56 ` Muneendra Kumar M [this message]
2020-10-22 12:34 ` [patch v4 5/5] scsi_transport_fc: Added store fucntionality to set the rport port_state using sysfs Muneendra
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=16b1982432ed23ef646130c94ed1e9db@mail.gmail.com \
--to=muneendra.kumar@broadcom.com \
--cc=emilne@redhat.com \
--cc=hare@suse.de \
--cc=jsmart2021@gmail.com \
--cc=linux-scsi@vger.kernel.org \
--cc=michael.christie@oracle.com \
--cc=mkumar@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.