Patch "ionic: Correctly print AQ errors if completions aren't received" has been added to the 5.17-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    ionic: Correctly print AQ errors if completions aren't received

to the 5.17-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     ionic-correctly-print-aq-errors-if-completions-aren-.patch
and it can be found in the queue-5.17 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit beb5126d869b637189208a49f2308d3d525c1d25
Author: Brett Creeley <brett@xxxxxxxxxxx>
Date:   Mon Jan 24 10:53:04 2022 -0800

    ionic: Correctly print AQ errors if completions aren't received
    
    [ Upstream commit bc43ed4f35abfdb1d52311110d49b545fccce975 ]
    
    Recent changes went into the driver to allow flexibility when
    printing error messages. Unfortunately this had the unexpected
    consequence of printing confusing messages like the following:
    
    IONIC_CMD_RX_FILTER_ADD (31) failed: IONIC_RC_SUCCESS (-6)
    
    In cases like this the completion of the admin queue command never
    completes, so the completion status is 0, hence IONIC_RC_SUCCESS
    is printed even though the command clearly failed. For example,
    this could happen when the driver tries to add a filter and at
    the same time the FW goes through a reset, so the AQ command
    never completes.
    
    Fix this by forcing the FW completion status to IONIC_RC_ERROR
    in cases where we never get the completion.
    
    Fixes: 8c9d956ab6fb ("ionic: allow adminq requests to override default error message")
    Signed-off-by: Brett Creeley <brett@xxxxxxxxxxx>
    Signed-off-by: Shannon Nelson <snelson@xxxxxxxxxxx>
    Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/net/ethernet/pensando/ionic/ionic_main.c b/drivers/net/ethernet/pensando/ionic/ionic_main.c
index 2e4294a4fa83..a0f9136b2d89 100644
--- a/drivers/net/ethernet/pensando/ionic/ionic_main.c
+++ b/drivers/net/ethernet/pensando/ionic/ionic_main.c
@@ -322,6 +322,7 @@ int ionic_adminq_wait(struct ionic_lif *lif, struct ionic_admin_ctx *ctx,
 		if (do_msg && !test_bit(IONIC_LIF_F_FW_RESET, lif->state))
 			netdev_err(netdev, "Posting of %s (%d) failed: %d\n",
 				   name, ctx->cmd.cmd.opcode, err);
+		ctx->comp.comp.status = IONIC_RC_ERROR;
 		return err;
 	}
 
@@ -340,6 +341,7 @@ int ionic_adminq_wait(struct ionic_lif *lif, struct ionic_admin_ctx *ctx,
 			if (do_msg)
 				netdev_err(netdev, "%s (%d) interrupted, FW in reset\n",
 					   name, ctx->cmd.cmd.opcode);
+			ctx->comp.comp.status = IONIC_RC_ERROR;
 			return -ENXIO;
 		}
 



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux