linux-watchdog.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Marek Behún" <kabel@kernel.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Gregory CLEMENT <gregory.clement@bootlin.com>,
	Arnd Bergmann <arnd@arndb.de>,
	soc@kernel.org, Andy Shevchenko <andy@kernel.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	Linus Walleij <linus.walleij@linaro.org>,
	linux-watchdog@vger.kernel.org,
	Wim Van Sebroeck <wim@linux-watchdog.org>,
	arm@kernel.org
Subject: Re: [PATCH v6 05/11] platform: cznic: turris-omnia-mcu: Add support for MCU watchdog
Date: Thu, 18 Apr 2024 16:15:10 +0200	[thread overview]
Message-ID: <20240418161510.5ff0dc46@dellmb> (raw)
In-Reply-To: <b0cce881-f42b-469f-a4db-dcfcf89738f5@roeck-us.net>

On Thu, 18 Apr 2024 06:26:04 -0700
Guenter Roeck <linux@roeck-us.net> wrote:

> On Thu, Apr 18, 2024 at 02:11:10PM +0200, Marek Behún wrote:
> > Add support for the watchdog mechanism provided by the MCU.
> > 
> > Signed-off-by: Marek Behún <kabel@kernel.org>  
> 
> This driver should reside in driver/watchdog and use a generic API
> such as regmap to access chip registers.

Hi Guenter,

I have these points against that:

- the regmap API is not applicable in a sane way to the Turris Omnia
  MCU interface. I was trying to do this 5 years ago. An explanation
  can be found at
    https://www.spinics.net/lists/linux-leds/msg11583.html
  (the LED driver uses same interface as the MCU driver, LED controller
   is implemented by the MCU).

  so were the watchdog driver a separate module, we would either need
  to rape the regmap API to do this, or come up with a new API specific
  for Turris Omnia, which seems like an unnecessary complication just
  for one device

- this watchdog is specific for Turris Omnia, the driver can not be
  reused anywhere else

- there are several other multifunction drivers in kernel registering
  watchdog that do not live in drivers/watchdog/

- leaving it in platform/cznic/turris-omnia-mcu* keeps all these
  turris-omnia-mcu features together and they are all implemented
  by one .ko module

Marek

  reply	other threads:[~2024-04-18 14:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-18 12:11 [PATCH v6 00/11] Turris Omnia MCU driver Marek Behún
2024-04-18 12:11 ` [PATCH v6 02/11] platform: cznic: Add preliminary support for Turris Omnia MCU Marek Behún
2024-04-18 12:11 ` [PATCH v6 05/11] platform: cznic: turris-omnia-mcu: Add support for MCU watchdog Marek Behún
2024-04-18 13:26   ` Guenter Roeck
2024-04-18 14:15     ` Marek Behún [this message]
2024-04-23 16:05 ` [PATCH v6 00/11] Turris Omnia MCU driver Andy Shevchenko

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=20240418161510.5ff0dc46@dellmb \
    --to=kabel@kernel.org \
    --cc=andy@kernel.org \
    --cc=arm@kernel.org \
    --cc=arnd@arndb.de \
    --cc=brgl@bgdev.pl \
    --cc=gregory.clement@bootlin.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-watchdog@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=soc@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).