greybus: svc_watchdog: Add sysfs file to change the behavior of bite
authorDavid Lin <dtwlin@google.com>
Tue, 26 Jul 2016 23:27:28 +0000 (16:27 -0700)
committerGreg Kroah-Hartman <gregkh@google.com>
Wed, 27 Jul 2016 03:58:37 +0000 (20:58 -0700)
commit7c4a0edb38ba734bd89efbda4262698a58839c26
treea0c4cfc896bbfc7d4198f71a75047e4279533569
parent6136cce89ca5d344d5183d36e887f0ff46896f1c
greybus: svc_watchdog: Add sysfs file to change the behavior of bite

Currently, AP performs unipro_reset if SVC fails to response to its
ping. While this error recovery is best suited for the end-user
experience, errors in the UniPro network could potentially go unnoticed
by the QA and fishfooders in the development phase of the project. This
patch adds an option to trigger a kernel panic so logs can be collected
for analysis.

Testing Done:
 - Reproduce issue and observe kernel panic when
   watchdob_control is changed to 'panic'

Signed-off-by: David Lin <dtwlin@google.com>
Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/Documentation/sysfs-bus-greybus
drivers/staging/greybus/svc.c
drivers/staging/greybus/svc.h
drivers/staging/greybus/svc_watchdog.c