]> git.karo-electronics.de Git - linux-beck.git/commit
greybus: svc: add power mode call for link hibernation
authorDavid Lin <dtwlin@google.com>
Fri, 8 Jul 2016 03:07:00 +0000 (22:07 -0500)
committerAlex Elder <elder@linaro.org>
Fri, 8 Jul 2016 19:56:28 +0000 (14:56 -0500)
commitc7dc28ff2b47d6dc4efd420b6f1325554b6f8287
treeb92820565144cdceed5e08fa209943d4f1fefd26
parentfc8a4027135252b49650a4dbfcf2a8fb434a6e6a
greybus: svc: add power mode call for link hibernation

Due to when using set_power_mode to hibernate a link, it won't trigger a
POWERMODEIND event, hence the hard-coded GB_SVC_SETPWRM_PWR_OK would be
returned and it should also be considered as successful result code for
link hibernation. Therefore, adding this set_power_mode_hibernate
function to separate the two calls in order to check with the correct
result code.

Testing Done:
 - Suspend an Interface and observe no set power mode error.

Signed-off-by: David Lin <dtwlin@google.com>
Reviewed-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Alex Elder <elder@linaro.org>
drivers/staging/greybus/svc.c
drivers/staging/greybus/svc.h