Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Pinkesh Vaghela" <pinkesh.vaghela@einfochips.com>
Cc: robh@kernel.org, devicetree@vger.kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH v2 8/8] riscv: dts: eswin: add watchdog support
Date: Mon, 06 Jul 2026 08:22:38 +0000	[thread overview]
Message-ID: <20260706082238.C8C891F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260706081055.1126275-9-pinkesh.vaghela@einfochips.com>

Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [High] Incorrect mapping of the APB clock (PCLK) to the timer reference clock (tclk), omitting the actual reference clock.
- [Low] Missing space after the '=' sign in the 'clocks' properties.
--

commit e654cdc83801a14778ef2783efed381807629c6f
Author: Pritesh Patel <pritesh.patel@einfochips.com>

riscv: dts: eswin: add watchdog support

This commit adds watchdog nodes for the ESWIN EIC7700 SoC and enables them
for the HiFive Premier P550 board.

[ ... ]

> diff --git a/arch/riscv/boot/dts/eswin/eic7700.dtsi b/arch/riscv/boot/dts/eswin/eic7700.dtsi
> index 6d328befc623d..d079bb337ecbb 100644
> --- a/arch/riscv/boot/dts/eswin/eic7700.dtsi
> +++ b/arch/riscv/boot/dts/eswin/eic7700.dtsi
> @@ -265,6 +265,46 @@ hsp_sp_csr: hsp-sp-top-csr@50440000 {
>  			};
>  		};
>  
> +		wdt0: watchdog@50800000 {
> +			compatible = "snps,dw-wdt";
> +			reg = <0x0 0x50800000 0x0 0x4000>;
> +			interrupts = <87>;
> +			clocks =<&clk EIC7700_CLK_GATE_LSP_WDT0_PCLK>;
                                ^^^^

[Severity: Low]
This isn't a bug, but there appears to be a missing space after the '=' sign.

> +			clock-names = "tclk";

[Severity: High]
Are we assigning the APB clock (PCLK) to the timer reference clock (tclk)
while omitting the actual reference clock (NOC_WDREF)?

The snps,dw-wdt driver retrieves tclk to determine the frequency for TOP
calculations and to enable the clock. Because EIC7700_CLK_GATE_LSP_WDT0_PCLK
is assigned to tclk here instead of the explicit watchdog reference clock
(EIC7700_CLK_GATE_NOC_WDREF), the driver might calculate timeouts using the
wrong rate and fail to enable NOC_WDREF entirely.

> +			resets = <&reset EIC7700_RESET_WDT0>;
> +			status = "disabled";
> +		};
> +
> +		wdt1: watchdog@50804000 {
> +			compatible = "snps,dw-wdt";
> +			reg = <0x0 0x50804000 0x0 0x4000>;
> +			interrupts = <88>;
> +			clocks =<&clk EIC7700_CLK_GATE_LSP_WDT1_PCLK>;
                                ^^^^

[Severity: Low]
This isn't a bug, but there is a missing space after the '=' sign here as
well.

> +			clock-names = "tclk";

[Severity: High]
Could this result in similar incorrect timeout calculations for wdt1 due to
omitting NOC_WDREF?

> +			resets = <&reset EIC7700_RESET_WDT1>;
> +			status = "disabled";
> +		};
> +
> +		wdt2: watchdog@50808000 {
> +			compatible = "snps,dw-wdt";
> +			reg = <0x0 0x50808000 0x0 0x4000>;
> +			interrupts = <89>;
> +			clocks =<&clk EIC7700_CLK_GATE_LSP_WDT2_PCLK>;
                                ^^^^

[Severity: Low]
This isn't a bug, but there is a missing space after the '=' sign.

> +			clock-names = "tclk";

[Severity: High]
Does this node also need NOC_WDREF to avoid incorrect timeout calculations?

> +			resets = <&reset EIC7700_RESET_WDT2>;
> +			status = "disabled";
> +		};
> +
> +		wdt3: watchdog@5080c000 {
> +			compatible = "snps,dw-wdt";
> +			reg = <0x0 0x5080c000 0x0 0x4000>;
> +			interrupts = <90>;
> +			clocks =<&clk EIC7700_CLK_GATE_LSP_WDT3_PCLK>;
                                ^^^^

[Severity: Low]
This isn't a bug, but there is a missing space after the '=' sign.

> +			clock-names = "tclk";

[Severity: High]
Is the explicit watchdog reference clock (NOC_WDREF) missing for wdt3 as
well?

> +			resets = <&reset EIC7700_RESET_WDT3>;
> +			status = "disabled";
> +		};

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260706081055.1126275-1-pinkesh.vaghela@einfochips.com?part=8

      reply	other threads:[~2026-07-06  8:22 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-06  8:10 [PATCH v2 0/8] riscv: eswin: eic7700: Add support for clocks, resets, pinctrl, HSP bus, I2C and watchdog Pinkesh Vaghela
2026-07-06  8:10 ` [PATCH v2 1/8] riscv: dts: eswin: add reset generator for EIC7700 SoC Pinkesh Vaghela
2026-07-06  8:10 ` [PATCH v2 2/8] riscv: dts: eswin: add clock " Pinkesh Vaghela
2026-07-06  8:16   ` sashiko-bot
2026-07-06  8:10 ` [PATCH v2 3/8] riscv: dts: eswin: eic7700: add pinctrl support Pinkesh Vaghela
2026-07-06  8:23   ` sashiko-bot
2026-07-06  8:10 ` [PATCH v2 4/8] dt-bindings: mfd: syscon: add ESWIN EIC7700 compatible Pinkesh Vaghela
2026-07-06  8:10 ` [PATCH v2 5/8] riscv: dts: eswin: add hsp bus node Pinkesh Vaghela
2026-07-06  8:23   ` sashiko-bot
2026-07-06 17:05     ` Conor Dooley
2026-07-06  8:10 ` [PATCH v2 6/8] dt-bindings: i2c: dw: add ESWIN EIC7700 SoC I2C controller Pinkesh Vaghela
2026-07-06 16:59   ` Conor Dooley
2026-07-06  8:10 ` [PATCH v2 7/8] riscv: dts: eswin: add I2C controller support Pinkesh Vaghela
2026-07-06  8:10 ` [PATCH v2 8/8] riscv: dts: eswin: add watchdog support Pinkesh Vaghela
2026-07-06  8:22   ` sashiko-bot [this message]

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=20260706082238.C8C891F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=pinkesh.vaghela@einfochips.com \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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