]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
Revert "drm/amdgpu: TA unload messages are not actually sent to psp when amdgpu is...
authorVitaly Prosyak <vitaly.prosyak@amd.com>
Fri, 20 Jan 2023 18:19:50 +0000 (13:19 -0500)
committerAndrea Righi <andrea.righi@canonical.com>
Tue, 14 Mar 2023 15:47:14 +0000 (16:47 +0100)
commit2b1be58f6c7c8242b4234610fda330623db5432b
tree489ed7e688a7a8dd3c49a56df19d4df024c3d7b9
parent5a12a9ead38329860a2d6d7504d77e0e32bc2fcb
Revert "drm/amdgpu: TA unload messages are not actually sent to psp when amdgpu is uninstalled"

BugLink: https://bugs.launchpad.net/bugs/2011425
[ Upstream commit 39934d3ed5725c5e3570ed1b67f612f1ea60ce03 ]

This reverts commit fac53471d0ea9693d314aa2df08d62b2e7e3a0f8.
The following change: move the drm_dev_unplug call after
amdgpu_driver_unload_kms in amdgpu_pci_remove. The reason is
the following: amdgpu_pci_remove calls drm_dev_unregister
and it should be called first to ensure userspace can't access the
device instance anymore. If we call drm_dev_unplug after
amdgpu_driver_unload_kms then we observe IGT PCI software unplug
test failure (kernel hung) for all ASICs. This is how this
regression was found.

After this revert, the following commands do work not, but it would
be fixed in the next commit:
 - sudo modprobe -r amdgpu
 - sudo modprobe amdgpu

Signed-off-by: Vitaly Prosyak <vitaly.prosyak@amd.com>
Reviewed-by Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c