Hi everyone.
I was using DVRRDK_04.00.00.03 with custom dm8168 board.
I ported saWatchdog.c to my app,just like
wdt_fd=open("/dev/watchdog",O_WRONLY);
data = WATCH_DOG_TIMER_TIME;
ioctl (wdt_fd, WDIOC_SETTIMEOUT, &data);
write(wdt_fd, "\0", 1);
I setted the watchdog timeout to 6 sec,my write call was 4 sec,and if my write call > 6 sec,it would reboot the system,indecating that the watchdog funtion work.
But when the app meet some error like a segmentation fault,the whole app process quit,and the login prompt was show,it indecated that the kernel and the filesystem are OK.but the machine didn't reboot,why??? Is it because when segmentation fault kernel will close all the opened fds(like wdt_fd)???