linux_dsm_epyc7002/drivers/gpu/drm/msm/adreno
Archit Taneja 9dcfbc182f drm/msm: Fix NULL deref in adreno_load_gpu
The msm/kms driver should work even if there is no GPU device specified
in DT. Currently, we get a NULL dereference crash in adreno_load_gpu
since the driver assumes that priv->gpu_pdev is non-NULL.

Perform an additional check on priv->gpu_pdev before trying to retrieve
the msm_gpu pointer from it.

v2: Incorporate Jordan's comments:
- Simplify the check to share the same error message.
- Use dev_err_once() to avoid an error message every time we open the
  drm device fd.

Fixes: eec874ce5f (drm/msm/adreno: load gpu at probe/bind time)

Signed-off-by: Archit Taneja <architt@codeaurora.org>
Acked-by: Jordan Crouse <jcrouse@codeaurora.org>
Signed-off-by: Rob Clark <robdclark@gmail.com>
2018-01-03 09:36:17 -05:00
..
a2xx.xml.h drm/msm: update generated headers 2017-06-16 11:16:07 -04:00
a3xx_gpu.c drm/msm: Support multiple ringbuffers 2017-10-28 11:01:36 -04:00
a3xx_gpu.h drm/msm: Remove uneeded platform dev members 2017-08-02 07:57:02 -04:00
a3xx.xml.h drm/msm: update generated headers 2017-06-16 11:16:07 -04:00
a4xx_gpu.c drm/msm: Support multiple ringbuffers 2017-10-28 11:01:36 -04:00
a4xx_gpu.h drm/msm: Remove uneeded platform dev members 2017-08-02 07:57:02 -04:00
a4xx.xml.h drm/msm: update generated headers 2017-06-16 11:16:07 -04:00
a5xx_gpu.c drm/msm: Implement preemption for A5XX targets 2017-10-28 11:01:38 -04:00
a5xx_gpu.h drm/msm: Implement preemption for A5XX targets 2017-10-28 11:01:38 -04:00
a5xx_power.c drm/msm: Support multiple ringbuffers 2017-10-28 11:01:36 -04:00
a5xx_preempt.c treewide: setup_timer() -> timer_setup() 2017-11-21 15:57:07 -08:00
a5xx.xml.h drm/msm: update generated headers 2017-06-16 11:16:07 -04:00
adreno_common.xml.h drm/msm: update generated headers 2017-06-16 11:16:07 -04:00
adreno_device.c drm/msm: Fix NULL deref in adreno_load_gpu 2018-01-03 09:36:17 -05:00
adreno_gpu.c drm/msm: fix spelling mistake: "ringubffer" -> "ringbuffer" 2017-12-13 11:01:20 -05:00
adreno_gpu.h drm/msm: Implement preemption for A5XX targets 2017-10-28 11:01:38 -04:00
adreno_pm4.xml.h drm/msm: update generated headers 2017-06-16 11:16:07 -04:00