Lines Matching refs:client
113 static int tda9875_write(struct i2c_client *client, int subaddr, unsigned char val) in tda9875_write() argument
120 if (2 != i2c_master_send(client,buffer,2)) { in tda9875_write()
129 static int tda9875_read(struct i2c_client *client)
133 if (1 != i2c_master_recv(client,&buffer,1)) {
160 static void tda9875_set(struct i2c_client *client) in tda9875_set() argument
162 struct tda9875 *tda = i2c_get_clientdata(client); in tda9875_set()
170 tda9875_write(client, TDA9875_MVL, a); in tda9875_set()
172 tda9875_write(client, TDA9875_MVR, a); in tda9875_set()
174 tda9875_write(client, TDA9875_MBA, a); in tda9875_set()
176 tda9875_write(client, TDA9875_MTR, a); in tda9875_set()
179 static void do_tda9875_init(struct i2c_client *client) in do_tda9875_init() argument
181 struct tda9875 *t = i2c_get_clientdata(client); in do_tda9875_init()
183 tda9875_write(client, TDA9875_CFG, 0xd0 ); /*reg de config 0 (reset)*/ in do_tda9875_init()
184 tda9875_write(client, TDA9875_MSR, 0x03 ); /* Monitor 0b00000XXX*/ in do_tda9875_init()
185 tda9875_write(client, TDA9875_C1MSB, 0x00 ); /*Car1(FM) MSB XMHz*/ in do_tda9875_init()
186 tda9875_write(client, TDA9875_C1MIB, 0x00 ); /*Car1(FM) MIB XMHz*/ in do_tda9875_init()
187 tda9875_write(client, TDA9875_C1LSB, 0x00 ); /*Car1(FM) LSB XMHz*/ in do_tda9875_init()
188 tda9875_write(client, TDA9875_C2MSB, 0x00 ); /*Car2(NICAM) MSB XMHz*/ in do_tda9875_init()
189 tda9875_write(client, TDA9875_C2MIB, 0x00 ); /*Car2(NICAM) MIB XMHz*/ in do_tda9875_init()
190 tda9875_write(client, TDA9875_C2LSB, 0x00 ); /*Car2(NICAM) LSB XMHz*/ in do_tda9875_init()
191 tda9875_write(client, TDA9875_DCR, 0x00 ); /*Demod config 0x00*/ in do_tda9875_init()
192 tda9875_write(client, TDA9875_DEEM, 0x44 ); /*DE-Emph 0b0100 0100*/ in do_tda9875_init()
193 tda9875_write(client, TDA9875_FMAT, 0x00 ); /*FM Matrix reg 0x00*/ in do_tda9875_init()
194 tda9875_write(client, TDA9875_SC1, 0x00 ); /* SCART 1 (SC1)*/ in do_tda9875_init()
195 tda9875_write(client, TDA9875_SC2, 0x01 ); /* SCART 2 (sc2)*/ in do_tda9875_init()
197 tda9875_write(client, TDA9875_CH1V, 0x10 ); /* Channel volume 1 mute*/ in do_tda9875_init()
198 tda9875_write(client, TDA9875_CH2V, 0x10 ); /* Channel volume 2 mute */ in do_tda9875_init()
199 tda9875_write(client, TDA9875_DACOS, 0x02 ); /* sig DAC i/o(in:nicam)*/ in do_tda9875_init()
200 tda9875_write(client, TDA9875_ADCIS, 0x6f ); /* sig ADC input(in:mono)*/ in do_tda9875_init()
201 tda9875_write(client, TDA9875_LOSR, 0x00 ); /* line out (in:mono)*/ in do_tda9875_init()
202 tda9875_write(client, TDA9875_AER, 0x00 ); /*06 Effect (AVL+PSEUDO) */ in do_tda9875_init()
203 tda9875_write(client, TDA9875_MCS, 0x44 ); /* Main ch select (DAC) */ in do_tda9875_init()
204 tda9875_write(client, TDA9875_MVL, 0x03 ); /* Vol Main left 10dB */ in do_tda9875_init()
205 tda9875_write(client, TDA9875_MVR, 0x03 ); /* Vol Main right 10dB*/ in do_tda9875_init()
206 tda9875_write(client, TDA9875_MBA, 0x00 ); /* Main Bass Main 0dB*/ in do_tda9875_init()
207 tda9875_write(client, TDA9875_MTR, 0x00 ); /* Main Treble Main 0dB*/ in do_tda9875_init()
208 tda9875_write(client, TDA9875_ACS, 0x44 ); /* Aux chan select (dac)*/ in do_tda9875_init()
209 tda9875_write(client, TDA9875_AVL, 0x00 ); /* Vol Aux left 0dB*/ in do_tda9875_init()
210 tda9875_write(client, TDA9875_AVR, 0x00 ); /* Vol Aux right 0dB*/ in do_tda9875_init()
211 tda9875_write(client, TDA9875_ABA, 0x00 ); /* Aux Bass Main 0dB*/ in do_tda9875_init()
212 tda9875_write(client, TDA9875_ATR, 0x00 ); /* Aux Aigus Main 0dB*/ in do_tda9875_init()
214 tda9875_write(client, TDA9875_MUT, 0xcc ); /* General mute */ in do_tda9875_init()
220 tda9875_set(client); in do_tda9875_init()
249 struct i2c_client *client; in tda9875_attach() local
257 client = &t->c; in tda9875_attach()
258 memcpy(client,&client_template,sizeof(struct i2c_client)); in tda9875_attach()
259 client->adapter = adap; in tda9875_attach()
260 client->addr = addr; in tda9875_attach()
261 i2c_set_clientdata(client, t); in tda9875_attach()
268 do_tda9875_init(client); in tda9875_attach()
272 i2c_attach_client(client); in tda9875_attach()
288 static int tda9875_detach(struct i2c_client *client) in tda9875_detach() argument
290 struct tda9875 *t = i2c_get_clientdata(client); in tda9875_detach()
292 do_tda9875_init(client); in tda9875_detach()
293 i2c_detach_client(client); in tda9875_detach()
300 static int tda9875_command(struct i2c_client *client, in tda9875_command() argument
303 struct tda9875 *t = i2c_get_clientdata(client); in tda9875_command()
376 tda9875_set(client); in tda9875_command()