]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
usb: gadget: loopback: fix: Don't share qlen and buflen between instances
authorKrzysztof Opasiak <k.opasiak@samsung.com>
Wed, 14 Oct 2015 21:03:34 +0000 (23:03 +0200)
committerFelipe Balbi <balbi@ti.com>
Thu, 15 Oct 2015 14:29:38 +0000 (09:29 -0500)
commit3e9d992f93fecc746baa9d4854acc026d422094f
tree0c6a0b9cc9ea29facd7da7e86d075baaaaae85d0
parent897ee0e85e5fad3109264af5b517a1ebb82912c3
usb: gadget: loopback: fix: Don't share qlen and buflen between instances

Each instance of loopback function may have different qlen
and buflen attributes values. When linking function to
configuration those values had been assigned to global
variables. Linking other instance to config overwrites those
values.

This commit moves those values to f_loopback structure
to avoid overwriting. Now each function has its own instance
of those values.

Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Reviewed-by: Robert Baldyga <r.baldyga@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/gadget/function/f_loopback.c