Skip to content

Commit

Permalink
can: flexcan: add support for DT property 'wakeup-source'
Browse files Browse the repository at this point in the history
The flexcan controller can be forced as a wakeup source by
stating that explicitly in the device's .dts file using the
"wakeup-source" boolean property.

Signed-off-by: Sean Nyekjaer <[email protected]>
Signed-off-by: Marc Kleine-Budde <[email protected]>
  • Loading branch information
sknsean authored and marckleinebudde committed Jul 24, 2019
1 parent 10e0c52 commit 915f966
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/net/can/flexcan.c
Original file line number Diff line number Diff line change
Expand Up @@ -1473,6 +1473,9 @@ static int flexcan_setup_stop_mode(struct platform_device *pdev)

device_set_wakeup_capable(&pdev->dev, true);

if (of_property_read_bool(np, "wakeup-source"))
device_set_wakeup_enable(&pdev->dev, true);

return 0;
}

Expand Down

0 comments on commit 915f966

Please sign in to comment.