soc: spacemit: pm_domain: Add return -EINVAL in notifier_call
authorJaehoon Chung <jh80.chung@samsung.com>
Tue, 7 Jan 2025 00:45:57 +0000 (09:45 +0900)
committerJaehoon Chung <jh80.chung@samsung.com>
Tue, 29 Apr 2025 03:38:28 +0000 (12:38 +0900)
If action is not matched with anything, it needs to return with value.
lock/unlock will be a pair. Otherwise unlock is called twice.

Change-Id: I4eb3955572635257eb5bdf992c201c5efb509495
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
drivers/soc/spacemit/pm_domain/k1x-pm_domain.c

index 49f4f6dd8345ce52d93133b6f852fb25c768abd2..b7c10cd2e55638757f9cccae9e2242d46fdc7a2c 100644 (file)
@@ -531,6 +531,7 @@ static int spacemit_cpuidle_qos_notfier_call(struct notifier_block *nb, unsigned
                default:
                        pr_warn("Invalidate pm qos value\n");
                        spin_unlock(&spacemit_apcr_qos_lock);
+                       return -EINVAL;
        }
 
        regmap_read(gpmu->regmap[MPMU_REGMAP_INDEX], MPMU_APCR_PER_REG, &apcr_per);