Lines Matching refs:state

298 static u16 MXL_GetMasterControl(u8 *MasterReg, int state);
339 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_SetRfFreqHz() local
354 ByteTable[0] |= state->config->AgcMasterByte; in mxl5005s_SetRfFreqHz()
371 state->config->AgcMasterByte; in mxl5005s_SetRfFreqHz()
387 state->config->AgcMasterByte ; in mxl5005s_SetRfFreqHz()
404 struct mxl5005s_state *state = fe->tuner_priv; in MXL5005_RegisterInit() local
405 state->TunerRegs_Num = TUNER_REGS_NUM ; in MXL5005_RegisterInit()
407 state->TunerRegs[0].Reg_Num = 9 ; in MXL5005_RegisterInit()
408 state->TunerRegs[0].Reg_Val = 0x40 ; in MXL5005_RegisterInit()
410 state->TunerRegs[1].Reg_Num = 11 ; in MXL5005_RegisterInit()
411 state->TunerRegs[1].Reg_Val = 0x19 ; in MXL5005_RegisterInit()
413 state->TunerRegs[2].Reg_Num = 12 ; in MXL5005_RegisterInit()
414 state->TunerRegs[2].Reg_Val = 0x60 ; in MXL5005_RegisterInit()
416 state->TunerRegs[3].Reg_Num = 13 ; in MXL5005_RegisterInit()
417 state->TunerRegs[3].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
419 state->TunerRegs[4].Reg_Num = 14 ; in MXL5005_RegisterInit()
420 state->TunerRegs[4].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
422 state->TunerRegs[5].Reg_Num = 15 ; in MXL5005_RegisterInit()
423 state->TunerRegs[5].Reg_Val = 0xC0 ; in MXL5005_RegisterInit()
425 state->TunerRegs[6].Reg_Num = 16 ; in MXL5005_RegisterInit()
426 state->TunerRegs[6].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
428 state->TunerRegs[7].Reg_Num = 17 ; in MXL5005_RegisterInit()
429 state->TunerRegs[7].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
431 state->TunerRegs[8].Reg_Num = 18 ; in MXL5005_RegisterInit()
432 state->TunerRegs[8].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
434 state->TunerRegs[9].Reg_Num = 19 ; in MXL5005_RegisterInit()
435 state->TunerRegs[9].Reg_Val = 0x34 ; in MXL5005_RegisterInit()
437 state->TunerRegs[10].Reg_Num = 21 ; in MXL5005_RegisterInit()
438 state->TunerRegs[10].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
440 state->TunerRegs[11].Reg_Num = 22 ; in MXL5005_RegisterInit()
441 state->TunerRegs[11].Reg_Val = 0x6B ; in MXL5005_RegisterInit()
443 state->TunerRegs[12].Reg_Num = 23 ; in MXL5005_RegisterInit()
444 state->TunerRegs[12].Reg_Val = 0x35 ; in MXL5005_RegisterInit()
446 state->TunerRegs[13].Reg_Num = 24 ; in MXL5005_RegisterInit()
447 state->TunerRegs[13].Reg_Val = 0x70 ; in MXL5005_RegisterInit()
449 state->TunerRegs[14].Reg_Num = 25 ; in MXL5005_RegisterInit()
450 state->TunerRegs[14].Reg_Val = 0x3E ; in MXL5005_RegisterInit()
452 state->TunerRegs[15].Reg_Num = 26 ; in MXL5005_RegisterInit()
453 state->TunerRegs[15].Reg_Val = 0x82 ; in MXL5005_RegisterInit()
455 state->TunerRegs[16].Reg_Num = 31 ; in MXL5005_RegisterInit()
456 state->TunerRegs[16].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
458 state->TunerRegs[17].Reg_Num = 32 ; in MXL5005_RegisterInit()
459 state->TunerRegs[17].Reg_Val = 0x40 ; in MXL5005_RegisterInit()
461 state->TunerRegs[18].Reg_Num = 33 ; in MXL5005_RegisterInit()
462 state->TunerRegs[18].Reg_Val = 0x53 ; in MXL5005_RegisterInit()
464 state->TunerRegs[19].Reg_Num = 34 ; in MXL5005_RegisterInit()
465 state->TunerRegs[19].Reg_Val = 0x81 ; in MXL5005_RegisterInit()
467 state->TunerRegs[20].Reg_Num = 35 ; in MXL5005_RegisterInit()
468 state->TunerRegs[20].Reg_Val = 0xC9 ; in MXL5005_RegisterInit()
470 state->TunerRegs[21].Reg_Num = 36 ; in MXL5005_RegisterInit()
471 state->TunerRegs[21].Reg_Val = 0x01 ; in MXL5005_RegisterInit()
473 state->TunerRegs[22].Reg_Num = 37 ; in MXL5005_RegisterInit()
474 state->TunerRegs[22].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
476 state->TunerRegs[23].Reg_Num = 41 ; in MXL5005_RegisterInit()
477 state->TunerRegs[23].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
479 state->TunerRegs[24].Reg_Num = 42 ; in MXL5005_RegisterInit()
480 state->TunerRegs[24].Reg_Val = 0xF8 ; in MXL5005_RegisterInit()
482 state->TunerRegs[25].Reg_Num = 43 ; in MXL5005_RegisterInit()
483 state->TunerRegs[25].Reg_Val = 0x43 ; in MXL5005_RegisterInit()
485 state->TunerRegs[26].Reg_Num = 44 ; in MXL5005_RegisterInit()
486 state->TunerRegs[26].Reg_Val = 0x20 ; in MXL5005_RegisterInit()
488 state->TunerRegs[27].Reg_Num = 45 ; in MXL5005_RegisterInit()
489 state->TunerRegs[27].Reg_Val = 0x80 ; in MXL5005_RegisterInit()
491 state->TunerRegs[28].Reg_Num = 46 ; in MXL5005_RegisterInit()
492 state->TunerRegs[28].Reg_Val = 0x88 ; in MXL5005_RegisterInit()
494 state->TunerRegs[29].Reg_Num = 47 ; in MXL5005_RegisterInit()
495 state->TunerRegs[29].Reg_Val = 0x86 ; in MXL5005_RegisterInit()
497 state->TunerRegs[30].Reg_Num = 48 ; in MXL5005_RegisterInit()
498 state->TunerRegs[30].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
500 state->TunerRegs[31].Reg_Num = 49 ; in MXL5005_RegisterInit()
501 state->TunerRegs[31].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
503 state->TunerRegs[32].Reg_Num = 53 ; in MXL5005_RegisterInit()
504 state->TunerRegs[32].Reg_Val = 0x94 ; in MXL5005_RegisterInit()
506 state->TunerRegs[33].Reg_Num = 54 ; in MXL5005_RegisterInit()
507 state->TunerRegs[33].Reg_Val = 0xFA ; in MXL5005_RegisterInit()
509 state->TunerRegs[34].Reg_Num = 55 ; in MXL5005_RegisterInit()
510 state->TunerRegs[34].Reg_Val = 0x92 ; in MXL5005_RegisterInit()
512 state->TunerRegs[35].Reg_Num = 56 ; in MXL5005_RegisterInit()
513 state->TunerRegs[35].Reg_Val = 0x80 ; in MXL5005_RegisterInit()
515 state->TunerRegs[36].Reg_Num = 57 ; in MXL5005_RegisterInit()
516 state->TunerRegs[36].Reg_Val = 0x41 ; in MXL5005_RegisterInit()
518 state->TunerRegs[37].Reg_Num = 58 ; in MXL5005_RegisterInit()
519 state->TunerRegs[37].Reg_Val = 0xDB ; in MXL5005_RegisterInit()
521 state->TunerRegs[38].Reg_Num = 59 ; in MXL5005_RegisterInit()
522 state->TunerRegs[38].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
524 state->TunerRegs[39].Reg_Num = 60 ; in MXL5005_RegisterInit()
525 state->TunerRegs[39].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
527 state->TunerRegs[40].Reg_Num = 61 ; in MXL5005_RegisterInit()
528 state->TunerRegs[40].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
530 state->TunerRegs[41].Reg_Num = 62 ; in MXL5005_RegisterInit()
531 state->TunerRegs[41].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
533 state->TunerRegs[42].Reg_Num = 65 ; in MXL5005_RegisterInit()
534 state->TunerRegs[42].Reg_Val = 0xF8 ; in MXL5005_RegisterInit()
536 state->TunerRegs[43].Reg_Num = 66 ; in MXL5005_RegisterInit()
537 state->TunerRegs[43].Reg_Val = 0xE4 ; in MXL5005_RegisterInit()
539 state->TunerRegs[44].Reg_Num = 67 ; in MXL5005_RegisterInit()
540 state->TunerRegs[44].Reg_Val = 0x90 ; in MXL5005_RegisterInit()
542 state->TunerRegs[45].Reg_Num = 68 ; in MXL5005_RegisterInit()
543 state->TunerRegs[45].Reg_Val = 0xC0 ; in MXL5005_RegisterInit()
545 state->TunerRegs[46].Reg_Num = 69 ; in MXL5005_RegisterInit()
546 state->TunerRegs[46].Reg_Val = 0x01 ; in MXL5005_RegisterInit()
548 state->TunerRegs[47].Reg_Num = 70 ; in MXL5005_RegisterInit()
549 state->TunerRegs[47].Reg_Val = 0x50 ; in MXL5005_RegisterInit()
551 state->TunerRegs[48].Reg_Num = 71 ; in MXL5005_RegisterInit()
552 state->TunerRegs[48].Reg_Val = 0x06 ; in MXL5005_RegisterInit()
554 state->TunerRegs[49].Reg_Num = 72 ; in MXL5005_RegisterInit()
555 state->TunerRegs[49].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
557 state->TunerRegs[50].Reg_Num = 73 ; in MXL5005_RegisterInit()
558 state->TunerRegs[50].Reg_Val = 0x20 ; in MXL5005_RegisterInit()
560 state->TunerRegs[51].Reg_Num = 76 ; in MXL5005_RegisterInit()
561 state->TunerRegs[51].Reg_Val = 0xBB ; in MXL5005_RegisterInit()
563 state->TunerRegs[52].Reg_Num = 77 ; in MXL5005_RegisterInit()
564 state->TunerRegs[52].Reg_Val = 0x13 ; in MXL5005_RegisterInit()
566 state->TunerRegs[53].Reg_Num = 81 ; in MXL5005_RegisterInit()
567 state->TunerRegs[53].Reg_Val = 0x04 ; in MXL5005_RegisterInit()
569 state->TunerRegs[54].Reg_Num = 82 ; in MXL5005_RegisterInit()
570 state->TunerRegs[54].Reg_Val = 0x75 ; in MXL5005_RegisterInit()
572 state->TunerRegs[55].Reg_Num = 83 ; in MXL5005_RegisterInit()
573 state->TunerRegs[55].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
575 state->TunerRegs[56].Reg_Num = 84 ; in MXL5005_RegisterInit()
576 state->TunerRegs[56].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
578 state->TunerRegs[57].Reg_Num = 85 ; in MXL5005_RegisterInit()
579 state->TunerRegs[57].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
581 state->TunerRegs[58].Reg_Num = 91 ; in MXL5005_RegisterInit()
582 state->TunerRegs[58].Reg_Val = 0x70 ; in MXL5005_RegisterInit()
584 state->TunerRegs[59].Reg_Num = 92 ; in MXL5005_RegisterInit()
585 state->TunerRegs[59].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
587 state->TunerRegs[60].Reg_Num = 93 ; in MXL5005_RegisterInit()
588 state->TunerRegs[60].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
590 state->TunerRegs[61].Reg_Num = 94 ; in MXL5005_RegisterInit()
591 state->TunerRegs[61].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
593 state->TunerRegs[62].Reg_Num = 95 ; in MXL5005_RegisterInit()
594 state->TunerRegs[62].Reg_Val = 0x0C ; in MXL5005_RegisterInit()
596 state->TunerRegs[63].Reg_Num = 96 ; in MXL5005_RegisterInit()
597 state->TunerRegs[63].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
599 state->TunerRegs[64].Reg_Num = 97 ; in MXL5005_RegisterInit()
600 state->TunerRegs[64].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
602 state->TunerRegs[65].Reg_Num = 98 ; in MXL5005_RegisterInit()
603 state->TunerRegs[65].Reg_Val = 0xE2 ; in MXL5005_RegisterInit()
605 state->TunerRegs[66].Reg_Num = 99 ; in MXL5005_RegisterInit()
606 state->TunerRegs[66].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
608 state->TunerRegs[67].Reg_Num = 100 ; in MXL5005_RegisterInit()
609 state->TunerRegs[67].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
611 state->TunerRegs[68].Reg_Num = 101 ; in MXL5005_RegisterInit()
612 state->TunerRegs[68].Reg_Val = 0x12 ; in MXL5005_RegisterInit()
614 state->TunerRegs[69].Reg_Num = 102 ; in MXL5005_RegisterInit()
615 state->TunerRegs[69].Reg_Val = 0x80 ; in MXL5005_RegisterInit()
617 state->TunerRegs[70].Reg_Num = 103 ; in MXL5005_RegisterInit()
618 state->TunerRegs[70].Reg_Val = 0x32 ; in MXL5005_RegisterInit()
620 state->TunerRegs[71].Reg_Num = 104 ; in MXL5005_RegisterInit()
621 state->TunerRegs[71].Reg_Val = 0xB4 ; in MXL5005_RegisterInit()
623 state->TunerRegs[72].Reg_Num = 105 ; in MXL5005_RegisterInit()
624 state->TunerRegs[72].Reg_Val = 0x60 ; in MXL5005_RegisterInit()
626 state->TunerRegs[73].Reg_Num = 106 ; in MXL5005_RegisterInit()
627 state->TunerRegs[73].Reg_Val = 0x83 ; in MXL5005_RegisterInit()
629 state->TunerRegs[74].Reg_Num = 107 ; in MXL5005_RegisterInit()
630 state->TunerRegs[74].Reg_Val = 0x84 ; in MXL5005_RegisterInit()
632 state->TunerRegs[75].Reg_Num = 108 ; in MXL5005_RegisterInit()
633 state->TunerRegs[75].Reg_Val = 0x9C ; in MXL5005_RegisterInit()
635 state->TunerRegs[76].Reg_Num = 109 ; in MXL5005_RegisterInit()
636 state->TunerRegs[76].Reg_Val = 0x02 ; in MXL5005_RegisterInit()
638 state->TunerRegs[77].Reg_Num = 110 ; in MXL5005_RegisterInit()
639 state->TunerRegs[77].Reg_Val = 0x81 ; in MXL5005_RegisterInit()
641 state->TunerRegs[78].Reg_Num = 111 ; in MXL5005_RegisterInit()
642 state->TunerRegs[78].Reg_Val = 0xC0 ; in MXL5005_RegisterInit()
644 state->TunerRegs[79].Reg_Num = 112 ; in MXL5005_RegisterInit()
645 state->TunerRegs[79].Reg_Val = 0x10 ; in MXL5005_RegisterInit()
647 state->TunerRegs[80].Reg_Num = 131 ; in MXL5005_RegisterInit()
648 state->TunerRegs[80].Reg_Val = 0x8A ; in MXL5005_RegisterInit()
650 state->TunerRegs[81].Reg_Num = 132 ; in MXL5005_RegisterInit()
651 state->TunerRegs[81].Reg_Val = 0x10 ; in MXL5005_RegisterInit()
653 state->TunerRegs[82].Reg_Num = 133 ; in MXL5005_RegisterInit()
654 state->TunerRegs[82].Reg_Val = 0x24 ; in MXL5005_RegisterInit()
656 state->TunerRegs[83].Reg_Num = 134 ; in MXL5005_RegisterInit()
657 state->TunerRegs[83].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
659 state->TunerRegs[84].Reg_Num = 135 ; in MXL5005_RegisterInit()
660 state->TunerRegs[84].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
662 state->TunerRegs[85].Reg_Num = 136 ; in MXL5005_RegisterInit()
663 state->TunerRegs[85].Reg_Val = 0x7E ; in MXL5005_RegisterInit()
665 state->TunerRegs[86].Reg_Num = 137 ; in MXL5005_RegisterInit()
666 state->TunerRegs[86].Reg_Val = 0x40 ; in MXL5005_RegisterInit()
668 state->TunerRegs[87].Reg_Num = 138 ; in MXL5005_RegisterInit()
669 state->TunerRegs[87].Reg_Val = 0x38 ; in MXL5005_RegisterInit()
671 state->TunerRegs[88].Reg_Num = 146 ; in MXL5005_RegisterInit()
672 state->TunerRegs[88].Reg_Val = 0xF6 ; in MXL5005_RegisterInit()
674 state->TunerRegs[89].Reg_Num = 147 ; in MXL5005_RegisterInit()
675 state->TunerRegs[89].Reg_Val = 0x1A ; in MXL5005_RegisterInit()
677 state->TunerRegs[90].Reg_Num = 148 ; in MXL5005_RegisterInit()
678 state->TunerRegs[90].Reg_Val = 0x62 ; in MXL5005_RegisterInit()
680 state->TunerRegs[91].Reg_Num = 149 ; in MXL5005_RegisterInit()
681 state->TunerRegs[91].Reg_Val = 0x33 ; in MXL5005_RegisterInit()
683 state->TunerRegs[92].Reg_Num = 150 ; in MXL5005_RegisterInit()
684 state->TunerRegs[92].Reg_Val = 0x80 ; in MXL5005_RegisterInit()
686 state->TunerRegs[93].Reg_Num = 156 ; in MXL5005_RegisterInit()
687 state->TunerRegs[93].Reg_Val = 0x56 ; in MXL5005_RegisterInit()
689 state->TunerRegs[94].Reg_Num = 157 ; in MXL5005_RegisterInit()
690 state->TunerRegs[94].Reg_Val = 0x17 ; in MXL5005_RegisterInit()
692 state->TunerRegs[95].Reg_Num = 158 ; in MXL5005_RegisterInit()
693 state->TunerRegs[95].Reg_Val = 0xA9 ; in MXL5005_RegisterInit()
695 state->TunerRegs[96].Reg_Num = 159 ; in MXL5005_RegisterInit()
696 state->TunerRegs[96].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
698 state->TunerRegs[97].Reg_Num = 160 ; in MXL5005_RegisterInit()
699 state->TunerRegs[97].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
701 state->TunerRegs[98].Reg_Num = 161 ; in MXL5005_RegisterInit()
702 state->TunerRegs[98].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
704 state->TunerRegs[99].Reg_Num = 162 ; in MXL5005_RegisterInit()
705 state->TunerRegs[99].Reg_Val = 0x40 ; in MXL5005_RegisterInit()
707 state->TunerRegs[100].Reg_Num = 166 ; in MXL5005_RegisterInit()
708 state->TunerRegs[100].Reg_Val = 0xAE ; in MXL5005_RegisterInit()
710 state->TunerRegs[101].Reg_Num = 167 ; in MXL5005_RegisterInit()
711 state->TunerRegs[101].Reg_Val = 0x1B ; in MXL5005_RegisterInit()
713 state->TunerRegs[102].Reg_Num = 168 ; in MXL5005_RegisterInit()
714 state->TunerRegs[102].Reg_Val = 0xF2 ; in MXL5005_RegisterInit()
716 state->TunerRegs[103].Reg_Num = 195 ; in MXL5005_RegisterInit()
717 state->TunerRegs[103].Reg_Val = 0x00 ; in MXL5005_RegisterInit()
724 struct mxl5005s_state *state = fe->tuner_priv; in MXL5005_ControlInit() local
725 state->Init_Ctrl_Num = INITCTRL_NUM; in MXL5005_ControlInit()
727 state->Init_Ctrl[0].Ctrl_Num = DN_IQTN_AMP_CUT ; in MXL5005_ControlInit()
728 state->Init_Ctrl[0].size = 1 ; in MXL5005_ControlInit()
729 state->Init_Ctrl[0].addr[0] = 73; in MXL5005_ControlInit()
730 state->Init_Ctrl[0].bit[0] = 7; in MXL5005_ControlInit()
731 state->Init_Ctrl[0].val[0] = 0; in MXL5005_ControlInit()
733 state->Init_Ctrl[1].Ctrl_Num = BB_MODE ; in MXL5005_ControlInit()
734 state->Init_Ctrl[1].size = 1 ; in MXL5005_ControlInit()
735 state->Init_Ctrl[1].addr[0] = 53; in MXL5005_ControlInit()
736 state->Init_Ctrl[1].bit[0] = 2; in MXL5005_ControlInit()
737 state->Init_Ctrl[1].val[0] = 1; in MXL5005_ControlInit()
739 state->Init_Ctrl[2].Ctrl_Num = BB_BUF ; in MXL5005_ControlInit()
740 state->Init_Ctrl[2].size = 2 ; in MXL5005_ControlInit()
741 state->Init_Ctrl[2].addr[0] = 53; in MXL5005_ControlInit()
742 state->Init_Ctrl[2].bit[0] = 1; in MXL5005_ControlInit()
743 state->Init_Ctrl[2].val[0] = 0; in MXL5005_ControlInit()
744 state->Init_Ctrl[2].addr[1] = 57; in MXL5005_ControlInit()
745 state->Init_Ctrl[2].bit[1] = 0; in MXL5005_ControlInit()
746 state->Init_Ctrl[2].val[1] = 1; in MXL5005_ControlInit()
748 state->Init_Ctrl[3].Ctrl_Num = BB_BUF_OA ; in MXL5005_ControlInit()
749 state->Init_Ctrl[3].size = 1 ; in MXL5005_ControlInit()
750 state->Init_Ctrl[3].addr[0] = 53; in MXL5005_ControlInit()
751 state->Init_Ctrl[3].bit[0] = 0; in MXL5005_ControlInit()
752 state->Init_Ctrl[3].val[0] = 0; in MXL5005_ControlInit()
754 state->Init_Ctrl[4].Ctrl_Num = BB_ALPF_BANDSELECT ; in MXL5005_ControlInit()
755 state->Init_Ctrl[4].size = 3 ; in MXL5005_ControlInit()
756 state->Init_Ctrl[4].addr[0] = 53; in MXL5005_ControlInit()
757 state->Init_Ctrl[4].bit[0] = 5; in MXL5005_ControlInit()
758 state->Init_Ctrl[4].val[0] = 0; in MXL5005_ControlInit()
759 state->Init_Ctrl[4].addr[1] = 53; in MXL5005_ControlInit()
760 state->Init_Ctrl[4].bit[1] = 6; in MXL5005_ControlInit()
761 state->Init_Ctrl[4].val[1] = 0; in MXL5005_ControlInit()
762 state->Init_Ctrl[4].addr[2] = 53; in MXL5005_ControlInit()
763 state->Init_Ctrl[4].bit[2] = 7; in MXL5005_ControlInit()
764 state->Init_Ctrl[4].val[2] = 1; in MXL5005_ControlInit()
766 state->Init_Ctrl[5].Ctrl_Num = BB_IQSWAP ; in MXL5005_ControlInit()
767 state->Init_Ctrl[5].size = 1 ; in MXL5005_ControlInit()
768 state->Init_Ctrl[5].addr[0] = 59; in MXL5005_ControlInit()
769 state->Init_Ctrl[5].bit[0] = 0; in MXL5005_ControlInit()
770 state->Init_Ctrl[5].val[0] = 0; in MXL5005_ControlInit()
772 state->Init_Ctrl[6].Ctrl_Num = BB_DLPF_BANDSEL ; in MXL5005_ControlInit()
773 state->Init_Ctrl[6].size = 2 ; in MXL5005_ControlInit()
774 state->Init_Ctrl[6].addr[0] = 53; in MXL5005_ControlInit()
775 state->Init_Ctrl[6].bit[0] = 3; in MXL5005_ControlInit()
776 state->Init_Ctrl[6].val[0] = 0; in MXL5005_ControlInit()
777 state->Init_Ctrl[6].addr[1] = 53; in MXL5005_ControlInit()
778 state->Init_Ctrl[6].bit[1] = 4; in MXL5005_ControlInit()
779 state->Init_Ctrl[6].val[1] = 1; in MXL5005_ControlInit()
781 state->Init_Ctrl[7].Ctrl_Num = RFSYN_CHP_GAIN ; in MXL5005_ControlInit()
782 state->Init_Ctrl[7].size = 4 ; in MXL5005_ControlInit()
783 state->Init_Ctrl[7].addr[0] = 22; in MXL5005_ControlInit()
784 state->Init_Ctrl[7].bit[0] = 4; in MXL5005_ControlInit()
785 state->Init_Ctrl[7].val[0] = 0; in MXL5005_ControlInit()
786 state->Init_Ctrl[7].addr[1] = 22; in MXL5005_ControlInit()
787 state->Init_Ctrl[7].bit[1] = 5; in MXL5005_ControlInit()
788 state->Init_Ctrl[7].val[1] = 1; in MXL5005_ControlInit()
789 state->Init_Ctrl[7].addr[2] = 22; in MXL5005_ControlInit()
790 state->Init_Ctrl[7].bit[2] = 6; in MXL5005_ControlInit()
791 state->Init_Ctrl[7].val[2] = 1; in MXL5005_ControlInit()
792 state->Init_Ctrl[7].addr[3] = 22; in MXL5005_ControlInit()
793 state->Init_Ctrl[7].bit[3] = 7; in MXL5005_ControlInit()
794 state->Init_Ctrl[7].val[3] = 0; in MXL5005_ControlInit()
796 state->Init_Ctrl[8].Ctrl_Num = RFSYN_EN_CHP_HIGAIN ; in MXL5005_ControlInit()
797 state->Init_Ctrl[8].size = 1 ; in MXL5005_ControlInit()
798 state->Init_Ctrl[8].addr[0] = 22; in MXL5005_ControlInit()
799 state->Init_Ctrl[8].bit[0] = 2; in MXL5005_ControlInit()
800 state->Init_Ctrl[8].val[0] = 0; in MXL5005_ControlInit()
802 state->Init_Ctrl[9].Ctrl_Num = AGC_IF ; in MXL5005_ControlInit()
803 state->Init_Ctrl[9].size = 4 ; in MXL5005_ControlInit()
804 state->Init_Ctrl[9].addr[0] = 76; in MXL5005_ControlInit()
805 state->Init_Ctrl[9].bit[0] = 0; in MXL5005_ControlInit()
806 state->Init_Ctrl[9].val[0] = 1; in MXL5005_ControlInit()
807 state->Init_Ctrl[9].addr[1] = 76; in MXL5005_ControlInit()
808 state->Init_Ctrl[9].bit[1] = 1; in MXL5005_ControlInit()
809 state->Init_Ctrl[9].val[1] = 1; in MXL5005_ControlInit()
810 state->Init_Ctrl[9].addr[2] = 76; in MXL5005_ControlInit()
811 state->Init_Ctrl[9].bit[2] = 2; in MXL5005_ControlInit()
812 state->Init_Ctrl[9].val[2] = 0; in MXL5005_ControlInit()
813 state->Init_Ctrl[9].addr[3] = 76; in MXL5005_ControlInit()
814 state->Init_Ctrl[9].bit[3] = 3; in MXL5005_ControlInit()
815 state->Init_Ctrl[9].val[3] = 1; in MXL5005_ControlInit()
817 state->Init_Ctrl[10].Ctrl_Num = AGC_RF ; in MXL5005_ControlInit()
818 state->Init_Ctrl[10].size = 4 ; in MXL5005_ControlInit()
819 state->Init_Ctrl[10].addr[0] = 76; in MXL5005_ControlInit()
820 state->Init_Ctrl[10].bit[0] = 4; in MXL5005_ControlInit()
821 state->Init_Ctrl[10].val[0] = 1; in MXL5005_ControlInit()
822 state->Init_Ctrl[10].addr[1] = 76; in MXL5005_ControlInit()
823 state->Init_Ctrl[10].bit[1] = 5; in MXL5005_ControlInit()
824 state->Init_Ctrl[10].val[1] = 1; in MXL5005_ControlInit()
825 state->Init_Ctrl[10].addr[2] = 76; in MXL5005_ControlInit()
826 state->Init_Ctrl[10].bit[2] = 6; in MXL5005_ControlInit()
827 state->Init_Ctrl[10].val[2] = 0; in MXL5005_ControlInit()
828 state->Init_Ctrl[10].addr[3] = 76; in MXL5005_ControlInit()
829 state->Init_Ctrl[10].bit[3] = 7; in MXL5005_ControlInit()
830 state->Init_Ctrl[10].val[3] = 1; in MXL5005_ControlInit()
832 state->Init_Ctrl[11].Ctrl_Num = IF_DIVVAL ; in MXL5005_ControlInit()
833 state->Init_Ctrl[11].size = 5 ; in MXL5005_ControlInit()
834 state->Init_Ctrl[11].addr[0] = 43; in MXL5005_ControlInit()
835 state->Init_Ctrl[11].bit[0] = 3; in MXL5005_ControlInit()
836 state->Init_Ctrl[11].val[0] = 0; in MXL5005_ControlInit()
837 state->Init_Ctrl[11].addr[1] = 43; in MXL5005_ControlInit()
838 state->Init_Ctrl[11].bit[1] = 4; in MXL5005_ControlInit()
839 state->Init_Ctrl[11].val[1] = 0; in MXL5005_ControlInit()
840 state->Init_Ctrl[11].addr[2] = 43; in MXL5005_ControlInit()
841 state->Init_Ctrl[11].bit[2] = 5; in MXL5005_ControlInit()
842 state->Init_Ctrl[11].val[2] = 0; in MXL5005_ControlInit()
843 state->Init_Ctrl[11].addr[3] = 43; in MXL5005_ControlInit()
844 state->Init_Ctrl[11].bit[3] = 6; in MXL5005_ControlInit()
845 state->Init_Ctrl[11].val[3] = 1; in MXL5005_ControlInit()
846 state->Init_Ctrl[11].addr[4] = 43; in MXL5005_ControlInit()
847 state->Init_Ctrl[11].bit[4] = 7; in MXL5005_ControlInit()
848 state->Init_Ctrl[11].val[4] = 0; in MXL5005_ControlInit()
850 state->Init_Ctrl[12].Ctrl_Num = IF_VCO_BIAS ; in MXL5005_ControlInit()
851 state->Init_Ctrl[12].size = 6 ; in MXL5005_ControlInit()
852 state->Init_Ctrl[12].addr[0] = 44; in MXL5005_ControlInit()
853 state->Init_Ctrl[12].bit[0] = 2; in MXL5005_ControlInit()
854 state->Init_Ctrl[12].val[0] = 0; in MXL5005_ControlInit()
855 state->Init_Ctrl[12].addr[1] = 44; in MXL5005_ControlInit()
856 state->Init_Ctrl[12].bit[1] = 3; in MXL5005_ControlInit()
857 state->Init_Ctrl[12].val[1] = 0; in MXL5005_ControlInit()
858 state->Init_Ctrl[12].addr[2] = 44; in MXL5005_ControlInit()
859 state->Init_Ctrl[12].bit[2] = 4; in MXL5005_ControlInit()
860 state->Init_Ctrl[12].val[2] = 0; in MXL5005_ControlInit()
861 state->Init_Ctrl[12].addr[3] = 44; in MXL5005_ControlInit()
862 state->Init_Ctrl[12].bit[3] = 5; in MXL5005_ControlInit()
863 state->Init_Ctrl[12].val[3] = 1; in MXL5005_ControlInit()
864 state->Init_Ctrl[12].addr[4] = 44; in MXL5005_ControlInit()
865 state->Init_Ctrl[12].bit[4] = 6; in MXL5005_ControlInit()
866 state->Init_Ctrl[12].val[4] = 0; in MXL5005_ControlInit()
867 state->Init_Ctrl[12].addr[5] = 44; in MXL5005_ControlInit()
868 state->Init_Ctrl[12].bit[5] = 7; in MXL5005_ControlInit()
869 state->Init_Ctrl[12].val[5] = 0; in MXL5005_ControlInit()
871 state->Init_Ctrl[13].Ctrl_Num = CHCAL_INT_MOD_IF ; in MXL5005_ControlInit()
872 state->Init_Ctrl[13].size = 7 ; in MXL5005_ControlInit()
873 state->Init_Ctrl[13].addr[0] = 11; in MXL5005_ControlInit()
874 state->Init_Ctrl[13].bit[0] = 0; in MXL5005_ControlInit()
875 state->Init_Ctrl[13].val[0] = 1; in MXL5005_ControlInit()
876 state->Init_Ctrl[13].addr[1] = 11; in MXL5005_ControlInit()
877 state->Init_Ctrl[13].bit[1] = 1; in MXL5005_ControlInit()
878 state->Init_Ctrl[13].val[1] = 0; in MXL5005_ControlInit()
879 state->Init_Ctrl[13].addr[2] = 11; in MXL5005_ControlInit()
880 state->Init_Ctrl[13].bit[2] = 2; in MXL5005_ControlInit()
881 state->Init_Ctrl[13].val[2] = 0; in MXL5005_ControlInit()
882 state->Init_Ctrl[13].addr[3] = 11; in MXL5005_ControlInit()
883 state->Init_Ctrl[13].bit[3] = 3; in MXL5005_ControlInit()
884 state->Init_Ctrl[13].val[3] = 1; in MXL5005_ControlInit()
885 state->Init_Ctrl[13].addr[4] = 11; in MXL5005_ControlInit()
886 state->Init_Ctrl[13].bit[4] = 4; in MXL5005_ControlInit()
887 state->Init_Ctrl[13].val[4] = 1; in MXL5005_ControlInit()
888 state->Init_Ctrl[13].addr[5] = 11; in MXL5005_ControlInit()
889 state->Init_Ctrl[13].bit[5] = 5; in MXL5005_ControlInit()
890 state->Init_Ctrl[13].val[5] = 0; in MXL5005_ControlInit()
891 state->Init_Ctrl[13].addr[6] = 11; in MXL5005_ControlInit()
892 state->Init_Ctrl[13].bit[6] = 6; in MXL5005_ControlInit()
893 state->Init_Ctrl[13].val[6] = 0; in MXL5005_ControlInit()
895 state->Init_Ctrl[14].Ctrl_Num = CHCAL_FRAC_MOD_IF ; in MXL5005_ControlInit()
896 state->Init_Ctrl[14].size = 16 ; in MXL5005_ControlInit()
897 state->Init_Ctrl[14].addr[0] = 13; in MXL5005_ControlInit()
898 state->Init_Ctrl[14].bit[0] = 0; in MXL5005_ControlInit()
899 state->Init_Ctrl[14].val[0] = 0; in MXL5005_ControlInit()
900 state->Init_Ctrl[14].addr[1] = 13; in MXL5005_ControlInit()
901 state->Init_Ctrl[14].bit[1] = 1; in MXL5005_ControlInit()
902 state->Init_Ctrl[14].val[1] = 0; in MXL5005_ControlInit()
903 state->Init_Ctrl[14].addr[2] = 13; in MXL5005_ControlInit()
904 state->Init_Ctrl[14].bit[2] = 2; in MXL5005_ControlInit()
905 state->Init_Ctrl[14].val[2] = 0; in MXL5005_ControlInit()
906 state->Init_Ctrl[14].addr[3] = 13; in MXL5005_ControlInit()
907 state->Init_Ctrl[14].bit[3] = 3; in MXL5005_ControlInit()
908 state->Init_Ctrl[14].val[3] = 0; in MXL5005_ControlInit()
909 state->Init_Ctrl[14].addr[4] = 13; in MXL5005_ControlInit()
910 state->Init_Ctrl[14].bit[4] = 4; in MXL5005_ControlInit()
911 state->Init_Ctrl[14].val[4] = 0; in MXL5005_ControlInit()
912 state->Init_Ctrl[14].addr[5] = 13; in MXL5005_ControlInit()
913 state->Init_Ctrl[14].bit[5] = 5; in MXL5005_ControlInit()
914 state->Init_Ctrl[14].val[5] = 0; in MXL5005_ControlInit()
915 state->Init_Ctrl[14].addr[6] = 13; in MXL5005_ControlInit()
916 state->Init_Ctrl[14].bit[6] = 6; in MXL5005_ControlInit()
917 state->Init_Ctrl[14].val[6] = 0; in MXL5005_ControlInit()
918 state->Init_Ctrl[14].addr[7] = 13; in MXL5005_ControlInit()
919 state->Init_Ctrl[14].bit[7] = 7; in MXL5005_ControlInit()
920 state->Init_Ctrl[14].val[7] = 0; in MXL5005_ControlInit()
921 state->Init_Ctrl[14].addr[8] = 12; in MXL5005_ControlInit()
922 state->Init_Ctrl[14].bit[8] = 0; in MXL5005_ControlInit()
923 state->Init_Ctrl[14].val[8] = 0; in MXL5005_ControlInit()
924 state->Init_Ctrl[14].addr[9] = 12; in MXL5005_ControlInit()
925 state->Init_Ctrl[14].bit[9] = 1; in MXL5005_ControlInit()
926 state->Init_Ctrl[14].val[9] = 0; in MXL5005_ControlInit()
927 state->Init_Ctrl[14].addr[10] = 12; in MXL5005_ControlInit()
928 state->Init_Ctrl[14].bit[10] = 2; in MXL5005_ControlInit()
929 state->Init_Ctrl[14].val[10] = 0; in MXL5005_ControlInit()
930 state->Init_Ctrl[14].addr[11] = 12; in MXL5005_ControlInit()
931 state->Init_Ctrl[14].bit[11] = 3; in MXL5005_ControlInit()
932 state->Init_Ctrl[14].val[11] = 0; in MXL5005_ControlInit()
933 state->Init_Ctrl[14].addr[12] = 12; in MXL5005_ControlInit()
934 state->Init_Ctrl[14].bit[12] = 4; in MXL5005_ControlInit()
935 state->Init_Ctrl[14].val[12] = 0; in MXL5005_ControlInit()
936 state->Init_Ctrl[14].addr[13] = 12; in MXL5005_ControlInit()
937 state->Init_Ctrl[14].bit[13] = 5; in MXL5005_ControlInit()
938 state->Init_Ctrl[14].val[13] = 1; in MXL5005_ControlInit()
939 state->Init_Ctrl[14].addr[14] = 12; in MXL5005_ControlInit()
940 state->Init_Ctrl[14].bit[14] = 6; in MXL5005_ControlInit()
941 state->Init_Ctrl[14].val[14] = 1; in MXL5005_ControlInit()
942 state->Init_Ctrl[14].addr[15] = 12; in MXL5005_ControlInit()
943 state->Init_Ctrl[14].bit[15] = 7; in MXL5005_ControlInit()
944 state->Init_Ctrl[14].val[15] = 0; in MXL5005_ControlInit()
946 state->Init_Ctrl[15].Ctrl_Num = DRV_RES_SEL ; in MXL5005_ControlInit()
947 state->Init_Ctrl[15].size = 3 ; in MXL5005_ControlInit()
948 state->Init_Ctrl[15].addr[0] = 147; in MXL5005_ControlInit()
949 state->Init_Ctrl[15].bit[0] = 2; in MXL5005_ControlInit()
950 state->Init_Ctrl[15].val[0] = 0; in MXL5005_ControlInit()
951 state->Init_Ctrl[15].addr[1] = 147; in MXL5005_ControlInit()
952 state->Init_Ctrl[15].bit[1] = 3; in MXL5005_ControlInit()
953 state->Init_Ctrl[15].val[1] = 1; in MXL5005_ControlInit()
954 state->Init_Ctrl[15].addr[2] = 147; in MXL5005_ControlInit()
955 state->Init_Ctrl[15].bit[2] = 4; in MXL5005_ControlInit()
956 state->Init_Ctrl[15].val[2] = 1; in MXL5005_ControlInit()
958 state->Init_Ctrl[16].Ctrl_Num = I_DRIVER ; in MXL5005_ControlInit()
959 state->Init_Ctrl[16].size = 2 ; in MXL5005_ControlInit()
960 state->Init_Ctrl[16].addr[0] = 147; in MXL5005_ControlInit()
961 state->Init_Ctrl[16].bit[0] = 0; in MXL5005_ControlInit()
962 state->Init_Ctrl[16].val[0] = 0; in MXL5005_ControlInit()
963 state->Init_Ctrl[16].addr[1] = 147; in MXL5005_ControlInit()
964 state->Init_Ctrl[16].bit[1] = 1; in MXL5005_ControlInit()
965 state->Init_Ctrl[16].val[1] = 1; in MXL5005_ControlInit()
967 state->Init_Ctrl[17].Ctrl_Num = EN_AAF ; in MXL5005_ControlInit()
968 state->Init_Ctrl[17].size = 1 ; in MXL5005_ControlInit()
969 state->Init_Ctrl[17].addr[0] = 147; in MXL5005_ControlInit()
970 state->Init_Ctrl[17].bit[0] = 7; in MXL5005_ControlInit()
971 state->Init_Ctrl[17].val[0] = 0; in MXL5005_ControlInit()
973 state->Init_Ctrl[18].Ctrl_Num = EN_3P ; in MXL5005_ControlInit()
974 state->Init_Ctrl[18].size = 1 ; in MXL5005_ControlInit()
975 state->Init_Ctrl[18].addr[0] = 147; in MXL5005_ControlInit()
976 state->Init_Ctrl[18].bit[0] = 6; in MXL5005_ControlInit()
977 state->Init_Ctrl[18].val[0] = 0; in MXL5005_ControlInit()
979 state->Init_Ctrl[19].Ctrl_Num = EN_AUX_3P ; in MXL5005_ControlInit()
980 state->Init_Ctrl[19].size = 1 ; in MXL5005_ControlInit()
981 state->Init_Ctrl[19].addr[0] = 156; in MXL5005_ControlInit()
982 state->Init_Ctrl[19].bit[0] = 0; in MXL5005_ControlInit()
983 state->Init_Ctrl[19].val[0] = 0; in MXL5005_ControlInit()
985 state->Init_Ctrl[20].Ctrl_Num = SEL_AAF_BAND ; in MXL5005_ControlInit()
986 state->Init_Ctrl[20].size = 1 ; in MXL5005_ControlInit()
987 state->Init_Ctrl[20].addr[0] = 147; in MXL5005_ControlInit()
988 state->Init_Ctrl[20].bit[0] = 5; in MXL5005_ControlInit()
989 state->Init_Ctrl[20].val[0] = 0; in MXL5005_ControlInit()
991 state->Init_Ctrl[21].Ctrl_Num = SEQ_ENCLK16_CLK_OUT ; in MXL5005_ControlInit()
992 state->Init_Ctrl[21].size = 1 ; in MXL5005_ControlInit()
993 state->Init_Ctrl[21].addr[0] = 137; in MXL5005_ControlInit()
994 state->Init_Ctrl[21].bit[0] = 4; in MXL5005_ControlInit()
995 state->Init_Ctrl[21].val[0] = 0; in MXL5005_ControlInit()
997 state->Init_Ctrl[22].Ctrl_Num = SEQ_SEL4_16B ; in MXL5005_ControlInit()
998 state->Init_Ctrl[22].size = 1 ; in MXL5005_ControlInit()
999 state->Init_Ctrl[22].addr[0] = 137; in MXL5005_ControlInit()
1000 state->Init_Ctrl[22].bit[0] = 7; in MXL5005_ControlInit()
1001 state->Init_Ctrl[22].val[0] = 0; in MXL5005_ControlInit()
1003 state->Init_Ctrl[23].Ctrl_Num = XTAL_CAPSELECT ; in MXL5005_ControlInit()
1004 state->Init_Ctrl[23].size = 1 ; in MXL5005_ControlInit()
1005 state->Init_Ctrl[23].addr[0] = 91; in MXL5005_ControlInit()
1006 state->Init_Ctrl[23].bit[0] = 5; in MXL5005_ControlInit()
1007 state->Init_Ctrl[23].val[0] = 1; in MXL5005_ControlInit()
1009 state->Init_Ctrl[24].Ctrl_Num = IF_SEL_DBL ; in MXL5005_ControlInit()
1010 state->Init_Ctrl[24].size = 1 ; in MXL5005_ControlInit()
1011 state->Init_Ctrl[24].addr[0] = 43; in MXL5005_ControlInit()
1012 state->Init_Ctrl[24].bit[0] = 0; in MXL5005_ControlInit()
1013 state->Init_Ctrl[24].val[0] = 1; in MXL5005_ControlInit()
1015 state->Init_Ctrl[25].Ctrl_Num = RFSYN_R_DIV ; in MXL5005_ControlInit()
1016 state->Init_Ctrl[25].size = 2 ; in MXL5005_ControlInit()
1017 state->Init_Ctrl[25].addr[0] = 22; in MXL5005_ControlInit()
1018 state->Init_Ctrl[25].bit[0] = 0; in MXL5005_ControlInit()
1019 state->Init_Ctrl[25].val[0] = 1; in MXL5005_ControlInit()
1020 state->Init_Ctrl[25].addr[1] = 22; in MXL5005_ControlInit()
1021 state->Init_Ctrl[25].bit[1] = 1; in MXL5005_ControlInit()
1022 state->Init_Ctrl[25].val[1] = 1; in MXL5005_ControlInit()
1024 state->Init_Ctrl[26].Ctrl_Num = SEQ_EXTSYNTHCALIF ; in MXL5005_ControlInit()
1025 state->Init_Ctrl[26].size = 1 ; in MXL5005_ControlInit()
1026 state->Init_Ctrl[26].addr[0] = 134; in MXL5005_ControlInit()
1027 state->Init_Ctrl[26].bit[0] = 2; in MXL5005_ControlInit()
1028 state->Init_Ctrl[26].val[0] = 0; in MXL5005_ControlInit()
1030 state->Init_Ctrl[27].Ctrl_Num = SEQ_EXTDCCAL ; in MXL5005_ControlInit()
1031 state->Init_Ctrl[27].size = 1 ; in MXL5005_ControlInit()
1032 state->Init_Ctrl[27].addr[0] = 137; in MXL5005_ControlInit()
1033 state->Init_Ctrl[27].bit[0] = 3; in MXL5005_ControlInit()
1034 state->Init_Ctrl[27].val[0] = 0; in MXL5005_ControlInit()
1036 state->Init_Ctrl[28].Ctrl_Num = AGC_EN_RSSI ; in MXL5005_ControlInit()
1037 state->Init_Ctrl[28].size = 1 ; in MXL5005_ControlInit()
1038 state->Init_Ctrl[28].addr[0] = 77; in MXL5005_ControlInit()
1039 state->Init_Ctrl[28].bit[0] = 7; in MXL5005_ControlInit()
1040 state->Init_Ctrl[28].val[0] = 0; in MXL5005_ControlInit()
1042 state->Init_Ctrl[29].Ctrl_Num = RFA_ENCLKRFAGC ; in MXL5005_ControlInit()
1043 state->Init_Ctrl[29].size = 1 ; in MXL5005_ControlInit()
1044 state->Init_Ctrl[29].addr[0] = 166; in MXL5005_ControlInit()
1045 state->Init_Ctrl[29].bit[0] = 7; in MXL5005_ControlInit()
1046 state->Init_Ctrl[29].val[0] = 1; in MXL5005_ControlInit()
1048 state->Init_Ctrl[30].Ctrl_Num = RFA_RSSI_REFH ; in MXL5005_ControlInit()
1049 state->Init_Ctrl[30].size = 3 ; in MXL5005_ControlInit()
1050 state->Init_Ctrl[30].addr[0] = 166; in MXL5005_ControlInit()
1051 state->Init_Ctrl[30].bit[0] = 0; in MXL5005_ControlInit()
1052 state->Init_Ctrl[30].val[0] = 0; in MXL5005_ControlInit()
1053 state->Init_Ctrl[30].addr[1] = 166; in MXL5005_ControlInit()
1054 state->Init_Ctrl[30].bit[1] = 1; in MXL5005_ControlInit()
1055 state->Init_Ctrl[30].val[1] = 1; in MXL5005_ControlInit()
1056 state->Init_Ctrl[30].addr[2] = 166; in MXL5005_ControlInit()
1057 state->Init_Ctrl[30].bit[2] = 2; in MXL5005_ControlInit()
1058 state->Init_Ctrl[30].val[2] = 1; in MXL5005_ControlInit()
1060 state->Init_Ctrl[31].Ctrl_Num = RFA_RSSI_REF ; in MXL5005_ControlInit()
1061 state->Init_Ctrl[31].size = 3 ; in MXL5005_ControlInit()
1062 state->Init_Ctrl[31].addr[0] = 166; in MXL5005_ControlInit()
1063 state->Init_Ctrl[31].bit[0] = 3; in MXL5005_ControlInit()
1064 state->Init_Ctrl[31].val[0] = 1; in MXL5005_ControlInit()
1065 state->Init_Ctrl[31].addr[1] = 166; in MXL5005_ControlInit()
1066 state->Init_Ctrl[31].bit[1] = 4; in MXL5005_ControlInit()
1067 state->Init_Ctrl[31].val[1] = 0; in MXL5005_ControlInit()
1068 state->Init_Ctrl[31].addr[2] = 166; in MXL5005_ControlInit()
1069 state->Init_Ctrl[31].bit[2] = 5; in MXL5005_ControlInit()
1070 state->Init_Ctrl[31].val[2] = 1; in MXL5005_ControlInit()
1072 state->Init_Ctrl[32].Ctrl_Num = RFA_RSSI_REFL ; in MXL5005_ControlInit()
1073 state->Init_Ctrl[32].size = 3 ; in MXL5005_ControlInit()
1074 state->Init_Ctrl[32].addr[0] = 167; in MXL5005_ControlInit()
1075 state->Init_Ctrl[32].bit[0] = 0; in MXL5005_ControlInit()
1076 state->Init_Ctrl[32].val[0] = 1; in MXL5005_ControlInit()
1077 state->Init_Ctrl[32].addr[1] = 167; in MXL5005_ControlInit()
1078 state->Init_Ctrl[32].bit[1] = 1; in MXL5005_ControlInit()
1079 state->Init_Ctrl[32].val[1] = 1; in MXL5005_ControlInit()
1080 state->Init_Ctrl[32].addr[2] = 167; in MXL5005_ControlInit()
1081 state->Init_Ctrl[32].bit[2] = 2; in MXL5005_ControlInit()
1082 state->Init_Ctrl[32].val[2] = 0; in MXL5005_ControlInit()
1084 state->Init_Ctrl[33].Ctrl_Num = RFA_FLR ; in MXL5005_ControlInit()
1085 state->Init_Ctrl[33].size = 4 ; in MXL5005_ControlInit()
1086 state->Init_Ctrl[33].addr[0] = 168; in MXL5005_ControlInit()
1087 state->Init_Ctrl[33].bit[0] = 0; in MXL5005_ControlInit()
1088 state->Init_Ctrl[33].val[0] = 0; in MXL5005_ControlInit()
1089 state->Init_Ctrl[33].addr[1] = 168; in MXL5005_ControlInit()
1090 state->Init_Ctrl[33].bit[1] = 1; in MXL5005_ControlInit()
1091 state->Init_Ctrl[33].val[1] = 1; in MXL5005_ControlInit()
1092 state->Init_Ctrl[33].addr[2] = 168; in MXL5005_ControlInit()
1093 state->Init_Ctrl[33].bit[2] = 2; in MXL5005_ControlInit()
1094 state->Init_Ctrl[33].val[2] = 0; in MXL5005_ControlInit()
1095 state->Init_Ctrl[33].addr[3] = 168; in MXL5005_ControlInit()
1096 state->Init_Ctrl[33].bit[3] = 3; in MXL5005_ControlInit()
1097 state->Init_Ctrl[33].val[3] = 0; in MXL5005_ControlInit()
1099 state->Init_Ctrl[34].Ctrl_Num = RFA_CEIL ; in MXL5005_ControlInit()
1100 state->Init_Ctrl[34].size = 4 ; in MXL5005_ControlInit()
1101 state->Init_Ctrl[34].addr[0] = 168; in MXL5005_ControlInit()
1102 state->Init_Ctrl[34].bit[0] = 4; in MXL5005_ControlInit()
1103 state->Init_Ctrl[34].val[0] = 1; in MXL5005_ControlInit()
1104 state->Init_Ctrl[34].addr[1] = 168; in MXL5005_ControlInit()
1105 state->Init_Ctrl[34].bit[1] = 5; in MXL5005_ControlInit()
1106 state->Init_Ctrl[34].val[1] = 1; in MXL5005_ControlInit()
1107 state->Init_Ctrl[34].addr[2] = 168; in MXL5005_ControlInit()
1108 state->Init_Ctrl[34].bit[2] = 6; in MXL5005_ControlInit()
1109 state->Init_Ctrl[34].val[2] = 1; in MXL5005_ControlInit()
1110 state->Init_Ctrl[34].addr[3] = 168; in MXL5005_ControlInit()
1111 state->Init_Ctrl[34].bit[3] = 7; in MXL5005_ControlInit()
1112 state->Init_Ctrl[34].val[3] = 1; in MXL5005_ControlInit()
1114 state->Init_Ctrl[35].Ctrl_Num = SEQ_EXTIQFSMPULSE ; in MXL5005_ControlInit()
1115 state->Init_Ctrl[35].size = 1 ; in MXL5005_ControlInit()
1116 state->Init_Ctrl[35].addr[0] = 135; in MXL5005_ControlInit()
1117 state->Init_Ctrl[35].bit[0] = 0; in MXL5005_ControlInit()
1118 state->Init_Ctrl[35].val[0] = 0; in MXL5005_ControlInit()
1120 state->Init_Ctrl[36].Ctrl_Num = OVERRIDE_1 ; in MXL5005_ControlInit()
1121 state->Init_Ctrl[36].size = 1 ; in MXL5005_ControlInit()
1122 state->Init_Ctrl[36].addr[0] = 56; in MXL5005_ControlInit()
1123 state->Init_Ctrl[36].bit[0] = 3; in MXL5005_ControlInit()
1124 state->Init_Ctrl[36].val[0] = 0; in MXL5005_ControlInit()
1126 state->Init_Ctrl[37].Ctrl_Num = BB_INITSTATE_DLPF_TUNE ; in MXL5005_ControlInit()
1127 state->Init_Ctrl[37].size = 7 ; in MXL5005_ControlInit()
1128 state->Init_Ctrl[37].addr[0] = 59; in MXL5005_ControlInit()
1129 state->Init_Ctrl[37].bit[0] = 1; in MXL5005_ControlInit()
1130 state->Init_Ctrl[37].val[0] = 0; in MXL5005_ControlInit()
1131 state->Init_Ctrl[37].addr[1] = 59; in MXL5005_ControlInit()
1132 state->Init_Ctrl[37].bit[1] = 2; in MXL5005_ControlInit()
1133 state->Init_Ctrl[37].val[1] = 0; in MXL5005_ControlInit()
1134 state->Init_Ctrl[37].addr[2] = 59; in MXL5005_ControlInit()
1135 state->Init_Ctrl[37].bit[2] = 3; in MXL5005_ControlInit()
1136 state->Init_Ctrl[37].val[2] = 0; in MXL5005_ControlInit()
1137 state->Init_Ctrl[37].addr[3] = 59; in MXL5005_ControlInit()
1138 state->Init_Ctrl[37].bit[3] = 4; in MXL5005_ControlInit()
1139 state->Init_Ctrl[37].val[3] = 0; in MXL5005_ControlInit()
1140 state->Init_Ctrl[37].addr[4] = 59; in MXL5005_ControlInit()
1141 state->Init_Ctrl[37].bit[4] = 5; in MXL5005_ControlInit()
1142 state->Init_Ctrl[37].val[4] = 0; in MXL5005_ControlInit()
1143 state->Init_Ctrl[37].addr[5] = 59; in MXL5005_ControlInit()
1144 state->Init_Ctrl[37].bit[5] = 6; in MXL5005_ControlInit()
1145 state->Init_Ctrl[37].val[5] = 0; in MXL5005_ControlInit()
1146 state->Init_Ctrl[37].addr[6] = 59; in MXL5005_ControlInit()
1147 state->Init_Ctrl[37].bit[6] = 7; in MXL5005_ControlInit()
1148 state->Init_Ctrl[37].val[6] = 0; in MXL5005_ControlInit()
1150 state->Init_Ctrl[38].Ctrl_Num = TG_R_DIV ; in MXL5005_ControlInit()
1151 state->Init_Ctrl[38].size = 6 ; in MXL5005_ControlInit()
1152 state->Init_Ctrl[38].addr[0] = 32; in MXL5005_ControlInit()
1153 state->Init_Ctrl[38].bit[0] = 2; in MXL5005_ControlInit()
1154 state->Init_Ctrl[38].val[0] = 0; in MXL5005_ControlInit()
1155 state->Init_Ctrl[38].addr[1] = 32; in MXL5005_ControlInit()
1156 state->Init_Ctrl[38].bit[1] = 3; in MXL5005_ControlInit()
1157 state->Init_Ctrl[38].val[1] = 0; in MXL5005_ControlInit()
1158 state->Init_Ctrl[38].addr[2] = 32; in MXL5005_ControlInit()
1159 state->Init_Ctrl[38].bit[2] = 4; in MXL5005_ControlInit()
1160 state->Init_Ctrl[38].val[2] = 0; in MXL5005_ControlInit()
1161 state->Init_Ctrl[38].addr[3] = 32; in MXL5005_ControlInit()
1162 state->Init_Ctrl[38].bit[3] = 5; in MXL5005_ControlInit()
1163 state->Init_Ctrl[38].val[3] = 0; in MXL5005_ControlInit()
1164 state->Init_Ctrl[38].addr[4] = 32; in MXL5005_ControlInit()
1165 state->Init_Ctrl[38].bit[4] = 6; in MXL5005_ControlInit()
1166 state->Init_Ctrl[38].val[4] = 1; in MXL5005_ControlInit()
1167 state->Init_Ctrl[38].addr[5] = 32; in MXL5005_ControlInit()
1168 state->Init_Ctrl[38].bit[5] = 7; in MXL5005_ControlInit()
1169 state->Init_Ctrl[38].val[5] = 0; in MXL5005_ControlInit()
1171 state->Init_Ctrl[39].Ctrl_Num = EN_CHP_LIN_B ; in MXL5005_ControlInit()
1172 state->Init_Ctrl[39].size = 1 ; in MXL5005_ControlInit()
1173 state->Init_Ctrl[39].addr[0] = 25; in MXL5005_ControlInit()
1174 state->Init_Ctrl[39].bit[0] = 3; in MXL5005_ControlInit()
1175 state->Init_Ctrl[39].val[0] = 1; in MXL5005_ControlInit()
1178 state->CH_Ctrl_Num = CHCTRL_NUM ; in MXL5005_ControlInit()
1180 state->CH_Ctrl[0].Ctrl_Num = DN_POLY ; in MXL5005_ControlInit()
1181 state->CH_Ctrl[0].size = 2 ; in MXL5005_ControlInit()
1182 state->CH_Ctrl[0].addr[0] = 68; in MXL5005_ControlInit()
1183 state->CH_Ctrl[0].bit[0] = 6; in MXL5005_ControlInit()
1184 state->CH_Ctrl[0].val[0] = 1; in MXL5005_ControlInit()
1185 state->CH_Ctrl[0].addr[1] = 68; in MXL5005_ControlInit()
1186 state->CH_Ctrl[0].bit[1] = 7; in MXL5005_ControlInit()
1187 state->CH_Ctrl[0].val[1] = 1; in MXL5005_ControlInit()
1189 state->CH_Ctrl[1].Ctrl_Num = DN_RFGAIN ; in MXL5005_ControlInit()
1190 state->CH_Ctrl[1].size = 2 ; in MXL5005_ControlInit()
1191 state->CH_Ctrl[1].addr[0] = 70; in MXL5005_ControlInit()
1192 state->CH_Ctrl[1].bit[0] = 6; in MXL5005_ControlInit()
1193 state->CH_Ctrl[1].val[0] = 1; in MXL5005_ControlInit()
1194 state->CH_Ctrl[1].addr[1] = 70; in MXL5005_ControlInit()
1195 state->CH_Ctrl[1].bit[1] = 7; in MXL5005_ControlInit()
1196 state->CH_Ctrl[1].val[1] = 0; in MXL5005_ControlInit()
1198 state->CH_Ctrl[2].Ctrl_Num = DN_CAP_RFLPF ; in MXL5005_ControlInit()
1199 state->CH_Ctrl[2].size = 9 ; in MXL5005_ControlInit()
1200 state->CH_Ctrl[2].addr[0] = 69; in MXL5005_ControlInit()
1201 state->CH_Ctrl[2].bit[0] = 5; in MXL5005_ControlInit()
1202 state->CH_Ctrl[2].val[0] = 0; in MXL5005_ControlInit()
1203 state->CH_Ctrl[2].addr[1] = 69; in MXL5005_ControlInit()
1204 state->CH_Ctrl[2].bit[1] = 6; in MXL5005_ControlInit()
1205 state->CH_Ctrl[2].val[1] = 0; in MXL5005_ControlInit()
1206 state->CH_Ctrl[2].addr[2] = 69; in MXL5005_ControlInit()
1207 state->CH_Ctrl[2].bit[2] = 7; in MXL5005_ControlInit()
1208 state->CH_Ctrl[2].val[2] = 0; in MXL5005_ControlInit()
1209 state->CH_Ctrl[2].addr[3] = 68; in MXL5005_ControlInit()
1210 state->CH_Ctrl[2].bit[3] = 0; in MXL5005_ControlInit()
1211 state->CH_Ctrl[2].val[3] = 0; in MXL5005_ControlInit()
1212 state->CH_Ctrl[2].addr[4] = 68; in MXL5005_ControlInit()
1213 state->CH_Ctrl[2].bit[4] = 1; in MXL5005_ControlInit()
1214 state->CH_Ctrl[2].val[4] = 0; in MXL5005_ControlInit()
1215 state->CH_Ctrl[2].addr[5] = 68; in MXL5005_ControlInit()
1216 state->CH_Ctrl[2].bit[5] = 2; in MXL5005_ControlInit()
1217 state->CH_Ctrl[2].val[5] = 0; in MXL5005_ControlInit()
1218 state->CH_Ctrl[2].addr[6] = 68; in MXL5005_ControlInit()
1219 state->CH_Ctrl[2].bit[6] = 3; in MXL5005_ControlInit()
1220 state->CH_Ctrl[2].val[6] = 0; in MXL5005_ControlInit()
1221 state->CH_Ctrl[2].addr[7] = 68; in MXL5005_ControlInit()
1222 state->CH_Ctrl[2].bit[7] = 4; in MXL5005_ControlInit()
1223 state->CH_Ctrl[2].val[7] = 0; in MXL5005_ControlInit()
1224 state->CH_Ctrl[2].addr[8] = 68; in MXL5005_ControlInit()
1225 state->CH_Ctrl[2].bit[8] = 5; in MXL5005_ControlInit()
1226 state->CH_Ctrl[2].val[8] = 0; in MXL5005_ControlInit()
1228 state->CH_Ctrl[3].Ctrl_Num = DN_EN_VHFUHFBAR ; in MXL5005_ControlInit()
1229 state->CH_Ctrl[3].size = 1 ; in MXL5005_ControlInit()
1230 state->CH_Ctrl[3].addr[0] = 70; in MXL5005_ControlInit()
1231 state->CH_Ctrl[3].bit[0] = 5; in MXL5005_ControlInit()
1232 state->CH_Ctrl[3].val[0] = 0; in MXL5005_ControlInit()
1234 state->CH_Ctrl[4].Ctrl_Num = DN_GAIN_ADJUST ; in MXL5005_ControlInit()
1235 state->CH_Ctrl[4].size = 3 ; in MXL5005_ControlInit()
1236 state->CH_Ctrl[4].addr[0] = 73; in MXL5005_ControlInit()
1237 state->CH_Ctrl[4].bit[0] = 4; in MXL5005_ControlInit()
1238 state->CH_Ctrl[4].val[0] = 0; in MXL5005_ControlInit()
1239 state->CH_Ctrl[4].addr[1] = 73; in MXL5005_ControlInit()
1240 state->CH_Ctrl[4].bit[1] = 5; in MXL5005_ControlInit()
1241 state->CH_Ctrl[4].val[1] = 1; in MXL5005_ControlInit()
1242 state->CH_Ctrl[4].addr[2] = 73; in MXL5005_ControlInit()
1243 state->CH_Ctrl[4].bit[2] = 6; in MXL5005_ControlInit()
1244 state->CH_Ctrl[4].val[2] = 0; in MXL5005_ControlInit()
1246 state->CH_Ctrl[5].Ctrl_Num = DN_IQTNBUF_AMP ; in MXL5005_ControlInit()
1247 state->CH_Ctrl[5].size = 4 ; in MXL5005_ControlInit()
1248 state->CH_Ctrl[5].addr[0] = 70; in MXL5005_ControlInit()
1249 state->CH_Ctrl[5].bit[0] = 0; in MXL5005_ControlInit()
1250 state->CH_Ctrl[5].val[0] = 0; in MXL5005_ControlInit()
1251 state->CH_Ctrl[5].addr[1] = 70; in MXL5005_ControlInit()
1252 state->CH_Ctrl[5].bit[1] = 1; in MXL5005_ControlInit()
1253 state->CH_Ctrl[5].val[1] = 0; in MXL5005_ControlInit()
1254 state->CH_Ctrl[5].addr[2] = 70; in MXL5005_ControlInit()
1255 state->CH_Ctrl[5].bit[2] = 2; in MXL5005_ControlInit()
1256 state->CH_Ctrl[5].val[2] = 0; in MXL5005_ControlInit()
1257 state->CH_Ctrl[5].addr[3] = 70; in MXL5005_ControlInit()
1258 state->CH_Ctrl[5].bit[3] = 3; in MXL5005_ControlInit()
1259 state->CH_Ctrl[5].val[3] = 0; in MXL5005_ControlInit()
1261 state->CH_Ctrl[6].Ctrl_Num = DN_IQTNGNBFBIAS_BST ; in MXL5005_ControlInit()
1262 state->CH_Ctrl[6].size = 1 ; in MXL5005_ControlInit()
1263 state->CH_Ctrl[6].addr[0] = 70; in MXL5005_ControlInit()
1264 state->CH_Ctrl[6].bit[0] = 4; in MXL5005_ControlInit()
1265 state->CH_Ctrl[6].val[0] = 1; in MXL5005_ControlInit()
1267 state->CH_Ctrl[7].Ctrl_Num = RFSYN_EN_OUTMUX ; in MXL5005_ControlInit()
1268 state->CH_Ctrl[7].size = 1 ; in MXL5005_ControlInit()
1269 state->CH_Ctrl[7].addr[0] = 111; in MXL5005_ControlInit()
1270 state->CH_Ctrl[7].bit[0] = 4; in MXL5005_ControlInit()
1271 state->CH_Ctrl[7].val[0] = 0; in MXL5005_ControlInit()
1273 state->CH_Ctrl[8].Ctrl_Num = RFSYN_SEL_VCO_OUT ; in MXL5005_ControlInit()
1274 state->CH_Ctrl[8].size = 1 ; in MXL5005_ControlInit()
1275 state->CH_Ctrl[8].addr[0] = 111; in MXL5005_ControlInit()
1276 state->CH_Ctrl[8].bit[0] = 7; in MXL5005_ControlInit()
1277 state->CH_Ctrl[8].val[0] = 1; in MXL5005_ControlInit()
1279 state->CH_Ctrl[9].Ctrl_Num = RFSYN_SEL_VCO_HI ; in MXL5005_ControlInit()
1280 state->CH_Ctrl[9].size = 1 ; in MXL5005_ControlInit()
1281 state->CH_Ctrl[9].addr[0] = 111; in MXL5005_ControlInit()
1282 state->CH_Ctrl[9].bit[0] = 6; in MXL5005_ControlInit()
1283 state->CH_Ctrl[9].val[0] = 1; in MXL5005_ControlInit()
1285 state->CH_Ctrl[10].Ctrl_Num = RFSYN_SEL_DIVM ; in MXL5005_ControlInit()
1286 state->CH_Ctrl[10].size = 1 ; in MXL5005_ControlInit()
1287 state->CH_Ctrl[10].addr[0] = 111; in MXL5005_ControlInit()
1288 state->CH_Ctrl[10].bit[0] = 5; in MXL5005_ControlInit()
1289 state->CH_Ctrl[10].val[0] = 0; in MXL5005_ControlInit()
1291 state->CH_Ctrl[11].Ctrl_Num = RFSYN_RF_DIV_BIAS ; in MXL5005_ControlInit()
1292 state->CH_Ctrl[11].size = 2 ; in MXL5005_ControlInit()
1293 state->CH_Ctrl[11].addr[0] = 110; in MXL5005_ControlInit()
1294 state->CH_Ctrl[11].bit[0] = 0; in MXL5005_ControlInit()
1295 state->CH_Ctrl[11].val[0] = 1; in MXL5005_ControlInit()
1296 state->CH_Ctrl[11].addr[1] = 110; in MXL5005_ControlInit()
1297 state->CH_Ctrl[11].bit[1] = 1; in MXL5005_ControlInit()
1298 state->CH_Ctrl[11].val[1] = 0; in MXL5005_ControlInit()
1300 state->CH_Ctrl[12].Ctrl_Num = DN_SEL_FREQ ; in MXL5005_ControlInit()
1301 state->CH_Ctrl[12].size = 3 ; in MXL5005_ControlInit()
1302 state->CH_Ctrl[12].addr[0] = 69; in MXL5005_ControlInit()
1303 state->CH_Ctrl[12].bit[0] = 2; in MXL5005_ControlInit()
1304 state->CH_Ctrl[12].val[0] = 0; in MXL5005_ControlInit()
1305 state->CH_Ctrl[12].addr[1] = 69; in MXL5005_ControlInit()
1306 state->CH_Ctrl[12].bit[1] = 3; in MXL5005_ControlInit()
1307 state->CH_Ctrl[12].val[1] = 0; in MXL5005_ControlInit()
1308 state->CH_Ctrl[12].addr[2] = 69; in MXL5005_ControlInit()
1309 state->CH_Ctrl[12].bit[2] = 4; in MXL5005_ControlInit()
1310 state->CH_Ctrl[12].val[2] = 0; in MXL5005_ControlInit()
1312 state->CH_Ctrl[13].Ctrl_Num = RFSYN_VCO_BIAS ; in MXL5005_ControlInit()
1313 state->CH_Ctrl[13].size = 6 ; in MXL5005_ControlInit()
1314 state->CH_Ctrl[13].addr[0] = 110; in MXL5005_ControlInit()
1315 state->CH_Ctrl[13].bit[0] = 2; in MXL5005_ControlInit()
1316 state->CH_Ctrl[13].val[0] = 0; in MXL5005_ControlInit()
1317 state->CH_Ctrl[13].addr[1] = 110; in MXL5005_ControlInit()
1318 state->CH_Ctrl[13].bit[1] = 3; in MXL5005_ControlInit()
1319 state->CH_Ctrl[13].val[1] = 0; in MXL5005_ControlInit()
1320 state->CH_Ctrl[13].addr[2] = 110; in MXL5005_ControlInit()
1321 state->CH_Ctrl[13].bit[2] = 4; in MXL5005_ControlInit()
1322 state->CH_Ctrl[13].val[2] = 0; in MXL5005_ControlInit()
1323 state->CH_Ctrl[13].addr[3] = 110; in MXL5005_ControlInit()
1324 state->CH_Ctrl[13].bit[3] = 5; in MXL5005_ControlInit()
1325 state->CH_Ctrl[13].val[3] = 0; in MXL5005_ControlInit()
1326 state->CH_Ctrl[13].addr[4] = 110; in MXL5005_ControlInit()
1327 state->CH_Ctrl[13].bit[4] = 6; in MXL5005_ControlInit()
1328 state->CH_Ctrl[13].val[4] = 0; in MXL5005_ControlInit()
1329 state->CH_Ctrl[13].addr[5] = 110; in MXL5005_ControlInit()
1330 state->CH_Ctrl[13].bit[5] = 7; in MXL5005_ControlInit()
1331 state->CH_Ctrl[13].val[5] = 1; in MXL5005_ControlInit()
1333 state->CH_Ctrl[14].Ctrl_Num = CHCAL_INT_MOD_RF ; in MXL5005_ControlInit()
1334 state->CH_Ctrl[14].size = 7 ; in MXL5005_ControlInit()
1335 state->CH_Ctrl[14].addr[0] = 14; in MXL5005_ControlInit()
1336 state->CH_Ctrl[14].bit[0] = 0; in MXL5005_ControlInit()
1337 state->CH_Ctrl[14].val[0] = 0; in MXL5005_ControlInit()
1338 state->CH_Ctrl[14].addr[1] = 14; in MXL5005_ControlInit()
1339 state->CH_Ctrl[14].bit[1] = 1; in MXL5005_ControlInit()
1340 state->CH_Ctrl[14].val[1] = 0; in MXL5005_ControlInit()
1341 state->CH_Ctrl[14].addr[2] = 14; in MXL5005_ControlInit()
1342 state->CH_Ctrl[14].bit[2] = 2; in MXL5005_ControlInit()
1343 state->CH_Ctrl[14].val[2] = 0; in MXL5005_ControlInit()
1344 state->CH_Ctrl[14].addr[3] = 14; in MXL5005_ControlInit()
1345 state->CH_Ctrl[14].bit[3] = 3; in MXL5005_ControlInit()
1346 state->CH_Ctrl[14].val[3] = 0; in MXL5005_ControlInit()
1347 state->CH_Ctrl[14].addr[4] = 14; in MXL5005_ControlInit()
1348 state->CH_Ctrl[14].bit[4] = 4; in MXL5005_ControlInit()
1349 state->CH_Ctrl[14].val[4] = 0; in MXL5005_ControlInit()
1350 state->CH_Ctrl[14].addr[5] = 14; in MXL5005_ControlInit()
1351 state->CH_Ctrl[14].bit[5] = 5; in MXL5005_ControlInit()
1352 state->CH_Ctrl[14].val[5] = 0; in MXL5005_ControlInit()
1353 state->CH_Ctrl[14].addr[6] = 14; in MXL5005_ControlInit()
1354 state->CH_Ctrl[14].bit[6] = 6; in MXL5005_ControlInit()
1355 state->CH_Ctrl[14].val[6] = 0; in MXL5005_ControlInit()
1357 state->CH_Ctrl[15].Ctrl_Num = CHCAL_FRAC_MOD_RF ; in MXL5005_ControlInit()
1358 state->CH_Ctrl[15].size = 18 ; in MXL5005_ControlInit()
1359 state->CH_Ctrl[15].addr[0] = 17; in MXL5005_ControlInit()
1360 state->CH_Ctrl[15].bit[0] = 6; in MXL5005_ControlInit()
1361 state->CH_Ctrl[15].val[0] = 0; in MXL5005_ControlInit()
1362 state->CH_Ctrl[15].addr[1] = 17; in MXL5005_ControlInit()
1363 state->CH_Ctrl[15].bit[1] = 7; in MXL5005_ControlInit()
1364 state->CH_Ctrl[15].val[1] = 0; in MXL5005_ControlInit()
1365 state->CH_Ctrl[15].addr[2] = 16; in MXL5005_ControlInit()
1366 state->CH_Ctrl[15].bit[2] = 0; in MXL5005_ControlInit()
1367 state->CH_Ctrl[15].val[2] = 0; in MXL5005_ControlInit()
1368 state->CH_Ctrl[15].addr[3] = 16; in MXL5005_ControlInit()
1369 state->CH_Ctrl[15].bit[3] = 1; in MXL5005_ControlInit()
1370 state->CH_Ctrl[15].val[3] = 0; in MXL5005_ControlInit()
1371 state->CH_Ctrl[15].addr[4] = 16; in MXL5005_ControlInit()
1372 state->CH_Ctrl[15].bit[4] = 2; in MXL5005_ControlInit()
1373 state->CH_Ctrl[15].val[4] = 0; in MXL5005_ControlInit()
1374 state->CH_Ctrl[15].addr[5] = 16; in MXL5005_ControlInit()
1375 state->CH_Ctrl[15].bit[5] = 3; in MXL5005_ControlInit()
1376 state->CH_Ctrl[15].val[5] = 0; in MXL5005_ControlInit()
1377 state->CH_Ctrl[15].addr[6] = 16; in MXL5005_ControlInit()
1378 state->CH_Ctrl[15].bit[6] = 4; in MXL5005_ControlInit()
1379 state->CH_Ctrl[15].val[6] = 0; in MXL5005_ControlInit()
1380 state->CH_Ctrl[15].addr[7] = 16; in MXL5005_ControlInit()
1381 state->CH_Ctrl[15].bit[7] = 5; in MXL5005_ControlInit()
1382 state->CH_Ctrl[15].val[7] = 0; in MXL5005_ControlInit()
1383 state->CH_Ctrl[15].addr[8] = 16; in MXL5005_ControlInit()
1384 state->CH_Ctrl[15].bit[8] = 6; in MXL5005_ControlInit()
1385 state->CH_Ctrl[15].val[8] = 0; in MXL5005_ControlInit()
1386 state->CH_Ctrl[15].addr[9] = 16; in MXL5005_ControlInit()
1387 state->CH_Ctrl[15].bit[9] = 7; in MXL5005_ControlInit()
1388 state->CH_Ctrl[15].val[9] = 0; in MXL5005_ControlInit()
1389 state->CH_Ctrl[15].addr[10] = 15; in MXL5005_ControlInit()
1390 state->CH_Ctrl[15].bit[10] = 0; in MXL5005_ControlInit()
1391 state->CH_Ctrl[15].val[10] = 0; in MXL5005_ControlInit()
1392 state->CH_Ctrl[15].addr[11] = 15; in MXL5005_ControlInit()
1393 state->CH_Ctrl[15].bit[11] = 1; in MXL5005_ControlInit()
1394 state->CH_Ctrl[15].val[11] = 0; in MXL5005_ControlInit()
1395 state->CH_Ctrl[15].addr[12] = 15; in MXL5005_ControlInit()
1396 state->CH_Ctrl[15].bit[12] = 2; in MXL5005_ControlInit()
1397 state->CH_Ctrl[15].val[12] = 0; in MXL5005_ControlInit()
1398 state->CH_Ctrl[15].addr[13] = 15; in MXL5005_ControlInit()
1399 state->CH_Ctrl[15].bit[13] = 3; in MXL5005_ControlInit()
1400 state->CH_Ctrl[15].val[13] = 0; in MXL5005_ControlInit()
1401 state->CH_Ctrl[15].addr[14] = 15; in MXL5005_ControlInit()
1402 state->CH_Ctrl[15].bit[14] = 4; in MXL5005_ControlInit()
1403 state->CH_Ctrl[15].val[14] = 0; in MXL5005_ControlInit()
1404 state->CH_Ctrl[15].addr[15] = 15; in MXL5005_ControlInit()
1405 state->CH_Ctrl[15].bit[15] = 5; in MXL5005_ControlInit()
1406 state->CH_Ctrl[15].val[15] = 0; in MXL5005_ControlInit()
1407 state->CH_Ctrl[15].addr[16] = 15; in MXL5005_ControlInit()
1408 state->CH_Ctrl[15].bit[16] = 6; in MXL5005_ControlInit()
1409 state->CH_Ctrl[15].val[16] = 1; in MXL5005_ControlInit()
1410 state->CH_Ctrl[15].addr[17] = 15; in MXL5005_ControlInit()
1411 state->CH_Ctrl[15].bit[17] = 7; in MXL5005_ControlInit()
1412 state->CH_Ctrl[15].val[17] = 1; in MXL5005_ControlInit()
1414 state->CH_Ctrl[16].Ctrl_Num = RFSYN_LPF_R ; in MXL5005_ControlInit()
1415 state->CH_Ctrl[16].size = 5 ; in MXL5005_ControlInit()
1416 state->CH_Ctrl[16].addr[0] = 112; in MXL5005_ControlInit()
1417 state->CH_Ctrl[16].bit[0] = 0; in MXL5005_ControlInit()
1418 state->CH_Ctrl[16].val[0] = 0; in MXL5005_ControlInit()
1419 state->CH_Ctrl[16].addr[1] = 112; in MXL5005_ControlInit()
1420 state->CH_Ctrl[16].bit[1] = 1; in MXL5005_ControlInit()
1421 state->CH_Ctrl[16].val[1] = 0; in MXL5005_ControlInit()
1422 state->CH_Ctrl[16].addr[2] = 112; in MXL5005_ControlInit()
1423 state->CH_Ctrl[16].bit[2] = 2; in MXL5005_ControlInit()
1424 state->CH_Ctrl[16].val[2] = 0; in MXL5005_ControlInit()
1425 state->CH_Ctrl[16].addr[3] = 112; in MXL5005_ControlInit()
1426 state->CH_Ctrl[16].bit[3] = 3; in MXL5005_ControlInit()
1427 state->CH_Ctrl[16].val[3] = 0; in MXL5005_ControlInit()
1428 state->CH_Ctrl[16].addr[4] = 112; in MXL5005_ControlInit()
1429 state->CH_Ctrl[16].bit[4] = 4; in MXL5005_ControlInit()
1430 state->CH_Ctrl[16].val[4] = 1; in MXL5005_ControlInit()
1432 state->CH_Ctrl[17].Ctrl_Num = CHCAL_EN_INT_RF ; in MXL5005_ControlInit()
1433 state->CH_Ctrl[17].size = 1 ; in MXL5005_ControlInit()
1434 state->CH_Ctrl[17].addr[0] = 14; in MXL5005_ControlInit()
1435 state->CH_Ctrl[17].bit[0] = 7; in MXL5005_ControlInit()
1436 state->CH_Ctrl[17].val[0] = 0; in MXL5005_ControlInit()
1438 state->CH_Ctrl[18].Ctrl_Num = TG_LO_DIVVAL ; in MXL5005_ControlInit()
1439 state->CH_Ctrl[18].size = 4 ; in MXL5005_ControlInit()
1440 state->CH_Ctrl[18].addr[0] = 107; in MXL5005_ControlInit()
1441 state->CH_Ctrl[18].bit[0] = 3; in MXL5005_ControlInit()
1442 state->CH_Ctrl[18].val[0] = 0; in MXL5005_ControlInit()
1443 state->CH_Ctrl[18].addr[1] = 107; in MXL5005_ControlInit()
1444 state->CH_Ctrl[18].bit[1] = 4; in MXL5005_ControlInit()
1445 state->CH_Ctrl[18].val[1] = 0; in MXL5005_ControlInit()
1446 state->CH_Ctrl[18].addr[2] = 107; in MXL5005_ControlInit()
1447 state->CH_Ctrl[18].bit[2] = 5; in MXL5005_ControlInit()
1448 state->CH_Ctrl[18].val[2] = 0; in MXL5005_ControlInit()
1449 state->CH_Ctrl[18].addr[3] = 107; in MXL5005_ControlInit()
1450 state->CH_Ctrl[18].bit[3] = 6; in MXL5005_ControlInit()
1451 state->CH_Ctrl[18].val[3] = 0; in MXL5005_ControlInit()
1453 state->CH_Ctrl[19].Ctrl_Num = TG_LO_SELVAL ; in MXL5005_ControlInit()
1454 state->CH_Ctrl[19].size = 3 ; in MXL5005_ControlInit()
1455 state->CH_Ctrl[19].addr[0] = 107; in MXL5005_ControlInit()
1456 state->CH_Ctrl[19].bit[0] = 7; in MXL5005_ControlInit()
1457 state->CH_Ctrl[19].val[0] = 1; in MXL5005_ControlInit()
1458 state->CH_Ctrl[19].addr[1] = 106; in MXL5005_ControlInit()
1459 state->CH_Ctrl[19].bit[1] = 0; in MXL5005_ControlInit()
1460 state->CH_Ctrl[19].val[1] = 1; in MXL5005_ControlInit()
1461 state->CH_Ctrl[19].addr[2] = 106; in MXL5005_ControlInit()
1462 state->CH_Ctrl[19].bit[2] = 1; in MXL5005_ControlInit()
1463 state->CH_Ctrl[19].val[2] = 1; in MXL5005_ControlInit()
1465 state->CH_Ctrl[20].Ctrl_Num = TG_DIV_VAL ; in MXL5005_ControlInit()
1466 state->CH_Ctrl[20].size = 11 ; in MXL5005_ControlInit()
1467 state->CH_Ctrl[20].addr[0] = 109; in MXL5005_ControlInit()
1468 state->CH_Ctrl[20].bit[0] = 2; in MXL5005_ControlInit()
1469 state->CH_Ctrl[20].val[0] = 0; in MXL5005_ControlInit()
1470 state->CH_Ctrl[20].addr[1] = 109; in MXL5005_ControlInit()
1471 state->CH_Ctrl[20].bit[1] = 3; in MXL5005_ControlInit()
1472 state->CH_Ctrl[20].val[1] = 0; in MXL5005_ControlInit()
1473 state->CH_Ctrl[20].addr[2] = 109; in MXL5005_ControlInit()
1474 state->CH_Ctrl[20].bit[2] = 4; in MXL5005_ControlInit()
1475 state->CH_Ctrl[20].val[2] = 0; in MXL5005_ControlInit()
1476 state->CH_Ctrl[20].addr[3] = 109; in MXL5005_ControlInit()
1477 state->CH_Ctrl[20].bit[3] = 5; in MXL5005_ControlInit()
1478 state->CH_Ctrl[20].val[3] = 0; in MXL5005_ControlInit()
1479 state->CH_Ctrl[20].addr[4] = 109; in MXL5005_ControlInit()
1480 state->CH_Ctrl[20].bit[4] = 6; in MXL5005_ControlInit()
1481 state->CH_Ctrl[20].val[4] = 0; in MXL5005_ControlInit()
1482 state->CH_Ctrl[20].addr[5] = 109; in MXL5005_ControlInit()
1483 state->CH_Ctrl[20].bit[5] = 7; in MXL5005_ControlInit()
1484 state->CH_Ctrl[20].val[5] = 0; in MXL5005_ControlInit()
1485 state->CH_Ctrl[20].addr[6] = 108; in MXL5005_ControlInit()
1486 state->CH_Ctrl[20].bit[6] = 0; in MXL5005_ControlInit()
1487 state->CH_Ctrl[20].val[6] = 0; in MXL5005_ControlInit()
1488 state->CH_Ctrl[20].addr[7] = 108; in MXL5005_ControlInit()
1489 state->CH_Ctrl[20].bit[7] = 1; in MXL5005_ControlInit()
1490 state->CH_Ctrl[20].val[7] = 0; in MXL5005_ControlInit()
1491 state->CH_Ctrl[20].addr[8] = 108; in MXL5005_ControlInit()
1492 state->CH_Ctrl[20].bit[8] = 2; in MXL5005_ControlInit()
1493 state->CH_Ctrl[20].val[8] = 1; in MXL5005_ControlInit()
1494 state->CH_Ctrl[20].addr[9] = 108; in MXL5005_ControlInit()
1495 state->CH_Ctrl[20].bit[9] = 3; in MXL5005_ControlInit()
1496 state->CH_Ctrl[20].val[9] = 1; in MXL5005_ControlInit()
1497 state->CH_Ctrl[20].addr[10] = 108; in MXL5005_ControlInit()
1498 state->CH_Ctrl[20].bit[10] = 4; in MXL5005_ControlInit()
1499 state->CH_Ctrl[20].val[10] = 1; in MXL5005_ControlInit()
1501 state->CH_Ctrl[21].Ctrl_Num = TG_VCO_BIAS ; in MXL5005_ControlInit()
1502 state->CH_Ctrl[21].size = 6 ; in MXL5005_ControlInit()
1503 state->CH_Ctrl[21].addr[0] = 106; in MXL5005_ControlInit()
1504 state->CH_Ctrl[21].bit[0] = 2; in MXL5005_ControlInit()
1505 state->CH_Ctrl[21].val[0] = 0; in MXL5005_ControlInit()
1506 state->CH_Ctrl[21].addr[1] = 106; in MXL5005_ControlInit()
1507 state->CH_Ctrl[21].bit[1] = 3; in MXL5005_ControlInit()
1508 state->CH_Ctrl[21].val[1] = 0; in MXL5005_ControlInit()
1509 state->CH_Ctrl[21].addr[2] = 106; in MXL5005_ControlInit()
1510 state->CH_Ctrl[21].bit[2] = 4; in MXL5005_ControlInit()
1511 state->CH_Ctrl[21].val[2] = 0; in MXL5005_ControlInit()
1512 state->CH_Ctrl[21].addr[3] = 106; in MXL5005_ControlInit()
1513 state->CH_Ctrl[21].bit[3] = 5; in MXL5005_ControlInit()
1514 state->CH_Ctrl[21].val[3] = 0; in MXL5005_ControlInit()
1515 state->CH_Ctrl[21].addr[4] = 106; in MXL5005_ControlInit()
1516 state->CH_Ctrl[21].bit[4] = 6; in MXL5005_ControlInit()
1517 state->CH_Ctrl[21].val[4] = 0; in MXL5005_ControlInit()
1518 state->CH_Ctrl[21].addr[5] = 106; in MXL5005_ControlInit()
1519 state->CH_Ctrl[21].bit[5] = 7; in MXL5005_ControlInit()
1520 state->CH_Ctrl[21].val[5] = 1; in MXL5005_ControlInit()
1522 state->CH_Ctrl[22].Ctrl_Num = SEQ_EXTPOWERUP ; in MXL5005_ControlInit()
1523 state->CH_Ctrl[22].size = 1 ; in MXL5005_ControlInit()
1524 state->CH_Ctrl[22].addr[0] = 138; in MXL5005_ControlInit()
1525 state->CH_Ctrl[22].bit[0] = 4; in MXL5005_ControlInit()
1526 state->CH_Ctrl[22].val[0] = 1; in MXL5005_ControlInit()
1528 state->CH_Ctrl[23].Ctrl_Num = OVERRIDE_2 ; in MXL5005_ControlInit()
1529 state->CH_Ctrl[23].size = 1 ; in MXL5005_ControlInit()
1530 state->CH_Ctrl[23].addr[0] = 17; in MXL5005_ControlInit()
1531 state->CH_Ctrl[23].bit[0] = 5; in MXL5005_ControlInit()
1532 state->CH_Ctrl[23].val[0] = 0; in MXL5005_ControlInit()
1534 state->CH_Ctrl[24].Ctrl_Num = OVERRIDE_3 ; in MXL5005_ControlInit()
1535 state->CH_Ctrl[24].size = 1 ; in MXL5005_ControlInit()
1536 state->CH_Ctrl[24].addr[0] = 111; in MXL5005_ControlInit()
1537 state->CH_Ctrl[24].bit[0] = 3; in MXL5005_ControlInit()
1538 state->CH_Ctrl[24].val[0] = 0; in MXL5005_ControlInit()
1540 state->CH_Ctrl[25].Ctrl_Num = OVERRIDE_4 ; in MXL5005_ControlInit()
1541 state->CH_Ctrl[25].size = 1 ; in MXL5005_ControlInit()
1542 state->CH_Ctrl[25].addr[0] = 112; in MXL5005_ControlInit()
1543 state->CH_Ctrl[25].bit[0] = 7; in MXL5005_ControlInit()
1544 state->CH_Ctrl[25].val[0] = 0; in MXL5005_ControlInit()
1546 state->CH_Ctrl[26].Ctrl_Num = SEQ_FSM_PULSE ; in MXL5005_ControlInit()
1547 state->CH_Ctrl[26].size = 1 ; in MXL5005_ControlInit()
1548 state->CH_Ctrl[26].addr[0] = 136; in MXL5005_ControlInit()
1549 state->CH_Ctrl[26].bit[0] = 7; in MXL5005_ControlInit()
1550 state->CH_Ctrl[26].val[0] = 0; in MXL5005_ControlInit()
1552 state->CH_Ctrl[27].Ctrl_Num = GPIO_4B ; in MXL5005_ControlInit()
1553 state->CH_Ctrl[27].size = 1 ; in MXL5005_ControlInit()
1554 state->CH_Ctrl[27].addr[0] = 149; in MXL5005_ControlInit()
1555 state->CH_Ctrl[27].bit[0] = 7; in MXL5005_ControlInit()
1556 state->CH_Ctrl[27].val[0] = 0; in MXL5005_ControlInit()
1558 state->CH_Ctrl[28].Ctrl_Num = GPIO_3B ; in MXL5005_ControlInit()
1559 state->CH_Ctrl[28].size = 1 ; in MXL5005_ControlInit()
1560 state->CH_Ctrl[28].addr[0] = 149; in MXL5005_ControlInit()
1561 state->CH_Ctrl[28].bit[0] = 6; in MXL5005_ControlInit()
1562 state->CH_Ctrl[28].val[0] = 0; in MXL5005_ControlInit()
1564 state->CH_Ctrl[29].Ctrl_Num = GPIO_4 ; in MXL5005_ControlInit()
1565 state->CH_Ctrl[29].size = 1 ; in MXL5005_ControlInit()
1566 state->CH_Ctrl[29].addr[0] = 149; in MXL5005_ControlInit()
1567 state->CH_Ctrl[29].bit[0] = 5; in MXL5005_ControlInit()
1568 state->CH_Ctrl[29].val[0] = 1; in MXL5005_ControlInit()
1570 state->CH_Ctrl[30].Ctrl_Num = GPIO_3 ; in MXL5005_ControlInit()
1571 state->CH_Ctrl[30].size = 1 ; in MXL5005_ControlInit()
1572 state->CH_Ctrl[30].addr[0] = 149; in MXL5005_ControlInit()
1573 state->CH_Ctrl[30].bit[0] = 4; in MXL5005_ControlInit()
1574 state->CH_Ctrl[30].val[0] = 1; in MXL5005_ControlInit()
1576 state->CH_Ctrl[31].Ctrl_Num = GPIO_1B ; in MXL5005_ControlInit()
1577 state->CH_Ctrl[31].size = 1 ; in MXL5005_ControlInit()
1578 state->CH_Ctrl[31].addr[0] = 149; in MXL5005_ControlInit()
1579 state->CH_Ctrl[31].bit[0] = 3; in MXL5005_ControlInit()
1580 state->CH_Ctrl[31].val[0] = 0; in MXL5005_ControlInit()
1582 state->CH_Ctrl[32].Ctrl_Num = DAC_A_ENABLE ; in MXL5005_ControlInit()
1583 state->CH_Ctrl[32].size = 1 ; in MXL5005_ControlInit()
1584 state->CH_Ctrl[32].addr[0] = 93; in MXL5005_ControlInit()
1585 state->CH_Ctrl[32].bit[0] = 1; in MXL5005_ControlInit()
1586 state->CH_Ctrl[32].val[0] = 0; in MXL5005_ControlInit()
1588 state->CH_Ctrl[33].Ctrl_Num = DAC_B_ENABLE ; in MXL5005_ControlInit()
1589 state->CH_Ctrl[33].size = 1 ; in MXL5005_ControlInit()
1590 state->CH_Ctrl[33].addr[0] = 93; in MXL5005_ControlInit()
1591 state->CH_Ctrl[33].bit[0] = 0; in MXL5005_ControlInit()
1592 state->CH_Ctrl[33].val[0] = 0; in MXL5005_ControlInit()
1594 state->CH_Ctrl[34].Ctrl_Num = DAC_DIN_A ; in MXL5005_ControlInit()
1595 state->CH_Ctrl[34].size = 6 ; in MXL5005_ControlInit()
1596 state->CH_Ctrl[34].addr[0] = 92; in MXL5005_ControlInit()
1597 state->CH_Ctrl[34].bit[0] = 2; in MXL5005_ControlInit()
1598 state->CH_Ctrl[34].val[0] = 0; in MXL5005_ControlInit()
1599 state->CH_Ctrl[34].addr[1] = 92; in MXL5005_ControlInit()
1600 state->CH_Ctrl[34].bit[1] = 3; in MXL5005_ControlInit()
1601 state->CH_Ctrl[34].val[1] = 0; in MXL5005_ControlInit()
1602 state->CH_Ctrl[34].addr[2] = 92; in MXL5005_ControlInit()
1603 state->CH_Ctrl[34].bit[2] = 4; in MXL5005_ControlInit()
1604 state->CH_Ctrl[34].val[2] = 0; in MXL5005_ControlInit()
1605 state->CH_Ctrl[34].addr[3] = 92; in MXL5005_ControlInit()
1606 state->CH_Ctrl[34].bit[3] = 5; in MXL5005_ControlInit()
1607 state->CH_Ctrl[34].val[3] = 0; in MXL5005_ControlInit()
1608 state->CH_Ctrl[34].addr[4] = 92; in MXL5005_ControlInit()
1609 state->CH_Ctrl[34].bit[4] = 6; in MXL5005_ControlInit()
1610 state->CH_Ctrl[34].val[4] = 0; in MXL5005_ControlInit()
1611 state->CH_Ctrl[34].addr[5] = 92; in MXL5005_ControlInit()
1612 state->CH_Ctrl[34].bit[5] = 7; in MXL5005_ControlInit()
1613 state->CH_Ctrl[34].val[5] = 0; in MXL5005_ControlInit()
1615 state->CH_Ctrl[35].Ctrl_Num = DAC_DIN_B ; in MXL5005_ControlInit()
1616 state->CH_Ctrl[35].size = 6 ; in MXL5005_ControlInit()
1617 state->CH_Ctrl[35].addr[0] = 93; in MXL5005_ControlInit()
1618 state->CH_Ctrl[35].bit[0] = 2; in MXL5005_ControlInit()
1619 state->CH_Ctrl[35].val[0] = 0; in MXL5005_ControlInit()
1620 state->CH_Ctrl[35].addr[1] = 93; in MXL5005_ControlInit()
1621 state->CH_Ctrl[35].bit[1] = 3; in MXL5005_ControlInit()
1622 state->CH_Ctrl[35].val[1] = 0; in MXL5005_ControlInit()
1623 state->CH_Ctrl[35].addr[2] = 93; in MXL5005_ControlInit()
1624 state->CH_Ctrl[35].bit[2] = 4; in MXL5005_ControlInit()
1625 state->CH_Ctrl[35].val[2] = 0; in MXL5005_ControlInit()
1626 state->CH_Ctrl[35].addr[3] = 93; in MXL5005_ControlInit()
1627 state->CH_Ctrl[35].bit[3] = 5; in MXL5005_ControlInit()
1628 state->CH_Ctrl[35].val[3] = 0; in MXL5005_ControlInit()
1629 state->CH_Ctrl[35].addr[4] = 93; in MXL5005_ControlInit()
1630 state->CH_Ctrl[35].bit[4] = 6; in MXL5005_ControlInit()
1631 state->CH_Ctrl[35].val[4] = 0; in MXL5005_ControlInit()
1632 state->CH_Ctrl[35].addr[5] = 93; in MXL5005_ControlInit()
1633 state->CH_Ctrl[35].bit[5] = 7; in MXL5005_ControlInit()
1634 state->CH_Ctrl[35].val[5] = 0; in MXL5005_ControlInit()
1637 state->CH_Ctrl[36].Ctrl_Num = RFSYN_EN_DIV ; in MXL5005_ControlInit()
1638 state->CH_Ctrl[36].size = 1 ; in MXL5005_ControlInit()
1639 state->CH_Ctrl[36].addr[0] = 109; in MXL5005_ControlInit()
1640 state->CH_Ctrl[36].bit[0] = 1; in MXL5005_ControlInit()
1641 state->CH_Ctrl[36].val[0] = 1; in MXL5005_ControlInit()
1643 state->CH_Ctrl[37].Ctrl_Num = RFSYN_DIVM ; in MXL5005_ControlInit()
1644 state->CH_Ctrl[37].size = 2 ; in MXL5005_ControlInit()
1645 state->CH_Ctrl[37].addr[0] = 112; in MXL5005_ControlInit()
1646 state->CH_Ctrl[37].bit[0] = 5; in MXL5005_ControlInit()
1647 state->CH_Ctrl[37].val[0] = 0; in MXL5005_ControlInit()
1648 state->CH_Ctrl[37].addr[1] = 112; in MXL5005_ControlInit()
1649 state->CH_Ctrl[37].bit[1] = 6; in MXL5005_ControlInit()
1650 state->CH_Ctrl[37].val[1] = 0; in MXL5005_ControlInit()
1652 state->CH_Ctrl[38].Ctrl_Num = DN_BYPASS_AGC_I2C ; in MXL5005_ControlInit()
1653 state->CH_Ctrl[38].size = 1 ; in MXL5005_ControlInit()
1654 state->CH_Ctrl[38].addr[0] = 65; in MXL5005_ControlInit()
1655 state->CH_Ctrl[38].bit[0] = 1; in MXL5005_ControlInit()
1656 state->CH_Ctrl[38].val[0] = 0; in MXL5005_ControlInit()
1694 struct mxl5005s_state *state = fe->tuner_priv; in MXL5005_TunerConfig() local
1696 state->Mode = Mode; in MXL5005_TunerConfig()
1697 state->IF_Mode = IF_mode; in MXL5005_TunerConfig()
1698 state->Chan_Bandwidth = Bandwidth; in MXL5005_TunerConfig()
1699 state->IF_OUT = IF_out; in MXL5005_TunerConfig()
1700 state->Fxtal = Fxtal; in MXL5005_TunerConfig()
1701 state->AGC_Mode = AGC_Mode; in MXL5005_TunerConfig()
1702 state->TOP = TOP; in MXL5005_TunerConfig()
1703 state->IF_OUT_LOAD = IF_OUT_LOAD; in MXL5005_TunerConfig()
1704 state->CLOCK_OUT = CLOCK_OUT; in MXL5005_TunerConfig()
1705 state->DIV_OUT = DIV_OUT; in MXL5005_TunerConfig()
1706 state->CAPSELECT = CAPSELECT; in MXL5005_TunerConfig()
1707 state->EN_RSSI = EN_RSSI; in MXL5005_TunerConfig()
1708 state->Mod_Type = Mod_Type; in MXL5005_TunerConfig()
1709 state->TF_Type = TF_Type; in MXL5005_TunerConfig()
1722 struct mxl5005s_state *state = fe->tuner_priv; in MXL_SynthIFLO_Calc() local
1723 if (state->Mode == 1) /* Digital Mode */ in MXL_SynthIFLO_Calc()
1724 state->IF_LO = state->IF_OUT; in MXL_SynthIFLO_Calc()
1726 if (state->IF_Mode == 0) /* Analog Zero IF mode */ in MXL_SynthIFLO_Calc()
1727 state->IF_LO = state->IF_OUT + 400000; in MXL_SynthIFLO_Calc()
1729 state->IF_LO = state->IF_OUT + state->Chan_Bandwidth/2; in MXL_SynthIFLO_Calc()
1735 struct mxl5005s_state *state = fe->tuner_priv; in MXL_SynthRFTGLO_Calc() local
1737 if (state->Mode == 1) /* Digital Mode */ { in MXL_SynthRFTGLO_Calc()
1739 state->RF_LO = state->RF_IN; in MXL_SynthRFTGLO_Calc()
1741 state->TG_LO = state->RF_IN - 750000; in MXL_SynthRFTGLO_Calc()
1743 if (state->IF_Mode == 0) /* Analog Zero IF mode */ { in MXL_SynthRFTGLO_Calc()
1744 state->RF_LO = state->RF_IN - 400000; in MXL_SynthRFTGLO_Calc()
1745 state->TG_LO = state->RF_IN - 1750000; in MXL_SynthRFTGLO_Calc()
1747 state->RF_LO = state->RF_IN - state->Chan_Bandwidth/2; in MXL_SynthRFTGLO_Calc()
1748 state->TG_LO = state->RF_IN - in MXL_SynthRFTGLO_Calc()
1749 state->Chan_Bandwidth + 500000; in MXL_SynthRFTGLO_Calc()
1768 struct mxl5005s_state *state = fe->tuner_priv; in MXL_BlockInit() local
1774 status += MXL_ControlWrite(fe, DN_IQTN_AMP_CUT, state->Mode ? 1 : 0); in MXL_BlockInit()
1777 status += MXL_ControlWrite(fe, BB_MODE, state->Mode ? 0 : 1); in MXL_BlockInit()
1778 status += MXL_ControlWrite(fe, BB_BUF, state->Mode ? 3 : 2); in MXL_BlockInit()
1779 status += MXL_ControlWrite(fe, BB_BUF_OA, state->Mode ? 1 : 0); in MXL_BlockInit()
1780 status += MXL_ControlWrite(fe, BB_IQSWAP, state->Mode ? 0 : 1); in MXL_BlockInit()
1784 if (state->Mode) { /* Digital Mode */ in MXL_BlockInit()
1785 switch (state->Chan_Bandwidth) { in MXL_BlockInit()
1798 switch (state->Chan_Bandwidth) { in MXL_BlockInit()
1801 (state->IF_Mode ? 0 : 3)); in MXL_BlockInit()
1805 (state->IF_Mode ? 1 : 4)); in MXL_BlockInit()
1809 (state->IF_Mode ? 2 : 5)); in MXL_BlockInit()
1815 status += MXL_ControlWrite(fe, RFSYN_CHP_GAIN, state->Mode ? 5 : 8); in MXL_BlockInit()
1817 RFSYN_EN_CHP_HIGAIN, state->Mode ? 1 : 1); in MXL_BlockInit()
1818 status += MXL_ControlWrite(fe, EN_CHP_LIN_B, state->Mode ? 0 : 0); in MXL_BlockInit()
1821 if (state->AGC_Mode == 0) /* Dual AGC */ { in MXL_BlockInit()
1825 status += MXL_ControlWrite(fe, AGC_RF, state->Mode ? 15 : 12); in MXL_BlockInit()
1827 if (state->TOP == 55) /* TOP == 5.5 */ in MXL_BlockInit()
1830 if (state->TOP == 72) /* TOP == 7.2 */ in MXL_BlockInit()
1833 if (state->TOP == 92) /* TOP == 9.2 */ in MXL_BlockInit()
1836 if (state->TOP == 110) /* TOP == 11.0 */ in MXL_BlockInit()
1839 if (state->TOP == 129) /* TOP == 12.9 */ in MXL_BlockInit()
1842 if (state->TOP == 147) /* TOP == 14.7 */ in MXL_BlockInit()
1845 if (state->TOP == 168) /* TOP == 16.8 */ in MXL_BlockInit()
1848 if (state->TOP == 194) /* TOP == 19.4 */ in MXL_BlockInit()
1851 if (state->TOP == 212) /* TOP == 21.2 */ in MXL_BlockInit()
1854 if (state->TOP == 232) /* TOP == 23.2 */ in MXL_BlockInit()
1857 if (state->TOP == 252) /* TOP == 25.2 */ in MXL_BlockInit()
1860 if (state->TOP == 271) /* TOP == 27.1 */ in MXL_BlockInit()
1863 if (state->TOP == 292) /* TOP == 29.2 */ in MXL_BlockInit()
1866 if (state->TOP == 317) /* TOP == 31.7 */ in MXL_BlockInit()
1869 if (state->TOP == 349) /* TOP == 34.9 */ in MXL_BlockInit()
1876 if (state->IF_OUT_LOAD == 200) { in MXL_BlockInit()
1880 if (state->IF_OUT_LOAD == 300) { in MXL_BlockInit()
1888 if (state->Mode) { /* Digital Mode */ in MXL_BlockInit()
1889 if (state->IF_OUT >= 4000000UL && state->IF_OUT <= 6280000UL) { in MXL_BlockInit()
1895 if ((state->IF_OUT == 36125000UL) || in MXL_BlockInit()
1896 (state->IF_OUT == 36150000UL)) { in MXL_BlockInit()
1902 if (state->IF_OUT > 36150000UL) { in MXL_BlockInit()
1909 if (state->IF_OUT >= 4000000UL && state->IF_OUT <= 5000000UL) { in MXL_BlockInit()
1915 if (state->IF_OUT > 5000000UL) { in MXL_BlockInit()
1924 if (state->CLOCK_OUT) in MXL_BlockInit()
1929 if (state->DIV_OUT == 1) in MXL_BlockInit()
1931 if (state->DIV_OUT == 0) in MXL_BlockInit()
1935 if (state->CAPSELECT) in MXL_BlockInit()
1940 if (state->Fxtal >= 12000000UL && state->Fxtal <= 16000000UL) in MXL_BlockInit()
1942 if (state->Fxtal > 16000000UL && state->Fxtal <= 32000000UL) in MXL_BlockInit()
1945 if (state->Fxtal >= 12000000UL && state->Fxtal <= 22000000UL) in MXL_BlockInit()
1947 if (state->Fxtal > 22000000UL && state->Fxtal <= 32000000UL) in MXL_BlockInit()
1951 if (state->Mode == 0 && state->IF_Mode == 1) /* Analog LowIF mode */ in MXL_BlockInit()
1960 MXL_Ceiling(state->Fxtal, 1000000)); in MXL_BlockInit()
1965 if (state->EN_RSSI) { in MXL_BlockInit()
1984 if (state->Mod_Type == MXL_DVBT) /* DVB-T Mode */ { in MXL_BlockInit()
1985 state->AGC_Mode = 1; /* Single AGC Mode */ in MXL_BlockInit()
2001 if (state->IF_OUT <= 6280000UL) /* Low IF */ in MXL_BlockInit()
2007 if (state->Mod_Type == MXL_ATSC) /* ATSC Mode */ { in MXL_BlockInit()
2008 state->AGC_Mode = 1; /* Single AGC Mode */ in MXL_BlockInit()
2028 if (state->IF_OUT <= 6280000UL) /* Low IF */ in MXL_BlockInit()
2033 if (state->Mod_Type == MXL_QAM) /* QAM Mode */ { in MXL_BlockInit()
2034 state->Mode = MXL_DIGITAL_MODE; in MXL_BlockInit()
2051 if (state->IF_OUT <= 6280000UL) /* Low IF */ in MXL_BlockInit()
2058 if (state->Mod_Type == MXL_ANALOG_CABLE) { in MXL_BlockInit()
2062 state->AGC_Mode = 1; /* Single AGC Mode */ in MXL_BlockInit()
2075 if (state->Mod_Type == MXL_ANALOG_OTA) { in MXL_BlockInit()
2094 if (state->EN_RSSI == 0) { in MXL_BlockInit()
2106 struct mxl5005s_state *state = fe->tuner_priv; in MXL_IFSynthInit() local
2113 if (state->Fxtal >= 12000000UL && state->Fxtal <= 16000000UL) in MXL_IFSynthInit()
2115 if (state->Fxtal > 16000000UL && state->Fxtal <= 32000000UL) in MXL_IFSynthInit()
2119 if (state->Mode == 0 && state->IF_Mode == 1) /* Analog Low IF mode */ { in MXL_IFSynthInit()
2120 if (state->IF_LO == 41000000UL) { in MXL_IFSynthInit()
2125 if (state->IF_LO == 47000000UL) { in MXL_IFSynthInit()
2130 if (state->IF_LO == 54000000UL) { in MXL_IFSynthInit()
2135 if (state->IF_LO == 60000000UL) { in MXL_IFSynthInit()
2140 if (state->IF_LO == 39250000UL) { in MXL_IFSynthInit()
2145 if (state->IF_LO == 39650000UL) { in MXL_IFSynthInit()
2150 if (state->IF_LO == 40150000UL) { in MXL_IFSynthInit()
2155 if (state->IF_LO == 40650000UL) { in MXL_IFSynthInit()
2162 if (state->Mode || (state->Mode == 0 && state->IF_Mode == 0)) { in MXL_IFSynthInit()
2163 if (state->IF_LO == 57000000UL) { in MXL_IFSynthInit()
2168 if (state->IF_LO == 44000000UL) { in MXL_IFSynthInit()
2173 if (state->IF_LO == 43750000UL) { in MXL_IFSynthInit()
2178 if (state->IF_LO == 36650000UL) { in MXL_IFSynthInit()
2183 if (state->IF_LO == 36150000UL) { in MXL_IFSynthInit()
2188 if (state->IF_LO == 36000000UL) { in MXL_IFSynthInit()
2193 if (state->IF_LO == 35250000UL) { in MXL_IFSynthInit()
2198 if (state->IF_LO == 34750000UL) { in MXL_IFSynthInit()
2203 if (state->IF_LO == 6280000UL) { in MXL_IFSynthInit()
2208 if (state->IF_LO == 5000000UL) { in MXL_IFSynthInit()
2213 if (state->IF_LO == 4500000UL) { in MXL_IFSynthInit()
2218 if (state->IF_LO == 4570000UL) { in MXL_IFSynthInit()
2223 if (state->IF_LO == 4000000UL) { in MXL_IFSynthInit()
2228 if (state->IF_LO == 57400000UL) { in MXL_IFSynthInit()
2233 if (state->IF_LO == 44400000UL) { in MXL_IFSynthInit()
2238 if (state->IF_LO == 44150000UL) { in MXL_IFSynthInit()
2243 if (state->IF_LO == 37050000UL) { in MXL_IFSynthInit()
2248 if (state->IF_LO == 36550000UL) { in MXL_IFSynthInit()
2253 if (state->IF_LO == 36125000UL) { in MXL_IFSynthInit()
2258 if (state->IF_LO == 6000000UL) { in MXL_IFSynthInit()
2263 if (state->IF_LO == 5400000UL) { in MXL_IFSynthInit()
2268 if (state->IF_LO == 5380000UL) { in MXL_IFSynthInit()
2273 if (state->IF_LO == 5200000UL) { in MXL_IFSynthInit()
2278 if (state->IF_LO == 4900000UL) { in MXL_IFSynthInit()
2283 if (state->IF_LO == 4400000UL) { in MXL_IFSynthInit()
2288 if (state->IF_LO == 4063000UL) /* add for 2.6.8 */ { in MXL_IFSynthInit()
2296 intModVal = Fref / (state->Fxtal * Kdbl/2); in MXL_IFSynthInit()
2299 fracModVal = (2<<15)*(Fref/1000 - (state->Fxtal/1000 * Kdbl/2) * in MXL_IFSynthInit()
2302 fracModVal = fracModVal / ((state->Fxtal * Kdbl/2)/1000); in MXL_IFSynthInit()
2310 struct mxl5005s_state *state = fe->tuner_priv; in MXL_TuneRF() local
2321 state->RF_IN = RF_Freq; in MXL_TuneRF()
2325 if (state->Fxtal >= 12000000UL && state->Fxtal <= 22000000UL) in MXL_TuneRF()
2327 if (state->Fxtal > 22000000 && state->Fxtal <= 32000000) in MXL_TuneRF()
2339 if (state->RF_LO < 40000000UL) in MXL_TuneRF()
2342 if (state->RF_LO >= 40000000UL && state->RF_LO <= 75000000UL) { in MXL_TuneRF()
2349 if (state->RF_LO > 75000000UL && state->RF_LO <= 100000000UL) { in MXL_TuneRF()
2356 if (state->RF_LO > 100000000UL && state->RF_LO <= 150000000UL) { in MXL_TuneRF()
2363 if (state->RF_LO > 150000000UL && state->RF_LO <= 200000000UL) { in MXL_TuneRF()
2370 if (state->RF_LO > 200000000UL && state->RF_LO <= 300000000UL) { in MXL_TuneRF()
2377 if (state->RF_LO > 300000000UL && state->RF_LO <= 650000000UL) { in MXL_TuneRF()
2384 if (state->RF_LO > 650000000UL && state->RF_LO <= 900000000UL) { in MXL_TuneRF()
2391 if (state->RF_LO > 900000000UL) in MXL_TuneRF()
2396 if (state->RF_LO >= 40000000UL && state->RF_LO <= 75000000UL) { in MXL_TuneRF()
2400 if (state->RF_LO > 75000000UL && state->RF_LO <= 100000000UL) { in MXL_TuneRF()
2404 if (state->RF_LO > 100000000UL && state->RF_LO <= 150000000UL) { in MXL_TuneRF()
2408 if (state->RF_LO > 150000000UL && state->RF_LO <= 200000000UL) { in MXL_TuneRF()
2412 if (state->RF_LO > 200000000UL && state->RF_LO <= 300000000UL) { in MXL_TuneRF()
2416 if (state->RF_LO > 300000000UL && state->RF_LO <= 400000000UL) { in MXL_TuneRF()
2420 if (state->RF_LO > 400000000UL && state->RF_LO <= 450000000UL) { in MXL_TuneRF()
2424 if (state->RF_LO > 450000000UL && state->RF_LO <= 500000000UL) { in MXL_TuneRF()
2428 if (state->RF_LO > 500000000UL && state->RF_LO <= 550000000UL) { in MXL_TuneRF()
2432 if (state->RF_LO > 550000000UL && state->RF_LO <= 600000000UL) { in MXL_TuneRF()
2436 if (state->RF_LO > 600000000UL && state->RF_LO <= 650000000UL) { in MXL_TuneRF()
2440 if (state->RF_LO > 650000000UL && state->RF_LO <= 700000000UL) { in MXL_TuneRF()
2444 if (state->RF_LO > 700000000UL && state->RF_LO <= 750000000UL) { in MXL_TuneRF()
2448 if (state->RF_LO > 750000000UL && state->RF_LO <= 800000000UL) { in MXL_TuneRF()
2452 if (state->RF_LO > 800000000UL && state->RF_LO <= 850000000UL) { in MXL_TuneRF()
2456 if (state->RF_LO > 850000000UL && state->RF_LO <= 900000000UL) { in MXL_TuneRF()
2476 if (state->RF_LO >= 40000000UL && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2489 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2502 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2515 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2528 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2541 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2554 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2567 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2580 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2593 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2606 if (state->RF_LO > FminBin && state->RF_LO <= FmaxBin) { in MXL_TuneRF()
2624 E3 = (((Fmax-state->RF_LO)/1000)*32)/((Fmax-Fmin)/1000) + 8 ; in MXL_TuneRF()
2628 E4 = (state->RF_LO*divider_val/1000)/(2*state->Fxtal*Kdbl_RF/1000); in MXL_TuneRF()
2632 E5 = ((2<<17)*(state->RF_LO/10000*divider_val - in MXL_TuneRF()
2633 (E4*(2*state->Fxtal*Kdbl_RF)/10000))) / in MXL_TuneRF()
2634 (2*state->Fxtal*Kdbl_RF/10000); in MXL_TuneRF()
2639 E5A = (((Fmax - state->RF_LO)/1000)*4/((Fmax-Fmin)/1000)) + 1 ; in MXL_TuneRF()
2659 if (state->TG_LO < 33000000UL) in MXL_TuneRF()
2664 if (state->TG_LO >= FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2673 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2682 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2691 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2700 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2709 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2718 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2727 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2736 if (state->TG_LO > FminBin && state->TG_LO <= FmaxBin) { in MXL_TuneRF()
2743 tg_divval = (state->TG_LO*divider_val/100000) * in MXL_TuneRF()
2744 (MXL_Ceiling(state->Fxtal, 1000000) * 100) / in MXL_TuneRF()
2745 (state->Fxtal/1000); in MXL_TuneRF()
2749 if (state->TG_LO > 600000000UL) in MXL_TuneRF()
2759 Fref_TG = (state->Fxtal/1000) / MXL_Ceiling(state->Fxtal, 1000000); in MXL_TuneRF()
2762 Fvco = (state->TG_LO/10000) * divider_val * Fref_TG; in MXL_TuneRF()
2786 if (state->Mod_Type == MXL_QAM) { in MXL_TuneRF()
2787 if (state->config->qam_gain != 0) in MXL_TuneRF()
2789 state->config->qam_gain); in MXL_TuneRF()
2790 else if (state->RF_IN < 680000000) in MXL_TuneRF()
2797 if (state->TF_Type == MXL_TF_OFF) { in MXL_TuneRF()
2806 if (state->TF_Type == MXL_TF_C) /* Tracking Filter type C */ { in MXL_TuneRF()
2810 if (state->RF_IN >= 43000000 && state->RF_IN < 150000000) { in MXL_TuneRF()
2817 if (state->RF_IN >= 150000000 && state->RF_IN < 280000000) { in MXL_TuneRF()
2824 if (state->RF_IN >= 280000000 && state->RF_IN < 360000000) { in MXL_TuneRF()
2831 if (state->RF_IN >= 360000000 && state->RF_IN < 560000000) { in MXL_TuneRF()
2838 if (state->RF_IN >= 560000000 && state->RF_IN < 580000000) { in MXL_TuneRF()
2845 if (state->RF_IN >= 580000000 && state->RF_IN < 630000000) { in MXL_TuneRF()
2852 if (state->RF_IN >= 630000000 && state->RF_IN < 700000000) { in MXL_TuneRF()
2859 if (state->RF_IN >= 700000000 && state->RF_IN < 760000000) { in MXL_TuneRF()
2866 if (state->RF_IN >= 760000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
2875 if (state->TF_Type == MXL_TF_C_H) { in MXL_TuneRF()
2880 if (state->RF_IN >= 43000000 && state->RF_IN < 150000000) { in MXL_TuneRF()
2886 if (state->RF_IN >= 150000000 && state->RF_IN < 280000000) { in MXL_TuneRF()
2892 if (state->RF_IN >= 280000000 && state->RF_IN < 360000000) { in MXL_TuneRF()
2898 if (state->RF_IN >= 360000000 && state->RF_IN < 560000000) { in MXL_TuneRF()
2904 if (state->RF_IN >= 560000000 && state->RF_IN < 580000000) { in MXL_TuneRF()
2910 if (state->RF_IN >= 580000000 && state->RF_IN < 630000000) { in MXL_TuneRF()
2916 if (state->RF_IN >= 630000000 && state->RF_IN < 700000000) { in MXL_TuneRF()
2922 if (state->RF_IN >= 700000000 && state->RF_IN < 760000000) { in MXL_TuneRF()
2928 if (state->RF_IN >= 760000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
2936 if (state->TF_Type == MXL_TF_D) { /* Tracking Filter type D */ in MXL_TuneRF()
2940 if (state->RF_IN >= 43000000 && state->RF_IN < 174000000) { in MXL_TuneRF()
2946 if (state->RF_IN >= 174000000 && state->RF_IN < 250000000) { in MXL_TuneRF()
2952 if (state->RF_IN >= 250000000 && state->RF_IN < 310000000) { in MXL_TuneRF()
2958 if (state->RF_IN >= 310000000 && state->RF_IN < 360000000) { in MXL_TuneRF()
2964 if (state->RF_IN >= 360000000 && state->RF_IN < 470000000) { in MXL_TuneRF()
2970 if (state->RF_IN >= 470000000 && state->RF_IN < 640000000) { in MXL_TuneRF()
2976 if (state->RF_IN >= 640000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
2984 if (state->TF_Type == MXL_TF_D_L) { in MXL_TuneRF()
2990 if (state->RF_IN >= 471000000 && in MXL_TuneRF()
2991 (state->RF_IN - 471000000)%6000000 != 0) { in MXL_TuneRF()
3000 if (state->RF_IN >= 43000000 && in MXL_TuneRF()
3001 state->RF_IN < 140000000) { in MXL_TuneRF()
3008 if (state->RF_IN >= 140000000 && in MXL_TuneRF()
3009 state->RF_IN < 240000000) { in MXL_TuneRF()
3015 if (state->RF_IN >= 240000000 && in MXL_TuneRF()
3016 state->RF_IN < 340000000) { in MXL_TuneRF()
3022 if (state->RF_IN >= 340000000 && in MXL_TuneRF()
3023 state->RF_IN < 430000000) { in MXL_TuneRF()
3029 if (state->RF_IN >= 430000000 && in MXL_TuneRF()
3030 state->RF_IN < 470000000) { in MXL_TuneRF()
3036 if (state->RF_IN >= 470000000 && in MXL_TuneRF()
3037 state->RF_IN < 570000000) { in MXL_TuneRF()
3043 if (state->RF_IN >= 570000000 && in MXL_TuneRF()
3044 state->RF_IN < 620000000) { in MXL_TuneRF()
3050 if (state->RF_IN >= 620000000 && in MXL_TuneRF()
3051 state->RF_IN < 760000000) { in MXL_TuneRF()
3057 if (state->RF_IN >= 760000000 && in MXL_TuneRF()
3058 state->RF_IN <= 900000000) { in MXL_TuneRF()
3067 if (state->TF_Type == MXL_TF_E) /* Tracking Filter type E */ { in MXL_TuneRF()
3071 if (state->RF_IN >= 43000000 && state->RF_IN < 174000000) { in MXL_TuneRF()
3077 if (state->RF_IN >= 174000000 && state->RF_IN < 250000000) { in MXL_TuneRF()
3083 if (state->RF_IN >= 250000000 && state->RF_IN < 310000000) { in MXL_TuneRF()
3089 if (state->RF_IN >= 310000000 && state->RF_IN < 360000000) { in MXL_TuneRF()
3095 if (state->RF_IN >= 360000000 && state->RF_IN < 470000000) { in MXL_TuneRF()
3101 if (state->RF_IN >= 470000000 && state->RF_IN < 640000000) { in MXL_TuneRF()
3107 if (state->RF_IN >= 640000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
3115 if (state->TF_Type == MXL_TF_F) { in MXL_TuneRF()
3120 if (state->RF_IN >= 43000000 && state->RF_IN < 160000000) { in MXL_TuneRF()
3126 if (state->RF_IN >= 160000000 && state->RF_IN < 210000000) { in MXL_TuneRF()
3132 if (state->RF_IN >= 210000000 && state->RF_IN < 300000000) { in MXL_TuneRF()
3138 if (state->RF_IN >= 300000000 && state->RF_IN < 390000000) { in MXL_TuneRF()
3144 if (state->RF_IN >= 390000000 && state->RF_IN < 515000000) { in MXL_TuneRF()
3150 if (state->RF_IN >= 515000000 && state->RF_IN < 650000000) { in MXL_TuneRF()
3156 if (state->RF_IN >= 650000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
3164 if (state->TF_Type == MXL_TF_E_2) { in MXL_TuneRF()
3169 if (state->RF_IN >= 43000000 && state->RF_IN < 174000000) { in MXL_TuneRF()
3175 if (state->RF_IN >= 174000000 && state->RF_IN < 250000000) { in MXL_TuneRF()
3181 if (state->RF_IN >= 250000000 && state->RF_IN < 350000000) { in MXL_TuneRF()
3187 if (state->RF_IN >= 350000000 && state->RF_IN < 400000000) { in MXL_TuneRF()
3193 if (state->RF_IN >= 400000000 && state->RF_IN < 570000000) { in MXL_TuneRF()
3199 if (state->RF_IN >= 570000000 && state->RF_IN < 770000000) { in MXL_TuneRF()
3205 if (state->RF_IN >= 770000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
3213 if (state->TF_Type == MXL_TF_G) { in MXL_TuneRF()
3218 if (state->RF_IN >= 50000000 && state->RF_IN < 190000000) { in MXL_TuneRF()
3225 if (state->RF_IN >= 190000000 && state->RF_IN < 280000000) { in MXL_TuneRF()
3231 if (state->RF_IN >= 280000000 && state->RF_IN < 350000000) { in MXL_TuneRF()
3237 if (state->RF_IN >= 350000000 && state->RF_IN < 400000000) { in MXL_TuneRF()
3243 if (state->RF_IN >= 400000000 && state->RF_IN < 470000000) { in MXL_TuneRF()
3249 if (state->RF_IN >= 470000000 && state->RF_IN < 640000000) { in MXL_TuneRF()
3255 if (state->RF_IN >= 640000000 && state->RF_IN < 820000000) { in MXL_TuneRF()
3261 if (state->RF_IN >= 820000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
3269 if (state->TF_Type == MXL_TF_E_NA) { in MXL_TuneRF()
3275 if (state->RF_IN >= 471000000 && in MXL_TuneRF()
3276 (state->RF_IN - 471000000)%6000000 != 0) { in MXL_TuneRF()
3308 if (state->RF_IN >= 43000000 && state->RF_IN < 174000000) { in MXL_TuneRF()
3315 if (state->RF_IN >= 174000000 && state->RF_IN < 250000000) { in MXL_TuneRF()
3321 if (state->RF_IN >= 250000000 && state->RF_IN < 350000000) { in MXL_TuneRF()
3327 if (state->RF_IN >= 350000000 && state->RF_IN < 400000000) { in MXL_TuneRF()
3333 if (state->RF_IN >= 400000000 && state->RF_IN < 570000000) { in MXL_TuneRF()
3339 if (state->RF_IN >= 570000000 && state->RF_IN < 770000000) { in MXL_TuneRF()
3345 if (state->RF_IN >= 770000000 && state->RF_IN <= 900000000) { in MXL_TuneRF()
3416 struct mxl5005s_state *state = fe->tuner_priv; in MXL_ControlWrite_Group() local
3423 for (i = 0; i < state->Init_Ctrl_Num; i++) { in MXL_ControlWrite_Group()
3425 if (controlNum == state->Init_Ctrl[i].Ctrl_Num) { in MXL_ControlWrite_Group()
3427 highLimit = 1 << state->Init_Ctrl[i].size; in MXL_ControlWrite_Group()
3429 for (j = 0; j < state->Init_Ctrl[i].size; j++) { in MXL_ControlWrite_Group()
3430 state->Init_Ctrl[i].val[j] = (u8)((value >> j) & 0x01); in MXL_ControlWrite_Group()
3431 MXL_RegWriteBit(fe, (u8)(state->Init_Ctrl[i].addr[j]), in MXL_ControlWrite_Group()
3432 (u8)(state->Init_Ctrl[i].bit[j]), in MXL_ControlWrite_Group()
3436 for (k = 0; k < state->Init_Ctrl[i].size; k++) in MXL_ControlWrite_Group()
3437 ctrlVal += state->Init_Ctrl[i].val[k] * (1 << k); in MXL_ControlWrite_Group()
3445 for (i = 0; i < state->CH_Ctrl_Num; i++) { in MXL_ControlWrite_Group()
3447 if (controlNum == state->CH_Ctrl[i].Ctrl_Num) { in MXL_ControlWrite_Group()
3449 highLimit = 1 << state->CH_Ctrl[i].size; in MXL_ControlWrite_Group()
3451 for (j = 0; j < state->CH_Ctrl[i].size; j++) { in MXL_ControlWrite_Group()
3452 state->CH_Ctrl[i].val[j] = (u8)((value >> j) & 0x01); in MXL_ControlWrite_Group()
3453 MXL_RegWriteBit(fe, (u8)(state->CH_Ctrl[i].addr[j]), in MXL_ControlWrite_Group()
3454 (u8)(state->CH_Ctrl[i].bit[j]), in MXL_ControlWrite_Group()
3458 for (k = 0; k < state->CH_Ctrl[i].size; k++) in MXL_ControlWrite_Group()
3459 ctrlVal += state->CH_Ctrl[i].val[k] * (1 << k); in MXL_ControlWrite_Group()
3468 for (i = 0; i < state->MXL_Ctrl_Num; i++) { in MXL_ControlWrite_Group()
3470 if (controlNum == state->MXL_Ctrl[i].Ctrl_Num) { in MXL_ControlWrite_Group()
3472 highLimit = (1 << state->MXL_Ctrl[i].size); in MXL_ControlWrite_Group()
3474 for (j = 0; j < state->MXL_Ctrl[i].size; j++) { in MXL_ControlWrite_Group()
3475 state->MXL_Ctrl[i].val[j] = (u8)((value >> j) & 0x01); in MXL_ControlWrite_Group()
3476 MXL_RegWriteBit(fe, (u8)(state->MXL_Ctrl[i].addr[j]), in MXL_ControlWrite_Group()
3477 (u8)(state->MXL_Ctrl[i].bit[j]), in MXL_ControlWrite_Group()
3481 for (k = 0; k < state->MXL_Ctrl[i].size; k++) in MXL_ControlWrite_Group()
3482 ctrlVal += state-> in MXL_ControlWrite_Group()
3496 struct mxl5005s_state *state = fe->tuner_priv; in MXL_RegRead() local
3500 if (RegNum == state->TunerRegs[i].Reg_Num) { in MXL_RegRead()
3501 *RegVal = (u8)(state->TunerRegs[i].Reg_Val); in MXL_RegRead()
3511 struct mxl5005s_state *state = fe->tuner_priv; in MXL_ControlRead() local
3515 for (i = 0; i < state->Init_Ctrl_Num ; i++) { in MXL_ControlRead()
3517 if (controlNum == state->Init_Ctrl[i].Ctrl_Num) { in MXL_ControlRead()
3520 for (k = 0; k < state->Init_Ctrl[i].size; k++) in MXL_ControlRead()
3521 ctrlVal += state->Init_Ctrl[i].val[k] * (1<<k); in MXL_ControlRead()
3527 for (i = 0; i < state->CH_Ctrl_Num ; i++) { in MXL_ControlRead()
3529 if (controlNum == state->CH_Ctrl[i].Ctrl_Num) { in MXL_ControlRead()
3532 for (k = 0; k < state->CH_Ctrl[i].size; k++) in MXL_ControlRead()
3533 ctrlVal += state->CH_Ctrl[i].val[k] * (1 << k); in MXL_ControlRead()
3541 for (i = 0; i < state->MXL_Ctrl_Num ; i++) { in MXL_ControlRead()
3543 if (controlNum == state->MXL_Ctrl[i].Ctrl_Num) { in MXL_ControlRead()
3546 for (k = 0; k < state->MXL_Ctrl[i].size; k++) in MXL_ControlRead()
3547 ctrlVal += state->MXL_Ctrl[i].val[k] * (1<<k); in MXL_ControlRead()
3560 struct mxl5005s_state *state = fe->tuner_priv; in MXL_RegWriteBit() local
3571 for (i = 0; i < state->TunerRegs_Num; i++) { in MXL_RegWriteBit()
3572 if (state->TunerRegs[i].Reg_Num == address) { in MXL_RegWriteBit()
3574 state->TunerRegs[i].Reg_Val |= OR_MAP[bit]; in MXL_RegWriteBit()
3576 state->TunerRegs[i].Reg_Val &= AND_MAP[bit]; in MXL_RegWriteBit()
3664 static u16 MXL_GetMasterControl(u8 *MasterReg, int state) in MXL_GetMasterControl() argument
3666 if (state == 1) /* Load_Start */ in MXL_GetMasterControl()
3668 if (state == 2) /* Power_Down */ in MXL_GetMasterControl()
3670 if (state == 3) /* Synth_Reset */ in MXL_GetMasterControl()
3672 if (state == 4) /* Seq_Off */ in MXL_GetMasterControl()
3681 struct mxl5005s_state *state = fe->tuner_priv; in MXL_VCORange_Test() local
3692 if (state->Mode == 0 && state->IF_Mode == 1) { in MXL_VCORange_Test()
3700 if (state->Mode == 0 && state->IF_Mode == 0) { in MXL_VCORange_Test()
3708 if (state->Mode == 1) /* Digital Mode */ { in MXL_VCORange_Test()
3728 if (state->Mode == 0 && state->IF_Mode == 1) { in MXL_VCORange_Test()
3736 if (state->Mode == 0 && state->IF_Mode == 0) { in MXL_VCORange_Test()
3744 if (state->Mode == 1) /* Digital Mode */ { in MXL_VCORange_Test()
3764 if (state->Mode == 0 && state->IF_Mode == 1) { in MXL_VCORange_Test()
3772 if (state->Mode == 0 && state->IF_Mode == 0) { in MXL_VCORange_Test()
3780 if (state->Mode == 1) /* Digital Mode */ { in MXL_VCORange_Test()
3800 if (state->Mode == 0 && state->IF_Mode == 1) { in MXL_VCORange_Test()
3808 if (state->Mode == 0 && state->IF_Mode == 0) { in MXL_VCORange_Test()
3816 if (state->Mode == 1) /* Digital Mode */ { in MXL_VCORange_Test()
3830 struct mxl5005s_state *state = fe->tuner_priv; in MXL_Hystersis_Test() local
3849 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_reset() local
3853 struct i2c_msg msg = { .addr = state->config->i2c_address, .flags = 0, in mxl5005s_reset()
3861 if (i2c_transfer(state->i2c, &msg, 1) != 1) { in mxl5005s_reset()
3877 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_writereg() local
3879 struct i2c_msg msg = { .addr = state->config->i2c_address, .flags = 0, in mxl5005s_writereg()
3887 if (i2c_transfer(state->i2c, &msg, 1) != 1) { in mxl5005s_writereg()
3918 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_init() local
3921 state->current_mode = MXL_QAM; in mxl5005s_init()
3928 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_reconfigure() local
3952 ByteTable[0] |= state->config->AgcMasterByte; in mxl5005s_reconfigure()
3972 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_AssignTunerMode() local
3973 struct mxl5005s_config *c = state->config; in mxl5005s_AssignTunerMode()
4000 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_set_params() local
4037 if (req_mode != state->current_mode || in mxl5005s_set_params()
4038 req_bw != state->Chan_Bandwidth) { in mxl5005s_set_params()
4039 state->current_mode = req_mode; in mxl5005s_set_params()
4055 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_get_frequency() local
4058 *frequency = state->RF_IN; in mxl5005s_get_frequency()
4065 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_get_bandwidth() local
4068 *bandwidth = state->Chan_Bandwidth; in mxl5005s_get_bandwidth()
4075 struct mxl5005s_state *state = fe->tuner_priv; in mxl5005s_get_if_frequency() local
4078 *frequency = state->IF_OUT; in mxl5005s_get_if_frequency()
4111 struct mxl5005s_state *state = NULL; in mxl5005s_attach() local
4114 state = kzalloc(sizeof(struct mxl5005s_state), GFP_KERNEL); in mxl5005s_attach()
4115 if (state == NULL) in mxl5005s_attach()
4118 state->frontend = fe; in mxl5005s_attach()
4119 state->config = config; in mxl5005s_attach()
4120 state->i2c = i2c; in mxl5005s_attach()
4128 fe->tuner_priv = state; in mxl5005s_attach()