Lines Matching refs:ret

33 	int ret;  in m88rs6000t_set_demod_mclk()  local
36 ret = regmap_read(dev->regmap, 0x15, &utmp); in m88rs6000t_set_demod_mclk()
37 if (ret) in m88rs6000t_set_demod_mclk()
98 ret = regmap_read(dev->regmap, 0x1D, &utmp); in m88rs6000t_set_demod_mclk()
99 if (ret) in m88rs6000t_set_demod_mclk()
108 ret = regmap_write(dev->regmap, 0x05, 0x40); in m88rs6000t_set_demod_mclk()
109 if (ret) in m88rs6000t_set_demod_mclk()
111 ret = regmap_write(dev->regmap, 0x11, 0x08); in m88rs6000t_set_demod_mclk()
112 if (ret) in m88rs6000t_set_demod_mclk()
114 ret = regmap_write(dev->regmap, 0x15, reg15); in m88rs6000t_set_demod_mclk()
115 if (ret) in m88rs6000t_set_demod_mclk()
117 ret = regmap_write(dev->regmap, 0x16, reg16); in m88rs6000t_set_demod_mclk()
118 if (ret) in m88rs6000t_set_demod_mclk()
120 ret = regmap_write(dev->regmap, 0x1D, reg1D); in m88rs6000t_set_demod_mclk()
121 if (ret) in m88rs6000t_set_demod_mclk()
123 ret = regmap_write(dev->regmap, 0x1E, reg1E); in m88rs6000t_set_demod_mclk()
124 if (ret) in m88rs6000t_set_demod_mclk()
126 ret = regmap_write(dev->regmap, 0x1F, reg1F); in m88rs6000t_set_demod_mclk()
127 if (ret) in m88rs6000t_set_demod_mclk()
129 ret = regmap_write(dev->regmap, 0x17, 0xc1); in m88rs6000t_set_demod_mclk()
130 if (ret) in m88rs6000t_set_demod_mclk()
132 ret = regmap_write(dev->regmap, 0x17, 0x81); in m88rs6000t_set_demod_mclk()
133 if (ret) in m88rs6000t_set_demod_mclk()
136 ret = regmap_write(dev->regmap, 0x05, 0x00); in m88rs6000t_set_demod_mclk()
137 if (ret) in m88rs6000t_set_demod_mclk()
139 ret = regmap_write(dev->regmap, 0x11, reg11); in m88rs6000t_set_demod_mclk()
140 if (ret) in m88rs6000t_set_demod_mclk()
144 if (ret) in m88rs6000t_set_demod_mclk()
145 dev_dbg(&dev->client->dev, "failed=%d\n", ret); in m88rs6000t_set_demod_mclk()
146 return ret; in m88rs6000t_set_demod_mclk()
156 int ret; in m88rs6000t_set_pll_freq() local
161 ret = regmap_write(dev->regmap, 0x36, (refDiv - 8)); in m88rs6000t_set_pll_freq()
162 if (ret) in m88rs6000t_set_pll_freq()
164 ret = regmap_write(dev->regmap, 0x31, 0x00); in m88rs6000t_set_pll_freq()
165 if (ret) in m88rs6000t_set_pll_freq()
167 ret = regmap_write(dev->regmap, 0x2c, 0x02); in m88rs6000t_set_pll_freq()
168 if (ret) in m88rs6000t_set_pll_freq()
219 ret = regmap_write(dev->regmap, 0x27, reg27); in m88rs6000t_set_pll_freq()
220 if (ret) in m88rs6000t_set_pll_freq()
222 ret = regmap_write(dev->regmap, 0x28, (u8)(ulNDiv1 & 0xFF)); in m88rs6000t_set_pll_freq()
223 if (ret) in m88rs6000t_set_pll_freq()
226 ret = regmap_write(dev->regmap, 0x29, reg29); in m88rs6000t_set_pll_freq()
227 if (ret) in m88rs6000t_set_pll_freq()
229 ret = regmap_write(dev->regmap, 0x2a, (u8)(ulNDiv2 & 0xFF)); in m88rs6000t_set_pll_freq()
230 if (ret) in m88rs6000t_set_pll_freq()
232 ret = regmap_write(dev->regmap, 0x2F, 0xf5); in m88rs6000t_set_pll_freq()
233 if (ret) in m88rs6000t_set_pll_freq()
235 ret = regmap_write(dev->regmap, 0x30, 0x05); in m88rs6000t_set_pll_freq()
236 if (ret) in m88rs6000t_set_pll_freq()
238 ret = regmap_write(dev->regmap, 0x08, 0x1f); in m88rs6000t_set_pll_freq()
239 if (ret) in m88rs6000t_set_pll_freq()
241 ret = regmap_write(dev->regmap, 0x08, 0x3f); in m88rs6000t_set_pll_freq()
242 if (ret) in m88rs6000t_set_pll_freq()
244 ret = regmap_write(dev->regmap, 0x09, 0x20); in m88rs6000t_set_pll_freq()
245 if (ret) in m88rs6000t_set_pll_freq()
247 ret = regmap_write(dev->regmap, 0x09, 0x00); in m88rs6000t_set_pll_freq()
248 if (ret) in m88rs6000t_set_pll_freq()
250 ret = regmap_write(dev->regmap, 0x3e, 0x11); in m88rs6000t_set_pll_freq()
251 if (ret) in m88rs6000t_set_pll_freq()
253 ret = regmap_write(dev->regmap, 0x08, 0x2f); in m88rs6000t_set_pll_freq()
254 if (ret) in m88rs6000t_set_pll_freq()
256 ret = regmap_write(dev->regmap, 0x08, 0x3f); in m88rs6000t_set_pll_freq()
257 if (ret) in m88rs6000t_set_pll_freq()
259 ret = regmap_write(dev->regmap, 0x09, 0x10); in m88rs6000t_set_pll_freq()
260 if (ret) in m88rs6000t_set_pll_freq()
262 ret = regmap_write(dev->regmap, 0x09, 0x00); in m88rs6000t_set_pll_freq()
263 if (ret) in m88rs6000t_set_pll_freq()
267 ret = regmap_read(dev->regmap, 0x42, &utmp); in m88rs6000t_set_pll_freq()
268 if (ret) in m88rs6000t_set_pll_freq()
272 ret = regmap_write(dev->regmap, 0x3e, 0x10); in m88rs6000t_set_pll_freq()
273 if (ret) in m88rs6000t_set_pll_freq()
275 ret = regmap_write(dev->regmap, 0x08, 0x2f); in m88rs6000t_set_pll_freq()
276 if (ret) in m88rs6000t_set_pll_freq()
278 ret = regmap_write(dev->regmap, 0x08, 0x3f); in m88rs6000t_set_pll_freq()
279 if (ret) in m88rs6000t_set_pll_freq()
281 ret = regmap_write(dev->regmap, 0x09, 0x10); in m88rs6000t_set_pll_freq()
282 if (ret) in m88rs6000t_set_pll_freq()
284 ret = regmap_write(dev->regmap, 0x09, 0x00); in m88rs6000t_set_pll_freq()
285 if (ret) in m88rs6000t_set_pll_freq()
289 ret = regmap_read(dev->regmap, 0x42, &utmp); in m88rs6000t_set_pll_freq()
290 if (ret) in m88rs6000t_set_pll_freq()
294 ret = regmap_write(dev->regmap, 0x3e, 0x11); in m88rs6000t_set_pll_freq()
295 if (ret) in m88rs6000t_set_pll_freq()
300 ret = regmap_read(dev->regmap, 0x2d, &utmp); in m88rs6000t_set_pll_freq()
301 if (ret) in m88rs6000t_set_pll_freq()
303 ret = regmap_write(dev->regmap, 0x2d, utmp); in m88rs6000t_set_pll_freq()
304 if (ret) in m88rs6000t_set_pll_freq()
306 ret = regmap_read(dev->regmap, 0x2e, &utmp); in m88rs6000t_set_pll_freq()
307 if (ret) in m88rs6000t_set_pll_freq()
309 ret = regmap_write(dev->regmap, 0x2e, utmp); in m88rs6000t_set_pll_freq()
310 if (ret) in m88rs6000t_set_pll_freq()
313 ret = regmap_read(dev->regmap, 0x27, &utmp); in m88rs6000t_set_pll_freq()
314 if (ret) in m88rs6000t_set_pll_freq()
317 ret = regmap_read(dev->regmap, 0x83, &utmp); in m88rs6000t_set_pll_freq()
318 if (ret) in m88rs6000t_set_pll_freq()
332 ret = regmap_write(dev->regmap, 0x36, (refDiv - 8)); in m88rs6000t_set_pll_freq()
333 if (ret) in m88rs6000t_set_pll_freq()
341 ret = regmap_write(dev->regmap, 0x27, reg27); in m88rs6000t_set_pll_freq()
342 if (ret) in m88rs6000t_set_pll_freq()
344 ret = regmap_write(dev->regmap, 0x28, (u8)(ulNDiv & 0xFF)); in m88rs6000t_set_pll_freq()
345 if (ret) in m88rs6000t_set_pll_freq()
347 ret = regmap_write(dev->regmap, 0x29, 0x80); in m88rs6000t_set_pll_freq()
348 if (ret) in m88rs6000t_set_pll_freq()
350 ret = regmap_write(dev->regmap, 0x31, 0x03); in m88rs6000t_set_pll_freq()
351 if (ret) in m88rs6000t_set_pll_freq()
358 ret = regmap_write(dev->regmap, 0x3b, utmp); in m88rs6000t_set_pll_freq()
359 if (ret) in m88rs6000t_set_pll_freq()
367 if (ret) in m88rs6000t_set_pll_freq()
368 dev_dbg(&dev->client->dev, "failed=%d\n", ret); in m88rs6000t_set_pll_freq()
369 return ret; in m88rs6000t_set_pll_freq()
389 int ret; in m88rs6000t_set_params() local
405 ret = m88rs6000t_set_pll_freq(dev, freq_MHz); in m88rs6000t_set_params()
406 if (ret) in m88rs6000t_set_params()
408 ret = m88rs6000t_set_bb(dev, c->symbol_rate / 1000, lpf_offset_KHz); in m88rs6000t_set_params()
409 if (ret) in m88rs6000t_set_params()
411 ret = regmap_write(dev->regmap, 0x00, 0x01); in m88rs6000t_set_params()
412 if (ret) in m88rs6000t_set_params()
414 ret = regmap_write(dev->regmap, 0x00, 0x00); in m88rs6000t_set_params()
415 if (ret) in m88rs6000t_set_params()
418 ret = m88rs6000t_set_demod_mclk(fe); in m88rs6000t_set_params()
420 if (ret) in m88rs6000t_set_params()
421 dev_dbg(&dev->client->dev, "failed=%d\n", ret); in m88rs6000t_set_params()
422 return ret; in m88rs6000t_set_params()
428 int ret; in m88rs6000t_init() local
432 ret = regmap_update_bits(dev->regmap, 0x11, 0x08, 0x08); in m88rs6000t_init()
433 if (ret) in m88rs6000t_init()
436 ret = regmap_update_bits(dev->regmap, 0x10, 0x01, 0x01); in m88rs6000t_init()
437 if (ret) in m88rs6000t_init()
440 ret = regmap_write(dev->regmap, 0x07, 0x7d); in m88rs6000t_init()
442 if (ret) in m88rs6000t_init()
443 dev_dbg(&dev->client->dev, "failed=%d\n", ret); in m88rs6000t_init()
444 return ret; in m88rs6000t_init()
450 int ret; in m88rs6000t_sleep() local
454 ret = regmap_write(dev->regmap, 0x07, 0x6d); in m88rs6000t_sleep()
455 if (ret) { in m88rs6000t_sleep()
456 dev_dbg(&dev->client->dev, "failed=%d\n", ret); in m88rs6000t_sleep()
457 return ret; in m88rs6000t_sleep()
488 int ret; in m88rs6000t_get_rf_strength() local
501 ret = regmap_read(dev->regmap, 0x5A, &val); in m88rs6000t_get_rf_strength()
502 if (ret) in m88rs6000t_get_rf_strength()
506 ret = regmap_read(dev->regmap, 0x5F, &val); in m88rs6000t_get_rf_strength()
507 if (ret) in m88rs6000t_get_rf_strength()
511 ret = regmap_read(dev->regmap, 0x3F, &val); in m88rs6000t_get_rf_strength()
512 if (ret) in m88rs6000t_get_rf_strength()
516 ret = regmap_read(dev->regmap, 0x77, &val); in m88rs6000t_get_rf_strength()
517 if (ret) in m88rs6000t_get_rf_strength()
521 ret = regmap_read(dev->regmap, 0x76, &val); in m88rs6000t_get_rf_strength()
522 if (ret) in m88rs6000t_get_rf_strength()
556 if (ret) in m88rs6000t_get_rf_strength()
557 dev_dbg(&dev->client->dev, "failed=%d\n", ret); in m88rs6000t_get_rf_strength()
558 return ret; in m88rs6000t_get_rf_strength()
582 int ret, i; in m88rs6000t_probe() local
618 ret = -ENOMEM; in m88rs6000t_probe()
627 ret = PTR_ERR(dev->regmap); in m88rs6000t_probe()
631 ret = regmap_update_bits(dev->regmap, 0x11, 0x08, 0x08); in m88rs6000t_probe()
632 if (ret) in m88rs6000t_probe()
635 ret = regmap_update_bits(dev->regmap, 0x10, 0x01, 0x01); in m88rs6000t_probe()
636 if (ret) in m88rs6000t_probe()
639 ret = regmap_write(dev->regmap, 0x07, 0x7d); in m88rs6000t_probe()
640 if (ret) in m88rs6000t_probe()
642 ret = regmap_write(dev->regmap, 0x04, 0x01); in m88rs6000t_probe()
643 if (ret) in m88rs6000t_probe()
647 ret = regmap_read(dev->regmap, 0x01, &utmp); in m88rs6000t_probe()
648 if (ret) in m88rs6000t_probe()
652 ret = -ENODEV; in m88rs6000t_probe()
657 ret = regmap_write(dev->regmap, 0x05, 0x40); in m88rs6000t_probe()
658 if (ret) in m88rs6000t_probe()
660 ret = regmap_write(dev->regmap, 0x11, 0x08); in m88rs6000t_probe()
661 if (ret) in m88rs6000t_probe()
663 ret = regmap_write(dev->regmap, 0x15, 0x6c); in m88rs6000t_probe()
664 if (ret) in m88rs6000t_probe()
666 ret = regmap_write(dev->regmap, 0x17, 0xc1); in m88rs6000t_probe()
667 if (ret) in m88rs6000t_probe()
669 ret = regmap_write(dev->regmap, 0x17, 0x81); in m88rs6000t_probe()
670 if (ret) in m88rs6000t_probe()
673 ret = regmap_write(dev->regmap, 0x05, 0x00); in m88rs6000t_probe()
674 if (ret) in m88rs6000t_probe()
676 ret = regmap_write(dev->regmap, 0x11, 0x0a); in m88rs6000t_probe()
677 if (ret) in m88rs6000t_probe()
681 ret = regmap_write(dev->regmap, in m88rs6000t_probe()
683 if (ret) in m88rs6000t_probe()
695 dev_dbg(&client->dev, "failed=%d\n", ret); in m88rs6000t_probe()
697 return ret; in m88rs6000t_probe()