RE: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-06-01 Thread Peter Chen
> > Thank you, that sounds like the best approach. > In this case I think perhaps the long wait without any data is an > problem with the imx6 Chipidea USB controller. > >>> > >>> What's the possible problem? > >> > >> Sorry for the delay in replying, I have been getting some

Re: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-06-01 Thread Baxter, Jim
> > FunctionFS is very specific, because read/write operations are > directly translated into USB requests, which are asynchronous, so > you cannot use O_NONBLOCK. > > If you need non-blocking API you can use Asynchronous I/O (AIO). You > can find some examples in kernel

RE: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-05-24 Thread Peter Chen
> >>> > >>> FunctionFS is very specific, because read/write operations are > >>> directly translated into USB requests, which are asynchronous, so > >>> you cannot use O_NONBLOCK. > >>> > >>> If you need non-blocking API you can use Asynchronous I/O (AIO). You > >>> can find some examples in kern

Re: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-05-22 Thread Baxter, Jim
> On Wed, Apr 01, 2015 at 06:29:05PM +0100, Baxter, Jim wrote: >>> >>> FunctionFS is very specific, because read/write operations are directly >>> translated into USB requests, which are asynchronous, so you cannot use >>> O_NONBLOCK. >>> >>> If you need non-blocking API you can use Asynchronous I

Re: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-04-01 Thread Peter Chen
On Wed, Apr 01, 2015 at 06:29:05PM +0100, Baxter, Jim wrote: > > > > FunctionFS is very specific, because read/write operations are directly > > translated into USB requests, which are asynchronous, so you cannot use > > O_NONBLOCK. > > > > If you need non-blocking API you can use Asynchronous I/

Re: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-04-01 Thread Baxter, Jim
> > FunctionFS is very specific, because read/write operations are directly > translated into USB requests, which are asynchronous, so you cannot use > O_NONBLOCK. > > If you need non-blocking API you can use Asynchronous I/O (AIO). You can > find some examples in kernel sources (tools/usb/ffs-ai

Re: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-04-01 Thread Robert Baldyga
Hi, On 03/31/2015 08:53 PM, Baxter, Jim wrote: > Hi, > > I have been looking at an issue where a phone that is the Function FS > host sometimes locks up and causes the function: > static ssize_t ffs_epfile_io(struct file *file, struct ffs_io_data > *io_data) in drivers/usb/gadget/function/f_fs.c

Re: usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-03-31 Thread Felipe Balbi
Hi, (it helps if you Cc the maintainer too :-) On Tue, Mar 31, 2015 at 07:53:39PM +0100, Baxter, Jim wrote: > I have been looking at an issue where a phone that is the Function FS > host sometimes locks up and causes the function: which USB controller ? which kernel ? which platform ? > static

usb: gadget: f_fs: O_NONBLOCK waits MAX_SCHEDULE_TIMEOUT

2015-03-31 Thread Baxter, Jim
Hi, I have been looking at an issue where a phone that is the Function FS host sometimes locks up and causes the function: static ssize_t ffs_epfile_io(struct file *file, struct ffs_io_data *io_data) in drivers/usb/gadget/function/f_fs.c to timeout after MAX_SCHEDULE_TIMEOUT jiffies. We are openi