• Edwin Peer's avatar
    bnxt_en: don't fake firmware response success when PCI is disabled · a2f3835c
    Edwin Peer authored
    The original intent here is to allow commands during reset to succeed
    without error when the device is disabled, to ensure that cleanup
    completes normally during NIC close, where firmware is not necessarily
    expected to respond.
    
    The problem with faking success during reset's PCI disablement is that
    unrelated ULP commands will also see inadvertent success during reset
    when failure would otherwise be appropriate. It is better to return
    a different error result such that reset related code can detect
    this unique condition and ignore as appropriate.
    
    Note, the pci_disable_device() when firmware is fatally wounded in
    bnxt_fw_reset_close() does not need to be addressed, as subsequent
    commands are already expected to fail due to the BNXT_NO_FW_ACCESS()
    check in bnxt_hwrm_do_send_msg().
    Reviewed-by: default avatarScott Branden <scott.branden@broadcom.com>
    Signed-off-by: default avatarEdwin Peer <edwin.peer@broadcom.com>
    Signed-off-by: default avatarMichael Chan <michael.chan@broadcom.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    a2f3835c
bnxt.c 350 KB