From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 50170CCA471 for ; Sat, 4 Oct 2025 02:22:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=OQ5BX4bP6W61faMdN80mdVI+gbL1YTWO1Tslt8PXCdg=; b=aCZDCRLH7mAqs/ Bd85yutUkRA/n+nbJYt6Ad53ellWJOf0wt303GGuVlWMwyhyh55Q+uKyf9W808LlxvTTDJgBZLXgC nCV6jQX/4V8BQZ+MkQFYo7MFeYxO0xydJn8rLvQb51xiUqzhSu+aHjo/rUETh4bu/80DeL2AYLFgm z8S6hsA00pq/SdACvZYevdM02XQ1kr7Ys0+7xoQMg0GG2nXPFOD47A6NpFZyvGkdsuYLU+o7lQtsp sD4PeXrUJJ+rx/q+MjoPNVoBvJdpSSdd4fm9pcles7jORN+CbbKVnVBP4QXQiqVTX23XJsU4L74z/ b49M3wyJ9n2CAQ/OFKlw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1v4ruU-0000000DO1t-3EPi; Sat, 04 Oct 2025 02:22:10 +0000 Received: from layka.disroot.org ([178.21.23.139]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1v4ruR-0000000DO1Y-2xNO for linux-riscv@lists.infradead.org; Sat, 04 Oct 2025 02:22:09 +0000 Received: from mail01.disroot.lan (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 7A9E626222; Sat, 4 Oct 2025 04:22:02 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from layka.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id L-mAlgRG7zDV; Sat, 4 Oct 2025 04:22:01 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1759544521; bh=kzhYlF7toSJUYLhb6Zjs2f+TE43JU+j0Ai5mwSU6n38=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=cqlAqblRnzhq6/cP064tVaoFUxarJaXkP0yLySa8sYNPgz6z6SYKJidlwnZtewnIA qLK1FM++X1Rz+7cKIx59TfPCPTMh9fbKuG58Cl5YZ/QU0qfr4NZiQEbciQhsPjZZie jvEk6AD1y+A8znqWUWrAmmVG2zBY2I112w0LOJ9+LDPiNnkXPd4iCyflRYTuR6lh4a 9kZ7UhXyChlPWBPSJHOwi8bH3P70W8h/yKmGuVEk1eZFe/8TSjNF3MA1tj/lVxURqU /++dUO20g/4qX9Beg0bmSEKHe7SiuP+4Kw3LQexE734gZaXjSr9ObmfANvODxGMWAD frPgVDe3rUqvw== Date: Sat, 4 Oct 2025 02:21:43 +0000 From: Yao Zi To: Drew Fustini Cc: Rob Herring , Conor Dooley , Albert Ou , Michal Wilczynski , Alexandre Ghiti , devicetree@vger.kernel.org, Han Gao , Han Gao , linux-kernel@vger.kernel.org, Guo Ren , Philipp Zabel , Paul Walmsley , Palmer Dabbelt , Krzysztof Kozlowski , linux-riscv@lists.infradead.org, Fu Wei Subject: Re: [PATCH v2 2/5] dt-bindings: reset: thead,th1520-reset: Add controllers for more subsys Message-ID: References: <20250915095331.53350-1-ziyao@disroot.org> <20250915095331.53350-3-ziyao@disroot.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20251003_192208_285280_3C56F9DD X-CRM114-Status: GOOD ( 21.73 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org On Fri, Oct 03, 2025 at 03:46:17PM -0700, Drew Fustini wrote: > On Mon, Sep 15, 2025 at 09:53:28AM +0000, Yao Zi wrote: > > TH1520 SoC is divided into several subsystems, most of them have > > distinct reset controllers. Let's document reset controllers other than > > the one for VO subsystem and IDs for their reset signals. > > > > Signed-off-by: Yao Zi > > Thanks for sending these patches. > > > --- > > .../bindings/reset/thead,th1520-reset.yaml | 8 +- > > .../dt-bindings/reset/thead,th1520-reset.h | 216 ++++++++++++++++++ > > 2 files changed, 223 insertions(+), 1 deletion(-) > > > [snip] > > diff --git a/include/dt-bindings/reset/thead,th1520-reset.h b/include/dt-bindings/reset/thead,th1520-reset.h > > index e51d6314d131..68ac52ed69de 100644 > > --- a/include/dt-bindings/reset/thead,th1520-reset.h > > +++ b/include/dt-bindings/reset/thead,th1520-reset.h > > @@ -7,6 +7,200 @@ > > #ifndef _DT_BINDINGS_TH1520_RESET_H > > #define _DT_BINDINGS_TH1520_RESET_H > [snip] > > +/* DSP Subsystem */ > > +#define TH1520_RESET_ID_X2X_DSP1 0 > > +#define TH1520_RESET_ID_X2X_DSP0 1 > > +#define TH1520_RESET_ID_X2X_SLAVE_DSP1 2 > > +#define TH1520_RESET_ID_X2X_SLAVE_DSP0 3 > > +#define TH1520_RESET_ID_DSP0_CORE 4 > > +#define TH1520_RESET_ID_DSP0_DEBUG 5 > > +#define TH1520_RESET_ID_DSP0_APB 6 > > +#define TH1520_RESET_ID_DSP1_CORE 4 > > +#define TH1520_RESET_ID_DSP1_DEBUG 5 > > +#define TH1520_RESET_ID_DSP1_APB 6 > > +#define TH1520_RESET_ID_DSPSYS_APB 7 > > +#define TH1520_RESET_ID_AXI4_DSPSYS_SLV 8 > > +#define TH1520_RESET_ID_AXI4_DSPSYS 9 > > +#define TH1520_RESET_ID_AXI4_DSP_RS 10 > > This doesn't seem right. The numbers for each subsystem should not > repeat. Here the DSP0 and DSP1 items have the same numbers: 4, 5, 6. > > This causes both clang and sparse to complain. I think you can just > change this so that TH1520_RESET_ID_DSP1_CORE is 7 and so on. The > indexes don't really have any concrete meaning other than how they are > used as unique keys. You're correct, it's a copy-paste error, just like the one spotted in v1 of the series... I'm not sure why either my GCC or sparse yielded no warning about them. Will figure it out and send v3 with this fixed. Much sorry for these stupid mistakes. Best regards, Yao Zi > The warnings: > > AR kernel/built-in.a > CC drivers/reset/reset-th1520.o > drivers/reset/reset-th1520.c:655:32: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides] > 655 | [TH1520_RESET_ID_DSP1_CORE] = { > | ^ > 656 | .bit = BIT(12), > | ~~~~~~~~~~~~~~~ > 657 | .reg = TH1520_DSPSYS_RST_CFG, > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 658 | }, > | ~ > drivers/reset/reset-th1520.c:643:32: note: previous initialization is here > 643 | [TH1520_RESET_ID_DSP0_CORE] = { > | ^ > 644 | .bit = BIT(8), > | ~~~~~~~~~~~~~~ > 645 | .reg = TH1520_DSPSYS_RST_CFG, > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 646 | }, > | ~ > drivers/reset/reset-th1520.c:659:33: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides] > 659 | [TH1520_RESET_ID_DSP1_DEBUG] = { > | ^ > 660 | .bit = BIT(13), > | ~~~~~~~~~~~~~~~ > 661 | .reg = TH1520_DSPSYS_RST_CFG, > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 662 | }, > | ~ > drivers/reset/reset-th1520.c:647:33: note: previous initialization is here > 647 | [TH1520_RESET_ID_DSP0_DEBUG] = { > | ^ > 648 | .bit = BIT(9), > | ~~~~~~~~~~~~~~ > 649 | .reg = TH1520_DSPSYS_RST_CFG, > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 650 | }, > | ~ > drivers/reset/reset-th1520.c:663:31: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides] > 663 | [TH1520_RESET_ID_DSP1_APB] = { > | ^ > 664 | .bit = BIT(14), > | ~~~~~~~~~~~~~~~ > 665 | .reg = TH1520_DSPSYS_RST_CFG, > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 666 | }, > | ~ > drivers/reset/reset-th1520.c:651:31: note: previous initialization is here > 651 | [TH1520_RESET_ID_DSP0_APB] = { > | ^ > 652 | .bit = BIT(10), > | ~~~~~~~~~~~~~~~ > 653 | .reg = TH1520_DSPSYS_RST_CFG, > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 654 | }, > | ~ > 3 warnings generated. > CHECK drivers/reset/reset-th1520.c > drivers/reset/reset-th1520.c:643:10: warning: Initializer entry defined twice > drivers/reset/reset-th1520.c:655:10: also defined here > > > Thanks, > Drew > > _______________________________________________ > linux-riscv mailing list > linux-riscv@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-riscv _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv