Commit 6e37ec8 1 parent e3bcfda commit 6e37ec8 Copy full SHA for 6e37ec8
File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 90
90
u64 __read_mostly kvm_mce_cap_supported = MCG_CTL_P | MCG_SER_P ;
91
91
EXPORT_SYMBOL_GPL (kvm_mce_cap_supported );
92
92
93
+ #define ERR_PTR_USR (e ) ((void __user *)ERR_PTR(e))
94
+
93
95
#define emul_to_vcpu (ctxt ) \
94
96
((struct kvm_vcpu *)(ctxt)->vcpu)
95
97
@@ -4340,7 +4342,7 @@ static inline void __user *kvm_get_attr_addr(struct kvm_device_attr *attr)
4340
4342
void __user * uaddr = (void __user * )(unsigned long )attr -> addr ;
4341
4343
4342
4344
if ((u64 )(unsigned long )uaddr != attr -> addr )
4343
- return ERR_PTR (- EFAULT );
4345
+ return ERR_PTR_USR (- EFAULT );
4344
4346
return uaddr ;
4345
4347
}
4346
4348
@@ -11684,8 +11686,6 @@ void kvm_arch_sync_events(struct kvm *kvm)
11684
11686
kvm_free_pit (kvm );
11685
11687
}
11686
11688
11687
- #define ERR_PTR_USR (e ) ((void __user *)ERR_PTR(e))
11688
-
11689
11689
/**
11690
11690
* __x86_set_memory_region: Setup KVM internal memory slot
11691
11691
*
You can’t perform that action at this time.
0 commit comments