All of lore.kernel.org
 help / color / mirror / Atom feed
* Failure to Assign UDC to ConfigFS Gadget
@ 2020-04-22 22:02 Sid Spry
  2020-04-23  3:28 ` Gopal, Saranya
  0 siblings, 1 reply; 3+ messages in thread
From: Sid Spry @ 2020-04-22 22:02 UTC (permalink / raw)
  To: linux-usb

Hi, I'm just following these slides: https://events.static.linuxfound.org/sites/events/files/slides/USB%20Gadget%20Configfs%20API_0.pdf

On page 18 I need to assign the UDC. On my version of Debian (repackaged by Armbian, with my own kernel and modules) there is no device in /sys/class/udc as expected, but there is a link that resolves to a device:

# stat /sys/class/udc/musb-hdrc.1.auto
  File: /sys/class/udc/musb-hdrc.1.auto -> ../../devices/platform/soc/1c19000.usb/musb-hdrc.1.auto/udc/musb-hdrc.1.auto

If I try to assign the UDC using the string 1c19000.usb I get:

# echo "1c19000.usb" > UDC                                       
bash: echo: write error: No such device

It's at this point I'm lost. I appreciate any help.

Cheers!

^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: Failure to Assign UDC to ConfigFS Gadget
  2020-04-22 22:02 Failure to Assign UDC to ConfigFS Gadget Sid Spry
@ 2020-04-23  3:28 ` Gopal, Saranya
  2020-04-23 13:09   ` Sid Spry
  0 siblings, 1 reply; 3+ messages in thread
From: Gopal, Saranya @ 2020-04-23  3:28 UTC (permalink / raw)
  To: Sid Spry, linux-usb

Hi Sid,

> # stat /sys/class/udc/musb-hdrc.1.auto
>   File: /sys/class/udc/musb-hdrc.1.auto ->
> ../../devices/platform/soc/1c19000.usb/musb-hdrc.1.auto/udc/musb-
> hdrc.1.auto
> 
> If I try to assign the UDC using the string 1c19000.usb I get:
> 
> # echo "1c19000.usb" > UDC
> bash: echo: write error: No such device
> 
> It's at this point I'm lost. I appreciate any help.

You need to give the exact name of UDC as present in /sys/class/udc.
So, try this:
echo "musb-hdrc.1.auto" > UDC

Thanks,
Saranya

> Cheers!

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Failure to Assign UDC to ConfigFS Gadget
  2020-04-23  3:28 ` Gopal, Saranya
@ 2020-04-23 13:09   ` Sid Spry
  0 siblings, 0 replies; 3+ messages in thread
From: Sid Spry @ 2020-04-23 13:09 UTC (permalink / raw)
  To: Gopal, Saranya, linux-usb

Ah, thanks. I actually tried that, but must have made a typo a couple times in a row. At least now I get a kernel bug printout!

On Wed, Apr 22, 2020, at 10:28 PM, Gopal, Saranya wrote:
> Hi Sid,
> 
> > # stat /sys/class/udc/musb-hdrc.1.auto
> > File: /sys/class/udc/musb-hdrc.1.auto ->
> > ../../devices/platform/soc/1c19000.usb/musb-hdrc.1.auto/udc/musb-
> > hdrc.1.auto
> > 
> > If I try to assign the UDC using the string 1c19000.usb I get:
> > 
> > # echo "1c19000.usb" > UDC
> > bash: echo: write error: No such device
> > 
> > It's at this point I'm lost. I appreciate any help.
> 
> You need to give the exact name of UDC as present in /sys/class/udc.
> So, try this:
> echo "musb-hdrc.1.auto" > UDC
> 
> Thanks,
> Saranya
> 
> > Cheers!
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-04-23 13:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-22 22:02 Failure to Assign UDC to ConfigFS Gadget Sid Spry
2020-04-23  3:28 ` Gopal, Saranya
2020-04-23 13:09   ` Sid Spry

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.