[PATCH] nvme/fc: Short-circuit reconnect retries
Hannes Reinecke
hare at suse.de
Sat May 22 02:48:47 PDT 2021
On 5/21/21 10:17 PM, Sagi Grimberg wrote:
>
>> if (recon && nvmf_should_reconnect(&ctrl->ctrl)) {
>> @@ -3286,12 +3290,17 @@ nvme_fc_reconnect_or_delete(struct
>> nvme_fc_ctrl *ctrl, int status)
>> queue_delayed_work(nvme_wq, &ctrl->connect_work, recon_delay);
>> } else {
>> - if (portptr->port_state == FC_OBJSTATE_ONLINE)
>> - dev_warn(ctrl->ctrl.device,
>> - "NVME-FC{%d}: Max reconnect attempts (%d) "
>> - "reached.\n",
>> - ctrl->cnum, ctrl->ctrl.nr_reconnects);
>> - else
>> + if (portptr->port_state == FC_OBJSTATE_ONLINE) {
>> + if (status > 0 && (status & NVME_SC_DNR))
>> + dev_warn(ctrl->ctrl.device,
>> + "NVME-FC{%d}: reconnect failure\n",
>
> Maybe worth to print the status here?
>
> Otherwise looks good,
> Reviewed-by: Sagi Grimberg <sagi at grimberg.me>
No need, as it's already printed by the previous message some lines
above this code :-)
Cheers,
Hannes
--
Dr. Hannes Reinecke Kernel Storage Architect
hare at suse.de +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer
More information about the Linux-nvme
mailing list