On 04/25/2011 11:04 AM, Jan Kiszka wrote:
> + > + ptep_user = (pt_element_t __user *)((void *)host_addr + offset); > + if (get_user(pte, ptep_user)) { ^^^^^^^^^^^^ This doesn't work for x86-32: pte is 64 bit, but get_user is only defined up to 32 bit on that platform.
I actually considered this, and saw: #ifdef CONFIG_X86_32 #define __get_user_8(__ret_gu, __val_gu, ptr) \ __get_user_x(X, __ret_gu, __val_gu, ptr) #else #define __get_user_8(__ret_gu, __val_gu, ptr) \ __get_user_x(8, __ret_gu, __val_gu, ptr) #endif #define get_user(x, ptr) \ ({ \ int __ret_gu; \ unsigned long __val_gu; \ __chk_user_ptr(ptr); \ might_fault(); \ switch (sizeof(*(ptr))) { \ ... case 8: \ __get_user_8(__ret_gu, __val_gu, ptr); \ break; \ ... } \ (x) = (__typeof__(*(ptr)))__val_gu; \ __ret_gu; \ }) so it should work. How does it fail?
Avi, what's your 32-bit buildbot doing? :)
I regularly autotest on x86_64, not on i386, sorry. -- error compiling committee.c: too many arguments to function -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html