mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
spi/qspi: Fix runtime resume path
Due to the following commit
commit 160a061301
Author: Wei Yongjun <[email protected]>
Date: Mon Nov 11 14:13:41 2013 +0800
spi/qspi: set correct platform drvdata in ti_qspi_probe()
The ti_qspi_remove() use the platform drvdata as a type of
struct ti_qspi, we should pass correct platform drvdata to
platform_set_drvdata() in ti_qspi_probe().
Signed-off-by: Wei Yongjun <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
platform_set_drvdata was changed in the probe, so we need to
correspondingly change deferencing of qspi in runtime resume
path. Else, this will lead to a NULL dereference pointer.
Based on v3.13-rc3
Signed-off-by: Sourav Poddar <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
This commit is contained in:
parent
374b105797
commit
f17414c4fc
1 changed files with 1 additions and 3 deletions
|
|
@ -417,10 +417,8 @@ out:
|
|||
static int ti_qspi_runtime_resume(struct device *dev)
|
||||
{
|
||||
struct ti_qspi *qspi;
|
||||
struct spi_master *master;
|
||||
|
||||
master = dev_get_drvdata(dev);
|
||||
qspi = spi_master_get_devdata(master);
|
||||
qspi = dev_get_drvdata(dev);
|
||||
ti_qspi_restore_ctx(qspi);
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue