Re: Configfs composite gadget with CCID and mass storage

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

 



W dniu 06.10.2015 o 14:38, Frans-Pieter van Wyk pisze:
Hi,


My question is, is it possible to setup a USB composite device
consisting of a smart card CCID and a mass storage device using Configfs?

ConfigFS is used to compose a gadget of existing functions.
As far as I can tell there is no smart card CCID usb function
in kernel, so either you need to have your own out-of-tree
implementation or implement it in userspace with FunctionFS.


Or more generally speaking, how can I pass a class descriptor, specific to a particular interface, to Configfs?

Usb gadget is one of the consumers (users) of ConfigFS.
ConfigFS applied to usb gadgets serves only the purpose of
composing gadgets of existing functions. These are the functions
which provide interface descriptors.

FunctionFS is a specific USB function which forwards most
of USB traffic to userspace. FunctionFS can be composed
into a gadget with ConfigFS, but, by design, its function
directory in ConfigFS is _empty_. In other words, if you

mkdir functions/ffs.ccid

you have empty functions/ffs.ccid. You need to mount
corresponding FunctionFS instance (ccid) and provide
all the descriptors the way FunctionFS expects it.

I am using kernel 3.14 with Configfs compiled into the kernel only with mass storage and FunctionFS support.

Here is some background and what I have tried thus far...

Using a previous implementation, I was able to successfully expose the embedded device as a CCID using gadgetfs

It looks like the problem you are facing are
the differences between FunctionFS and gadgetfs.

AP
--
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