提交 fbb9c3c9 编写于 作者: M Marek Szyprowski 提交者: MyungJoo Ham

PM / devfreq: exynos-bus: Suspend all devices on system shutdown

Force all Exynos buses to safe operation points before doing the system
reboot operation. There are board on which some aggressive power saving
operation points are behind the capabilities of the bootloader to properly
reset the hardware and boot the board. This way one can avoid board crash
early after reboot.

This fixes reboot issue on OdroidU3 board both with eMMC and SD boot.
Reported-by: NMarkus Reichl <m.reichl@fivetechno.de>
Signed-off-by: NMarek Szyprowski <m.szyprowski@samsung.com>
Acked-by: NChanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: NMyungJoo Ham <myungjoo.ham@samsung.com>
上级 b53b0128
...@@ -514,6 +514,13 @@ static int exynos_bus_probe(struct platform_device *pdev) ...@@ -514,6 +514,13 @@ static int exynos_bus_probe(struct platform_device *pdev)
return ret; return ret;
} }
static void exynos_bus_shutdown(struct platform_device *pdev)
{
struct exynos_bus *bus = dev_get_drvdata(&pdev->dev);
devfreq_suspend_device(bus->devfreq);
}
#ifdef CONFIG_PM_SLEEP #ifdef CONFIG_PM_SLEEP
static int exynos_bus_resume(struct device *dev) static int exynos_bus_resume(struct device *dev)
{ {
...@@ -556,6 +563,7 @@ MODULE_DEVICE_TABLE(of, exynos_bus_of_match); ...@@ -556,6 +563,7 @@ MODULE_DEVICE_TABLE(of, exynos_bus_of_match);
static struct platform_driver exynos_bus_platdrv = { static struct platform_driver exynos_bus_platdrv = {
.probe = exynos_bus_probe, .probe = exynos_bus_probe,
.shutdown = exynos_bus_shutdown,
.driver = { .driver = {
.name = "exynos-bus", .name = "exynos-bus",
.pm = &exynos_bus_pm, .pm = &exynos_bus_pm,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册