From: Rob Herring <robh@kernel.org>
To: Bharat Bhushan <bbhushan2@marvell.com>
Cc: wim@linux-watchdog.org, linux@roeck-us.net,
krzysztof.kozlowski+dt@linaro.org,
linux-watchdog@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] Watchdog: Add octeontx2 GTI watchdog driver
Date: Tue, 18 Apr 2023 16:05:47 -0500 [thread overview]
Message-ID: <20230418210547.GA2322152-robh@kernel.org> (raw)
In-Reply-To: <20230414102342.23696-2-bbhushan2@marvell.com>
On Fri, Apr 14, 2023 at 03:53:42PM +0530, Bharat Bhushan wrote:
> GTI watchdog timer are programmed in "interrupt + del3t + reset mode"
> and del3t traps are not enabled.
> GTI watchdog exception flow is:
> - 1st timer expiration generates watchdog interrupt.
> - 2nd timer expiration is ignored
> - On 3rd timer expiration will trigger a system-wide core reset.
>
> Signed-off-by: Bharat Bhushan <bbhushan2@marvell.com>
> ---
> drivers/watchdog/Kconfig | 9 ++
> drivers/watchdog/Makefile | 1 +
> drivers/watchdog/octeontx2_wdt.c | 238 +++++++++++++++++++++++++++++++
> 3 files changed, 248 insertions(+)
> create mode 100644 drivers/watchdog/octeontx2_wdt.c
>
> diff --git a/drivers/watchdog/Kconfig b/drivers/watchdog/Kconfig
> index f0872970daf9..31ff282c62ad 100644
> --- a/drivers/watchdog/Kconfig
> +++ b/drivers/watchdog/Kconfig
> @@ -2212,4 +2212,13 @@ config KEEMBAY_WATCHDOG
> To compile this driver as a module, choose M here: the
> module will be called keembay_wdt.
>
> +config OCTEONTX2_WATCHDOG
> + tristate "OCTEONTX2 Watchdog driver"
> + depends on ARCH_THUNDER || (COMPILE_TEST && 64BIT)
> + help
> + OCTEONTX2 GTI hardware supports watchdog timer. This watchdog timer are
> + programmed in "interrupt + del3t + reset" mode. On first expiry it will
> + generate interrupt. Second expiry (del3t) is ignored and system will reset
> + on final timer expiry.
> +
> endif # WATCHDOG
> diff --git a/drivers/watchdog/Makefile b/drivers/watchdog/Makefile
> index 9cbf6580f16c..aa1b813ad1f9 100644
> --- a/drivers/watchdog/Makefile
> +++ b/drivers/watchdog/Makefile
> @@ -230,3 +230,4 @@ obj-$(CONFIG_MENZ069_WATCHDOG) += menz69_wdt.o
> obj-$(CONFIG_RAVE_SP_WATCHDOG) += rave-sp-wdt.o
> obj-$(CONFIG_STPMIC1_WATCHDOG) += stpmic1_wdt.o
> obj-$(CONFIG_SL28CPLD_WATCHDOG) += sl28cpld_wdt.o
> +obj-$(CONFIG_OCTEONTX2_WATCHDOG) += octeontx2_wdt.o
> diff --git a/drivers/watchdog/octeontx2_wdt.c b/drivers/watchdog/octeontx2_wdt.c
> new file mode 100644
> index 000000000000..7b78a092e83f
> --- /dev/null
> +++ b/drivers/watchdog/octeontx2_wdt.c
> @@ -0,0 +1,238 @@
> +// SPDX-License-Identifier: GPL-2.0
> +/* Marvell Octeontx2 Watchdog driver
> + *
> + * Copyright (C) 2023 Marvell International Ltd.
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 2 as
> + * published by the Free Software Foundation.
> + */
> +
> +#include <linux/module.h>
> +#include <linux/cpu.h>
> +#include <linux/interrupt.h>
> +#include <linux/of_platform.h>
It's doubtful you need anything from of_platform.h other than implicit
includes. Use the header(s) you need directly.
Rob
next prev parent reply other threads:[~2023-04-18 21:05 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-14 10:23 [PATCH 1/2] dt-bindings: watchdog: marvell octeonTX2 GTI system atchdog driver Bharat Bhushan
2023-04-14 10:23 ` [PATCH 2/2] Watchdog: Add octeontx2 GTI watchdog driver Bharat Bhushan
2023-04-14 11:27 ` Krzysztof Kozlowski
2023-04-14 11:44 ` [EXT] " Bharat Bhushan
2023-04-14 12:28 ` Krzysztof Kozlowski
2023-04-14 14:34 ` Guenter Roeck
2023-04-17 11:06 ` [EXT] " Bharat Bhushan
2023-04-17 14:10 ` Guenter Roeck
2023-04-15 3:59 ` kernel test robot
2023-04-18 21:05 ` Rob Herring [this message]
2023-04-14 11:21 ` [PATCH 1/2] dt-bindings: watchdog: marvell octeonTX2 GTI system atchdog driver Krzysztof Kozlowski
2023-04-14 11:29 ` [EXT] " Bharat Bhushan
2023-04-14 11:31 ` Krzysztof Kozlowski
2023-04-14 11:34 ` Bharat Bhushan
2023-04-14 14:35 ` 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=20230418210547.GA2322152-robh@kernel.org \
--to=robh@kernel.org \
--cc=bbhushan2@marvell.com \
--cc=devicetree@vger.kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=linux@roeck-us.net \
--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).