File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -305,7 +305,9 @@ static __always_inline unsigned long kvm_vcpu_get_hfar(const struct kvm_vcpu *vc
305
305
306
306
static __always_inline phys_addr_t kvm_vcpu_get_fault_ipa (const struct kvm_vcpu * vcpu )
307
307
{
308
- return ((phys_addr_t )vcpu -> arch .fault .hpfar_el2 & HPFAR_MASK ) << 8 ;
308
+ u64 hpfar = vcpu -> arch .fault .hpfar_el2 ;
309
+
310
+ return FIELD_GET (HPFAR_EL2_FIPA , hpfar ) << 12 ;
309
311
}
310
312
311
313
static inline u64 kvm_vcpu_get_disr (const struct kvm_vcpu * vcpu )
Original file line number Diff line number Diff line change @@ -578,7 +578,7 @@ void handle_host_mem_abort(struct kvm_cpu_context *host_ctxt)
578
578
return ;
579
579
}
580
580
581
- addr = ( fault .hpfar_el2 & HPFAR_MASK ) << 8 ;
581
+ addr = FIELD_GET ( HPFAR_EL2_FIPA , fault .hpfar_el2 ) << 12 ;
582
582
ret = host_stage2_idmap (addr );
583
583
BUG_ON (ret && ret != - EAGAIN );
584
584
}
Original file line number Diff line number Diff line change @@ -3433,3 +3433,10 @@ Field 5 F
3433
3433
Field 4 P
3434
3434
Field 3:0 Align
3435
3435
EndSysreg
3436
+
3437
+ Sysreg HPFAR_EL2 3 4 6 0 4
3438
+ Field 63 NS
3439
+ Res0 62:48
3440
+ Field 47:4 FIPA
3441
+ Res0 3:0
3442
+ EndSysreg
You can’t perform that action at this time.
0 commit comments