usb: gadget: f_obex: use bind_deactivated flag
authorRobert Baldyga <r.baldyga@samsung.com>
Mon, 4 May 2015 12:55:15 +0000 (14:55 +0200)
committerFelipe Balbi <balbi@ti.com>
Wed, 29 Jul 2015 14:59:20 +0000 (09:59 -0500)
commit4cfbd95232dd6194c04d432d1a8ac45cec269d8b
tree6d894c3ef0dc70574019a9423ecaca250bc15254
parentf277bf27cf5cd56bcd1c4b95ae140f61680a6e83
usb: gadget: f_obex: use bind_deactivated flag

Use bind_deactivated flag instead of calling usb_function_deactivate()
in function bind(). Field 'can_activate' in struct f_obex is no longer
needed as setting 'bind_deactivated' flag makes us sure, that the function
will be binded only if deactivation can be performed successfully.

Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/gadget/function/f_obex.c