Lines Matching refs:err

83 	int err;  in mv88e6250_g1_eeprom_reload()  local
85 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL1, &val); in mv88e6250_g1_eeprom_reload()
86 if (err) in mv88e6250_g1_eeprom_reload()
87 return err; in mv88e6250_g1_eeprom_reload()
91 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_CTL1, val); in mv88e6250_g1_eeprom_reload()
92 if (err) in mv88e6250_g1_eeprom_reload()
93 return err; in mv88e6250_g1_eeprom_reload()
102 int err; in mv88e6xxx_g1_is_eeprom_done() local
104 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_STS, &val); in mv88e6xxx_g1_is_eeprom_done()
105 if (err < 0) { in mv88e6xxx_g1_is_eeprom_done()
107 return err; in mv88e6xxx_g1_is_eeprom_done()
174 int err; in mv88e6xxx_g1_set_switch_mac() local
177 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_MAC_01, reg); in mv88e6xxx_g1_set_switch_mac()
178 if (err) in mv88e6xxx_g1_set_switch_mac()
179 return err; in mv88e6xxx_g1_set_switch_mac()
182 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_MAC_23, reg); in mv88e6xxx_g1_set_switch_mac()
183 if (err) in mv88e6xxx_g1_set_switch_mac()
184 return err; in mv88e6xxx_g1_set_switch_mac()
187 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_MAC_45, reg); in mv88e6xxx_g1_set_switch_mac()
188 if (err) in mv88e6xxx_g1_set_switch_mac()
189 return err; in mv88e6xxx_g1_set_switch_mac()
199 int err; in mv88e6185_g1_reset() local
204 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL1, &val); in mv88e6185_g1_reset()
205 if (err) in mv88e6185_g1_reset()
206 return err; in mv88e6185_g1_reset()
211 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_CTL1, val); in mv88e6185_g1_reset()
212 if (err) in mv88e6185_g1_reset()
213 return err; in mv88e6185_g1_reset()
215 err = mv88e6xxx_g1_wait_init_ready(chip); in mv88e6185_g1_reset()
216 if (err) in mv88e6185_g1_reset()
217 return err; in mv88e6185_g1_reset()
225 int err; in mv88e6250_g1_reset() local
228 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL1, &val); in mv88e6250_g1_reset()
229 if (err) in mv88e6250_g1_reset()
230 return err; in mv88e6250_g1_reset()
234 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_CTL1, val); in mv88e6250_g1_reset()
235 if (err) in mv88e6250_g1_reset()
236 return err; in mv88e6250_g1_reset()
243 int err; in mv88e6352_g1_reset() local
245 err = mv88e6250_g1_reset(chip); in mv88e6352_g1_reset()
246 if (err) in mv88e6352_g1_reset()
247 return err; in mv88e6352_g1_reset()
255 int err; in mv88e6185_g1_ppu_enable() local
257 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL1, &val); in mv88e6185_g1_ppu_enable()
258 if (err) in mv88e6185_g1_ppu_enable()
259 return err; in mv88e6185_g1_ppu_enable()
263 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_CTL1, val); in mv88e6185_g1_ppu_enable()
264 if (err) in mv88e6185_g1_ppu_enable()
265 return err; in mv88e6185_g1_ppu_enable()
273 int err; in mv88e6185_g1_ppu_disable() local
275 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL1, &val); in mv88e6185_g1_ppu_disable()
276 if (err) in mv88e6185_g1_ppu_disable()
277 return err; in mv88e6185_g1_ppu_disable()
281 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_CTL1, val); in mv88e6185_g1_ppu_disable()
282 if (err) in mv88e6185_g1_ppu_disable()
283 return err; in mv88e6185_g1_ppu_disable()
291 int err; in mv88e6185_g1_set_max_frame_size() local
295 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL1, &val); in mv88e6185_g1_set_max_frame_size()
296 if (err) in mv88e6185_g1_set_max_frame_size()
297 return err; in mv88e6185_g1_set_max_frame_size()
319 int err; in mv88e6085_g1_ip_pri_map() local
322 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_0, 0x0000); in mv88e6085_g1_ip_pri_map()
323 if (err) in mv88e6085_g1_ip_pri_map()
324 return err; in mv88e6085_g1_ip_pri_map()
326 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_1, 0x0000); in mv88e6085_g1_ip_pri_map()
327 if (err) in mv88e6085_g1_ip_pri_map()
328 return err; in mv88e6085_g1_ip_pri_map()
330 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_2, 0x5555); in mv88e6085_g1_ip_pri_map()
331 if (err) in mv88e6085_g1_ip_pri_map()
332 return err; in mv88e6085_g1_ip_pri_map()
334 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_3, 0x5555); in mv88e6085_g1_ip_pri_map()
335 if (err) in mv88e6085_g1_ip_pri_map()
336 return err; in mv88e6085_g1_ip_pri_map()
338 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_4, 0xaaaa); in mv88e6085_g1_ip_pri_map()
339 if (err) in mv88e6085_g1_ip_pri_map()
340 return err; in mv88e6085_g1_ip_pri_map()
342 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_5, 0xaaaa); in mv88e6085_g1_ip_pri_map()
343 if (err) in mv88e6085_g1_ip_pri_map()
344 return err; in mv88e6085_g1_ip_pri_map()
346 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_6, 0xffff); in mv88e6085_g1_ip_pri_map()
347 if (err) in mv88e6085_g1_ip_pri_map()
348 return err; in mv88e6085_g1_ip_pri_map()
350 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_IP_PRI_7, 0xffff); in mv88e6085_g1_ip_pri_map()
351 if (err) in mv88e6085_g1_ip_pri_map()
352 return err; in mv88e6085_g1_ip_pri_map()
379 int err; in mv88e6095_g1_set_egress_port() local
381 err = mv88e6xxx_g1_read(chip, MV88E6185_G1_MONITOR_CTL, &reg); in mv88e6095_g1_set_egress_port()
382 if (err) in mv88e6095_g1_set_egress_port()
383 return err; in mv88e6095_g1_set_egress_port()
410 int err; in mv88e6095_g1_set_cpu_port() local
412 err = mv88e6xxx_g1_read(chip, MV88E6185_G1_MONITOR_CTL, &reg); in mv88e6095_g1_set_cpu_port()
413 if (err) in mv88e6095_g1_set_cpu_port()
414 return err; in mv88e6095_g1_set_cpu_port()
479 int err; in mv88e6390_g1_mgmt_rsvd2cpu() local
483 err = mv88e6390_g1_monitor_write(chip, ptr, 0xff); in mv88e6390_g1_mgmt_rsvd2cpu()
484 if (err) in mv88e6390_g1_mgmt_rsvd2cpu()
485 return err; in mv88e6390_g1_mgmt_rsvd2cpu()
489 err = mv88e6390_g1_monitor_write(chip, ptr, 0xff); in mv88e6390_g1_mgmt_rsvd2cpu()
490 if (err) in mv88e6390_g1_mgmt_rsvd2cpu()
491 return err; in mv88e6390_g1_mgmt_rsvd2cpu()
495 err = mv88e6390_g1_monitor_write(chip, ptr, 0xff); in mv88e6390_g1_mgmt_rsvd2cpu()
496 if (err) in mv88e6390_g1_mgmt_rsvd2cpu()
497 return err; in mv88e6390_g1_mgmt_rsvd2cpu()
501 err = mv88e6390_g1_monitor_write(chip, ptr, 0xff); in mv88e6390_g1_mgmt_rsvd2cpu()
502 if (err) in mv88e6390_g1_mgmt_rsvd2cpu()
503 return err; in mv88e6390_g1_mgmt_rsvd2cpu()
514 int err; in mv88e6xxx_g1_ctl2_mask() local
516 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_CTL2, &reg); in mv88e6xxx_g1_ctl2_mask()
517 if (err) in mv88e6xxx_g1_ctl2_mask()
518 return err; in mv88e6xxx_g1_ctl2_mask()
576 int err; in mv88e6095_g1_stats_set_histogram() local
578 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_STATS_OP, &val); in mv88e6095_g1_stats_set_histogram()
579 if (err) in mv88e6095_g1_stats_set_histogram()
580 return err; in mv88e6095_g1_stats_set_histogram()
584 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_STATS_OP, val); in mv88e6095_g1_stats_set_histogram()
586 return err; in mv88e6095_g1_stats_set_histogram()
591 int err; in mv88e6xxx_g1_stats_snapshot() local
594 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_STATS_OP, in mv88e6xxx_g1_stats_snapshot()
598 if (err) in mv88e6xxx_g1_stats_snapshot()
599 return err; in mv88e6xxx_g1_stats_snapshot()
614 int err; in mv88e6390_g1_stats_snapshot() local
619 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_STATS_OP, in mv88e6390_g1_stats_snapshot()
622 if (err) in mv88e6390_g1_stats_snapshot()
623 return err; in mv88e6390_g1_stats_snapshot()
633 int err; in mv88e6xxx_g1_stats_read() local
637 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_STATS_OP, in mv88e6xxx_g1_stats_read()
640 if (err) in mv88e6xxx_g1_stats_read()
643 err = mv88e6xxx_g1_stats_wait(chip); in mv88e6xxx_g1_stats_read()
644 if (err) in mv88e6xxx_g1_stats_read()
647 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_STATS_COUNTER_32, &reg); in mv88e6xxx_g1_stats_read()
648 if (err) in mv88e6xxx_g1_stats_read()
653 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_STATS_COUNTER_01, &reg); in mv88e6xxx_g1_stats_read()
654 if (err) in mv88e6xxx_g1_stats_read()
662 int err; in mv88e6xxx_g1_stats_clear() local
665 err = mv88e6xxx_g1_read(chip, MV88E6XXX_G1_STATS_OP, &val); in mv88e6xxx_g1_stats_clear()
666 if (err) in mv88e6xxx_g1_stats_clear()
667 return err; in mv88e6xxx_g1_stats_clear()
673 err = mv88e6xxx_g1_write(chip, MV88E6XXX_G1_STATS_OP, val); in mv88e6xxx_g1_stats_clear()
674 if (err) in mv88e6xxx_g1_stats_clear()
675 return err; in mv88e6xxx_g1_stats_clear()