Lines Matching defs:cpu_base
3581 static int tg3_pause_cpu(struct tg3 *tp, u32 cpu_base)
3587 tw32(cpu_base + CPU_STATE, 0xffffffff);
3588 tw32(cpu_base + CPU_MODE, CPU_MODE_HALT);
3589 if (tr32(cpu_base + CPU_MODE) & CPU_MODE_HALT)
3617 static void tg3_resume_cpu(struct tg3 *tp, u32 cpu_base)
3619 tw32(cpu_base + CPU_STATE, 0xffffffff);
3620 tw32_f(cpu_base + CPU_MODE, 0x00000000);
3630 static int tg3_halt_cpu(struct tg3 *tp, u32 cpu_base)
3634 BUG_ON(cpu_base == TX_CPU_BASE && tg3_flag(tp, 5705_PLUS));
3642 if (cpu_base == RX_CPU_BASE) {
3657 __func__, cpu_base == RX_CPU_BASE ? "RX" : "TX");
3695 static int tg3_load_firmware_cpu(struct tg3 *tp, u32 cpu_base,
3703 if (cpu_base == TX_CPU_BASE && tg3_flag(tp, 5705_PLUS)) {
3720 err = tg3_halt_cpu(tp, cpu_base);
3728 tw32(cpu_base + CPU_STATE, 0xffffffff);
3729 tw32(cpu_base + CPU_MODE,
3730 tr32(cpu_base + CPU_MODE) | CPU_MODE_HALT);
3761 static int tg3_pause_cpu_and_set_pc(struct tg3 *tp, u32 cpu_base, u32 pc)
3766 tw32(cpu_base + CPU_STATE, 0xffffffff);
3767 tw32_f(cpu_base + CPU_PC, pc);
3770 if (tr32(cpu_base + CPU_PC) == pc)
3772 tw32(cpu_base + CPU_STATE, 0xffffffff);
3773 tw32(cpu_base + CPU_MODE, CPU_MODE_HALT);
3774 tw32_f(cpu_base + CPU_PC, pc);
3899 unsigned long cpu_base, cpu_scratch_base, cpu_scratch_size;
3916 cpu_base = RX_CPU_BASE;
3919 cpu_base = TX_CPU_BASE;
3924 err = tg3_load_firmware_cpu(tp, cpu_base,
3931 err = tg3_pause_cpu_and_set_pc(tp, cpu_base,
3936 __func__, tr32(cpu_base + CPU_PC),
3941 tg3_resume_cpu(tp, cpu_base);