linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: bugzilla-daemon@bugzilla.kernel.org
To: linux-usb@vger.kernel.org
Subject: [Bug 212045] dwc2 gadget mode read call blocks
Date: Fri, 05 Mar 2021 10:37:50 +0000	[thread overview]
Message-ID: <bug-212045-208809-ZiNUZNm0g9@https.bugzilla.kernel.org/> (raw)
In-Reply-To: <bug-212045-208809@https.bugzilla.kernel.org/>

https://bugzilla.kernel.org/show_bug.cgi?id=212045

--- Comment #5 from Tomasz Grobelny (tomasz@grobelny.net) ---
The files that functionfs exposes are ep0 (for reading, events), ep1 (for
writing, direction: to host) and ep2 (for reading, direction: to gadget). Not
sure how and why they are named in dmesg. You can find the gadget configuration
here:
https://github.com/tomasz-grobelny/AACS/blob/master/AAServer/src/descriptors.cpp
- line 75 and 84:
                    .bEndpointAddress = 1 | USB_DIR_IN,
                    .bEndpointAddress = 2 | USB_DIR_OUT,

The code that fails/hangs is readWraper function here:
https://github.com/tomasz-grobelny/AACS/blob/master/AAServer/src/AaCommunicator.cpp:493

select succeeds for ep2 and the read blocks. Exactly same function works ok for
ep0 for all 3 hosts that I tested on and the code works fully ok for 2 out of 3
hosts that I tested on. I also know that in principle the 3rd host also should
work because it works with other devices.

Maybe lack of ep2 in the logs is something interesting?

-- 
You may reply to this email to add a comment.

You are receiving this mail because:
You are watching the assignee of the bug.

  parent reply	other threads:[~2021-03-05 10:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-03 23:51 [Bug 212045] New: dwc2 gadget mode read call blocks bugzilla-daemon
2021-03-05  9:30 ` [Bug 212045] " bugzilla-daemon
2021-03-05 10:37 ` bugzilla-daemon [this message]
2021-03-10 10:13 ` bugzilla-daemon

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=bug-212045-208809-ZiNUZNm0g9@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@bugzilla.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).