On 06/28/2010 11:21 AM, Alexander Graf wrote:
The other alternative I'd see is to reuse an instruction that is not sc. We could for
example pull the mfpvr trick again, but pass a different magic value in the register this
time that tells the hypervisor "this is a hypercall".
Or we could reserve a different SPR. But from what I've seen there are already
quite a lot of SPRs out there. More than available numbers :).
The hypercall technique I used here is actually inspired by MOL. They use magic constants
in r3 and r4 for their "OSI" identification. I'm frankly not sure what the best
approach is, but considering that syscalls from the kernel lie in the guest kernel's
hand, we could just declare any breakage a guest kernel bug.
Magic = liable to break without notice.
Given r0 is the architectural syscall number, and r3 is the Linux
syscall number, we can use a combination of r0 and r3, reserve r3 in
Linux, and hope that no one else uses our selection of r0.
Still smelly, but not as bad.
--
error compiling committee.c: too many arguments to function
_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev