diff options
author | Andrzej Pietrasiewicz <andrzej.p@samsung.com> | 2015-03-20 07:18:47 (GMT) |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2015-05-07 18:46:54 (GMT) |
commit | 83210e59ee1527f229af6aef78c95b747bdcf9c4 (patch) | |
tree | 64ab5affe49ae6be3b808e06e52bf6123c91b099 /tools/perf/builtin-help.c | |
parent | d74c23d36e7829ca7517a82c725c493d16328a44 (diff) | |
download | linux-83210e59ee1527f229af6aef78c95b747bdcf9c4.tar.xz |
usb: gadget: rndis: use rndis_params instead of configNr
RNDIS function has a limitation on the number of allowed instances.
So far it has been RNDIS_MAX_CONFIGS, which happens to be one.
In order to eliminate this kind of arbitrary limitation we should not
preallocate a predefined (RNDIS_MAX_CONFIGS) array of struct rndis_params
instances but instead allow allocating them on demand.
This patch prepares the elimination of the said limit by converting all the
functions which accept rndis config number to accept a pointer to the
actual struct rndis_params. Consequently, rndis_register() returns
a pointer to a corresponding struct rndis_params instance. The pointer
is then always used by f_rndis.c instead of config number when it talks
to rndis.c API.
A nice side-effect of the changes is that many lines of code in rndis.c
become shorter and fit in 80 columns.
If a function prototype changes in rndis.h a style cleanup is made
at the same time, otherwise checkpatch complains that the patch
has style problems.
Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'tools/perf/builtin-help.c')
0 files changed, 0 insertions, 0 deletions