Lines Matching refs:index

17 static inline u32 pattern_table_get_killer_word16(u8 dqs, u8 index);
18 static inline u32 pattern_table_get_sso_word(u8 sso, u8 index);
19 static inline u32 pattern_table_get_vref_word(u8 index);
20 static inline u32 pattern_table_get_vref_word16(u8 index);
21 static inline u32 pattern_table_get_sso_full_xtalk_word(u8 bit, u8 index);
22 static inline u32 pattern_table_get_sso_full_xtalk_word16(u8 bit, u8 index);
23 static inline u32 pattern_table_get_sso_xtalk_free_word(u8 bit, u8 index);
24 static inline u32 pattern_table_get_sso_xtalk_free_word16(u8 bit, u8 index);
25 static inline u32 pattern_table_get_isi_word(u8 index);
26 static inline u32 pattern_table_get_isi_word16(u8 index);
95 static inline u32 pattern_table_get_killer_word_4(u8 dqs, u8 index)
99 if (index >= (KILLER_PATTERN_LENGTH * 2)) {
100 printf("error: %s: invalid index [%u] found\n", __func__, index);
104 byte = pattern_killer_map[index];
150 /* cas latency values per frequency for each speed bin index */
207 u32 mv_ddr_cl_val_get(u32 index, u32 freq)
209 return cl_table[index].cl_val[freq];
212 /* cas write latency values per frequency for each speed bin index */
269 u32 mv_ddr_cwl_val_get(u32 index, u32 freq)
271 return cwl_table[index].cl_val[freq];
506 /* Return speed Bin value for selected index and t* element */
507 unsigned int mv_ddr_speed_bin_timing_get(enum mv_ddr_speed_bin index, enum mv_ddr_speed_bin_timing element)
514 result = speed_bin_table_t_rcd_t_rp[index];
517 if (index <= SPEED_BIN_DDR_1066G)
519 else if (index <= SPEED_BIN_DDR_1333J)
521 else if (index <= SPEED_BIN_DDR_1600K)
523 else if (index <= SPEED_BIN_DDR_1866M)
529 result = speed_bin_table_t_rc[index];
532 if (index <= SPEED_BIN_DDR_800E)
534 else if (index <= SPEED_BIN_DDR_1066G)
536 else if (index <= SPEED_BIN_DDR_1600K)
542 if (index <= SPEED_BIN_DDR_1066G)
544 else if (index <= SPEED_BIN_DDR_1600K)
550 if (index < SPEED_BIN_DDR_800E)
552 else if (index < SPEED_BIN_DDR_1333J)
558 if (index <= SPEED_BIN_DDR_800E)
560 else if (index <= SPEED_BIN_DDR_1066G)
562 else if (index <= SPEED_BIN_DDR_1600K)
564 else if (index <= SPEED_BIN_DDR_1866M)
570 if (index <= SPEED_BIN_DDR_1066G)
572 else if (index <= SPEED_BIN_DDR_1333J)
574 else if (index <= SPEED_BIN_DDR_1600K)
604 static inline u32 pattern_table_get_killer_word(u8 dqs, u8 index)
613 byte |= pattern_killer_pattern_table_map[index][role] << i;
620 static inline u32 pattern_table_get_killer_word16(u8 dqs, u8 index)
629 byte0 |= pattern_killer_pattern_table_map[index * 2][role] << i;
630 byte1 |= pattern_killer_pattern_table_map[index * 2 + 1][role] << i;
636 static inline u32 pattern_table_get_sso_word(u8 sso, u8 index)
640 if (0 == ((index / step) & 1))
646 static inline u32 pattern_table_get_sso_full_xtalk_word(u8 bit, u8 index)
650 if ((index & 1) == 1)
657 static inline u32 pattern_table_get_sso_xtalk_free_word(u8 bit, u8 index)
661 if ((index & 1) == 1)
667 static inline u32 pattern_table_get_isi_word(u8 index)
669 u8 i0 = index % 32;
670 u8 i1 = index % 8;
683 static inline u32 pattern_table_get_sso_full_xtalk_word16(u8 bit, u8 index)
687 if ((index & 1) == 1)
693 static inline u32 pattern_table_get_sso_xtalk_free_word16(u8 bit, u8 index)
697 if ((index & 1) == 0)
703 static inline u32 pattern_table_get_isi_word16(u8 index)
705 u8 i0 = index % 16;
706 u8 i1 = index % 4;
719 static inline u32 pattern_table_get_vref_word(u8 index)
721 if (0 == ((pattern_vref_pattern_table_map[index / 8] >>
722 (index % 8)) & 1))
728 static inline u32 pattern_table_get_vref_word16(u8 index)
731 [PATTERN_KILLER_PATTERN_TABLE_MAP_ROLE_VICTIM][index * 2] &&
733 [PATTERN_KILLER_PATTERN_TABLE_MAP_ROLE_VICTIM][index * 2 + 1])
736 [PATTERN_KILLER_PATTERN_TABLE_MAP_ROLE_VICTIM][index * 2] &&
738 [PATTERN_KILLER_PATTERN_TABLE_MAP_ROLE_VICTIM][index * 2 + 1])
741 [PATTERN_KILLER_PATTERN_TABLE_MAP_ROLE_VICTIM][index * 2] &&
743 [PATTERN_KILLER_PATTERN_TABLE_MAP_ROLE_VICTIM][index * 2 + 1])
750 static inline u32 pattern_table_get_static_pbs_word(u8 index)
754 temp = ((0x00ff << (index / 3)) & 0xff00) >> 8;
760 u32 pattern_table_get_word(u32 dev_num, enum hws_pattern type, u8 index)
771 if (index == 0 || index == 2 || index == 5 ||
772 index == 7)
780 if (0 == (index & 1))
788 if (index < 6)
798 pattern = pattern_table_get_static_pbs_word(index);
814 (u8)(type - PATTERN_KILLER_DQ0), index);
818 if (index < 6)
827 if (index > 1 && index < 6)
837 (u8)(type - PATTERN_FULL_SSO0), index);
840 pattern = pattern_table_get_vref_word(index);
851 (u8)(type - PATTERN_SSO_FULL_XTALK_DQ0), index);
862 (u8)(type - PATTERN_SSO_XTALK_FREE_DQ0), index);
865 pattern = pattern_table_get_isi_word(index);
877 (u8)(type - PATTERN_KILLER_DQ0_INV), index);
891 if (index < t_end)
892 pattern = ((index % (t_num * 2)) >= t_num) ? 0xffffffff : 0x00000000;
894 pattern = ((index % 2) == 0) ? 0xffffffff : 0x00000000;
904 pattern = ~pattern_table_get_vref_word(index);
925 if (index < 3)
947 (u8)(type - PATTERN_KILLER_DQ0), index);
951 if (index < 3)
959 if ((index == 0) || (index == 3))
964 if ((index > 1) && (index < 6))
980 (u8)(type - PATTERN_FULL_SSO1), index);
982 (u8)(type - PATTERN_FULL_SSO0), index);
986 pattern = pattern_table_get_vref_word16(index);
997 (u8)(type - PATTERN_SSO_FULL_XTALK_DQ0), index);
1008 (u8)(type - PATTERN_SSO_XTALK_FREE_DQ0), index);
1011 pattern = pattern_table_get_isi_word16(index);
1023 (u8)(type - PATTERN_KILLER_DQ0_INV), index);
1037 if (index < t_end)
1038 pattern = ((index % (t_num * 2)) >= t_num) ? 0xffffffff : 0x00000000;
1040 pattern = ((index % 2) == 0) ? 0xffffffff : 0x00000000;
1044 pattern = ~pattern_table_get_vref_word16(index);