>>> On 07.08.18 at 12:00, <wei.l...@citrix.com> wrote:
> --- a/xen/include/asm-x86/hvm/guest_access.h
> +++ b/xen/include/asm-x86/hvm/guest_access.h
> @@ -1,8 +1,32 @@
>  #ifndef __ASM_X86_HVM_GUEST_ACCESS_H__
>  #define __ASM_X86_HVM_GUEST_ACCESS_H__
>  
> +#if CONFIG_HVM
> +
>  unsigned long copy_to_user_hvm(void *to, const void *from, unsigned len);
>  unsigned long clear_user_hvm(void *to, unsigned int len);
>  unsigned long copy_from_user_hvm(void *to, const void *from, unsigned len);
>  
> +#else
> +
> +static inline
> +unsigned long copy_to_user_hvm(void *to, const void *from, unsigned len)
> +{
> +    return len;
> +}
> +
> +static inline
> +unsigned long clear_user_hvm(void *to, unsigned int len)
> +{
> +    return len;
> +}
> +
> +static inline
> +unsigned long copy_from_user_hvm(void *to, const void *from, unsigned len)
> +{
> +    return len;
> +}
> +
> +#endif

With BUG() or at least ASSERT_UNREACHABLE() put into all of them
Acked-by: Jan Beulich <jbeul...@suse.com>

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to