Skip to content

Commit

Permalink
HSI: omap_ssi: fix removal of port platform device
Browse files Browse the repository at this point in the history
This avoids removal of the HSI port device when
only the platform port device should be removed
and clears the POPULATED bit in the DT node, so
that a new platform device is created when the
driver is probed again.

Acked-by: Pavel Machek <[email protected]>
Signed-off-by: Sebastian Reichel <[email protected]>
  • Loading branch information
sre committed May 2, 2016
1 parent 0845e1f commit 2a57aba
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/hsi/controllers/omap_ssi.c
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,10 @@ static int ssi_remove_ports(struct device *dev, void *c)
{
struct platform_device *pdev = to_platform_device(dev);

if (!dev->of_node)
return 0;

of_node_clear_flag(dev->of_node, OF_POPULATED);
of_device_unregister(pdev);

return 0;
Expand Down

0 comments on commit 2a57aba

Please sign in to comment.