diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-23 14:13:11 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-23 14:13:11 -0400 |
commit | d4e06701b89286a306b31e20ec69a904fae374a1 (patch) | |
tree | f6adefd65b021ccddb7655109ea8b9ab4e714292 /drivers/scsi/libfc | |
parent | e4980371059ca4a81ccdcb4381c41af8869ca711 (diff) | |
parent | 87045b033a62777337ae4aa62834876da09b5fb5 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (77 commits)
[SCSI] fix crash in scsi_dispatch_cmd()
[SCSI] sr: check_events() ignore GET_EVENT when TUR says otherwise
[SCSI] bnx2i: Fixed kernel panic due to illegal usage of sc->request->cpu
[SCSI] bfa: Update the driver version to 3.0.2.1
[SCSI] bfa: Driver and BSG enhancements.
[SCSI] bfa: Added support to query PHY.
[SCSI] bfa: Added HBA diagnostics support.
[SCSI] bfa: Added support for flash configuration
[SCSI] bfa: Added support to obtain SFP info.
[SCSI] bfa: Added support for CEE info and stats query.
[SCSI] bfa: Extend BSG interface.
[SCSI] bfa: FCS bug fixes.
[SCSI] bfa: DMA memory allocation enhancement.
[SCSI] bfa: Brocade-1860 Fabric Adapter vHBA support.
[SCSI] bfa: Brocade-1860 Fabric Adapter PLL init fixes.
[SCSI] bfa: Added Fabric Assigned Address(FAA) support
[SCSI] bfa: IOC bug fixes.
[SCSI] bfa: Enable ASIC block configuration and query.
[SCSI] bnx2i: Updated copyright and bump version
[SCSI] bnx2i: Modified to skip CNIC registration if iSCSI is not supported
...
Fix up some trivial conflicts in:
- drivers/scsi/bnx2fc/{bnx2fc.h,bnx2fc_fcoe.c}:
Crazy broadcom version number conflicts
- drivers/target/tcm_fc/tfc_cmd.c
Just trivial cleanups done on adjacent lines
Diffstat (limited to 'drivers/scsi/libfc')
-rw-r--r-- | drivers/scsi/libfc/fc_exch.c | 26 | ||||
-rw-r--r-- | drivers/scsi/libfc/fc_lport.c | 2 | ||||
-rw-r--r-- | drivers/scsi/libfc/fc_rport.c | 14 |
3 files changed, 40 insertions, 2 deletions
diff --git a/drivers/scsi/libfc/fc_exch.c b/drivers/scsi/libfc/fc_exch.c index 3b8a6451ea28..f5a0665b6773 100644 --- a/drivers/scsi/libfc/fc_exch.c +++ b/drivers/scsi/libfc/fc_exch.c | |||
@@ -965,8 +965,30 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport, | |||
965 | sp = &ep->seq; | 965 | sp = &ep->seq; |
966 | if (sp->id != fh->fh_seq_id) { | 966 | if (sp->id != fh->fh_seq_id) { |
967 | atomic_inc(&mp->stats.seq_not_found); | 967 | atomic_inc(&mp->stats.seq_not_found); |
968 | reject = FC_RJT_SEQ_ID; /* sequence/exch should exist */ | 968 | if (f_ctl & FC_FC_END_SEQ) { |
969 | goto rel; | 969 | /* |
970 | * Update sequence_id based on incoming last | ||
971 | * frame of sequence exchange. This is needed | ||
972 | * for FCoE target where DDP has been used | ||
973 | * on target where, stack is indicated only | ||
974 | * about last frame's (payload _header) header. | ||
975 | * Whereas "seq_id" which is part of | ||
976 | * frame_header is allocated by initiator | ||
977 | * which is totally different from "seq_id" | ||
978 | * allocated when XFER_RDY was sent by target. | ||
979 | * To avoid false -ve which results into not | ||
980 | * sending RSP, hence write request on other | ||
981 | * end never finishes. | ||
982 | */ | ||
983 | spin_lock_bh(&ep->ex_lock); | ||
984 | sp->ssb_stat |= SSB_ST_RESP; | ||
985 | sp->id = fh->fh_seq_id; | ||
986 | spin_unlock_bh(&ep->ex_lock); | ||
987 | } else { | ||
988 | /* sequence/exch should exist */ | ||
989 | reject = FC_RJT_SEQ_ID; | ||
990 | goto rel; | ||
991 | } | ||
970 | } | 992 | } |
971 | } | 993 | } |
972 | WARN_ON(ep != fc_seq_exch(sp)); | 994 | WARN_ON(ep != fc_seq_exch(sp)); |
diff --git a/drivers/scsi/libfc/fc_lport.c b/drivers/scsi/libfc/fc_lport.c index 389ab80aef0a..e008b1673507 100644 --- a/drivers/scsi/libfc/fc_lport.c +++ b/drivers/scsi/libfc/fc_lport.c | |||
@@ -1025,6 +1025,8 @@ static void fc_lport_enter_reset(struct fc_lport *lport) | |||
1025 | fc_vport_set_state(lport->vport, FC_VPORT_LINKDOWN); | 1025 | fc_vport_set_state(lport->vport, FC_VPORT_LINKDOWN); |
1026 | } | 1026 | } |
1027 | fc_lport_state_enter(lport, LPORT_ST_RESET); | 1027 | fc_lport_state_enter(lport, LPORT_ST_RESET); |
1028 | fc_host_post_event(lport->host, fc_get_event_number(), | ||
1029 | FCH_EVT_LIPRESET, 0); | ||
1028 | fc_vports_linkchange(lport); | 1030 | fc_vports_linkchange(lport); |
1029 | fc_lport_reset_locked(lport); | 1031 | fc_lport_reset_locked(lport); |
1030 | if (lport->link_up) | 1032 | if (lport->link_up) |
diff --git a/drivers/scsi/libfc/fc_rport.c b/drivers/scsi/libfc/fc_rport.c index 01e13a2eb93a..760db7619446 100644 --- a/drivers/scsi/libfc/fc_rport.c +++ b/drivers/scsi/libfc/fc_rport.c | |||
@@ -789,6 +789,20 @@ static void fc_rport_recv_flogi_req(struct fc_lport *lport, | |||
789 | 789 | ||
790 | switch (rdata->rp_state) { | 790 | switch (rdata->rp_state) { |
791 | case RPORT_ST_INIT: | 791 | case RPORT_ST_INIT: |
792 | /* | ||
793 | * If received the FLOGI request on RPORT which is INIT state | ||
794 | * (means not transition to FLOGI either fc_rport timeout | ||
795 | * function didn;t trigger or this end hasn;t received | ||
796 | * beacon yet from other end. In that case only, allow RPORT | ||
797 | * state machine to continue, otherwise fall through which | ||
798 | * causes the code to send reject response. | ||
799 | * NOTE; Not checking for FIP->state such as VNMP_UP or | ||
800 | * VNMP_CLAIM because if FIP state is not one of those, | ||
801 | * RPORT wouldn;t have created and 'rport_lookup' would have | ||
802 | * failed anyway in that case. | ||
803 | */ | ||
804 | if (lport->point_to_multipoint) | ||
805 | break; | ||
792 | case RPORT_ST_DELETE: | 806 | case RPORT_ST_DELETE: |
793 | mutex_unlock(&rdata->rp_mutex); | 807 | mutex_unlock(&rdata->rp_mutex); |
794 | rjt_data.reason = ELS_RJT_FIP; | 808 | rjt_data.reason = ELS_RJT_FIP; |