Skip to content
Commit 8f9577ed authored by George G. Davis's avatar George G. Davis Committed by Shuah Khan
Browse files

selftests: watchdog: Validate optional file argument



The newly added optional file argument does not validate if the
file is indeed a watchdog, e.g.:

./watchdog-test  -f /dev/zero
Watchdog Ticking Away!

Fix it by confirming that the WDIOC_GETSUPPORT ioctl succeeds.

Fixes: a4864a33 ("selftests: watchdog: Add optional file argument")
Reported-by: default avatarEugeniu Rosca <erosca@de.adit-jv.com>
Signed-off-by: default avatarGeorge G. Davis <george_davis@mentor.com>
Signed-off-by: default avatarEugeniu Rosca <erosca@de.adit-jv.com>
Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
parent 852c8cbf
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment