Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-07-14 Thread Noralf Trønnes
Den 02.06.2020 13.46, skrev Noralf Trønnes: > > > Den 02.06.2020 04.32, skrev Alan Stern: >> On Tue, Jun 02, 2020 at 12:12:07AM +, Peter Stuge wrote: >> >> ... >> >>> The way I read composite_setup() after try_fun_setup: it calls f->setup() >>> when available, and that can return < 0 to sta

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-05 Thread Noralf Trønnes
Den 02.06.2020 20.38, skrev Peter Stuge: > Alan Stern wrote: A gadget driver can STALL in response to a control-OUT data packet, but only before it has seen the packet. >>> >>> How can it do that for OUT, and IN if possible there too? >> >> In the way described just above: The gadget dr

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-03 Thread Noralf Trønnes
Den 02.06.2020 02.12, skrev Peter Stuge: > Hi Noralf, > > Thanks a lot for going into more detail. > > Noralf Trønnes wrote: >>> Several Linux/DRM internals have "leaked" into the USB protocol - this >>> should be avoided if you want device implementations other than your >>> gadget, because th

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-02 Thread Peter Stuge
Alan Stern wrote: > > > A gadget driver can STALL in response to a control-OUT data packet, > > > but only before it has seen the packet. > > > > How can it do that for OUT, and IN if possible there too? > > In the way described just above: The gadget driver's SETUP handler tells > the UDC to st

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-02 Thread Alan Stern
On Tue, Jun 02, 2020 at 05:21:50AM +, Peter Stuge wrote: > > The USB protocol forbids a device from sending a STALL response to a > > SETUP packet. The only valid response is ACK. Thus, there is no way > > to prevent the host from sending its DATA packet for a control-OUT > > transfer. > > R

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-02 Thread Noralf Trønnes
Den 02.06.2020 04.32, skrev Alan Stern: > On Tue, Jun 02, 2020 at 12:12:07AM +, Peter Stuge wrote: > > ... > >> The way I read composite_setup() after try_fun_setup: it calls f->setup() >> when available, and that can return < 0 to stall. >> >> I expect that composite_setup() and thus f->s

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-01 Thread Peter Stuge
Hi Alan, Alan Stern wrote: > > The way I read composite_setup() after try_fun_setup: it calls f->setup() > > when available, and that can return < 0 to stall. > > > > I expect that composite_setup() and thus f->setup() run when the > > SETUP packet has arrived, thus before the data packet arrives

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-01 Thread Alan Stern
On Tue, Jun 02, 2020 at 12:12:07AM +, Peter Stuge wrote: ... > The way I read composite_setup() after try_fun_setup: it calls f->setup() > when available, and that can return < 0 to stall. > > I expect that composite_setup() and thus f->setup() run when the > SETUP packet has arrived, thus b

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-01 Thread Peter Stuge
Hi Noralf, Thanks a lot for going into more detail. Noralf Trønnes wrote: > > Several Linux/DRM internals have "leaked" into the USB protocol - this > > should be avoided if you want device implementations other than your > > gadget, because those internals can change within Linux in the future,

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-06-01 Thread Noralf Trønnes
Hi Peter, Den 30.05.2020 00.45, skrev Peter Stuge: > Hi Noralf, > > Noralf Trønnes wrote: >> This adds a generic USB display driver with the intention that it can be >> used with future USB interfaced low end displays/adapters. > > Fun! > > >> The Linux gadget device driver will serve as the c

Re: [PATCH v3 4/6] drm: Add Generic USB Display driver

2020-05-29 Thread Peter Stuge
Hi Noralf, Noralf Trønnes wrote: > This adds a generic USB display driver with the intention that it can be > used with future USB interfaced low end displays/adapters. Fun! > The Linux gadget device driver will serve as the canonical device > implementation. That's a great goal, but as propos

[PATCH v3 4/6] drm: Add Generic USB Display driver

2020-05-29 Thread Noralf Trønnes
This adds a generic USB display driver with the intention that it can be used with future USB interfaced low end displays/adapters. The Linux gadget device driver will serve as the canonical device implementation. The following DRM properties are supported: - Plane rotation - Connector TV properti