diff options
author | Joe Eykholt <jeykholt@cisco.com> | 2009-08-25 17:02:49 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2009-09-10 13:07:53 -0400 |
commit | 29d898e909e3d086055e2649f5a24d4c2c1ca884 (patch) | |
tree | bfd57b880623777caa37fadfe75d1d8d8011ef93 /drivers/scsi/libfc/fc_lport.c | |
parent | 81a67b9717d9e4f81bed7d1f2df6ba86aaab9ad9 (diff) |
[SCSI] libfc: clean up point-to-point discovery code.
The discovery code had a special-case for the point-to-point mode,
which used a bunch of code that wasn't really needed.
Now that rport_create adds the rport to the discovery list,
completely skip discovery for the point-to-point case.
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/libfc/fc_lport.c')
-rw-r--r-- | drivers/scsi/libfc/fc_lport.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/drivers/scsi/libfc/fc_lport.c b/drivers/scsi/libfc/fc_lport.c index f33e5732e3fc..7000df573691 100644 --- a/drivers/scsi/libfc/fc_lport.c +++ b/drivers/scsi/libfc/fc_lport.c | |||
@@ -708,7 +708,8 @@ static void fc_lport_enter_ready(struct fc_lport *lport) | |||
708 | 708 | ||
709 | fc_lport_state_enter(lport, LPORT_ST_READY); | 709 | fc_lport_state_enter(lport, LPORT_ST_READY); |
710 | 710 | ||
711 | lport->tt.disc_start(fc_lport_disc_callback, lport); | 711 | if (!lport->ptp_rp) |
712 | lport->tt.disc_start(fc_lport_disc_callback, lport); | ||
712 | } | 713 | } |
713 | 714 | ||
714 | /** | 715 | /** |
@@ -794,8 +795,6 @@ static void fc_lport_recv_flogi_req(struct fc_seq *sp_in, | |||
794 | fc_lport_ptp_setup(lport, remote_fid, remote_wwpn, | 795 | fc_lport_ptp_setup(lport, remote_fid, remote_wwpn, |
795 | get_unaligned_be64(&flp->fl_wwnn)); | 796 | get_unaligned_be64(&flp->fl_wwnn)); |
796 | 797 | ||
797 | lport->tt.disc_start(fc_lport_disc_callback, lport); | ||
798 | |||
799 | out: | 798 | out: |
800 | sp = fr_seq(rx_fp); | 799 | sp = fr_seq(rx_fp); |
801 | fc_frame_free(rx_fp); | 800 | fc_frame_free(rx_fp); |
@@ -1512,14 +1511,6 @@ static void fc_lport_flogi_resp(struct fc_seq *sp, struct fc_frame *fp, | |||
1512 | fc_lport_enter_dns(lport); | 1511 | fc_lport_enter_dns(lport); |
1513 | } | 1512 | } |
1514 | } | 1513 | } |
1515 | |||
1516 | if (flp) { | ||
1517 | csp_flags = ntohs(flp->fl_csp.sp_features); | ||
1518 | if ((csp_flags & FC_SP_FT_FPORT) == 0) { | ||
1519 | lport->tt.disc_start(fc_lport_disc_callback, | ||
1520 | lport); | ||
1521 | } | ||
1522 | } | ||
1523 | } else { | 1514 | } else { |
1524 | FC_LPORT_DBG(lport, "Bad FLOGI response\n"); | 1515 | FC_LPORT_DBG(lport, "Bad FLOGI response\n"); |
1525 | } | 1516 | } |