On 08/02/17 09:43, Johan Hovold wrote: > On Tue, Feb 07, 2017 at 02:31:04PM +0000, Bryan O'Donoghue wrote: >> On 07/02/17 14:19, Johan Hovold wrote: >>> On Mon, Jan 23, 2017 at 01:04:14PM +0100, Johan Hovold wrote: >>>> Add a struct timer_list to struct gb_operation and use that to implement >>>> generic operation timeouts. >>>> >>>> This simplifies the synchronous operation handling somewhat while also >>>> providing a generic timeout mechanism that drivers can use for >>>> asynchronous operations. >>>> >>>> Signed-off-by: Johan Hovold <johan@xxxxxxxxxx> >>> >>> Greg, >>> >>> I believe you can apply this one now. This is the right way to implement >>> operation timeouts, and it is independent of Bryan's patches converting >>> loopback to use the new interface, which can be applied on top when they >>> are ready. >>> >>> Thanks, >>> Johan >>> >> > > My approach using a single timer which either times out or is cancelled > upon completion is about as efficient as this can get, and therefore > also allows the current synchronous-operation implementation to be built > on top of this generic mechanism. I'm just wondering what impact it has instead of wait_event_interruptible() more/less overhead (I suspect more) - and I reckoned you'd not be on for that change - so only made a change on the asynchronous path. But whatever you're happier with yourself. -- bod _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel