diff options
| author | Vijaya Mohan Guvva <vmohan@brocade.com> | 2013-11-21 04:37:46 -0500 |
|---|---|---|
| committer | James Bottomley <JBottomley@Parallels.com> | 2013-12-19 10:39:05 -0500 |
| commit | 7593e524254a8e477e28dc662ca27b8b0ab9f1d7 (patch) | |
| tree | 855e14052f19968b92ec460b1ffa57821bdb4d87 /drivers/scsi/bfa | |
| parent | 9781851f47a7fba2013f879f13cfdadfcdc879dc (diff) | |
[SCSI] bfa: Fix for bcu or hcm faa query hang
This patch set fixes the issue of brocade management utility hang
(bcu/HCM) when faa attributes are queried from multiple application
threads. Hang was due to race between the threads and completion handler
corruption.
Signed-off-by: Vijaya Mohan Guvva <vmohan@brocade.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/bfa')
| -rw-r--r-- | drivers/scsi/bfa/bfa_core.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/scsi/bfa/bfa_core.c b/drivers/scsi/bfa/bfa_core.c index 520540a5fef6..e3f67b097a5c 100644 --- a/drivers/scsi/bfa/bfa_core.c +++ b/drivers/scsi/bfa/bfa_core.c | |||
| @@ -1367,10 +1367,6 @@ bfa_faa_query(struct bfa_s *bfa, struct bfa_faa_attr_s *attr, | |||
| 1367 | struct bfa_iocfc_s *iocfc = &bfa->iocfc; | 1367 | struct bfa_iocfc_s *iocfc = &bfa->iocfc; |
| 1368 | bfa_status_t status; | 1368 | bfa_status_t status; |
| 1369 | 1369 | ||
| 1370 | iocfc->faa_args.faa_attr = attr; | ||
| 1371 | iocfc->faa_args.faa_cb.faa_cbfn = cbfn; | ||
| 1372 | iocfc->faa_args.faa_cb.faa_cbarg = cbarg; | ||
| 1373 | |||
| 1374 | status = bfa_faa_validate_request(bfa); | 1370 | status = bfa_faa_validate_request(bfa); |
| 1375 | if (status != BFA_STATUS_OK) | 1371 | if (status != BFA_STATUS_OK) |
| 1376 | return status; | 1372 | return status; |
| @@ -1378,6 +1374,10 @@ bfa_faa_query(struct bfa_s *bfa, struct bfa_faa_attr_s *attr, | |||
| 1378 | if (iocfc->faa_args.busy == BFA_TRUE) | 1374 | if (iocfc->faa_args.busy == BFA_TRUE) |
| 1379 | return BFA_STATUS_DEVBUSY; | 1375 | return BFA_STATUS_DEVBUSY; |
| 1380 | 1376 | ||
| 1377 | iocfc->faa_args.faa_attr = attr; | ||
| 1378 | iocfc->faa_args.faa_cb.faa_cbfn = cbfn; | ||
| 1379 | iocfc->faa_args.faa_cb.faa_cbarg = cbarg; | ||
| 1380 | |||
| 1381 | iocfc->faa_args.busy = BFA_TRUE; | 1381 | iocfc->faa_args.busy = BFA_TRUE; |
| 1382 | memset(&faa_attr_req, 0, sizeof(struct bfi_faa_query_s)); | 1382 | memset(&faa_attr_req, 0, sizeof(struct bfi_faa_query_s)); |
| 1383 | bfi_h2i_set(faa_attr_req.mh, BFI_MC_IOCFC, | 1383 | bfi_h2i_set(faa_attr_req.mh, BFI_MC_IOCFC, |
