Skip to contentSkip to conversation

psci: rename psci_features function

PATCH RESEND Superseded Igor Opaniuk 2 participants 2 messages May 5, 2021

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 psci: rename psci_features function

From: Igor Opaniuk <[email protected]>

s/psci_features/psci_features_req/g for the case when both ARCH_SUPPORT_PSCI=y and ARM_PSCI_FW=y, that leads to these compilation issues:

drivers/firmware/psci.c:69:12: error: conflicting types for 'psci_features'
69 | static int psci_features(u32 psci_func_id)

      |            ^~~~~~~~~~~~~
In file included from drivers/firmware/psci.c:23:
./arch/arm/include/asm/system.h:548:5: note: previous declaration of 'psci_features' was here
  548 | s32 psci_features(u32 function_id, u32 psci_fid);
      |     ^~~~~~~~~~~~~

---

 drivers/firmware/psci.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/firmware/psci.c +2 -2
index be57552aba..f1841a1835 100644
@@ -66,7 +66,7 @@ unsigned long __efi_runtime invoke_psci_fn
 	return res.a0;
 }
 
-static int psci_features(u32 psci_func_id)
+static int psci_features_req(u32 psci_func_id)
 {
 	return invoke_psci_fn(PSCI_1_0_FN_PSCI_FEATURES,
 			      psci_func_id, 0, 0);
@@ -85,7 +85,7 @@ static bool psci_is_system_reset2_supported(void)
 	ver = psci_0_2_get_version();
 
 	if (PSCI_VERSION_MAJOR(ver) >= 1) {
-		ret = psci_features(PSCI_FN_NATIVE(1_1, SYSTEM_RESET2));
+		ret = psci_features_req(PSCI_FN_NATIVE(1_1, SYSTEM_RESET2));
 
 		if (ret != PSCI_RET_NOT_SUPPORTED)
 			return true;
Signature · 1 line
2.25.1
#1 lore raw

PATCH RESEND 1/1 psci: rename psci_features function

Quoted 11 lines · Igor Opaniuk

From: Igor Opaniuk <[email protected]>

s/psci_features/psci_features_req/g for the case when both ARCH_SUPPORT_PSCI=y and ARM_PSCI_FW=y, that leads to these compilation issues:

drivers/firmware/psci.c:69:12: error: conflicting types for 'psci_features'
69 | static int psci_features(u32 psci_func_id)
| ^~~~~~~~~~~~~
In file included from drivers/firmware/psci.c:23:
./arch/arm/include/asm/system.h:548:5: note: previous declaration of 'psci_features' was heremailto:igor.opaniuk at foundries.io

Quoted 5 lines
   548 | s32 psci_features(u32 function_id, u32 psci_fid);
       |     ^~~~~~~~~~~~~
Quoted 19 lines

---

  drivers/firmware/psci.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
drivers/firmware/psci.c +1 -1
index be57552aba..f1841a1835 100644
@@ -66,7 +66,7 @@ unsigned long __efi_runtime invoke_psci_fn
  	return res.a0;
  }
 
-static int psci_features(u32 psci_func_id)
+static int psci_features_req(u32 psci_func_id)
  {
  	return invoke_psci_fn(PSCI_1_0_FN_PSCI_FEATURES,
  			      psci_func_id, 0, 0);

drivers/firmware/psci.c req(PSCI_FN_NATIVE(1_1, SYSTEM_RESET2)); · line 89

Quoted 6 lines
drivers/firmware/psci.c +1 -1
@@ -85,7 +85,7 @@req(PSCI_FN_NATIVE(1_1, SYSTEM_RESET2));
   static bool psci_is_system_reset2_supported(void)
  	ver = psci_0_2_get_version();
 
  	if (PSCI_VERSION_MAJOR(ver) >= 1) {
-		ret = psci_features(PSCI_FN_NATIVE(1_1, SYSTEM_RESET2));
+		ret = psci_features_req(PSCI_FN_NATIVE(1_1, SYSTEM_RESET2));

Can you include a verb in the function name? For example request_psci_features(), or call_psci_features()

Alex