1
0
Fork 0
mirror of https://github.com/linux-usb-gadgets/libusbgx.git synced 2025-07-19 14:05:06 +03:00
Commit graph

9 commits

Author SHA1 Message Date
Ming Liu
4f3f2ad08e libusbgx: Add interface name for NCM Feature Descriptors
In commit: abf422bffc
[
Author: Stefan Agner <stefan.agner@toradex.com>
Date:   Tue Jan 24 14:22:25 2017 -0800

    libusbgx: Add interface name for Feature Descriptors

    This adds interface name required for "Feature Descriptors". If
    specified, we can assume that a Feature Descriptor with the
    interface name of the specified string is understood by the
    kernel (e.g. interface.rndis).
]

it only added Feature Descriptors for RNDIS, NCM also needs that, or
else it could not be recognized by Windows systems.

Add Feature Descriptors interface name for NCM.

Signed-off-by: Ming Liu <liu.ming50@gmail.com>
2022-12-11 16:06:08 +01:00
Paul Wise
36e71e1e1e
Rename the net class variables to class_
Using C++ keywords like "class" as variable names causes
build failures when libusbgx is used in C++ projects.

Reported-by: Thomas Moeller (@moether)
Reported-in: https://github.com/linux-usb-gadgets/libusbgx/issues/65#issuecomment-1296790932
Fixes: commit 4ca4a7699b
Fixes: commit efdd7a657c
2022-11-01 10:47:52 +08:00
Fernando Ginez
4ca4a7699b net: adds class, subclass and protocol attributes
This commit allows the library user to change class, subclass and
protocol values inside net derivated functions. This is needed by
Windows 10 users using RNDIS function with the native driver.
2022-09-12 16:24:02 -03:00
Stefan Agner
abf422bffc libusbgx: Add interface name for Feature Descriptors
This adds interface name required for "Feature Descriptors". If
specified, we can assume that a Feature Descriptor with the
interface name of the specified string is understood by the
kernel (e.g. interface.rndis).

Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
[Allow multiple os_desc ifaces per funciton]
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
2017-12-12 14:06:36 +01:00
Krzysztof Opasiak
5d0962ed41 libusbgx: Fix meaning of HAS_LIBCONFIG and HAS_GADGET_SCHEMES
We have two configure options related to libconfig:
1) --disable-gadget-schemes
2) --without-libconfig

Option #1 means that libusbgx itself should be compiled without gadget
schemes support. Option #2 means that everything what requires
libconfig should be turned off. So option #2 is wider than #1 as
libconfig us used also in our testing program.

To fix this meaning let's use HAS_GADGET_SCHEMES inside library source
code to determine if we should use libconfig or not and HAS_LIBCONFIG
inside our tests source code.

Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
2017-03-03 17:48:44 +01:00
Krzysztof Opasiak
5637edd558 libusbgx: Switch to a new function API
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
2015-12-23 00:49:03 +01:00
Krzysztof Opasiak
5fff0aefae libusbgx: net: Add implementation of function specific API
Implement all function-specific functions from header file

Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
2015-12-23 00:49:03 +01:00
Krzysztof Opasiak
5ea221a027 libusbgx: common: Add alloc_inst() and free_inst() callbacks
Those callback can be used by specific function type to allocate
and then free more memory than in raw usbg_function structure.

Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
2015-12-23 00:49:03 +01:00
Krzysztof Opasiak
013b9cc990 libusbgx: Add internal API for defining function types
Adding support for a new function type was quite complicated.
Moreover the main library source fail was growing realy fast.

As a solution introduce internal OO API for defining function.
Thanks to this support for each function may be placed in
a separate file.

Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
2015-12-23 00:49:02 +01:00