<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/Documentation/watchdog, branch v3.10.78</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>watchdog: core: dt: add support for the timeout-sec dt property</title>
<updated>2013-03-01T11:48:36+00:00</updated>
<author>
<name>Fabio Porcedda</name>
<email>fabio.porcedda@gmail.com</email>
</author>
<published>2013-01-08T10:04:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3048253ed957fc6cdc34599178408559aa1e0062'/>
<id>3048253ed957fc6cdc34599178408559aa1e0062</id>
<content type='text'>
Add support for watchdog drivers to initialize/set the timeout field
of the watchdog_device structure. The timeout field is initialised
either with the module timeout parameter value (if valid) or with the
timeout-sec dt property (if valid). If both are invalid the initial
value is unchanged.

Signed-off-by: Fabio Porcedda &lt;fabio.porcedda@gmail.com&gt;
Acked-by: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add support for watchdog drivers to initialize/set the timeout field
of the watchdog_device structure. The timeout field is initialised
either with the module timeout parameter value (if valid) or with the
timeout-sec dt property (if valid). If both are invalid the initial
value is unchanged.

Signed-off-by: Fabio Porcedda &lt;fabio.porcedda@gmail.com&gt;
Acked-by: Nicolas Ferre &lt;nicolas.ferre@atmel.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>watchdog: fix watchdog-test.c build warning</title>
<updated>2012-08-29T15:12:58+00:00</updated>
<author>
<name>Randy Dunlap</name>
<email>rdunlap@xenotime.net</email>
</author>
<published>2012-07-23T17:46:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=4b1c2f41c2dda158bb7a3dded70775a76b581995'/>
<id>4b1c2f41c2dda158bb7a3dded70775a76b581995</id>
<content type='text'>
Fix compiler warning by making the function static:

Documentation/watchdog/src/watchdog-test.c:34:6: warning: no previous prototype for 'term'

Signed-off-by: Randy Dunlap &lt;rdunlap@xenotime.net&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix compiler warning by making the function static:

Documentation/watchdog/src/watchdog-test.c:34:6: warning: no previous prototype for 'term'

Signed-off-by: Randy Dunlap &lt;rdunlap@xenotime.net&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Watchdog: DA9052/53 PMIC watchdog support</title>
<updated>2012-05-30T05:56:12+00:00</updated>
<author>
<name>Ashish Jangam</name>
<email>ashish.jangam@kpitcummins.com</email>
</author>
<published>2012-05-24T13:01:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=664a0d7862a6b10c709d4b4a3655fe2c59a20064'/>
<id>664a0d7862a6b10c709d4b4a3655fe2c59a20064</id>
<content type='text'>
This driver adds support for the watchdog functionality provided by
the Dialog Semiconductor DA9052 PMIC chip.

Tested on samsung smdkv6410 and i.mx53 QS boards.

Signed-off-by: Anthony Olech &lt;Anthony.Olech@diasemi.com&gt;
Signed-off-by: Ashish Jangam &lt;ashish.jangam@kpitcummins.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This driver adds support for the watchdog functionality provided by
the Dialog Semiconductor DA9052 PMIC chip.

Tested on samsung smdkv6410 and i.mx53 QS boards.

Signed-off-by: Anthony Olech &lt;Anthony.Olech@diasemi.com&gt;
Signed-off-by: Ashish Jangam &lt;ashish.jangam@kpitcummins.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>watchdog: Add support for dynamically allocated watchdog_device structs</title>
<updated>2012-05-30T05:55:31+00:00</updated>
<author>
<name>Hans de Goede</name>
<email>hdegoede@redhat.com</email>
</author>
<published>2012-05-22T09:40:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e907df32725204d6d2cb79b872529911c8eadcdf'/>
<id>e907df32725204d6d2cb79b872529911c8eadcdf</id>
<content type='text'>
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: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>watchdog: Add Locking support</title>
<updated>2012-05-30T05:55:23+00:00</updated>
<author>
<name>Hans de Goede</name>
<email>hdegoede@redhat.com</email>
</author>
<published>2012-05-22T09:40:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f4e9c82f64b524314a390b13d3ba7d483f09258f'/>
<id>f4e9c82f64b524314a390b13d3ba7d483f09258f</id>
<content type='text'>
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: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>watchdog: create all the proper device files</title>
<updated>2012-05-30T05:54:46+00:00</updated>
<author>
<name>Alan Cox</name>
<email>alan@linux.intel.com</email>
</author>
<published>2012-05-11T10:00:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d6b469d915ae348b3bb8b25034063d6870ff4a00'/>
<id>d6b469d915ae348b3bb8b25034063d6870ff4a00</id>
<content type='text'>
Create the watchdog class and it's associated devices.

Signed-off-by: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Create the watchdog class and it's associated devices.

Signed-off-by: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>watchdog: Add multiple device support</title>
<updated>2012-05-30T05:54:25+00:00</updated>
<author>
<name>Alan Cox</name>
<email>alan@linux.intel.com</email>
</author>
<published>2012-05-10T19:48:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=45f5fed30a6460ec58f159ff297a2974153a97de'/>
<id>45f5fed30a6460ec58f159ff297a2974153a97de</id>
<content type='text'>
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: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Tomas Winkler &lt;tomas.winkler@intel.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Documentation/watchdog: Fix the file descriptor leak when no cmdline arg given</title>
<updated>2012-05-23T14:27:48+00:00</updated>
<author>
<name>Devendra Naga</name>
<email>devendra.aaru@gmail.com</email>
</author>
<published>2012-05-17T09:37:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=cad19fa66469d2a745fae0c168833d5d33d64489'/>
<id>cad19fa66469d2a745fae0c168833d5d33d64489</id>
<content type='text'>
we start a infinite loop when user gives ./watchdog-test, and when user
ctrl + c's the program, we just exit immeadiately with out closing the
filedescriptor of the watchdog device. a signal handler is used to
do the job of closing the filedescriptor and exiting the program.

Signed-off-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
we start a infinite loop when user gives ./watchdog-test, and when user
ctrl + c's the program, we just exit immeadiately with out closing the
filedescriptor of the watchdog device. a signal handler is used to
do the job of closing the filedescriptor and exiting the program.

Signed-off-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Documentation/watchdog: close the fd when cmdline arg given</title>
<updated>2012-05-23T14:27:40+00:00</updated>
<author>
<name>Devendra Naga</name>
<email>devendra.aaru@gmail.com</email>
</author>
<published>2012-05-14T18:12:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3c2a6186c1a69d647e3a48ad3f7f9078c451111e'/>
<id>3c2a6186c1a69d647e3a48ad3f7f9078c451111e</id>
<content type='text'>
in the watchdog test code, the ioctl is performed on the watchdog device
and just doing exit(0) so we leak a filedescripor.

Signed-off-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
in the watchdog test code, the ioctl is performed on the watchdog device
and just doing exit(0) so we leak a filedescripor.

Signed-off-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Documentation/watchdog: Fix a small typo</title>
<updated>2012-05-23T14:27:00+00:00</updated>
<author>
<name>Devendra Naga</name>
<email>devendra.aaru@gmail.com</email>
</author>
<published>2012-05-14T09:03:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=2deca7365582b7568dbdd2c3d9eef7ac17d41fd6'/>
<id>2deca7365582b7568dbdd2c3d9eef7ac17d41fd6</id>
<content type='text'>
Signed-off-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Signed-off-by: Wim Van Sebroeck &lt;wim@iguana.be&gt;
</pre>
</div>
</content>
</entry>
</feed>
