Re: [PATCH] watchdog: add f71862fg support

From: Giel van Schijndel
Date: Fri Sep 10 2010 - 19:48:58 EST


On Sat, Sep 11, 2010 at 01:24:07 +0200, Lutz Ballaschke wrote:
> On Fri, Sep 10, 2010 at 11:03:01 +0200, Wim Van Sebroeck wrote:
>>> Given that the F71862 has *two* pins assignable to the WDTRST#
>>> signal, please document that fact, and the reason for choosing this
>>> one in the code.
>>>
>>> Perhaps it might even be desirable to insert a printk there. This
>>> to make the user aware of the fact that this driver might not work
>>> if the pin configuration of their hardware doesn't match the
>>> assumption you make about it in this code.
>>
>> I propose to Document it in the code and add a module-parameter so
>> that it is selectable.
>
> I agree. I will post the patch again (missing parts will follow soon).
> I placed printk in watchdog_start(). Since this means printk output
> everytime /dev/watchdog is opened I'm not sure whether i like it there.
> Maybe it fits better in f71808e_find(). But this would require
> additional if / else and stuff.

Can't you fit that printk in the switch(devid) block? That wouldn't
require additional logic. In fact, if you make the selected pin
configurable I wouldn't consider a printk explaining the current
policy/config assumptions necessary because that way there aren't any
policy-related assumptions made in the driver anymore.

--
Met vriendelijke groet,
With kind regards,
Giel van Schijndel
--
"It would seem that perfection is attained not when no more can be
added, but when no more can be removed."
-- Antoine de Saint ExupÃry

Attachment: signature.asc
Description: Digital signature