usb: gadget: add 'ep_match' callback to usb_gadget_ops
authorRobert Baldyga <r.baldyga@samsung.com>
Thu, 6 Aug 2015 12:11:10 +0000 (14:11 +0200)
committerFelipe Balbi <balbi@ti.com>
Thu, 6 Aug 2015 14:31:45 +0000 (09:31 -0500)
Add callback that is called by epautoconf to allow UDC driver match the
best endpoint for specific descriptor. It's intended to supply mechanism
which allows to get rid of chip-specific endpoint matching code from
epautoconf.

If gadget has set 'ep_match' callback we prefer to call it first, and
if it fails to find matching endpoint, then we try to use default matching
algorithm.

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

Simple merge
Simple merge