__local_per_cpu_offset = __per_cpu_offset(cpuid);
- if (tlb_type == hypervisor)
+ if (tlb_type == hypervisor) {
sun4v_register_fault_status();
+ sun4v_ktsb_register();
+ }
__flush_tlb_all();
"2" (arg1), "3" (arg2),
"i" (HV_FAST_TRAP)
: "memory");
- if (likely(func == HV_EOK))
+ if (likely(arg0 == HV_EOK))
break;
if (unlikely(++retries > 100)) {
"2" (arg1), "3" (arg2),
"i" (HV_FAST_TRAP)
: "memory");
- if (likely(func == HV_EOK))
+ if (likely(arg0 == HV_EOK))
break;
if (unlikely(++retries > 100)) {
if (!cpu_isset(cpu, cpu_online_map)) {
ret = -ENODEV;
} else {
- smp_synchronize_one_tick(cpu);
+ /* On SUN4V, writes to %tick and %stick are
+ * not allowed.
+ */
+ if (tlb_type != hypervisor)
+ smp_synchronize_one_tick(cpu);
}
}
return ret;