From: Jeff Layton Subject: Re: [PATCH v1 8/8] cifs: convert cifs_iovec_write to use async writes Date: Fri, 23 Mar 2012 17:11:00 -0400 Message-ID: <20120323171100.606a7b5d@tlielax.poochiereds.net> References: <1328279581-21889-1-git-send-email-jlayton@redhat.com> <1328279581-21889-9-git-send-email-jlayton@redhat.com> <20120221065455.4f4b3ec5@tlielax.poochiereds.net> <20120323170140.3cdd927f@tlielax.poochiereds.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Pavel Shilovsky , linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Steve French Return-path: In-Reply-To: Sender: linux-cifs-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-ID: On Fri, 23 Mar 2012 16:05:20 -0500 Steve French wrote: > On Fri, Mar 23, 2012 at 4:01 PM, Jeff Layton wro= te: > > On Fri, 23 Mar 2012 15:55:14 -0500 > > Steve French wrote: > > > >> Jeff, > >> We should cleanup compile warning - was planning to add a tiny pat= ch > >> to fix if no objection. > >> > >> Look correct? > >> > >> diff --git a/fs/cifs/file.c b/fs/cifs/file.c > >> index daaaca8..460d87b 100644 > >> --- a/fs/cifs/file.c > >> +++ b/fs/cifs/file.c > >> @@ -2114,7 +2114,7 @@ cifs_uncached_marshal_iov(struct kvec *iov, > >> struct cifs_writedata *wdata) > >> > >> =C2=A0 =C2=A0 =C2=A0 =C2=A0 /* marshal up the pages into iov array= */ > >> =C2=A0 =C2=A0 =C2=A0 =C2=A0 for (i =3D 0; i < wdata->nr_pages; i++= ) { > >> - =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 iov[i + 1].iov_= len =3D min(bytes, PAGE_SIZE); > >> + =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 iov[i + 1].iov_= len =3D min_t(size_t, bytes, PAGE_SIZE); > >> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 iov[i + 1]= =2Eiov_base =3D kmap(wdata->pages[i]); > >> =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 bytes -=3D= iov[i + 1].iov_len; > >> =C2=A0 =C2=A0 =C2=A0 =C2=A0 } > >> > > > > That patch looks harmless, but I don't seem to be able to reproduce= any > > warnings. Can you elaborate on how you're getting a warning from th= at? >=20 > make modules C=3D1 M=3Dfs/cifs CF=3D-D__CHECK_ENDIAN__ >=20 > FC16 >=20 > [stevef@smf-gateway cifs-2.6]$ gcc --version > gcc (GCC) 4.6.2 20111027 (Red Hat 4.6.2-1) > Copyright (C) 2011 Free Software Foundation, Inc. >=20 >=20 Hrm...I don't see it on my F16 box. Are you on 32 bit arch? If so, that might be why. In any case, that patch is fine if it silences the warning for you. --=20 Jeff Layton