• Home
  • Raw
  • Download

Lines Matching refs:id

14 static void sff8079_show_identifier(const __u8 *id)  in sff8079_show_identifier()  argument
16 sff8024_show_identifier(id, 0); in sff8079_show_identifier()
19 static void sff8079_show_ext_identifier(const __u8 *id) in sff8079_show_ext_identifier() argument
21 printf("\t%-41s : 0x%02x", "Extended identifier", id[1]); in sff8079_show_ext_identifier()
22 if (id[1] == 0x00) in sff8079_show_ext_identifier()
24 else if (id[1] == 0x04) in sff8079_show_ext_identifier()
26 else if (id[1] <= 0x07) in sff8079_show_ext_identifier()
27 printf(" (GBIC compliant with MOD_DEF %u)\n", id[1]); in sff8079_show_ext_identifier()
32 static void sff8079_show_connector(const __u8 *id) in sff8079_show_connector() argument
34 sff8024_show_connector(id, 2); in sff8079_show_connector()
37 static void sff8079_show_transceiver(const __u8 *id) in sff8079_show_transceiver() argument
45 id[3], id[4], id[5], id[6], in sff8079_show_transceiver()
46 id[7], id[8], id[9], id[10], id[36]); in sff8079_show_transceiver()
48 if (id[3] & (1 << 7)) in sff8079_show_transceiver()
51 if (id[3] & (1 << 6)) in sff8079_show_transceiver()
53 if (id[3] & (1 << 5)) in sff8079_show_transceiver()
55 if (id[3] & (1 << 4)) in sff8079_show_transceiver()
58 if (id[3] & (1 << 3)) in sff8079_show_transceiver()
60 if (id[3] & (1 << 2)) in sff8079_show_transceiver()
62 if (id[3] & (1 << 1)) in sff8079_show_transceiver()
64 if (id[3] & (1 << 0)) in sff8079_show_transceiver()
67 if (id[4] & (1 << 7)) in sff8079_show_transceiver()
69 if (id[4] & (1 << 6)) in sff8079_show_transceiver()
72 if (id[4] & (1 << 5)) in sff8079_show_transceiver()
74 if (id[4] & (1 << 4)) in sff8079_show_transceiver()
76 if (id[4] & (1 << 3)) in sff8079_show_transceiver()
78 if (id[4] & (1 << 2)) in sff8079_show_transceiver()
80 if (id[4] & (1 << 1)) in sff8079_show_transceiver()
82 if (id[4] & (1 << 0)) in sff8079_show_transceiver()
84 if (id[5] & (1 << 6)) in sff8079_show_transceiver()
86 if (id[5] & (1 << 5)) in sff8079_show_transceiver()
88 if (id[5] & (1 << 4)) in sff8079_show_transceiver()
90 if (id[5] & (1 << 2)) in sff8079_show_transceiver()
92 if (id[5] & (1 << 1)) in sff8079_show_transceiver()
94 if (id[5] & (1 << 0)) in sff8079_show_transceiver()
97 if (id[6] & (1 << 7)) in sff8079_show_transceiver()
99 if (id[6] & (1 << 6)) in sff8079_show_transceiver()
101 if (id[6] & (1 << 5)) in sff8079_show_transceiver()
103 if (id[6] & (1 << 4)) in sff8079_show_transceiver()
105 if (id[6] & (1 << 3)) in sff8079_show_transceiver()
107 if (id[6] & (1 << 2)) in sff8079_show_transceiver()
109 if (id[6] & (1 << 1)) in sff8079_show_transceiver()
111 if (id[6] & (1 << 0)) in sff8079_show_transceiver()
114 if (id[7] & (1 << 7)) in sff8079_show_transceiver()
116 if (id[7] & (1 << 6)) in sff8079_show_transceiver()
118 if (id[7] & (1 << 5)) in sff8079_show_transceiver()
120 if (id[7] & (1 << 4)) in sff8079_show_transceiver()
122 if (id[7] & (1 << 3)) in sff8079_show_transceiver()
125 if (id[7] & (1 << 2)) in sff8079_show_transceiver()
127 if (id[7] & (1 << 1)) in sff8079_show_transceiver()
129 if (id[7] & (1 << 0)) in sff8079_show_transceiver()
131 if (id[8] & (1 << 7)) in sff8079_show_transceiver()
133 if (id[8] & (1 << 6)) in sff8079_show_transceiver()
135 if (id[8] & (1 << 5)) in sff8079_show_transceiver()
137 if (id[8] & (1 << 4)) in sff8079_show_transceiver()
139 if (id[8] & (1 << 3)) in sff8079_show_transceiver()
141 if (id[8] & (1 << 2)) in sff8079_show_transceiver()
143 if (id[8] & (1 << 1)) in sff8079_show_transceiver()
146 if (id[9] & (1 << 7)) in sff8079_show_transceiver()
148 if (id[9] & (1 << 6)) in sff8079_show_transceiver()
150 if (id[9] & (1 << 5)) in sff8079_show_transceiver()
152 if (id[9] & (1 << 4)) in sff8079_show_transceiver()
154 if (id[9] & (1 << 3)) in sff8079_show_transceiver()
156 if (id[9] & (1 << 2)) in sff8079_show_transceiver()
158 if (id[9] & (1 << 0)) in sff8079_show_transceiver()
161 if (id[10] & (1 << 7)) in sff8079_show_transceiver()
163 if (id[10] & (1 << 6)) in sff8079_show_transceiver()
165 if (id[10] & (1 << 4)) in sff8079_show_transceiver()
167 if (id[10] & (1 << 2)) in sff8079_show_transceiver()
169 if (id[10] & (1 << 0)) in sff8079_show_transceiver()
172 if (id[36] == 0x1) in sff8079_show_transceiver()
174 if (id[36] == 0x2) in sff8079_show_transceiver()
176 if (id[36] == 0x3) in sff8079_show_transceiver()
178 if (id[36] == 0x4) in sff8079_show_transceiver()
180 if (id[36] == 0x8) in sff8079_show_transceiver()
182 if (id[36] == 0xb) in sff8079_show_transceiver()
184 if (id[36] == 0xc) in sff8079_show_transceiver()
186 if (id[36] == 0xd) in sff8079_show_transceiver()
188 if (id[36] == 0x18) in sff8079_show_transceiver()
190 if (id[36] == 0x19) in sff8079_show_transceiver()
194 static void sff8079_show_encoding(const __u8 *id) in sff8079_show_encoding() argument
196 sff8024_show_encoding(id, 11, ETH_MODULE_SFF_8472); in sff8079_show_encoding()
199 static void sff8079_show_rate_identifier(const __u8 *id) in sff8079_show_rate_identifier() argument
201 printf("\t%-41s : 0x%02x", "Rate identifier", id[13]); in sff8079_show_rate_identifier()
202 switch (id[13]) { in sff8079_show_rate_identifier()
224 static void sff8079_show_oui(const __u8 *id) in sff8079_show_oui() argument
227 id[37], id[38], id[39]); in sff8079_show_oui()
230 static void sff8079_show_wavelength_or_copper_compliance(const __u8 *id) in sff8079_show_wavelength_or_copper_compliance() argument
232 if (id[8] & (1 << 2)) { in sff8079_show_wavelength_or_copper_compliance()
233 printf("\t%-41s : 0x%02x", "Passive Cu cmplnce.", id[60]); in sff8079_show_wavelength_or_copper_compliance()
234 switch (id[60]) { in sff8079_show_wavelength_or_copper_compliance()
246 } else if (id[8] & (1 << 3)) { in sff8079_show_wavelength_or_copper_compliance()
247 printf("\t%-41s : 0x%02x", "Active Cu cmplnce.", id[60]); in sff8079_show_wavelength_or_copper_compliance()
248 switch (id[60]) { in sff8079_show_wavelength_or_copper_compliance()
265 (id[60] << 8) | id[61]); in sff8079_show_wavelength_or_copper_compliance()
269 static void sff8079_show_value_with_unit(const __u8 *id, unsigned int reg, in sff8079_show_value_with_unit() argument
273 unsigned int val = id[reg]; in sff8079_show_value_with_unit()
278 static void sff8079_show_ascii(const __u8 *id, unsigned int first_reg, in sff8079_show_ascii() argument
284 while (first_reg <= last_reg && id[last_reg] == ' ') in sff8079_show_ascii()
287 val = id[reg]; in sff8079_show_ascii()
293 static void sff8079_show_options(const __u8 *id) in sff8079_show_options() argument
298 printf("\t%-41s : 0x%02x 0x%02x\n", "Option values", id[64], id[65]); in sff8079_show_options()
299 if (id[65] & (1 << 1)) in sff8079_show_options()
301 if (id[65] & (1 << 2)) in sff8079_show_options()
303 if (id[65] & (1 << 3)) in sff8079_show_options()
305 if (id[65] & (1 << 4)) in sff8079_show_options()
307 if (id[65] & (1 << 5)) in sff8079_show_options()
309 if (id[65] & (1 << 6)) in sff8079_show_options()
311 if (id[65] & (1 << 7)) in sff8079_show_options()
313 if (id[64] & (1 << 0)) in sff8079_show_options()
315 if (id[64] & (1 << 1)) in sff8079_show_options()
317 if (id[64] & (1 << 2)) in sff8079_show_options()
319 if (id[64] & (1 << 3)) in sff8079_show_options()
321 if (id[64] & (1 << 4)) in sff8079_show_options()
323 if (id[64] & (1 << 5)) in sff8079_show_options()
327 void sff8079_show_all(const __u8 *id) in sff8079_show_all() argument
329 sff8079_show_identifier(id); in sff8079_show_all()
330 if (((id[0] == 0x02) || (id[0] == 0x03)) && (id[1] == 0x04)) { in sff8079_show_all()
331 sff8079_show_ext_identifier(id); in sff8079_show_all()
332 sff8079_show_connector(id); in sff8079_show_all()
333 sff8079_show_transceiver(id); in sff8079_show_all()
334 sff8079_show_encoding(id); in sff8079_show_all()
335 sff8079_show_value_with_unit(id, 12, "BR, Nominal", 100, "MBd"); in sff8079_show_all()
336 sff8079_show_rate_identifier(id); in sff8079_show_all()
337 sff8079_show_value_with_unit(id, 14, in sff8079_show_all()
339 sff8079_show_value_with_unit(id, 15, "Length (SMF)", 100, "m"); in sff8079_show_all()
340 sff8079_show_value_with_unit(id, 16, "Length (50um)", 10, "m"); in sff8079_show_all()
341 sff8079_show_value_with_unit(id, 17, in sff8079_show_all()
343 sff8079_show_value_with_unit(id, 18, "Length (Copper)", 1, "m"); in sff8079_show_all()
344 sff8079_show_value_with_unit(id, 19, "Length (OM3)", 10, "m"); in sff8079_show_all()
345 sff8079_show_wavelength_or_copper_compliance(id); in sff8079_show_all()
346 sff8079_show_ascii(id, 20, 35, "Vendor name"); in sff8079_show_all()
347 sff8079_show_oui(id); in sff8079_show_all()
348 sff8079_show_ascii(id, 40, 55, "Vendor PN"); in sff8079_show_all()
349 sff8079_show_ascii(id, 56, 59, "Vendor rev"); in sff8079_show_all()
350 sff8079_show_options(id); in sff8079_show_all()
351 sff8079_show_value_with_unit(id, 66, "BR margin, max", 1, "%"); in sff8079_show_all()
352 sff8079_show_value_with_unit(id, 67, "BR margin, min", 1, "%"); in sff8079_show_all()
353 sff8079_show_ascii(id, 68, 83, "Vendor SN"); in sff8079_show_all()
354 sff8079_show_ascii(id, 84, 91, "Date code"); in sff8079_show_all()