Guest/Xen memory parameters
Hollis, Jimi,
I had a go at the Xen changes needed to support different memory passing schemes. See the changes in public/memory.h and xen/guest_access.h. I think it does what you require and also has the advantage of keeping pointer type checking. It has the disadvantage that you have to define a structural type for each different 'type' of handle you want to deal with, and the type names can't contain whitespace.
The names and interfaces can be changed if we come up with something better. When we're happy with the changes we can apply them to other hypercalls too.
-- Keir
Quoted 4 lines · Keir Fraser
I had a go at the Xen changes needed to support different memory passing schemes. See the changes in
public/memory.handxen/guest_access.h.
Thanks Keir. As soon as I've merged up some of the other things we've let slide (arch API changes, porting to the new gdb stub) I'll be checking this out...
Is the end goal to replace all copy_to_user() callers in arch-generic code with copy_to_guest()?
Signature · 2 lines
Hollis Blanchard IBM Linux Technology Center
Quoted 10 lines · Hollis Blanchard
Quoted 3 lines
I had a go at the Xen changes needed to support different memory passing schemes. See the changes in
public/memory.handxen/guest_access.h.Thanks Keir. As soon as I've merged up some of the other things we've let slide (arch API changes, porting to the new gdb stub) I'll be checking this out...
Is the end goal to replace all
copy_to_user()callers in arch-generic code withcopy_to_guest()?
Yes, the xxx_user macros will be limited to arch-dep code and will ultimately be renamed to something more informative.
-- Keir