On 29/10/2018 22:39, Emilio G. Cota wrote:
> I'm not convinced about adding an "assert(!user-mode)" to run_on_cpu.
> Given that now it does not depend on the BQL, it could actually
> work in user-mode if called. If we really wanted to make sure
> that no user-mode would call it, then a compile-time check
> would be better than an assert. But again, I fail to see what
> we'd gain from that.
> 
> For context, do_run_on_cpu et al. were moved to cpus-common.c by
> d148d90ee8 ("cpus-common: move CPU work item management to
> common code", 2016-09-27). The point was to consolidate the
> run-on-cpu code in a common (softmmu & user-mode) file, since
> user-mode needed async_run_on_cpu for exclusive work.
> 
> Now we can finally make run_on_cpu generic as well.

I agree, the run_on_cpu stuff should not be system-specific at all.

Paolo

Reply via email to