[PATCH 2/2] cpuidle: qcom-spm: drop unnecessary initialisations

Johan Hovold posted 2 patches 1 day, 10 hours ago
[PATCH 2/2] cpuidle: qcom-spm: drop unnecessary initialisations
Posted by Johan Hovold 1 day, 10 hours ago
Drop the unnecessary initialisations of the platform device and driver
data pointers which are assigned on first use when registering the
cpuidle device during probe.

Signed-off-by: Johan Hovold <johan@kernel.org>
---
 drivers/cpuidle/cpuidle-qcom-spm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/cpuidle/cpuidle-qcom-spm.c b/drivers/cpuidle/cpuidle-qcom-spm.c
index f60a4cf53642..7ab6f68b96a8 100644
--- a/drivers/cpuidle/cpuidle-qcom-spm.c
+++ b/drivers/cpuidle/cpuidle-qcom-spm.c
@@ -86,9 +86,9 @@ static const struct of_device_id qcom_idle_state_match[] = {
 
 static int spm_cpuidle_register(struct device *cpuidle_dev, int cpu)
 {
-	struct platform_device *pdev = NULL;
+	struct platform_device *pdev;
 	struct device_node *cpu_node, *saw_node;
-	struct cpuidle_qcom_spm_data *data = NULL;
+	struct cpuidle_qcom_spm_data *data;
 	int ret;
 
 	cpu_node = of_cpu_device_node_get(cpu);
-- 
2.49.1
Re: [PATCH 2/2] cpuidle: qcom-spm: drop unnecessary initialisations
Posted by Konrad Dybcio 1 day, 10 hours ago
On 9/8/25 5:22 PM, Johan Hovold wrote:
> Drop the unnecessary initialisations of the platform device and driver
> data pointers which are assigned on first use when registering the
> cpuidle device during probe.
> 
> Signed-off-by: Johan Hovold <johan@kernel.org>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>

Konrad