- 30 5月, 2012 6 次提交
-
-
由 Hans de Goede 提交于
If a driver's watchdog_device struct is part of a dynamically allocated struct (which it often will be), merely locking the module is not enough, even with a drivers module locked, the driver can be unbound from the device, examples: 1) The root user can unbind it through sysfd 2) The i2c bus master driver being unloaded for an i2c watchdog I will gladly admit that these are corner cases, but we still need to handle them correctly. The fix for this consists of 2 parts: 1) Add ref / unref operations, so that the driver can refcount the struct holding the watchdog_device struct and delay freeing it until any open filehandles referring to it are closed 2) Most driver operations will do IO on the device and the driver should not do any IO on the device after it has been unbound. Rather then letting each driver deal with this internally, it is better to ensure at the watchdog core level that no operations (other then unref) will get called after the driver has called watchdog_unregister_device(). This actually is the bulk of this patch. Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
由 Hans de Goede 提交于
This patch fixes some potential multithreading issues, despite only allowing one process to open the /dev/watchdog device, we can still get called multiple times at the same time, since a program could be using thread, or could share the fd after a fork. This causes 2 potential problems: 1) watchdog_start / open do an unlocked test_n_set / test_n_clear, if these 2 race, the watchdog could be stopped while the active bit indicates it is running or visa versa. 2) Most watchdog_dev drivers probably assume that only one watchdog-op will get called at a time, this is not necessary true atm. Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
由 Alan Cox 提交于
Create the watchdog class and it's associated devices. Signed-off-by: NAlan Cox <alan@linux.intel.com> Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
由 Alan Cox 提交于
Some watchdogs merely trigger external alarms and controls. In a managed environment this is very useful but we want drivers to be able to figure out which is which now multiple dogs can be loaded. Thus add an ALARMONLY feature flag. Signed-off-by: NAlan Cox <alan@linux.intel.com> Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
由 Alan Cox 提交于
We keep the old /dev/watchdog interface file for the first watchdog via miscdev. This is basically a cut and paste of the relevant interface code from the rtc driver layer tweaked for watchdog. Revised to fix problems noted by Hans de Goede Signed-off-by: NAlan Cox <alan@linux.intel.com> Signed-off-by: NHans de Goede <hdegoede@redhat.com> Signed-off-by: NTomas Winkler <tomas.winkler@intel.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
由 Viresh Kumar 提交于
Some watchdog may need to check if watchdog is ACTIVE or not, for example in their suspend/resume hooks. This patch adds this routine and changes the core drivers to use it. Signed-off-by: NViresh Kumar <viresh.kumar@st.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
- 28 3月, 2012 2 次提交
-
-
由 Viresh Kumar 提交于
This patch adds support for WDIOC_GETTIMELEFT IOCTL in watchdog core. So, there is another function pointer added to struct watchdog_ops, which can be passed by drivers to support this IOCTL. Related documentation is updated too. Signed-off-by: NViresh Kumar <viresh.kumar@st.com> Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
由 Wim Van Sebroeck 提交于
nowayout is actually a boolean value. So make it bool for all watchdog device drivers. Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
- 06 1月, 2012 1 次提交
-
-
由 Wim Van Sebroeck 提交于
Add two nowayout helpers for the Watchdog Timer Driver Kernel API. And apply this to the already converted drivers. Note: s3c2410_wdt lost the nowayout feature during the conversion. Reviewed-by: NWolfram Sang <w.sang@pengutronix.de> Acked-by: NMark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
-
- 28 7月, 2011 8 次提交
-
-
由 Wim Van Sebroeck 提交于
Add min_timeout (minimum timeout) and max_timeout values so that the framework can check if the new timeout value is between the minimum and maximum timeout values. If both values are 0, then the framework will leave the check for the watchdog device driver itself. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
Add support for extra ioctl calls by adding a ioctl watchdog operation. This operation will be called before we do our own handling of ioctl commands. This way we can override the internal ioctl command handling and we can also add extra ioctl commands. The ioctl watchdog operation should return the appropriate error codes or -ENOIOCTLCMD if the ioctl command should be handled through the internal ioctl handling of the framework. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
Add support for the nowayout feature to the WatchDog Timer Driver Core framework. This feature prevents the watchdog timer from being stopped. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
Add support for the Magic Close feature to the WatchDog Timer Driver Core framework. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
This part add's the WDIOC_SETTIMEOUT and WDIOC_GETTIMEOUT ioctl functionality to the WatchDog Timer Driver Core framework. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
This part add's the WDIOC_SETOPTIONS ioctl functionality to the WatchDog Timer Driver Core framework. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
This part add's the basic ioctl functionality to the WatchDog Timer Driver Core framework. The supported ioctl call's are: WDIOC_GETSUPPORT WDIOC_GETSTATUS WDIOC_GETBOOTSTATUS Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Wim Van Sebroeck 提交于
The WatchDog Timer Driver Core is a framework that contains the common code for all watchdog-driver's. It also introduces a watchdog device structure and the operations that go with it. This is the introduction of this framework. This part supports the minimal watchdog userspace API (or with other words: the functionality to use /dev/watchdog's open, release and write functionality as defined in the simplest watchdog API). Extra functionality will follow in the next set of patches. Signed-off-by: NAlan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Acked-by: NArnd Bergmann <arnd@arndb.de> Acked-by: NWolfram Sang <w.sang@pengutronix.de>
-
- 21 6月, 2006 2 次提交
-
-
由 Wim Van Sebroeck 提交于
Some watchdog drivers have the ability to report the remaining time before the system will reboot. With the WDIOC_GETTIMELEFT ioctl you can now read the time left before the watchdog would reboot your system. The following drivers support this new IOCTL: i8xx_tco.c, pcwd_pci.c and pcwd_usb.c . Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Signed-off-by: NAndrew Morton <akpm@osdl.org>
-
由 Corey Minyard 提交于
Some watchdog timers support the concept of a "pretimeout" which occurs some time before the real timeout. The pretimeout can be delivered via an interrupt or NMI and can be used to panic the system when it occurs (so you get useful information instead of a blind reboot). Signed-off-by: NCorey Minyard <minyard@acm.org> Signed-off-by: NWim Van Sebroeck <wim@iguana.be> Signed-off-by: NAndrew Morton <akpm@osdl.org>
-
- 28 7月, 2005 1 次提交
-
-
由 Andrey Panin 提交于
Attached patch removes #ifdef CONFIG_WATCHDOG_NOWAYOUT mess duplicated in almost every watchdog driver and replaces it with common define in linux/watchdog.h. Signed-off-by: NAndrey Panin <pazke@donpac.ru> Signed-off-by: NAndrew Morton <akpm@osdl.org> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
- 17 4月, 2005 1 次提交
-
-
由 Linus Torvalds 提交于
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
-