diff options
author | Florian Mickler <florian@mickler.org> | 2011-03-21 11:19:08 +0100 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-05-20 14:28:05 +0200 |
commit | 1c6410f317c3e78409f0179283089034c77a6ad5 (patch) | |
tree | 281a8ff04d5e6af29030572f78cb14a4447441b6 /drivers/media/dvb/dvb-usb/vp702x.h | |
parent | [media] vp702x: rename struct vp702x_state -> vp702x_adapter_state (diff) | |
download | linux-1c6410f317c3e78409f0179283089034c77a6ad5.tar.xz linux-1c6410f317c3e78409f0179283089034c77a6ad5.zip |
[media] vp702x: preallocate memory on device probe
This sets up a buffer and a mutex protecting that buffer in
the struct vp702x_device_state.
The definition of struct vp702x_device_state is moved into the header
in order to use the buffer also in the frontend.
Signed-off-by: Florian Mickler <florian@mickler.org>
Cc: Patrick Boettcher <pb@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/dvb/dvb-usb/vp702x.h')
-rw-r--r-- | drivers/media/dvb/dvb-usb/vp702x.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/media/dvb/dvb-usb/vp702x.h b/drivers/media/dvb/dvb-usb/vp702x.h index c2f97f96c21f..86960c657522 100644 --- a/drivers/media/dvb/dvb-usb/vp702x.h +++ b/drivers/media/dvb/dvb-usb/vp702x.h @@ -98,6 +98,14 @@ extern int dvb_usb_vp702x_debug; #define RESET_TUNER 0xBE /* IN i: 0, v: 0, no extra buffer */ +struct vp702x_device_state { + u8 power_state; + struct mutex buf_mutex; + int buf_len; + u8 *buf; +}; + + extern struct dvb_frontend * vp702x_fe_attach(struct dvb_usb_device *d); extern int vp702x_usb_inout_op(struct dvb_usb_device *d, u8 *o, int olen, u8 *i, int ilen, int msec); |