diff options
author | Krishna Gudipati <kgudipat@brocade.com> | 2010-03-05 22:36:19 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-03-07 02:28:59 -0500 |
commit | 738c9e66dcb7e17a962a7d65c976386b970d10ca (patch) | |
tree | b45a592df452039b14ab9e5cafbb983961c62cfe /drivers | |
parent | f926a05f5c1507aeae0e36175a03c0a19c201187 (diff) |
[SCSI] bfa: Added firmware save clear feature for BFA driver.
Signed-off-by: Krishna Gudipati <kgudipat@brocade.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/bfa/bfa_core.c | 9 | ||||
-rw-r--r-- | drivers/scsi/bfa/bfa_ioc.c | 10 | ||||
-rw-r--r-- | drivers/scsi/bfa/bfa_ioc.h | 1 | ||||
-rw-r--r-- | drivers/scsi/bfa/include/bfa.h | 1 |
4 files changed, 20 insertions, 1 deletions
diff --git a/drivers/scsi/bfa/bfa_core.c b/drivers/scsi/bfa/bfa_core.c index 72e3f2f63b2e..0c08e185a766 100644 --- a/drivers/scsi/bfa/bfa_core.c +++ b/drivers/scsi/bfa/bfa_core.c | |||
@@ -385,6 +385,15 @@ bfa_debug_fwsave(struct bfa_s *bfa, void *trcdata, int *trclen) | |||
385 | } | 385 | } |
386 | 386 | ||
387 | /** | 387 | /** |
388 | * Clear the saved firmware trace information of an IOC. | ||
389 | */ | ||
390 | void | ||
391 | bfa_debug_fwsave_clear(struct bfa_s *bfa) | ||
392 | { | ||
393 | bfa_ioc_debug_fwsave_clear(&bfa->ioc); | ||
394 | } | ||
395 | |||
396 | /** | ||
388 | * Fetch firmware trace data. | 397 | * Fetch firmware trace data. |
389 | * | 398 | * |
390 | * @param[in] bfa BFA instance | 399 | * @param[in] bfa BFA instance |
diff --git a/drivers/scsi/bfa/bfa_ioc.c b/drivers/scsi/bfa/bfa_ioc.c index 8a6361cf2439..0019ff7359db 100644 --- a/drivers/scsi/bfa/bfa_ioc.c +++ b/drivers/scsi/bfa/bfa_ioc.c | |||
@@ -1488,7 +1488,6 @@ return (auto_recover) ? BFA_DBG_FWTRC_LEN : 0; | |||
1488 | void | 1488 | void |
1489 | bfa_ioc_debug_memclaim(struct bfa_ioc_s *ioc, void *dbg_fwsave) | 1489 | bfa_ioc_debug_memclaim(struct bfa_ioc_s *ioc, void *dbg_fwsave) |
1490 | { | 1490 | { |
1491 | bfa_assert(ioc->auto_recover); | ||
1492 | ioc->dbg_fwsave = dbg_fwsave; | 1491 | ioc->dbg_fwsave = dbg_fwsave; |
1493 | ioc->dbg_fwsave_len = bfa_ioc_debug_trcsz(ioc->auto_recover); | 1492 | ioc->dbg_fwsave_len = bfa_ioc_debug_trcsz(ioc->auto_recover); |
1494 | } | 1493 | } |
@@ -1925,6 +1924,15 @@ bfa_ioc_debug_fwsave(struct bfa_ioc_s *ioc, void *trcdata, int *trclen) | |||
1925 | } | 1924 | } |
1926 | 1925 | ||
1927 | /** | 1926 | /** |
1927 | * Clear saved firmware trace | ||
1928 | */ | ||
1929 | void | ||
1930 | bfa_ioc_debug_fwsave_clear(struct bfa_ioc_s *ioc) | ||
1931 | { | ||
1932 | ioc->dbg_fwsave_once = BFA_TRUE; | ||
1933 | } | ||
1934 | |||
1935 | /** | ||
1928 | * Retrieve saved firmware trace from a prior IOC failure. | 1936 | * Retrieve saved firmware trace from a prior IOC failure. |
1929 | */ | 1937 | */ |
1930 | bfa_status_t | 1938 | bfa_status_t |
diff --git a/drivers/scsi/bfa/bfa_ioc.h b/drivers/scsi/bfa/bfa_ioc.h index 853cc3136f0e..4b73efad1ee5 100644 --- a/drivers/scsi/bfa/bfa_ioc.h +++ b/drivers/scsi/bfa/bfa_ioc.h | |||
@@ -270,6 +270,7 @@ int bfa_ioc_debug_trcsz(bfa_boolean_t auto_recover); | |||
270 | void bfa_ioc_debug_memclaim(struct bfa_ioc_s *ioc, void *dbg_fwsave); | 270 | void bfa_ioc_debug_memclaim(struct bfa_ioc_s *ioc, void *dbg_fwsave); |
271 | bfa_status_t bfa_ioc_debug_fwsave(struct bfa_ioc_s *ioc, void *trcdata, | 271 | bfa_status_t bfa_ioc_debug_fwsave(struct bfa_ioc_s *ioc, void *trcdata, |
272 | int *trclen); | 272 | int *trclen); |
273 | void bfa_ioc_debug_fwsave_clear(struct bfa_ioc_s *ioc); | ||
273 | bfa_status_t bfa_ioc_debug_fwtrc(struct bfa_ioc_s *ioc, void *trcdata, | 274 | bfa_status_t bfa_ioc_debug_fwtrc(struct bfa_ioc_s *ioc, void *trcdata, |
274 | int *trclen); | 275 | int *trclen); |
275 | u32 bfa_ioc_smem_pgnum(struct bfa_ioc_s *ioc, u32 fmaddr); | 276 | u32 bfa_ioc_smem_pgnum(struct bfa_ioc_s *ioc, u32 fmaddr); |
diff --git a/drivers/scsi/bfa/include/bfa.h b/drivers/scsi/bfa/include/bfa.h index 942ae64038c9..17654cae0c75 100644 --- a/drivers/scsi/bfa/include/bfa.h +++ b/drivers/scsi/bfa/include/bfa.h | |||
@@ -172,6 +172,7 @@ void bfa_timer_tick(struct bfa_s *bfa); | |||
172 | */ | 172 | */ |
173 | bfa_status_t bfa_debug_fwtrc(struct bfa_s *bfa, void *trcdata, int *trclen); | 173 | bfa_status_t bfa_debug_fwtrc(struct bfa_s *bfa, void *trcdata, int *trclen); |
174 | bfa_status_t bfa_debug_fwsave(struct bfa_s *bfa, void *trcdata, int *trclen); | 174 | bfa_status_t bfa_debug_fwsave(struct bfa_s *bfa, void *trcdata, int *trclen); |
175 | void bfa_debug_fwsave_clear(struct bfa_s *bfa); | ||
175 | 176 | ||
176 | #include "bfa_priv.h" | 177 | #include "bfa_priv.h" |
177 | 178 | ||