Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Guenter Roeck
On 12/22/2015 02:05 PM, Tomas Winkler wrote: > Do you see a situation where holding the lock between calls into the driver > might be a problem ? I don't think u are holding the lock now in watchdog_unregister when WDOG_UNREGISTERED was dropped. the lock is held while clearing the

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Guenter Roeck
On 12/22/2015 11:28 AM, Damien Riegel wrote: On Tue, Dec 22, 2015 at 08:22:40AM -0800, Guenter Roeck wrote: On 12/22/2015 08:09 AM, Damien Riegel wrote: On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: On 12/21/2015 09:28 AM, Damien Riegel wrote: On Sun, Dec 20, 2015 at

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Damien Riegel
On Tue, Dec 22, 2015 at 08:22:40AM -0800, Guenter Roeck wrote: > On 12/22/2015 08:09 AM, Damien Riegel wrote: > >On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: > >>On 12/21/2015 09:28 AM, Damien Riegel wrote: > >>>On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: >

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Guenter Roeck
On 12/22/2015 08:09 AM, Damien Riegel wrote: On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: On 12/21/2015 09:28 AM, Damien Riegel wrote: On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: All variables required by the watchdog core to manage a watchdog are

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Damien Riegel
On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: > On 12/21/2015 09:28 AM, Damien Riegel wrote: > >On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: > >>All variables required by the watchdog core to manage a watchdog are > >>currently stored in struct watchdog_device.

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Damien Riegel
On Tue, Dec 22, 2015 at 08:22:40AM -0800, Guenter Roeck wrote: > On 12/22/2015 08:09 AM, Damien Riegel wrote: > >On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: > >>On 12/21/2015 09:28 AM, Damien Riegel wrote: > >>>On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: >

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Guenter Roeck
On 12/22/2015 02:05 PM, Tomas Winkler wrote: > Do you see a situation where holding the lock between calls into the driver > might be a problem ? I don't think u are holding the lock now in watchdog_unregister when WDOG_UNREGISTERED was dropped. the lock is held while clearing the

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Damien Riegel
On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: > On 12/21/2015 09:28 AM, Damien Riegel wrote: > >On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: > >>All variables required by the watchdog core to manage a watchdog are > >>currently stored in struct watchdog_device.

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Guenter Roeck
On 12/22/2015 08:09 AM, Damien Riegel wrote: On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: On 12/21/2015 09:28 AM, Damien Riegel wrote: On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: All variables required by the watchdog core to manage a watchdog are

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-22 Thread Guenter Roeck
On 12/22/2015 11:28 AM, Damien Riegel wrote: On Tue, Dec 22, 2015 at 08:22:40AM -0800, Guenter Roeck wrote: On 12/22/2015 08:09 AM, Damien Riegel wrote: On Mon, Dec 21, 2015 at 05:10:58PM -0800, Guenter Roeck wrote: On 12/21/2015 09:28 AM, Damien Riegel wrote: On Sun, Dec 20, 2015 at

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Guenter Roeck
On 12/21/2015 03:36 PM, Tomas Winkler wrote: On Mon, Dec 21, 2015 at 7:28 PM, Damien Riegel wrote: On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: All variables required by the watchdog core to manage a watchdog are currently stored in struct watchdog_device. The lifetime of

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Guenter Roeck
On 12/21/2015 09:28 AM, Damien Riegel wrote: On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: All variables required by the watchdog core to manage a watchdog are currently stored in struct watchdog_device. The lifetime of those variables is determined by the watchdog driver.

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Tomas Winkler
On Mon, Dec 21, 2015 at 7:28 PM, Damien Riegel wrote: > > On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: > > All variables required by the watchdog core to manage a watchdog are > > currently stored in struct watchdog_device. The lifetime of those > > variables is determined by

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Damien Riegel
On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: > All variables required by the watchdog core to manage a watchdog are > currently stored in struct watchdog_device. The lifetime of those > variables is determined by the watchdog driver. However, the lifetime > of variables used by

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Tomas Winkler
On Mon, Dec 21, 2015 at 7:28 PM, Damien Riegel wrote: > > On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: > > All variables required by the watchdog core to manage a watchdog are > > currently stored in struct watchdog_device. The lifetime of

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Guenter Roeck
On 12/21/2015 09:28 AM, Damien Riegel wrote: On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: All variables required by the watchdog core to manage a watchdog are currently stored in struct watchdog_device. The lifetime of those variables is determined by the watchdog driver.

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Guenter Roeck
On 12/21/2015 03:36 PM, Tomas Winkler wrote: On Mon, Dec 21, 2015 at 7:28 PM, Damien Riegel wrote: On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: All variables required by the watchdog core to manage a watchdog are currently stored in

Re: [PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-21 Thread Damien Riegel
On Sun, Dec 20, 2015 at 01:05:00PM -0800, Guenter Roeck wrote: > All variables required by the watchdog core to manage a watchdog are > currently stored in struct watchdog_device. The lifetime of those > variables is determined by the watchdog driver. However, the lifetime > of variables used by

[PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-20 Thread Guenter Roeck
All variables required by the watchdog core to manage a watchdog are currently stored in struct watchdog_device. The lifetime of those variables is determined by the watchdog driver. However, the lifetime of variables used by the watchdog core differs from the lifetime of struct watchdog_device.

[PATCH 2/5] watchdog: Separate and maintain variables based on variable lifetime

2015-12-20 Thread Guenter Roeck
All variables required by the watchdog core to manage a watchdog are currently stored in struct watchdog_device. The lifetime of those variables is determined by the watchdog driver. However, the lifetime of variables used by the watchdog core differs from the lifetime of struct watchdog_device.