[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20180725040600.GA11041@nautica>
Date: Wed, 25 Jul 2018 06:06:00 +0200
From: Dominique Martinet <asmadeus@...ewreck.org>
To: piaojun <piaojun@...wei.com>
Cc: "akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
Eric Van Hensbergen <ericvh@...il.com>,
Ron Minnich <rminnich@...dia.gov>,
Latchesar Ionkov <lucho@...kov.net>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
v9fs-developer@...ts.sourceforge.net, groug@...d.org
Subject: Re: [PATCH] fs/9p/xattr.c: catch the error of p9_client_clunk when
setting xattr failed
piaojun wrote on Wed, Jul 25, 2018:
> On 2018/7/25 11:32, Dominique Martinet wrote:
> >> p9_client_write(fid, 0, &from, &retval);
> >
> > I'm not sure what to do about this but it's also possible for
> > p9_client_write to not write the full length without setting and error.
> >
> > We should probably compare the return value of p9_client_write and
> > value_len to detect short writes and return an error in this case.
>
> It looks like we could identify short writes error from the *err. If no
> error case breaks the while loop, the total equal to the whole data len.
Ah, I looked too fast and missed the while loop in p9_client_write...
It's rather unusual for such a low level call to handle retries, but I
guess that's 9p.
Right, will take that patch as is then.
Thanks,
--
Dominique
Powered by blists - more mailing lists