Re: configfs hierarchy (WAS: Re: [RFCv4 PATCH 02/13] usb: gadget: Add USB Functions Gadget)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 26 Nov 2012, Michal Nazarewicz wrote:

> On Mon, Nov 26 2012, Alan Stern wrote:
> > In your example, what files would appear under under
> > /functions/storage?  I gather that the "storage" part is just a
> > placeholder name with no real meaning.  The meaning is conveyed
> > when the user writes "mass_storage" to /functions/storage/name.
> >
> > When this happens, would the additional files created in this
> > directory be those required specifically by the mass_storage function
> > driver?  And nothing else?
> 
> Specifically by a single instance.

Ah, now I see.  I missed the part where Sebastian said that these 
directories would be symlinked under 
/gadgets/gadget1/default-configuration.

> > On the other hand, why have two separate directories for
> > /functions/ttyS0 and /functions/ttyS1?  Aren't these two different
> > instances of the same function?  So if the user then writes "acm"  to
> > /functions/ttyS0/name and /functions/ttyS1/name, wouldn't your
> > framework get an error when it tried to load the acm function module a
> > second time?
> 
> This would just create another instance of the same function.
> 
> 
> This actually gave me an idea.  Why not:
> 
> mkdir functions/acm       # the f_acm module is loaded
> mkdir functions/acm/blah  # instance of the function is created

That does seem to make more sense.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux