Re: RFC/patch portability: split kvm_vm_ioctl v2

Zhang, Xiantao
2007-10-26T01:05:49Z

Carsten Otte wrote:
> This patch splits kvm_vm_ioctl into archtecture independent parts, and
> x86 specific parts which go to kvm_arch_vcpu_ioctl in x86.c.
>
> Common ioctls for all architectures are:
> KVM_CREATE_VCPU, KVM_GET_DIRTY_LOG, KVM_SET_USER_MEMORY_REGION
>
> KVM_SET_USER_MEMORY_REGION is actually implemented in x86.c now,
Hi Carsten,

I don't think we can move the whole function to arch-specific part,
because it should work well (or with few issues) for most archs.
Basically, IA64 mostly can use it directly. If we move them as
arch-specific, it will introduces many duplicates. As you said, S390 has
quite difference about this side, but I think maybe we can use macros,
such as #ifndef CONFIG_S390 to comment out them, and S390 define it in
your arch-specific portions. Any other good ideas ?

Thanks
Xiantao