Skip to content

Commit

Permalink
spi: pxa2xx: drv_data can't be NULL in ->remove()
Browse files Browse the repository at this point in the history
There is no need for drv_data check against NULL, since it won't happen.
Remove useless check.

Signed-off-by: Andy Shevchenko <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
  • Loading branch information
andy-shev authored and broonie committed Feb 24, 2020
1 parent 14af1df commit 3d24b2a
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions drivers/spi/spi-pxa2xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -1884,11 +1884,7 @@ static int pxa2xx_spi_probe(struct platform_device *pdev)
static int pxa2xx_spi_remove(struct platform_device *pdev)
{
struct driver_data *drv_data = platform_get_drvdata(pdev);
struct ssp_device *ssp;

if (!drv_data)
return 0;
ssp = drv_data->ssp;
struct ssp_device *ssp = drv_data->ssp;

pm_runtime_get_sync(&pdev->dev);

Expand Down

0 comments on commit 3d24b2a

Please sign in to comment.