plat/arm: css: Convert CSS_SYSTEM_PWR_STATE from macro to inline function
This is to fix a number of Coverity Scan DEADCODE defects, CID numbers
listed below, as reported from
https://scan.coverity.com/projects/arm-software-arm-trusted-firmware
CID 267023
CID 267022
CID 267020
Change-Id: I2963a799b210149e84ccab5c5b9082267ddfe337
Signed-off-by: Nariman Poushin <nariman.poushin@linaro.org>
diff --git a/plat/arm/css/common/css_pm.c b/plat/arm/css/common/css_pm.c
index 3df5b78..986cb08 100644
--- a/plat/arm/css/common/css_pm.c
+++ b/plat/arm/css/common/css_pm.c
@@ -96,7 +96,7 @@
void css_pwr_domain_on_finish(const psci_power_state_t *target_state)
{
/* Assert that the system power domain need not be initialized */
- assert(CSS_SYSTEM_PWR_STATE(target_state) == ARM_LOCAL_STATE_RUN);
+ assert(css_system_pwr_state(target_state) == ARM_LOCAL_STATE_RUN);
/* Program the gic per-cpu distributor or re-distributor interface */
plat_arm_gic_pcpu_init();
@@ -149,7 +149,7 @@
css_power_down_common(target_state);
/* Perform system domain state saving if issuing system suspend */
- if (CSS_SYSTEM_PWR_STATE(target_state) == ARM_LOCAL_STATE_OFF) {
+ if (css_system_pwr_state(target_state) == ARM_LOCAL_STATE_OFF) {
arm_system_pwr_domain_save();
/* Power off the Redistributor after having saved its context */
@@ -174,7 +174,7 @@
return;
/* Perform system domain restore if woken up from system suspend */
- if (CSS_SYSTEM_PWR_STATE(target_state) == ARM_LOCAL_STATE_OFF)
+ if (css_system_pwr_state(target_state) == ARM_LOCAL_STATE_OFF)
/*
* At this point, the Distributor must be powered on to be ready
* to have its state restored. The Redistributor will be powered