It appears to have introduced a regression on arm64, possibly due to the
fact that the pcpu pointer is reloaded outside of the critical section
in _rm_rlock(). Until this is resolved one way or another, let's
revert.
Reported by: Ronald Klop <ronald-lists@klop.ws>
Sponsored by: The FreeBSD Foundation
(cherry picked from commit
afb44cb01018eb1363cb4ee20a31534b844d00f7)
atomic_interrupt_fence();
- pc = get_pcpu();
+ pc = cpuid_to_pcpu[td->td_oncpu];
rm_tracker_add(pc, tracker);
return;
td->td_critnest++; /* critical_enter(); */
- pc = get_pcpu();
+ pc = cpuid_to_pcpu[td->td_oncpu];
rm_tracker_remove(pc, tracker);
td->td_critnest--;
sched_unpin();