diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2024-07-19 14:31:18 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2024-07-19 14:31:18 -0700 |
commit | 9c67f9084af3f84e63abb44b82316fe0dbccd5d5 (patch) | |
tree | eb17f64e3ecf9133f63df51b81fed779d658daf3 /drivers/power | |
parent | 12cc3d5389f313f07222b000fefa2cd8fc98c4f8 (diff) | |
parent | 1a8c67a8b21e26843d5641c55f48130b3e323ce8 (diff) |
Merge tag 'pwrseq-fixes-for-v6.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux
Pull power sequencing fixes from Bartosz Golaszewski:
"There's one fix for an invalid pointer dereference in error path
reported by smatch and two patches that address the noisy config
choices you reported earlier this week.
Summary:
- fix an invalid pointer dereference in error path in pwrseq core
- reduce the Kconfig noise from PCI pwrctl choices"
* tag 'pwrseq-fixes-for-v6.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
arm64: qcom: don't select HAVE_PWRCTL when PCI=n
Kconfig: reduce the amount of power sequencing noise
power: sequencing: fix an invalid pointer dereference in error path
Diffstat (limited to 'drivers/power')
-rw-r--r-- | drivers/power/sequencing/core.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/power/sequencing/core.c b/drivers/power/sequencing/core.c index 9c32b07a55e7..0ffc259c6bb6 100644 --- a/drivers/power/sequencing/core.c +++ b/drivers/power/sequencing/core.c @@ -212,7 +212,8 @@ pwrseq_target_new(const struct pwrseq_target_data *data) static void pwrseq_target_free(struct pwrseq_target *target) { - pwrseq_unit_put(target->unit); + if (!IS_ERR_OR_NULL(target->unit)) + pwrseq_unit_put(target->unit); kfree_const(target->name); kfree(target); } |