On Fri, 2010-11-12 at 15:51 -0800, Joe Eykholt wrote: > > On 11/12/10 3:39 PM, Nicholas A. Bellinger wrote: > > On Fri, 2010-11-12 at 14:46 -0800, Joe Eykholt wrote: > >>
<SNIP> > > Thanks for reporting Joe. Below is the patch being pushed to > > lio-core-2.6.git/tcm_fc_ddp_offload now.. > > > > Also, this needs to be fixed in non tcm_fc_ddp_offload tcm_fc code as > > well, yes..? > > This is shared for both, I believe. > > >>From 437651c709056ce3a6c327bb0a74dad518039335 Mon Sep 17 00:00:00 2001 > > From: Nicholas Bellinger <[email protected]> > > Date: Fri, 12 Nov 2010 23:40:58 +0000 > > Subject: [PATCH] tcm_fc: Clear frame_len before skipping to next frame > > > > If we fall through at this point, we should set frame_len to 0, so that > > we'll get a new frame next time around the loop. Previously frame_len would > > be 0 at this point, but if we limited out (very correctly) on the SG_LEN > > check, then we should set frame_len to 0 here. > > > > Reported-by: Joe Eykholt <[email protected]> > > Signed-off-by: Nicholas A. Bellinger <[email protected]> > > --- > > drivers/target/tcm_fc/tfc_io.c | 4 +++- > > 1 files changed, 3 insertions(+), 1 deletions(-) > > > > diff --git a/drivers/target/tcm_fc/tfc_io.c b/drivers/target/tcm_fc/tfc_io.c > > index 4c3c0ef..b3c7a28 100644 > > --- a/drivers/target/tcm_fc/tfc_io.c > > +++ b/drivers/target/tcm_fc/tfc_io.c > > @@ -192,8 +192,10 @@ int ft_queue_data_in(struct se_cmd *se_cmd) > > remaining -= tlen; > > > > if (frame_len && > > - (skb_shinfo(fp_skb(fp))->nr_frags < FC_FRAME_SG_LEN)) > > + (skb_shinfo(fp_skb(fp))->nr_frags < FC_FRAME_SG_LEN)) { > > + frame_len = 0; > > continue; > > + } > > Not quite. I still don't have the full fix. I was thinking it should be: > > > if (frame_len && > > (skb_shinfo(fp_skb(fp))->nr_frags < FC_FRAME_SG_LEN)) > > continue; > > + frame_len = 0; > > So it'll get a new frame next time around. But, that messes up the fh_offset > value, which was computed on the frame_len we had when we started. So I > moved that around to fix it as well. > > I'll see if I can send you a fix later. Sounds good, I will revert this incorrect version for now and await your patch. Thanks! --nab > > > if (!remaining) > > f_ctl |= FC_FC_END_SEQ; > > fc_fill_fc_hdr(fp, FC_RCTL_DD_SOL_DATA, ep->did, ep->sid, > _______________________________________________ devel mailing list [email protected] http://www.open-fcoe.org/mailman/listinfo/devel
