]> Git Repo - linux.git/commitdiff
memory: tegra30-emc: Fix panic on suspend
authorDmitry Osipenko <[email protected]>
Fri, 15 Nov 2019 16:26:42 +0000 (19:26 +0300)
committerThierry Reding <[email protected]>
Mon, 18 Nov 2019 12:54:40 +0000 (13:54 +0100)
Trying to suspend driver results in a crash if timings aren't available in
device-tree.

Reported-by: Jon Hunter <[email protected]>
Fixes: e34212c75a68 ("memory: tegra: Introduce Tegra30 EMC driver")
Signed-off-by: Dmitry Osipenko <[email protected]>
Acked-by: Jon Hunter <[email protected]>
Tested-by: Jon Hunter <[email protected]>
Signed-off-by: Thierry Reding <[email protected]>
drivers/memory/tegra/tegra30-emc.c

index 6929980bf907ebdfa6cc115ea1760e5069f3c067..0b6a5e451ea36ac682ce59332cf6e10d44815714 100644 (file)
@@ -1093,7 +1093,7 @@ static int tegra_emc_probe(struct platform_device *pdev)
        if (of_get_child_count(pdev->dev.of_node) == 0) {
                dev_info(&pdev->dev,
                         "device-tree node doesn't have memory timings\n");
-               return 0;
+               return -ENODEV;
        }
 
        np = of_parse_phandle(pdev->dev.of_node, "nvidia,memory-controller", 0);
This page took 0.05868 seconds and 4 git commands to generate.