From patchwork Mon Nov 21 04:17:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Icenowy Zheng X-Patchwork-Id: 13050330 X-Patchwork-Delegate: palmer@dabbelt.com 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 A61BCC4332F for ; Mon, 21 Nov 2022 04:18:42 +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:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=VY/QXqalX9J/nBv9C3B1Ts5szWSqwi7EjuZXqrJMeHM=; b=Beb2CbpCsT0yoS rFUHGAEXVVDiomzoC8+0iQmWuVcsGN77mxKiFlODuuVMLq7WlaQ4u28ObwIQ6cdyAxDVDL/RlL1ui Ss9hKoD34P+V2Q4YQq+fVw0aG5pMu2HfzjcajYILYYkCpbYkJVGyfjFhoso8aoOD5bXXgxee9Tpot WlKi/IfuJQGziCU0QFFLSHSuBtRsy6pA/NnJBuzUMUuXRWu1d5KnheaajbJjh0kv3b4OyCwgcWP4+ 7zsPwHxu270es2b0KoDL0f+5KIhA+jRbL2qe2JsUkhNZTDQ7lnn9DjamEHJeUBG+sK3s6O8wmErmi Hs3EoPQ/FlpY1BzpbFjg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1owyGP-009IG5-NO; Mon, 21 Nov 2022 04:18:33 +0000 Received: from sender4-op-o18.zoho.com ([136.143.188.18]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1owyGN-009IFg-8C for linux-riscv@lists.infradead.org; Mon, 21 Nov 2022 04:18:32 +0000 ARC-Seal: i=1; a=rsa-sha256; t=1669004306; cv=none; d=zohomail.com; s=zohoarc; b=dwATXG8k/51p7QFxP3OE4q2a4JGoVJ9MNI59UQkdx0xlU2T9kN9NGsFqH2iB6a33tSv2Hg1dyhS0Bj5AN9+TqCHbJ+I/HfI2JK6arJfDH39qUWv5GsKFzcoWZ33vgEQNeinXHdDIO9zOxerJi6mgZNABPYPyvQL7GAmFBm3trSs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1669004306; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=yswQKN/NwiMTTVeDwWejovNA0LCHs9YyUSqdR/PYtho=; b=dJl3LuNi2k+AP04WqKijzFHYPG6yEo3hgNXUWSw4mV03TeBXA4Rhv432Jzcg+sjCFAdMG5BK2c4Sv7z24O4QnEfisC8rOQ9hlIDAtuC4+9MnsuEhhlDd7P95UC+U3bxokRBZhSwzTgWqgSECtbz66d5ismYlRVqiQr+l7fG+OnE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1669004306; s=zmail; d=icenowy.me; i=uwu@icenowy.me; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-Id:Message-Id:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Reply-To; bh=yswQKN/NwiMTTVeDwWejovNA0LCHs9YyUSqdR/PYtho=; b=aYn+JLu0d/dP+2Ij+Wou35VkIDBSj1pT2SbuZ/Ez30kO1xbBADT8WtFCUWsT+itU KKyGlYVn8+48jqRupqiVQKF6borkKkfmklZsIAUwa8vVzooAb0gNtfPlKOFMdHnw/RL lUxipWYWFm7j6dJMXY2VKxkePJHyAi+rZgtpJnqk= Received: from edelgard.fodlan.icenowy.me (112.94.100.29 [112.94.100.29]) by mx.zohomail.com with SMTPS id 1669004306146990.0421850975872; Sun, 20 Nov 2022 20:18:26 -0800 (PST) From: Icenowy Zheng To: Marc Zyngier , Rob Herring , Krzysztof Kozlowski , Palmer Dabbelt , Paul Walmsley , Daniel Lezcano , Jisheng Zhang , Samuel Holland Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-riscv@lists.infradead.org, Icenowy Zheng Subject: [PATCH 1/3] dt-bindings: timer: sifive,clint: add comaptibles for T-Head's C9xx Date: Mon, 21 Nov 2022 12:17:55 +0800 Message-Id: <20221121041757.418645-2-uwu@icenowy.me> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20221121041757.418645-1-uwu@icenowy.me> References: <20221121041757.418645-1-uwu@icenowy.me> MIME-Version: 1.0 X-ZohoMailClient: External X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221120_201831_357532_290E9924 X-CRM114-Status: UNSURE ( 8.93 ) X-CRM114-Notice: Please train this message. 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: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org T-Head C906/C910 CLINT is not compliant to SiFive ones (and even not compliant to the newcoming ACLINT spec) because of lack of mtime register. Add a compatible string formatted like the C9xx-specific PLIC compatible, and do not allow a SiFive one as fallback because they're not really compliant. Signed-off-by: Icenowy Zheng Acked-by: Krzysztof Kozlowski Reviewed-by: Samuel Holland Acked-by: Conor Dooley --- Documentation/devicetree/bindings/timer/sifive,clint.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Documentation/devicetree/bindings/timer/sifive,clint.yaml b/Documentation/devicetree/bindings/timer/sifive,clint.yaml index bbad24165837..aada6957216c 100644 --- a/Documentation/devicetree/bindings/timer/sifive,clint.yaml +++ b/Documentation/devicetree/bindings/timer/sifive,clint.yaml @@ -20,6 +20,10 @@ description: property of "/cpus" DT node. The "timebase-frequency" DT property is described in Documentation/devicetree/bindings/riscv/cpus.yaml + T-Head C906/C910 CPU cores include an implementation of CLINT too, however + their implementation lacks a memory-mapped MTIME register, thus not + compatible with SiFive ones. + properties: compatible: oneOf: @@ -29,6 +33,10 @@ properties: - starfive,jh7100-clint - canaan,k210-clint - const: sifive,clint0 + - items: + - enum: + - allwinner,sun20i-d1-clint + - const: thead,c900-clint - items: - const: sifive,clint0 - const: riscv,clint0 From patchwork Mon Nov 21 04:17:56 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Icenowy Zheng X-Patchwork-Id: 13050331 X-Patchwork-Delegate: palmer@dabbelt.com 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 B4AC8C43217 for ; Mon, 21 Nov 2022 04:18:50 +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:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=qMPf4nxzSzRic4KEE9HfZHIRLjZtIOS5NOztCjUg8I4=; b=jVrPlW5wxHILRJ N+Gm0HEYfA/wBSlwZEESuzEGb+kDz5mUYQvAryejuq5a5kf9v+8e6aHNzzm5xkQNz+EOZCp1irPtX ZHHIYioRH6PGqy5N8gleA2vIb1YJBTVTUknmdZ0E6K0AtTjbv0X9FZMloqVBewZ4xtfoFNVVl0X8L cvVzKq5zvawz9I04EbQdIg7NtcMTFzUQP/PpyC6qO8jkKmV9exmGumDxe3vFXGQbJRFg+1h5I4mOM /k+rKEJmWm7EMJwlskoUZ5otLQLowUzATvDn9ryOZoGdoBHNgCG3XrwKq35rtIR+c5ZeQlAv9Qt+v nZjp6NcJ/kpuhF0qPF6A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1owyGY-009IJ7-1t; Mon, 21 Nov 2022 04:18:42 +0000 Received: from sender4-op-o18.zoho.com ([136.143.188.18]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1owyGV-009II6-PB for linux-riscv@lists.infradead.org; Mon, 21 Nov 2022 04:18:41 +0000 ARC-Seal: i=1; a=rsa-sha256; t=1669004316; cv=none; d=zohomail.com; s=zohoarc; b=aixIFHpi3bHX4fgmZ3jw6KdRI02uqQHXp/1mFoKt6XzDRrFU3cndHsJbUCsF6ZgSstQWSWKq17+bux6kgZIlqZZdyVreWGrQqBuijAr3uiwAO5/kd2jBfDCy9NKFS+Vj/82TH4M/vAA1SBAuhQzoipTxzOFiQjit/q5i0wB6fUU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1669004316; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=1jvBArX5LMEqGndC/rqeiRHpRcDw256YhccTebGyEL8=; b=DRkD33XgFDBpBkUfgL772kN8xlu2Q1JO4TuKnGVCn9Ct937mzlLI/gXomTplEfTizo7bJr1K/GtqSW54Q+ML9tLDzhXKL/pgFD2FA4SyBFKZOqfvmhZquB52J/YQ2GdI16dqYwVAPTQaa4QpNeGAyGt6e1E22ci34cchhJ31HJg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1669004316; s=zmail; d=icenowy.me; i=uwu@icenowy.me; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-Id:Message-Id:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Reply-To; bh=1jvBArX5LMEqGndC/rqeiRHpRcDw256YhccTebGyEL8=; b=WBLe4bVOKOeFkUgh+EGrCsx73wKCpTEBVPhaGux/W8pcJM+arJuhX32P4TKVapzM 5bjyb3/M3WCPy+l7/Ii4/IYjfliXcHAU6bIrv9R4u40Cqp7fVomldgPNv/SZdElvgBp J1fPNdB+DNxtLGOWmNZInsRkwl+4V3Gg83dWjW8E= Received: from edelgard.fodlan.icenowy.me (112.94.100.29 [112.94.100.29]) by mx.zohomail.com with SMTPS id 166900431506566.96637222919264; Sun, 20 Nov 2022 20:18:35 -0800 (PST) From: Icenowy Zheng To: Marc Zyngier , Rob Herring , Krzysztof Kozlowski , Palmer Dabbelt , Paul Walmsley , Daniel Lezcano , Jisheng Zhang , Samuel Holland Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-riscv@lists.infradead.org, Icenowy Zheng Subject: [PATCH 2/3] dt-bindings: timer: sifive,clint: add compatible for OpenC906 Date: Mon, 21 Nov 2022 12:17:56 +0800 Message-Id: <20221121041757.418645-3-uwu@icenowy.me> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20221121041757.418645-1-uwu@icenowy.me> References: <20221121041757.418645-1-uwu@icenowy.me> MIME-Version: 1.0 X-ZohoMailClient: External X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221120_201839_904296_971EADDC X-CRM114-Status: UNSURE ( 8.07 ) X-CRM114-Notice: Please train this message. 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: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org T-Head OpenC906 is a open-source-licensed fixed-configuration of C906, which is now public and able to be integrated. Add a compatible for the CLINT shipped as part of OpenC906, which should just be ordinary C9xx CLINT. Signed-off-by: Icenowy Zheng --- Documentation/devicetree/bindings/timer/sifive,clint.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/timer/sifive,clint.yaml b/Documentation/devicetree/bindings/timer/sifive,clint.yaml index aada6957216c..86703e995e31 100644 --- a/Documentation/devicetree/bindings/timer/sifive,clint.yaml +++ b/Documentation/devicetree/bindings/timer/sifive,clint.yaml @@ -35,6 +35,7 @@ properties: - const: sifive,clint0 - items: - enum: + - thead,openc906-clint - allwinner,sun20i-d1-clint - const: thead,c900-clint - items: From patchwork Mon Nov 21 04:17:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Icenowy Zheng X-Patchwork-Id: 13050332 X-Patchwork-Delegate: palmer@dabbelt.com 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 1A283C4332F for ; Mon, 21 Nov 2022 04:18:58 +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:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=AtCuUtsykUb4ZVx0EnmKxikG85epNi6ire6xkJnsJMs=; b=WS/AwfsFr8qWQe xtcm+sP5l+K1Qb0uN3BQanBLiEwWd/hJiBlIUnLbBNu67KFx2gZWNb9mn6bJKzyZmeTzMW3SELxqw J51cUS+HWBGP2NM8wVNrK7mnDsAuXbMbW9n9/N5XxmdQKLGf/zOSNjjQJRMHaKSjZmFfgkyFfCN02 v+tGxh81gAQiMBGgT0cl4aumICC+7vQYOe+lQSvAegPPWyXb1D6ZVAafWMBASc8Vj3cuLqKSdaU+D fdOKaAVozA9CY+tGAWVISM9mMcYoB+flnvgGOxrgTVejV+5R0MKOdEHtWY7QaOMdEHwLYJQEZz1W/ Acfo42nvrup92pkiokXw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1owyGg-009IMg-5I; Mon, 21 Nov 2022 04:18:50 +0000 Received: from sender4-op-o18.zoho.com ([136.143.188.18]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1owyGd-009IKX-1W for linux-riscv@lists.infradead.org; Mon, 21 Nov 2022 04:18:48 +0000 ARC-Seal: i=1; a=rsa-sha256; t=1669004323; cv=none; d=zohomail.com; s=zohoarc; b=fyshxFY9Mc/+iJ1znLlt674Lkas5pFte2C+XYQTgLN7twzB6oiciAGD71SWwdKJYSWu9U14IBwlUNSCSiEQh3l7TUKYWlrhN/nNXMLG+Mt+xd65yPGBlPRn9+5GsKbAfdhrvrwNXnAJ94K6lG3MRI01cKHD6VwrwhSqOmja/7TQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1669004323; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=3mufr77oeRQMIDQ9BLCeK57+i5lF/oGGUHybbQbCGv0=; b=SVO8XJ6yGlRfdKEtCycXw6K1MAX46QfAe8vf4WVf0/6apAEPkDzPKJ5PX8fVP714NYbxijEqQVOPq0l30Qzxwoer8d4M7Pgtzw6G+efKQY+mBWvk2JOSpAIImm/Aj24lOAi3NU9ZX3HKzD19kE47UJiQMAEU7npXXrTMwrdUGak= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1669004323; s=zmail; d=icenowy.me; i=uwu@icenowy.me; h=From:From:To:To:Cc:Cc:Subject:Subject:Date:Date:Message-Id:Message-Id:In-Reply-To:References:MIME-Version:Content-Transfer-Encoding:Reply-To; bh=3mufr77oeRQMIDQ9BLCeK57+i5lF/oGGUHybbQbCGv0=; b=bgWiYmXimeGexCxx/i1ZdvkWwgnY8ctOaoF23X/GecU0aP0ozpndtbVvorG9XYuG jKJc4b90Y4mNnMsDYcjOYJp9RsKWkQ7RgvGnEJz2VHKIExV1WhLnh0DVOieKdrM8oPP yYVyQLcerP1Ib9tbj82kd2UHkIJQzgnsqraBpu94= Received: from edelgard.fodlan.icenowy.me (112.94.100.29 [112.94.100.29]) by mx.zohomail.com with SMTPS id 1669004322259164.1933466310711; Sun, 20 Nov 2022 20:18:42 -0800 (PST) From: Icenowy Zheng To: Marc Zyngier , Rob Herring , Krzysztof Kozlowski , Palmer Dabbelt , Paul Walmsley , Daniel Lezcano , Jisheng Zhang , Samuel Holland Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-riscv@lists.infradead.org, Icenowy Zheng Subject: [PATCH 3/3] dt-bindings: interrupt-controller: sifive,plic: add OpenC906 compatible Date: Mon, 21 Nov 2022 12:17:57 +0800 Message-Id: <20221121041757.418645-4-uwu@icenowy.me> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20221121041757.418645-1-uwu@icenowy.me> References: <20221121041757.418645-1-uwu@icenowy.me> MIME-Version: 1.0 X-ZohoMailClient: External X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221120_201847_153618_FAE583CF X-CRM114-Status: UNSURE ( 8.17 ) X-CRM114-Notice: Please train this message. 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: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org T-Head OpenC906 is a open-source-licensed fixed-configuration of C906, which is now public and able to be integrated. Add a compatible for the PLIC shipped as part of OpenC906, which should just be ordinary C9xx PLIC. Signed-off-by: Icenowy Zheng Acked-by: Krzysztof Kozlowski --- .../bindings/interrupt-controller/sifive,plic-1.0.0.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/interrupt-controller/sifive,plic-1.0.0.yaml b/Documentation/devicetree/bindings/interrupt-controller/sifive,plic-1.0.0.yaml index 99e01f4d0a69..4d14c5f5c611 100644 --- a/Documentation/devicetree/bindings/interrupt-controller/sifive,plic-1.0.0.yaml +++ b/Documentation/devicetree/bindings/interrupt-controller/sifive,plic-1.0.0.yaml @@ -65,6 +65,7 @@ properties: - items: - enum: - allwinner,sun20i-d1-plic + - thead,openc906-plic - const: thead,c900-plic - items: - const: sifive,plic-1.0.0