[linux-dvb] A couple of questions about dvb-usb framework

Tomi Orava tomimo+linux-dvb at ncircle.nullnet.fi
Sat Sep 22 09:34:32 CEST 2007


I've been playing with a modified version of the existing Cinergy T²
driver which has been merged to fit into current dvb-usb driver framework
like the rest of the drivers existing under the dvb-usb directory in
HG-tree. However, there are a couple of things which I have a problem

1) For some reason if I define a release handler funtion for the frontend
(of type struct dvb_frontend_ops ) --> .release = cinergyt2_fe_release and
then physically remove the usb-device from the computer and re-connect
immediately after, the kernel modules ref-counter goes backwards to
unsigned 32-bit -1 (ie value is shown to be 4294967295 by the lsmod-cmd).
This seems to happen because of the dvb_frontend_detach() calls the
frontends release handler if it has been defined and immediately after it
calls symbol_put_addr(ptr).

void dvb_frontend_detach(struct dvb_frontend* fe)
	void *ptr;

	if (fe->ops.release_sec) {
	if (fe->ops.tuner_ops.release) {
	ptr = (void*)fe->ops.release;
	if (ptr) {

If I don't define the release handler for the frontend, the modules
ref-counter stays 0 as expected.

2) Is there any chance to change the "struct dvb_usb_rc_key" defined in
dvb-usb.h as currently it contains two fields of type u8, while the
Cinergy T² device sepcs say that the device sends 32-bit remote control
codes and therefore I don't know how to get the Cinergy T² remote
controller handling to fit the current dvb-usb system ... ?
(this can be seen in the current Cinergy T² driver sources as well)

struct dvb_usb_rc_key {
	u8 custom,data;
	u32 event;

Tomi Orava

-------------- next part --------------
A non-text attachment was scrubbed...
Name: dvb-usb-cinergyT2-v2.diff
Type: text/x-patch
Size: 29058 bytes
Desc: not available
Url : http://www.linuxtv.org/pipermail/linux-dvb/attachments/20070922/5f4097ec/attachment-0001.bin 

More information about the linux-dvb mailing list