From 60dcedf9d72f23aa9a4ea1db0e17ec7bae56c50c Mon Sep 17 00:00:00 2001 From: Vasu Dev Date: Fri, 9 Mar 2012 14:49:58 -0800 Subject: [PATCH] --- yaml --- r: 298275 b: refs/heads/master c: 73d67aa40b1f94a4e5edecbbc3b94d352eeeae0a h: refs/heads/master i: 298273: b2e4c99a7fd41daab79cbf8d592b3c3c3673cd33 298271: 3e8db688eb1232da785c28ce7cde682af891a2ca v: v3 --- [refs] | 2 +- trunk/drivers/scsi/libfc/fc_lport.c | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index ac45474d95cf..45c7461e2c35 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 14619ea689cc0b257cf998469005d0515133d7bc +refs/heads/master: 73d67aa40b1f94a4e5edecbbc3b94d352eeeae0a diff --git a/trunk/drivers/scsi/libfc/fc_lport.c b/trunk/drivers/scsi/libfc/fc_lport.c index 9a0b2a9caad6..4f7ef76aa795 100644 --- a/trunk/drivers/scsi/libfc/fc_lport.c +++ b/trunk/drivers/scsi/libfc/fc_lport.c @@ -1743,8 +1743,16 @@ void fc_lport_flogi_resp(struct fc_seq *sp, struct fc_frame *fp, mfs = ntohs(flp->fl_csp.sp_bb_data) & FC_SP_BB_DATA_MASK; if (mfs >= FC_SP_MIN_MAX_PAYLOAD && - mfs < lport->mfs) + mfs <= lport->mfs) { lport->mfs = mfs; + fc_host_maxframe_size(lport->host) = mfs; + } else { + FC_LPORT_DBG(lport, "FLOGI bad mfs:%hu response, " + "lport->mfs:%hu\n", mfs, lport->mfs); + fc_lport_error(lport, fp); + goto err; + } + csp_flags = ntohs(flp->fl_csp.sp_features); r_a_tov = ntohl(flp->fl_csp.sp_r_a_tov); e_d_tov = ntohl(flp->fl_csp.sp_e_d_tov);