]> git.ipfire.org Git - thirdparty/linux.git/commit
LoongArch: KVM: Fix base address calculation in kvm_eiointc_regs_access()
authorBibo Mao <maobibo@loongson.cn>
Thu, 26 Mar 2026 06:29:09 +0000 (14:29 +0800)
committerHuacai Chen <chenhuacai@loongson.cn>
Thu, 26 Mar 2026 06:29:09 +0000 (14:29 +0800)
commit6bcfb7f46d667b04bd1a1169ccedf5fb699c60df
treea00d5e2d479adc745ff7152da9988d4c188899b6
parentb97bd69eb0f67b5f961b304d28e9ba45e202d841
LoongArch: KVM: Fix base address calculation in kvm_eiointc_regs_access()

In function kvm_eiointc_regs_access(), the register base address is
caculated from array base address plus offset, the offset is absolute
value from the base address. The data type of array base address is
u64, it should be converted into the "void *" type and then plus the
offset.

Cc: <stable@vger.kernel.org>
Fixes: d3e43a1f34ac ("LoongArch: KVM: Use 64-bit register definition for EIOINTC").
Reported-by: Aurelien Jarno <aurel32@debian.org>
Link: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1131431
Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
arch/loongarch/kvm/intc/eiointc.c