Report the failure of WDIOC_SETOPTIONS/WDIOC_SETTIMEOUT ioctls. Signed-off-by: Eugeniu Rosca <erosca@xxxxxxxxxxxxxx> --- tools/testing/selftests/watchdog/watchdog-test.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tools/testing/selftests/watchdog/watchdog-test.c b/tools/testing/selftests/watchdog/watchdog-test.c index 5cfa88c73095..c1c9a3bb9ec7 100644 --- a/tools/testing/selftests/watchdog/watchdog-test.c +++ b/tools/testing/selftests/watchdog/watchdog-test.c @@ -94,12 +94,16 @@ int main(int argc, char *argv[]) ret = ioctl(fd, WDIOC_SETOPTIONS, &flags); if (!ret) printf("Watchdog card disabled.\n"); + else + printf("Failed to disable watchdog card.\n"); break; case 'e': flags = WDIOS_ENABLECARD; ret = ioctl(fd, WDIOC_SETOPTIONS, &flags); if (!ret) printf("Watchdog card enabled.\n"); + else + printf("Failed to enable watchdog card.\n"); break; case 'p': ping_rate = strtoul(optarg, NULL, 0); @@ -110,6 +114,8 @@ int main(int argc, char *argv[]) ret = ioctl(fd, WDIOC_SETTIMEOUT, &flags); if (!ret) printf("Watchdog timeout set to %u seconds.\n", flags); + else + printf("Failed to set timeout to %u seconds.\n", flags); break; default: usage(argv[0]); -- 2.13.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kselftest" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html