mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
spi: ti-qspi: improve ->remove() callback
there's no need to call pm_runtime_get_sync() followed by pm_runtime_put(). We should, instead, just call pm_runtime_put_sync() and pm_runtime_disable(). Signed-off-by: Felipe Balbi <[email protected]> Signed-off-by: Mark Brown <[email protected]>
This commit is contained in:
parent
57c2ecd9bf
commit
e6b5140b70
1 changed files with 1 additions and 10 deletions
|
|
@ -555,16 +555,7 @@ free_master:
|
|||
|
||||
static int ti_qspi_remove(struct platform_device *pdev)
|
||||
{
|
||||
struct ti_qspi *qspi = platform_get_drvdata(pdev);
|
||||
int ret;
|
||||
|
||||
ret = pm_runtime_get_sync(qspi->dev);
|
||||
if (ret < 0) {
|
||||
dev_err(qspi->dev, "pm_runtime_get_sync() failed\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
pm_runtime_put(qspi->dev);
|
||||
pm_runtime_put_sync(&pdev->dev);
|
||||
pm_runtime_disable(&pdev->dev);
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue