From: Dominique Martinet <asmadeus@codewreck.org>
To: piaojun <piaojun@huawei.com>
Cc: "akpm@linux-foundation.org" <akpm@linux-foundation.org>,
Eric Van Hensbergen <ericvh@gmail.com>,
Ron Minnich <rminnich@sandia.gov>,
Latchesar Ionkov <lucho@ionkov.net>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
v9fs-developer@lists.sourceforge.net, groug@kaod.org
Subject: Re: [PATCH] fs/9p/xattr.c: catch the error of p9_client_clunk when setting xattr failed
Date: Wed, 25 Jul 2018 06:06:00 +0200 [thread overview]
Message-ID: <20180725040600.GA11041@nautica> (raw)
In-Reply-To: <5B57F564.9070604@huawei.com>
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
prev parent reply other threads:[~2018-07-25 4:06 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-25 3:13 [PATCH] fs/9p/xattr.c: catch the error of p9_client_clunk when setting xattr failed piaojun
2018-07-25 3:32 ` Dominique Martinet
2018-07-25 3:58 ` piaojun
2018-07-25 4:06 ` Dominique Martinet [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180725040600.GA11041@nautica \
--to=asmadeus@codewreck.org \
--cc=akpm@linux-foundation.org \
--cc=ericvh@gmail.com \
--cc=groug@kaod.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lucho@ionkov.net \
--cc=piaojun@huawei.com \
--cc=rminnich@sandia.gov \
--cc=v9fs-developer@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox