diff options
author | Vasundhara Volam <vasundhara-v.volam@broadcom.com> | 2019-10-31 15:38:52 +0530 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-10-31 11:00:45 -0700 |
commit | 0b0eacf3c83cb292c6eef55c76d5138c9302dc20 (patch) | |
tree | 35702cf48794ab0ee813bdd6cba1d8c3585a86e4 /drivers/net/ethernet/broadcom/bnxt/bnxt.h | |
parent | bnxt_en: Add support to invoke OP-TEE API to reset firmware (diff) | |
download | linux-dev-0b0eacf3c83cb292c6eef55c76d5138c9302dc20.tar.xz linux-dev-0b0eacf3c83cb292c6eef55c76d5138c9302dc20.zip |
bnxt_en: Add support to collect crash dump via ethtool
Driver supports 2 types of core dumps.
1. Live dump - Firmware dump when system is up and running.
2. Crash dump - Dump which is collected during firmware crash
that can be retrieved after recovery.
Crash dump is currently supported only on specific 58800 chips
which can be retrieved using OP-TEE API only, as firmware cannot
access this region directly.
User needs to set the dump flag using following command before
initiating the dump collection:
$ ethtool -W|--set-dump eth0 N
Where N is "0" for live dump and "1" for crash dump
Command to collect the dump after setting the flag:
$ ethtool -w eth0 data Filename
v3: Modify set_dump to support even when CONFIG_TEE_BNXT_FW=n.
Also change log message to netdev_info().
Cc: Jakub Kicinski <jakub.kicinski@netronome.com>
Cc: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: Vasundhara Volam <vasundhara-v.volam@broadcom.com>
Signed-off-by: Sheetal Tigadoli <sheetal.tigadoli@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnxt/bnxt.h')
-rw-r--r-- | drivers/net/ethernet/broadcom/bnxt/bnxt.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.h b/drivers/net/ethernet/broadcom/bnxt/bnxt.h index 09437150f818..3e7d1fb1b0b1 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.h +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.h @@ -1807,6 +1807,9 @@ struct bnxt { u8 num_leds; struct bnxt_led_info leds[BNXT_MAX_LED]; + u16 dump_flag; +#define BNXT_DUMP_LIVE 0 +#define BNXT_DUMP_CRASH 1 struct bpf_prog *xdp_prog; |