KVM: hyper-v: housekeeping: Remove unnecessary type cast
Subsystems (4)
PATCH 1/1 KVM: hyper-v: housekeeping: Remove unnecessary type cast
Remove unnecessary type cast of 'u8 instructions[]' to 'unsigned char *'.
Signed-off-by Siddharth Chandrasekaran <[email protected]>
--- arch/x86/kvm/hyperv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kvm/hyperv.c +1 -1
@@ -1252,7 +1252,7 @@ static int kvm_hv_set_msr_pw(struct kvm_vcpu *vcpu, u32 msr, u64 data, i +=3 ;/* ret */ - ((unsigned char *)instructions)[i++] =0xc3 ; + instructions[i++] =0xc3 ; addr = data &HV_X64_MSR_HYPERCALL_PAGE_ADDRESS_MASK ;if (kvm_vcpu_write_guest (vcpu, addr, instructions, i))
Signature · 12 lines
2.17.1 Amazon Development Center Germany GmbH Krausenstr. 38 10117 Berlin Geschaeftsfuehrung: Christian Schlaeger, Jonathan Weiss Eingetragen am Amtsgericht Charlottenburg unter HRB 149173 B Sitz: Berlin Ust-ID: DE 289 237 879
Quoted 5 lines · Siddharth Chandrasekaran
Remove unnecessary type cast of 'u8 instructions[]' to 'unsigned char *'.
Signed-off-by Siddharth Chandrasekaran <[email protected]>---
Reviewed-by Sean Christopherson <[email protected]>