Mailing List archive

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

[linux-dvb] Re: refactoring



On Friday 08 Oct 2004 13:03, Gerd Knorr wrote:
> Andrew de Quincey <adq_dvb@lidskialf.net> writes:
> > > It should always be possible to determine on the register/device
> > > state whether a firmware reload in init() is required, not? Is
> > > anything serious done in the detach() functions?
> >
> > Now that I've removed the i2c_driver stuff,
>
> Oh, no, not *this* again please.  What the heck is the reason to not
> use the kernel i2c stuff?  I think we had discussed that ...

I have removed the kernel i2c_driver structures because we do not need it.

I have left it using the kernel i2c_adapter stuff, and i2c_transfer() 
functions as before.

> > the only thing done in the _detach() functions is
> > dvb_unregister_adapter().
>
> And free the drivers private data.  And any other cleanups the driver
> migth have to do depending on the hardware.  We certainly need a
> detach function.

There is no private data any longer. There is only one function which needs 
cleanup really, and that can be done in a different way. Have to see how it 
goes really.

> It could be part of the function pointer struct through.  So the only
> thing exported by the module is the attach function and everything
> else (including detach) can be accessed indirectly via function
> pointers.

Yeah.




Home | Main Index | Thread Index