]> git.baikalelectronics.ru Git - kernel.git/commitdiff
ionic: add new bad firmware error code
authorShannon Nelson <snelson@pensando.io>
Thu, 1 Oct 2020 16:22:46 +0000 (09:22 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 2 Oct 2020 23:30:01 +0000 (16:30 -0700)
If the new firmware image downladed for update is corrupted
or is a bad format, the download process will report a status
code specifically for that.

Signed-off-by: Shannon Nelson <snelson@pensando.io>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/pensando/ionic/ionic_if.h
drivers/net/ethernet/pensando/ionic/ionic_main.c

index 5bb56a27a50d600f43da8a5a5b42501cb8bb34ec..31ccfcdc2b0a45381c1d3ccdbc8abbfb054c722e 100644 (file)
@@ -96,6 +96,7 @@ enum ionic_status_code {
        IONIC_RC_ERROR          = 29,   /* Generic error */
        IONIC_RC_ERDMA          = 30,   /* Generic RDMA error */
        IONIC_RC_EVFID          = 31,   /* VF ID does not exist */
+       IONIC_RC_EBAD_FW        = 32,   /* FW file is invalid or corrupted */
 };
 
 enum ionic_notifyq_opcode {
index c21195be59e18d00c3faaea820a9590b8e11ac30..ee0740881af31cd5512839a1a96cf420715d396f 100644 (file)
@@ -64,6 +64,8 @@ static const char *ionic_error_to_str(enum ionic_status_code code)
                return "IONIC_RC_ERROR";
        case IONIC_RC_ERDMA:
                return "IONIC_RC_ERDMA";
+       case IONIC_RC_EBAD_FW:
+               return "IONIC_RC_EBAD_FW";
        default:
                return "IONIC_RC_UNKNOWN";
        }