Skip to contentSkip to conversation

smccc: kvm_guest: Align with DISCOVER_IMPL_CPUS ABI

PATCH Applied Oliver Upton 2 participants 3 messages Mar 27, 2025 – Apr 1, 2025

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 smccc: kvm_guest: Align with DISCOVER_IMPL_CPUS ABI

The ABI of the hypercall requires that R2 and R3 are 0. Explicitly pass 0 for these parameters.

Cc Shameer Kolothum <[email protected]>
Fixes 86edf6bdcf05 ("smccc/kvm_guest: Enable errata based on implementation CPUs")
---
 drivers/firmware/smccc/kvm_guest.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/firmware/smccc/kvm_guest.c +1 -1
index 5767aed25cdc..ac2d3cf8a776 100644
@@ -95,7 +95,7 @@ void  __init kvm_arm_target_impl_cpu_init(void)
 
 	for (i = 0; i < max_cpus; i++) {
 		arm_smccc_1_1_invoke(ARM_SMCCC_VENDOR_HYP_KVM_DISCOVER_IMPL_CPUS_FUNC_ID,
-				     i, &res);
+				     i, 0, 0, &res);
 		if (res.a0 != SMCCC_RET_SUCCESS) {
 			pr_warn("Discovering target implementation CPUs failed\n");
 			goto mem_free;

base-commit: 369c0122682c4468a69f2454614eded71c5348f3

Signature · 1 line
2.39.5
Reviewed-by on v1 1/1
#1 lore raw
Quoted 14 lines

-----Original Message-----
From: Oliver Upton <[email protected]>
Sent: Thursday, March 27, 2025 4:36 PM
To: [email protected]
Cc: [email protected]; [email protected]; Mark Rutland <[email protected]>; Lorenzo Pieralisi <[email protected]>; Sudeep Holla <[email protected]>; Catalin Marinas <[email protected]>; Marc Zyngier <[email protected]>; Oliver Upton <[email protected]>; Shameerali Kolothum Thodi <[email protected]>
Subject: [PATCH] smccc: kvm_guest: Align with DISCOVER_IMPL_CPUS ABI

Quoted 7 lines

The ABI of the hypercall requires that R2 and R3 are 0. Explicitly pass 0 for these parameters.

Cc Shameer Kolothum <[email protected]>
Fixes 86edf6bdcf05 ("smccc/kvm_guest: Enable errata based on

implementation CPUs")

Thanks,
Shameer

Quoted 25 lines
---
 drivers/firmware/smccc/kvm_guest.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/firmware/smccc/kvm_guest.c +1 -1
index 5767aed25cdc..ac2d3cf8a776 100644
@@ -95,7 +95,7 @@ void  __init kvm_arm_target_impl_cpu_init(void)
 
 	for (i = 0; i < max_cpus; i++) {
 
 	arm_smccc_1_1_invoke(ARM_SMCCC_VENDOR_HYP_KVM_DISCOVE
 R_IMPL_CPUS_FUNC_ID,
-				     i, &res);
+				     i, 0, 0, &res);
 		if (res.a0 != SMCCC_RET_SUCCESS) {

pr_warn("Discovering target implementation CPUs
failed\n");
goto mem_free;

base-commit: 369c0122682c4468a69f2454614eded71c5348f3 --
2.39.5