cpufreq: armada-37xx: stop using 0 as NULL pointer
authorMiles Chen <miles.chen@mediatek.com>
Tue, 10 Jan 2023 03:12:52 +0000 (11:12 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 1 Feb 2023 07:27:17 +0000 (08:27 +0100)
[ Upstream commit 08f0adb193c008de640fde34a2e00a666c01d77c ]

Use NULL for NULL pointer to fix the following sparse warning:
drivers/cpufreq/armada-37xx-cpufreq.c:448:32: sparse: warning: Using plain integer as NULL pointer

Signed-off-by: Miles Chen <miles.chen@mediatek.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/cpufreq/armada-37xx-cpufreq.c

index c10fc33..b74289a 100644 (file)
@@ -445,7 +445,7 @@ static int __init armada37xx_cpufreq_driver_init(void)
                return -ENODEV;
        }
 
-       clk = clk_get(cpu_dev, 0);
+       clk = clk_get(cpu_dev, NULL);
        if (IS_ERR(clk)) {
                dev_err(cpu_dev, "Cannot get clock for CPU0\n");
                return PTR_ERR(clk);