Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linux-dvb] Re: [rfc/patch] pll handling and cx22702 update



[ ... back from xmas holidays ... ]

  Hi,

happy new year to everyone ;)

> Lemme know what you think...

> static int tuner_generic_init(struct dvb_tuner_desc* desc, dvb_tuner_ops* ops)
> {
> 	u8* buf;
> 
> 	buf = alloca(desc->tuner_data_size);
> 	if (buf == NULL)
> 		return -ENOMEM;
> 
> 	memcpy(buf, desc->init_data, desc->tuner_data_size);
> 	return ops->write(desc, ops, 0, buf, desc->tuner_data_size);
> }

The ops->write() scares me, I think that isn't going to work with
mt352-based frontends.

I *intentionally* havn't done it that way but let the generic code
just calculate the four bytes needed to program the tuners and *nothing*
else.

Also note that I just want catch the 90% of the tuners which can be
driven that way with 4-byte command sequences.  There is also no point
in squezzing *every* tuner into that model, that will vanish the
advantages because it becomes to complex then (see the dynamic memory
alloc stuff you've started doing for example).  Don't overdesign it
*please*.

  Gerd

-- 
#define printk(args...) fprintf(stderr, ## args)




Home | Main Index | Thread Index