diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/libfc/fc_exch.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/scsi/libfc/fc_exch.c b/drivers/scsi/libfc/fc_exch.c index 744fefe81341..d261e982a2fa 100644 --- a/drivers/scsi/libfc/fc_exch.c +++ b/drivers/scsi/libfc/fc_exch.c | |||
@@ -1981,6 +1981,7 @@ static struct fc_seq *fc_exch_seq_send(struct fc_lport *lport, | |||
1981 | struct fc_exch *ep; | 1981 | struct fc_exch *ep; |
1982 | struct fc_seq *sp = NULL; | 1982 | struct fc_seq *sp = NULL; |
1983 | struct fc_frame_header *fh; | 1983 | struct fc_frame_header *fh; |
1984 | struct fc_fcp_pkt *fsp = NULL; | ||
1984 | int rc = 1; | 1985 | int rc = 1; |
1985 | 1986 | ||
1986 | ep = fc_exch_alloc(lport, fp); | 1987 | ep = fc_exch_alloc(lport, fp); |
@@ -2003,8 +2004,10 @@ static struct fc_seq *fc_exch_seq_send(struct fc_lport *lport, | |||
2003 | fc_exch_setup_hdr(ep, fp, ep->f_ctl); | 2004 | fc_exch_setup_hdr(ep, fp, ep->f_ctl); |
2004 | sp->cnt++; | 2005 | sp->cnt++; |
2005 | 2006 | ||
2006 | if (ep->xid <= lport->lro_xid && fh->fh_r_ctl == FC_RCTL_DD_UNSOL_CMD) | 2007 | if (ep->xid <= lport->lro_xid && fh->fh_r_ctl == FC_RCTL_DD_UNSOL_CMD) { |
2008 | fsp = fr_fsp(fp); | ||
2007 | fc_fcp_ddp_setup(fr_fsp(fp), ep->xid); | 2009 | fc_fcp_ddp_setup(fr_fsp(fp), ep->xid); |
2010 | } | ||
2008 | 2011 | ||
2009 | if (unlikely(lport->tt.frame_send(lport, fp))) | 2012 | if (unlikely(lport->tt.frame_send(lport, fp))) |
2010 | goto err; | 2013 | goto err; |
@@ -2018,7 +2021,8 @@ static struct fc_seq *fc_exch_seq_send(struct fc_lport *lport, | |||
2018 | spin_unlock_bh(&ep->ex_lock); | 2021 | spin_unlock_bh(&ep->ex_lock); |
2019 | return sp; | 2022 | return sp; |
2020 | err: | 2023 | err: |
2021 | fc_fcp_ddp_done(fr_fsp(fp)); | 2024 | if (fsp) |
2025 | fc_fcp_ddp_done(fsp); | ||
2022 | rc = fc_exch_done_locked(ep); | 2026 | rc = fc_exch_done_locked(ep); |
2023 | spin_unlock_bh(&ep->ex_lock); | 2027 | spin_unlock_bh(&ep->ex_lock); |
2024 | if (!rc) | 2028 | if (!rc) |