11.09.2023 15:32, Kevin Wolf wrote:
..

The approach with static inline functions defined only for a very
specific configuration looks a lot more fragile to me. In fact, I'm
surprised that it works because I think it requires that the header
isn't used in any files that are shared between user space and system
emulation - and naively cpu.c sounded like something that could be
shared. Looks like this patch only works because the linux-user target
uses a separate build of the same CPU emulation source file.

That's why both I and Stephan disliked the #ifdef condition, not the
approach.  If it were me, I'd change the condition to be !KVM and keep
the inline functions (or #defines for that matter), instead of re-
introducing stubs in a separate .c file.

/mjt

Reply via email to