aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/linux-yocto-4.14.71/4175-drm-amdgpu-fix-null-pointer-panic-with-direct-fw-loa.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.14.71/4175-drm-amdgpu-fix-null-pointer-panic-with-direct-fw-loa.patch')
-rw-r--r--common/recipes-kernel/linux/linux-yocto-4.14.71/4175-drm-amdgpu-fix-null-pointer-panic-with-direct-fw-loa.patch55
1 files changed, 55 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.14.71/4175-drm-amdgpu-fix-null-pointer-panic-with-direct-fw-loa.patch b/common/recipes-kernel/linux/linux-yocto-4.14.71/4175-drm-amdgpu-fix-null-pointer-panic-with-direct-fw-loa.patch
new file mode 100644
index 00000000..f197d500
--- /dev/null
+++ b/common/recipes-kernel/linux/linux-yocto-4.14.71/4175-drm-amdgpu-fix-null-pointer-panic-with-direct-fw-loa.patch
@@ -0,0 +1,55 @@
+From ed65d402d64c102d14ed02863ecec029b5ba955f Mon Sep 17 00:00:00 2001
+From: Huang Rui <ray.huang@amd.com>
+Date: Sun, 8 Apr 2018 14:39:18 +0800
+Subject: [PATCH 4175/5725] drm/amdgpu: fix null pointer panic with direct fw
+ loading on gpu reset
+
+When system uses fw direct loading, then psp context structure won't be
+initiliazed. And it is also unable to execute mode reset.
+
+[ 434.601474] amdgpu 0000:0c:00.0: GPU reset begin!
+[ 434.694326] amdgpu 0000:0c:00.0: GPU reset
+[ 434.743152] BUG: unable to handle kernel NULL pointer dereference at
+0000000000000058
+[ 434.838474] IP: psp_gpu_reset+0xc/0x30 [amdgpu]
+[ 434.893532] PGD 406ed9067
+[ 434.893533] P4D 406ed9067
+[ 434.926376] PUD 400b46067
+[ 434.959217] PMD 0
+[ 435.033379] Oops: 0000 [#1] SMP
+[ 435.072573] Modules linked in: amdgpu(OE) chash(OE) gpu_sched(OE) ttm(OE)
+drm_kms_helper(OE) drm(OE) fb_sys_fops syscopyarea sysfillrect sysimgblt
+rpcsec_gss_krb5 auth_rpcgss nfsv4 nfs lockd grace fscache snd_hda_codec_realtek
+snd_hda_codec_generic snd_hda_codec_hdmi snd_hda_intel snd_hda_codec
+snd_hda_core snd_hwdep snd_pcm edac_mce_amd snd_seq_midi snd_seq_midi_event
+kvm_amd snd_rawmidi kvm irqbypass crct10dif_pclmul crc32_pclmul snd_seq
+ghash_clmulni_intel snd_seq_device pcbc snd_timer eeepc_wmi aesni_intel snd
+asus_wmi aes_x86_64 sparse_keymap crypto_simd glue_helper joydev soundcore
+wmi_bmof cryptd video i2c_piix4 shpchp 8250_dw i2c_designware_platform mac_hid
+i2c_designware_core sunrpc parport_pc ppdev lp parport autofs4 hid_generic igb
+usbhid dca ptp mxm_wmi pps_core ahci hid i2c_algo_bit
+[ 435.931754] libahci wmi
+
+Signed-off-by: Huang Rui <ray.huang@amd.com>
+Reviewed-by: Evan Quan <evan.quan@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c
+index 5992024..4ce246c 100644
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c
++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c
+@@ -509,6 +509,9 @@ static int psp_resume(void *handle)
+
+ int psp_gpu_reset(struct amdgpu_device *adev)
+ {
++ if (adev->firmware.load_type != AMDGPU_FW_LOAD_PSP)
++ return 0;
++
+ return psp_mode1_reset(&adev->psp);
+ }
+
+--
+2.7.4
+