Home
last modified time | relevance | path

Searched hist:aba3a8d01d623a5efef48ab8e78752d58d4c90c3 (Results 1 – 2 of 2) sorted by relevance

/linux/drivers/usb/gadget/function/
H A Du_serial.hdiff aba3a8d01d623a5efef48ab8e78752d58d4c90c3 Thu Apr 23 13:55:54 CEST 2020 Fabrice Gasnier <fabrice.gasnier@st.com> usb: gadget: u_serial: add suspend resume callbacks

Add suspend resume callbacks to handle the case seen when the bus is
suspended by the HOST, and the device opens the port (cat /dev/ttyGS0).

Gadget controller (like DWC2) doesn't accept usb requests to be queued in
this case (when in L2 state), from the gs_open() call. Error log is printed
- configfs-gadget gadget: acm ttyGS0 can't notify serial state, -11
If the HOST resumes (opens) the bus, the port still isn't functional.

Use suspend/resume callbacks to monitor the gadget suspended state by using
'suspended' flag. In case the port gets opened (cat /dev/ttyGS0), the I/O
stream will be delayed until the bus gets resumed by the HOST.

Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
H A Du_serial.cdiff aba3a8d01d623a5efef48ab8e78752d58d4c90c3 Thu Apr 23 13:55:54 CEST 2020 Fabrice Gasnier <fabrice.gasnier@st.com> usb: gadget: u_serial: add suspend resume callbacks

Add suspend resume callbacks to handle the case seen when the bus is
suspended by the HOST, and the device opens the port (cat /dev/ttyGS0).

Gadget controller (like DWC2) doesn't accept usb requests to be queued in
this case (when in L2 state), from the gs_open() call. Error log is printed
- configfs-gadget gadget: acm ttyGS0 can't notify serial state, -11
If the HOST resumes (opens) the bus, the port still isn't functional.

Use suspend/resume callbacks to monitor the gadget suspended state by using
'suspended' flag. In case the port gets opened (cat /dev/ttyGS0), the I/O
stream will be delayed until the bus gets resumed by the HOST.

Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>