OSDN Git Service
(root)
/
uclinux-h8
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
04b8a4b
)
drm/nouveau/pmu: do not assume a PMU is present
author
Alexandre Courbot
<acourbot@nvidia.com>
Thu, 3 Sep 2015 08:39:52 +0000
(17:39 +0900)
committer
Ben Skeggs
<bskeggs@redhat.com>
Tue, 3 Nov 2015 05:02:18 +0000
(15:02 +1000)
Some devices may not have a PMU. Avoid a NULL pointer dereference in
such cases by checking whether the pointer given to nvkm_pmu_pgob() is
valid.
Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c
b/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c
index
27a79c0
..
d95eb86
100644
(file)
--- a/
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c
+++ b/
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c
@@
-28,7
+28,7
@@
void
nvkm_pmu_pgob(struct nvkm_pmu *pmu, bool enable)
{
- if (pmu->func->pgob)
+ if (pmu
&& pmu
->func->pgob)
pmu->func->pgob(pmu, enable);
}