On Saturday 19 March 2005 17:37, Patrick Boettcher wrote: > On Sat, 19 Mar 2005, Kenneth Aafl?y wrote: > > While doing cleanups for the mt352 frontend to remove that ugly mt352_write > > function, converting it to single register writereg style, I found what > > appears to be a copy/paste bug in dvb-bt8xx.c, which I have now fixed to > > contain the correct register as per the datasheet. > > I once introduced this ugly write, because the dibusb-device which uses > the mt352 is only able to write one reg at a time. > > At that time some suggested to place it in dibusb instead of mt352, I > ignored that, but now I know this is the right way to go. > > Did you already commit the change? Because I then have to change dibusb > accordingly. I have not gotten around to committing it yet, and I'm not sure I get why dibusb has to be changed either. I've attached the patch for mt352* so you can have a look at it. It has the following cleanups: - remove casting of void* - remove status values from state - rename mt352_single_write to mt352_writeregI - rename mt352_read_register to mt352_readregI - use state as parameter to mt352_writeregI - convert all i2c reads|writes to use mt352_(read|write)regI - add mt352_(read|write)reg which is exported and takes frontend * - use -EREMOTEIO not -EIO for i2c errors Kenneth -------------- next part -------------- A non-text attachment was scrubbed... Name: mt352.patch Type: text/x-diff Size: 12279 bytes Desc: not available Url : http://www.linuxtv.org/pipermail/linux-dvb/attachments/20050319/ad224c71/mt352.bin