summaryrefslogtreecommitdiffstats
path: root/drivers/soc/tegra
diff options
context:
space:
mode:
authorPetlozu Pravareshwar <petlozup@nvidia.com>2022-09-06 13:51:17 +0000
committerThierry Reding <treding@nvidia.com>2022-09-15 14:10:49 +0200
commit74f7f183d81c26a53c2b1708364069d391b1b4d6 (patch)
treea4be576a6f358cd653cd490741e1331974f35391 /drivers/soc/tegra
parentc18f3524422dd28d2049f9ad3822a70e918a340d (diff)
downloadlinux-74f7f183d81c26a53c2b1708364069d391b1b4d6.tar.bz2
soc/tegra: pmc: Check device node status property
In early_initcall, check if PMC device is available for use and avoid accessing PMC resources if the device node status property is set to disabled. Signed-off-by: Manish Bhardwaj <mbhardwaj@nvidia.com> Signed-off-by: Petlozu Pravareshwar <petlozup@nvidia.com> Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'drivers/soc/tegra')
-rw-r--r--drivers/soc/tegra/pmc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/soc/tegra/pmc.c b/drivers/soc/tegra/pmc.c
index 961b2de16307..678e8bc8a45d 100644
--- a/drivers/soc/tegra/pmc.c
+++ b/drivers/soc/tegra/pmc.c
@@ -4044,7 +4044,7 @@ static int __init tegra_pmc_early_init(void)
return -ENXIO;
}
- if (np) {
+ if (of_device_is_available(np)) {
pmc->soc = match->data;
if (pmc->soc->maybe_tz_only)