Manu, 1) thanks for prompt reply, 2) see inline: > -----Original Message----- > From: Manu Abraham [mailto:abraham.manu@xxxxxxxxx] > Sent: Wednesday, August 01, 2007 9:18 PM > To: Akiva Sadovski > Cc: linux-dvb@xxxxxxxxxxx > Subject: Re: dvb_ca_en50221.c,h - a hook needed > > > Hi, > > On 8/1/07, Akiva Sadovski <akivas@xxxxxxxxxx> wrote: > > > > > > > > Dear all, > > I'm working on a driver for a SCM's CIMaX chip > > (http://www.scmmicro.com/ir/pdf/10K-Q4-04.pdf - DVB-CI > > interface). The driver is supposed to be used at our proprietary HW > > platform. I'd like to use the dvb-core as a (great) > platform for the driver. > > However, IMHO it lacks the following functionality: > > > > before using the CIMaX chip I have to set up some registers that > > configure the voltages it uses, pin assignment etc, > > > use that part in the cimax driver, assigning voltages, pin > assignments etc. > > > > the most natural place to do it is while open()-ing the > device, but the > > dvb_ca_en50221_io_open() has no hook > > (smth like int (*slot_reset)() ) available, > > > To reset, use CA_RESET. Since the CiMax just follows EN50221, the > device specifies that the modules are daisy chained according to > EN50221, see page 16 of the CiMax datasheet. (Don't know whether you > have the same datasheet, what i have is Rev A, 7-Sep-01) > > See also 5.4.4 en50221. Also A.2.2.1. > > But i didn't really follow this part, if you mean the Hot Insertion > feature on the CIMAx, just add in flag to say ca->flags (you need to > define the flag though) and just do the code run conditionally based > on the flag, say something like DVB_CA_EN50221_HOT_INSERT to > conditionally enable the Reset code in dvb_ca_en50221. > > That would help ? Is that what you were asking ? Not exactly. Let's put it this way: 1. before starting to work with cimax I have to: 1.1 reset the chip (it controls 2 CAM slots) 1.2 configure some cimax registers - these registers will remain unchanged until next power down / power up 2. I prefer not to do these tasks in int (*slot_reset)(struct dvb_ca_en50221* ca, int slot); hook, since it's activated per CAM slot and I'd prefer something device-wide [my 'device' is the cimax controlling two CAM slots] 3. IMHO the ideal place for such a hook will be somewhere in dvb_ca_en50221_io_open() function... Have I explained myself, best regards, Akiva S. > > > > and I don't want to put any chip-wide initialization > code to driver's > > init function (the driver is supposed to deal with > > with few CIMaXes) > > device specific code has to go into the device specific driver alone. > > > Manu > _______________________________________________ linux-dvb mailing list linux-dvb@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb