[media] dvb_usb_v2: add .init() callback
Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
parent
c79b339f92
commit
dc78693706
2 changed files with 6 additions and 0 deletions
|
@ -239,6 +239,8 @@ enum dvb_usb_mode {
|
||||||
* @read_mac_address: called to read the MAC address of the device.
|
* @read_mac_address: called to read the MAC address of the device.
|
||||||
* @identify_state: called to determine the state (cold or warm), when it
|
* @identify_state: called to determine the state (cold or warm), when it
|
||||||
* is not distinguishable by the USB IDs.
|
* is not distinguishable by the USB IDs.
|
||||||
|
* @init: called after adapters are created in order to finalize device
|
||||||
|
* configuration.
|
||||||
*
|
*
|
||||||
* @rc: remote controller properties
|
* @rc: remote controller properties
|
||||||
*
|
*
|
||||||
|
@ -283,6 +285,7 @@ struct dvb_usb_device_properties {
|
||||||
int (*read_mac_address) (struct dvb_usb_device *, u8 []);
|
int (*read_mac_address) (struct dvb_usb_device *, u8 []);
|
||||||
int (*identify_state) (struct usb_device *, struct dvb_usb_device_properties *,
|
int (*identify_state) (struct usb_device *, struct dvb_usb_device_properties *,
|
||||||
struct dvb_usb_device_description **, int *);
|
struct dvb_usb_device_description **, int *);
|
||||||
|
int (*init) (struct dvb_usb_device *);
|
||||||
|
|
||||||
struct {
|
struct {
|
||||||
enum dvb_usb_mode mode; /* Drivers shouldn't touch on it */
|
enum dvb_usb_mode mode; /* Drivers shouldn't touch on it */
|
||||||
|
|
|
@ -164,6 +164,9 @@ static int dvb_usb_init(struct dvb_usb_device *d, short *adapter_nums)
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (d->props.init)
|
||||||
|
d->props.init(d);
|
||||||
|
|
||||||
if ((ret = dvb_usb_remote_init(d)))
|
if ((ret = dvb_usb_remote_init(d)))
|
||||||
err("could not initialize remote control.");
|
err("could not initialize remote control.");
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue