On Thu, Apr 16, 2009 at 11:52:27AM -0700, Love, Robert W wrote: > Leech, Christopher wrote: > > On Thu, Apr 16, 2009 at 11:38:29AM -0700, Robert Love wrote: > >> When building with a .config generated from 'make allmodconfig' > >> some build warnings are generated. This patch corrects the warnings, > >> adds a FC_FID_NONE (= 0) enumeration for FC-IDs and cleans up one > >> variable naming to meet our variable naming conventions. For example, > >> fc_lport's should be named "lport," not "lp." > >> > >> Signed-off-by: Robert Love <[email protected]> > > > >> @@ -535,7 +535,8 @@ static void fc_rport_plogi_resp(struct fc_seq > >> *sp, struct fc_frame *fp, > >> > >> op = fc_frame_payload_op(fp); > >> if (op == ELS_LS_ACC && > >> - (plp = fc_frame_payload_get(fp, sizeof(*plp))) != NULL) { > >> + (plp = fc_frame_payload_get(fp, > >> + sizeof(struct fc_els_flogi))) != NULL) { > >> rport->port_name = get_unaligned_be64(&plp->fl_wwpn); > >> rport->node_name = get_unaligned_be64(&plp->fl_wwnn); > >> > > > > Was there a warning fixed by this change? I find the split long line > > uglier than the existing use of sizeof on a variable instead of a > > type. > > > Yeah, it did fix the compile warning and I agree with you that the split > line is obnoxious. Would initializing plp to NULL would be preferable?
I thought this patch did both? (In the preceding chunk that I didn't quote) If the initialization to NULL alone fixes it, then I'd prefer not to make this sizeof change. _______________________________________________ devel mailing list [email protected] http://www.open-fcoe.org/mailman/listinfo/devel
