mirror of
https://github.com/torvalds/linux.git
synced 2026-06-06 21:45:45 +02:00
drm/radeon: Call radeon_suspend_kms() in radeon_pci_shutdown() for Loongson64
commit c1bfd74bfe upstream.
On the Loongson64 platform used with Radeon GPU, shutdown or reboot failed
when console=tty is in the boot cmdline.
radeon_suspend_kms() puts the hw in the suspend state, especially set fb
state as FBINFO_STATE_SUSPENDED:
if (fbcon) {
console_lock();
radeon_fbdev_set_suspend(rdev, 1);
console_unlock();
}
Then avoid to do any more fb operations in the related functions:
if (p->state != FBINFO_STATE_RUNNING)
return;
So call radeon_suspend_kms() in radeon_pci_shutdown() for Loongson64 to fix
this issue, it looks like some kind of workaround like powerpc.
Co-developed-by: Jianmin Lv <lvjianmin@loongson.cn>
Signed-off-by: Jianmin Lv <lvjianmin@loongson.cn>
Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
7aa28f2f67
commit
0d50d93d05
|
|
@ -416,13 +416,13 @@ radeon_pci_shutdown(struct pci_dev *pdev)
|
||||||
if (radeon_device_is_virtual())
|
if (radeon_device_is_virtual())
|
||||||
radeon_pci_remove(pdev);
|
radeon_pci_remove(pdev);
|
||||||
|
|
||||||
#ifdef CONFIG_PPC64
|
#if defined(CONFIG_PPC64) || defined(CONFIG_MACH_LOONGSON64)
|
||||||
/*
|
/*
|
||||||
* Some adapters need to be suspended before a
|
* Some adapters need to be suspended before a
|
||||||
* shutdown occurs in order to prevent an error
|
* shutdown occurs in order to prevent an error
|
||||||
* during kexec.
|
* during kexec, shutdown or reboot.
|
||||||
* Make this power specific becauase it breaks
|
* Make this power and Loongson specific because
|
||||||
* some non-power boards.
|
* it breaks some other boards.
|
||||||
*/
|
*/
|
||||||
radeon_suspend_kms(pci_get_drvdata(pdev), true, true, false);
|
radeon_suspend_kms(pci_get_drvdata(pdev), true, true, false);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user