[SOLVED] watchdog for raspberry pi?

Ask questions about Arch Linux ARM. Please search before making a new topic.

[SOLVED] watchdog for raspberry pi?

Postby iMike » Thu Feb 14, 2019 8:39 pm

I was following the instructions at https://archlinuxarm.org/wiki/Raspberry_Pi for using the watchdog. However, I don't get how to "enable bcm2708_wdog" as mentioned on that page. Here is what I tried:
$this->bbcode_second_pass_code('', '
[root@piameter ~]# modprobe -c | grep bcm2708
blacklist i2c_bcm2708'
options bcm2708_fb fbwidth=656
options bcm2708_fb fbheight=416
options bcm2708_fb fbswap=1
alias of:N*T*Cbrcm,bcm2708_i2c i2c_bcm2708
alias of:N*T*Cbrcm,bcm2708_i2cC* i2c_bcm2708
alias platform:bcm2708_i2c i2c_bcm2708

[root@piameter ~]# ls /usr/lib/modules/4.14.98-1-ARCH/kernel/*/
[root@piameter ~]# ls /usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/watchdog/
gpio_wdt.ko.gz

[root@piameter ~]# modprobe -c | grep dog
alias symbol:ar9003_hw_bb_watchdog_check ath9k_hw
alias symbol:ar9003_hw_bb_watchdog_dbg_info ath9k_hw
alias symbol:rt2x00usb_watchdog rt2x00usb
alias symbol:rtl92c_dm_watchdog rtl8192c_common

[root@piameter ~]# for i in ath9k_hw ath9k_hw rt2x00usb rtl8192c_common; do modinfo $i; done
<results did not show what I guess is the watchdog being referred to in the instructions. I'm not sure how to use the gpio_wdt.ko.gz file if it is the right one.

Perhaps this doesn't exist for ARMv6 or ARMv7? Or, where should I get it?
Thanks!



')
Last edited by iMike on Sun Feb 17, 2019 5:18 pm, edited 1 time in total.
iMike
 
Posts: 10
Joined: Mon Jul 13, 2015 7:55 pm

Re: watchdog for raspberry pi?

Postby iMike » Sat Feb 16, 2019 9:59 pm

I found a bit more info, but still have a question about this one. I noticed in dmesg:
$this->bbcode_second_pass_code('', '
[ 4.704563] bcm2835-wdt 3f100000.watchdog: Broadcom BCM2835 watchdog timer
')
So it sort of appears there is some watchdog going. However, modinfo gives me only that:
$this->bbcode_second_pass_code('', '
modinfo: ERROR: Module bcm2835_wdt not found.
')
Should I conclude it's built into the kernel?
(I guess I could download the kernel config somewhere and take a look! Anyway, perhaps that bit of the user doc
https://archlinuxarm.org/platforms/armv7/broadcom/raspberry-pi-2
should be changed?)
iMike
 
Posts: 10
Joined: Mon Jul 13, 2015 7:55 pm

Re: watchdog for raspberry pi?

Postby graysky » Sat Feb 16, 2019 10:18 pm

You can simple zgrep from /proc/config.gz ... no need to download anything. You can also look for the modules like `find /usr/lib/modules -type f -name 'bcm2835*'`
graysky
Developer
 
Posts: 1876
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000

Re: watchdog for raspberry pi?

Postby iMike » Sun Feb 17, 2019 5:18 pm

Thanks @graysky! Good point. From the config I get:
$this->bbcode_second_pass_code('', '
[mike@picasso ~]$ zgrep -i dog /proc/config.gz
CONFIG_WATCHDOG=y
CONFIG_WATCHDOG_CORE=y
# CONFIG_WATCHDOG_NOWAYOUT is not set
CONFIG_WATCHDOG_HANDLE_BOOT_ENABLED=y
# CONFIG_WATCHDOG_SYSFS is not set
# Watchdog Device Drivers
# CONFIG_SOFT_WATCHDOG is not set
CONFIG_GPIO_WATCHDOG=m
# CONFIG_XILINX_WATCHDOG is not set
# CONFIG_ZIIRAVE_WATCHDOG is not set
# CONFIG_ARM_SP805_WATCHDOG is not set
# CONFIG_CADENCE_WATCHDOG is not set
# CONFIG_DW_WATCHDOG is not set
# CONFIG_MAX63XX_WATCHDOG is not set
# USB-based Watchdog Cards
# CONFIG_USBPCWATCHDOG is not set
# Watchdog Pretimeout Governors
# CONFIG_WATCHDOG_PRETIMEOUT_GOV is not set
# CONFIG_WQ_WATCHDOG is not set
')
So the next stop is kernel.org for the documentation on what these mean exactly (or actually download and make menuconfig).
However, it's clear some watchdog is built in (y) and some not (m). The find you suggested gives me:
$this->bbcode_second_pass_code('', '
[mike@picasso ~]$ sudo find /usr/lib/modules -type f -name 'bcm2835*'
/usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/misc/bcm2835_smi.ko.gz
/usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/mtd/nand/bcm2835_smi_nand.ko.gz
/usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko.gz
/usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/media/platform/bcm2835/bcm2835-unicam.ko.gz
/usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/char/broadcom/bcm2835_smi_dev.ko.gz
/usr/lib/modules/4.14.98-1-ARCH/kernel/drivers/char/hw_random/bcm2835-rng.ko.gz
')
And doing something similar with "bcm2708*" and "*wdog*" would suggest that page of instructions mentioned in the original posting is just out-of-date. Checking for "*wdt*" does find the GPIO module that one sees in the config. Thank you!
iMike
 
Posts: 10
Joined: Mon Jul 13, 2015 7:55 pm


Return to User Questions

Who is online

Users browsing this forum: No registered users and 17 guests