#define hypercall_preempt_check() (unlikely( \
softirq_pending(smp_processor_id()) | \
local_events_need_delivery() \
))
Generally speaking, if there is pending softirq or upcall
events, the hypercall handler will exit and try to re-execute
next time. I have two confusions on hypercall preemption:
(1) Why pending softirq or upcall events can affect
hypercall's continuation ?
(2) When do we need to do hypercall_preempt_check()? For
example, do_mmuext_op() has this check but many other
hypercall handles don't do the check. How to judge where to
appy preemption check?
A lot of thanks,