From: Guenter Roeck <linux@roeck-us.net>
To: Vladimir Panteleev <git@vladimir.panteleev.md>
Cc: Wim Van Sebroeck <wim@linux-watchdog.org>,
linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] watchdog: sp5100_tco: Add "action" module parameter
Date: Mon, 19 Sep 2022 05:29:02 -0700 [thread overview]
Message-ID: <736d150c-03fe-ce39-a42e-b9b62f40a937@roeck-us.net> (raw)
In-Reply-To: <CAHhfkvw_U_uF1UFcLTBUsw=_YoM_7pi3tw3KCovTT6PZTnH0ig@mail.gmail.com>
On 9/18/22 22:58, Vladimir Panteleev wrote:
> On Mon, 19 Sept 2022 at 04:17, Guenter Roeck <linux@roeck-us.net> wrote:
>>
>> On 9/18/22 07:08, Vladimir Panteleev wrote:
>>> +MODULE_PARM_DESC(action, "Action taken when watchdog expires, 0 to reset, 1 to poweroff (default="
>>> + __MODULE_STRING(WATCHDOG_ACTION) ")");
>>> +
>>
>> Other module parameters are not visible. I do not see the benefit of
>> having this one visible.
>
> My bad
>
>>> -#define SP5100_WDT_ACTION_RESET BIT(2)
>>> +#define SP5100_WDT_ACTION BIT(2)
>>
>> I do not see the point of renaming this define.
>
> The bit is just called "action" ("WatchDogAction") in the technical
> documentation. I figure that the original author chose to name the
> define "ACTION_RESET" instead of just "ACTION" because the original
> implementation only ever cleared this bit, therefore only setting the
> action to "reset". Now that this is no longer true, calling it simply
> "action" to match the spec seemed more appropriate. What do you think?
>
I am not getting into define name editing wars. The define is named as
it is. There is never a good reason to rename it. If I'd accept your
change, someone else might come tomorrow and want it renamed to
"SP5100_WDT_ACTION_POWEROFF" because setting the bit to 1 causes
the system to power off.
No, I am not getting into that.
Guenter
next prev parent reply other threads:[~2022-09-19 12:29 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220918140829.443722-1-git@vladimir.panteleev.md>
2022-09-19 4:17 ` [PATCH] watchdog: sp5100_tco: Add "action" module parameter Guenter Roeck
2022-09-19 5:58 ` Vladimir Panteleev
2022-09-19 12:29 ` Guenter Roeck [this message]
2022-09-19 13:18 ` Vladimir Panteleev
2022-09-19 13:27 ` Guenter Roeck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=736d150c-03fe-ce39-a42e-b9b62f40a937@roeck-us.net \
--to=linux@roeck-us.net \
--cc=git@vladimir.panteleev.md \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=wim@linux-watchdog.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.