From: Michal Nazarewicz <mina86@mina86.com>
To: Felipe Balbi <felipe.balbi@linux.intel.com>,
"Du, Changbin" <changbin.du@intel.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Al Viro <viro@zeniv.linux.org.uk>,
rui.silva@linaro.org, k.opasiak@samsung.com, lars@metafoo.de,
linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org
Subject: [PATCH 0/2] f_fs: better handle excess data on read
Date: Sat, 21 May 2016 20:47:33 +0200 [thread overview]
Message-ID: <1463856455-18160-1-git-send-email-mina86@mina86.com> (raw)
Between this set and Du, Changbin’s patch, we now have implementation
for the following three possibilities to choose from:
1. Buffer excess data (this whole patch set).
2. Fail the transfer (Du, Changbin’s patch).
3. Drop excess data (the first patch from this set).
As per earlier comments, I think 3. is the correct, i.e. the second
patch should not be ocmmited because:
* it complicates the code,
* doesn’t handle AIO anyway,
* introduces weird behaviours when partial read happens just before
endpoint is disabled (we may end up silently dropping excess data
anyway),
* goes beyond what UDC does and
* breaks one read -> one request model which has been true so far.
Michal Nazarewicz (2):
usb: gadget: f_fs: printk error when excess data is dropped on read
usb: gadget: f_fs: buffer data from ‘oversized’ OUT requests
drivers/usb/gadget/function/f_fs.c | 179 ++++++++++++++++++++++++++++++-------
1 file changed, 145 insertions(+), 34 deletions(-)
--
Best regards
ミハウ “𝓶𝓲𝓷𝓪86” ナザレヴイツ
«If at first you don’t succeed, give up skydiving»
next reply other threads:[~2016-05-21 18:47 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-21 18:47 Michal Nazarewicz [this message]
2016-05-21 18:47 ` [PATCH 1/2] usb: gadget: f_fs: printk error when excess data is dropped " Michal Nazarewicz
2016-05-21 18:47 ` [PATCH 2/2] usb: gadget: f_fs: buffer data from ‘oversized’ OUT requests Michal Nazarewicz
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=1463856455-18160-1-git-send-email-mina86@mina86.com \
--to=mina86@mina86.com \
--cc=changbin.du@intel.com \
--cc=felipe.balbi@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=k.opasiak@samsung.com \
--cc=lars@metafoo.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=rui.silva@linaro.org \
--cc=viro@zeniv.linux.org.uk \
/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
all inboxes | Powered by JetHome®