From patchwork Thu Jun 27 15:31:15 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808100 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6C20A198E81; Thu, 27 Jun 2024 15:32:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502353; cv=none; b=J+ltHuwR+k7JYHQ+lF3Ekm2MwLPFl06subR/JM7zBU2BEaUqL1RzNtanyB0hcW2uDAhnxwVH7s3D/lUP2+865TS4EspAI7LtVl9nSVvrISmipGo1xbNyHfbAcSvo4AR7XpQ1v2+OXaZ12xo+OcGMCWPS3Av9w2u4nfBCuDEV0h4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502353; c=relaxed/simple; bh=AmRVyrrnbky9NGM25IDJL98iq6w0qLUaV8yzYOFQOrk=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=UBxcGyKHlPahXcQuLf1Rle/9ErgscHVbsLg1j2At9ElqW9Rv4L8YLgH5l6zSMUCBNALc1oBrM8ukDCoa0gzHdAd0pKHfNSYX6OdApeRO+LMriCc7mw/pyOXcHuMr3zQY/Qz0jAhs4PRZ0z9uRxWelSphuaV6cY2HCK3NLvWi0pg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:15 +0000 Subject: [PATCH v2 01/10] dt-bindings: vendor-prefixes: add spacemit Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-1-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=920; i=dlan@gentoo.org; h=from:subject:message-id; bh=EJxb7EeTC9u7CCdTJTxx28CPOGa+wgjU03pSv3TtRsE=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXfZMfeOnLAd+tWnxhngeusAefsZ+c5pev+Q Okj1g4AdqyJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F318UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277QRgD/98O7jkOqAavN5KZS lMvJzyEW6LAEmNlyCJyxwdyUayJtH8GIZJgUWRVdt7ZX7j3De/gRwkjRmeVuzj10B8q8MDGXHNv 3TCZ0F0DFhJoWtByqxbIkKNXtGzJF82Zy4kIOhbsTS4Tc25wvUiSqM19my2DeR18Yu8O4AY6Rgw AA2VZwFTSFu+oK87nwdGerGGQUCSY/YORBN2+pGMLa3+NItSvRyd9YAbo7N6h/smGaCnGFFwFHO npkERepOD1AZipXwXNJ6coqrqqBJ6Hjh4ljZJ+OgZTLSUTdGb/2aY+VclN0AF7saAFQYr/aMe2d vQ1yHOd00kQyEOegy8PT+SYEd2x+8C1/zSFPVF6PLpBo5GS+Kv3VzuNwFqtpAuvc0QM9ajr5Biq jxCCQKn52dnx+s7wLLh1rgAb++1lEBfEX9SrWpMY/cEavhNEw5j5ONYSHQEE1zvRt5XqrZ2AzpE jZ2Im+ZEfkRIwGw62CEGOKzhNID8XnwadTDPYomSGJwLWQnlo0/v/6gekxutdGo2PuE/IelbyCo oIWZg8sTFab16kVerHXlpvCcPBVdlOSgru0NFHArR7f5+IML/U1eg2Jc1/M2v7edcw9ZUAgL4E2 Rg7Y34eUg8WOWRB6hBU8RhPCRCsO32WySw9et6RwPkqJ0t2uUxJ6NJcMg/uJf9oDW3pA== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Add new vendor strings to dt bindings for SpacemiT K1 SoC. Link: https://www.spacemit.com/en/spacemit-key-stone-2/ Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan --- Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml index fbf47f0bacf1a..7ee6e4a89376e 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml @@ -1362,6 +1362,8 @@ patternProperties: description: Sophgo Technology Inc. "^sourceparts,.*": description: Source Parts Inc. + "^spacemit,.*": + description: SpacemiT (Hangzhou) Technology Co. Ltd "^spansion,.*": description: Spansion Inc. "^sparkfun,.*": From patchwork Thu Jun 27 15:31:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808485 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 870301990BE; Thu, 27 Jun 2024 15:32:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502359; cv=none; b=ndTmyLsT1iQ7xKLtFRJ5FNiK1+MfzVkjyMGmmN+1yBiRkCM3L0+0wMBTyPhKE1HX6i/cwAB3Ld5VtrpNk1e/2UFwhFFL0E7iFk360B+sXWxFsQdu8JjsOplX8RFmymFzLMlbuju0OYnDGdAFDNE2ZuBGr65DdGHrOQWfgf3zGXA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502359; c=relaxed/simple; bh=e2VERBSC3hvoUe3+71zYxaKEO87k4x7VETYOMNHFzPg=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=BPEezY06TAvNZxBShg5XN9YHb8NhkcfA4NkzSDl60IzyplXw4w/L9WBRMA70HbQifwxGos5r7YctpzpfXO1sDjaMGj/mnDTeR48U/lQt0Z+LC5Y0mYA5wnW8SZqHvWThrkEH13wAGYAUwXizy+T4I9hlV202uo0WuRuo8MjqYm0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:16 +0000 Subject: [PATCH v2 02/10] dt-bindings: riscv: Add SpacemiT X60 compatibles Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-2-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=853; i=dlan@gentoo.org; h=from:subject:message-id; bh=oiadtAT5r7xDGzsCnaCGPJ2frMTxz+XpkwmHxkPFkkA=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXjsrZOKxCkQrojHnkDrw7pdrxsCq7ycSSsn /C9MT4rJyWJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F418UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277RwQD/4hzCsplIb2vrQt9n 5IXGzH3kWcO5Wtvxw6BcBTbWTVcA0hMvgoxjVeVIOlsmUAcrtJqKuK4dskwimO6KOVhXekrZzxW Lv5YMu1bJnPMNVvEnNdWFKR2PLk26ncFYAA1hO/1Fk3MRXwCFsAzMTpAgnVgeDg76lucL8pJpkY PtcZI5NATDRsxPvvgiv2+UziB1KrFd2hUgel6BTFo8GAY2fNDJNxstMtpDAz20xCwEwQwWphEVQ rDT0pgrIjCExeRud32LcP37hWNT4Y3vLiceZepRtl5C/GV0wIvVuRy5eFQfVzij7KT+nxR1OwtI RxgzzsVhhla0s+UNS2uyZlLJe4pSfSZ+q5Ow16LuoXrIR6OPE1oNQXxn+zggYHVq51vnGISfzJl Szx7htGmM5WskMVzQ92wSMhiGVukwfkS0l+ew40E22OqvV181B/TOQQ+uSbNaGdpgb56pL9FACn GuRRCs3GMIveibo6psuy4FN0Y7p+2oUyrBumBMNu4Y0ebKQB9FWoOqtMp8jmm1EsaHQvLlJbxR+ naEblORmjEiRmE4G1KmFs20mvJqr4YUj5KJY2j9lVMsX9U7ESNgxkwbS+Z8boltEiiKA+WOJ4ih Yysj4umnW23flwGzvqopfZoZpj6yJNvcmt02bn553k4ZzdCO2QFiAySGpS/i7Mls8wKQ== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen The X60 is RISC-V CPU cores from SpacemiT and currently used in their K1 SoC. Link: https://www.spacemit.com/en/spacemit-x60-core/ Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan Acked-by: Conor Dooley --- Documentation/devicetree/bindings/riscv/cpus.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/riscv/cpus.yaml b/Documentation/devicetree/bindings/riscv/cpus.yaml index d87dd50f1a4b5..5ad9cb4103356 100644 --- a/Documentation/devicetree/bindings/riscv/cpus.yaml +++ b/Documentation/devicetree/bindings/riscv/cpus.yaml @@ -46,6 +46,7 @@ properties: - sifive,u7 - sifive,u74 - sifive,u74-mc + - spacemit,x60 - thead,c906 - thead,c910 - thead,c920 From patchwork Thu Jun 27 15:31:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808099 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BC1001991A4; Thu, 27 Jun 2024 15:32:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502367; cv=none; b=i81oZU7r7eGgcIrQH7IinIfiBleMIX1W4gXMn3zqSEnQ71TeO47kp7bfgUZWegJGa5MzuOSrqVqsjZ7gixN3f+A+FTFFpoisfuY/t72M+0ql2VI3OzonW3u+CLIT4hQV+3AZ0PhOjxv6w/sYLiu+h4QLM5bIK68I5d63paEGD1c= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502367; c=relaxed/simple; bh=MorS0V5oojZXAcpztqtXzmyXhOw8QyVHp6j8OUOcVGw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Hg4ps0sYYvH8VEI7OWk0255I5HThAo7onAtCp/adtBecxy465QQuxGbmenf+7ASkpELEX+jSImNWn6Pi4IUmaUxtL6xM8sjm9WdNRVJ1dx6tF1ePVpZUiDSezKaWfsvaSUa+c37GkWle9YzZF4RSnNMH7/KOCMb3e1PgOdlTWc4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:17 +0000 Subject: [PATCH v2 03/10] dt-bindings: riscv: add SpacemiT K1 bindings Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-3-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1231; i=dlan@gentoo.org; h=from:subject:message-id; bh=0ZjMf1/zFz8nSN0KohGoIaKW8DB3sA+2dQaSsEZNxvA=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXmVyqk3XHGF18KdlOJHjwS1qLj2fyXfZJNU Fgq7053byyJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F5l8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277WVJD/oCNQBiPOWQ7vhCKY 1MLVFyY1/NHqG40hGglELdn1zaG8shgO+/g82wa6bOGZl36WH4iZ1RlrAb/6jfRZG3oxa8dz11R AqyQXaFyqV31Qr3wN/jgg+fpS0HE3Q8Xui0LNfSVlPwHXIBezAPAQkvCrAuI/cyKJfrC71LO07q OaGKskyYMz0b/bsII1PSc/kfiXb0YgrbZovc5+Y5gJ7pArvrJms3KtT+tC9hdAVy6Pwj8INGSDB QjVfyjd7GwQjULx72lqJYOsK3bKPgyftmqd3a3HfCP3NSyTJo0lVnj50D3nO6ViLYtQJ/FRSgQ0 jcaLj4GJCfB/kaJGbiGKLskgW+jc0t41vl7dxVcrnkF/dUjPgDgoLfW5ivX3T10Xtt5qF95mUEa 0jlnG4/GkDmkXqJVI7+9hcylkZqb7fdd7QvP1aWT4qMIjf2x9wptuOSSXcoE4fWVhaYfpbRGi+F YC/hx080WgRQ3EfSzxq+AaQh2jD1rdMEjqiUqXtfSls9izSVN0F28gyTcjL/pH5Nx5yeuZfqzHc atbQYL7avYxxhRXWjEV0yUi+KBnwKiRGWXx5fbslIThSOh0BCbbja1GaJ3U1nYyFadDT8x1PHj6 qUFM7G6ba1rpA8wTe6joV3Xy/GzF//f2DtCTTa8/Ju1qWJ5NTIXFS2IN5kFmaKFZ6FPg== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Add DT binding documentation for the SpacemiT K1 Soc[1] and the Banana Pi BPi-F3 board[2] which used it. [1] https://www.spacemit.com/en/spacemit-key-stone-2/ [2] https://docs.banana-pi.org/en/BPI-F3/BananaPi_BPI-F3 Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan --- .../devicetree/bindings/riscv/spacemit.yaml | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/Documentation/devicetree/bindings/riscv/spacemit.yaml b/Documentation/devicetree/bindings/riscv/spacemit.yaml new file mode 100644 index 0000000000000..3b151fd02473e --- /dev/null +++ b/Documentation/devicetree/bindings/riscv/spacemit.yaml @@ -0,0 +1,24 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/riscv/spacemit.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: SpacemiT SoC-based boards + +description: + SpacemiT SoC-based boards + +properties: + $nodename: + const: '/' + compatible: + oneOf: + - items: + - enum: + - bananapi,bpi-f3 + - const: spacemit,k1 + +additionalProperties: true + +... From patchwork Thu Jun 27 15:31:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808484 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 858B61990AE; Thu, 27 Jun 2024 15:32:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502376; cv=none; b=GG0wOQH8pdLI9/bIv/wPp7w2GI7sV0dhPJjWdPAf00Upy671UR/T+Zeofm1f5Ib9xfWKJwz2CNyw9yJ95uPkrK8cho59YyJvoCjnhwX86NqFhW5w2lD9GcX2bxn1qZO7JgYTMXMrSRwN6FI9tOToN+oCqB1pW2pjVL7ww38IfwM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502376; c=relaxed/simple; bh=ryEHU26hC2m6o+qKz3yQBlyDRFU6B17IZTG4/ovqvoY=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=JKtz9q75AXukIw4AkU2iFmWzSRz+0WvTVYextLs7VVUdQL2qUgYYhnAcZ7RmZVV7RtGGZ+emunVTnh/bIilhU41B4yNmv2FLcSrNWfeAbKDTZOjQRC5mRpazEM/W6JlRfmEmQOvd+AML2gqXECT7py39sFNek26bSxKsF0WNm4w= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:18 +0000 Subject: [PATCH v2 04/10] dt-bindings: timer: Add SpacemiT K1 CLINT Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-4-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=974; i=dlan@gentoo.org; h=from:subject:message-id; bh=jlJAxtgKZpcQOsCvH4z2K1QJ+1Ic6ECnm70OutsapPk=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXpKAR/bCQvjdy9lSXYBFTh1lzfuFwG3ENLm sU1PZ2NnVGJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F6V8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277RIbD/0Ypzru6itSvvzThA fWnHbEAURPxmubhKUNVrGutgsOcGFV0xKw8OnXD10MizThQVF7Q5oGNR98sxYvaZW9EpGTDJBr/ uBoLaZCeRoRxQykUGlvr73BGDwxEkcwbPWcF/nbncR06D1OMCohfmFRIESVb/K+a2bRtbLkZGPn vXljDi9wqbyAD8BkzM4chLs0BhntIGF2SzUJjddJ1fQm+Z5c4nUqECALKbNKVoko4jkF1Ih8z9v WDEswiKS8J0oLHbf1U8w2ZoLYgO66BejC2/RhxwHI2MNAhWex+n2MHAi0GCbX1FHAOU39uotMtD YPLB3fzd/lpdA9D+hypeEaQWf7hM41+qHrMYwaJtbK45nMzlHSPkmNA4LGHVc4+HGNcydwRK4+g SbC4e3e9Pihj3ZqtKGu1WWs6Qme7g1QM7y0k0hAlfIxl8dk1oFcpmVQkZoajzHHAZI9aEsPVoPQ szwRMfWh7e02hhbp+R8BjKivsq1Fm9JmYGZnRRnBoogsZRqdQiSdMVdmfsdSqZJtWVEk0ixexfg Q6YoaeiVnGNKQykAANUgx4gaqhVKRrLGJkVq3OlTPRgN0jB2WPyBd7nGcJLWYHkNhioLz53vbjW kPZA00kuCTmPa6s5B0BlYO/x5oHSfGOXNIyQAVRBm8V/5iG7IeLEUZf+gTa8NvUyHxeA== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Add compatible string for SpacemiT K1 CLINT. Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan Acked-by: Conor Dooley --- 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 fced6f2d8ecbb..c2e68587a806a 100644 --- a/Documentation/devicetree/bindings/timer/sifive,clint.yaml +++ b/Documentation/devicetree/bindings/timer/sifive,clint.yaml @@ -31,6 +31,7 @@ properties: - enum: - canaan,k210-clint # Canaan Kendryte K210 - sifive,fu540-c000-clint # SiFive FU540 + - spacemit,k1-clint # SpacemiT K1 - starfive,jh7100-clint # StarFive JH7100 - starfive,jh7110-clint # StarFive JH7110 - starfive,jh8100-clint # StarFive JH8100 From patchwork Thu Jun 27 15:31:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808098 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B67961991D7; Thu, 27 Jun 2024 15:32:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502380; cv=none; b=L7G+52OZ2OfbOJ9f6K1Sj56DpcNhHFZOgyw9NTORYfzbGVtCkIJ38EzsHJ/nx0Ae/X1Ap8fEBKJHz0WDhxjxvO+AcXkfWU+/LPqoUl8iiGZ2T03TUw48dntrwNj5UhWenneC7nibSExILrLhPPsBuWU1v/NRw4Z7po4/nT9++ng= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502380; c=relaxed/simple; bh=Xq3EPz3Bewa4lpONxr7fD/RU/vsUKnqdk0lFgB4kADA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=SK60CKinfqyAMba8Ad6q+uUtKHanTrAL121lAH0H5nSGjClOE8LVdcVDxPvs5qRHtZj5QNtMoNoU1s2jEFxCszi7nDE7KCKgjQKOpxLFVmBoljzrSyjImSJ9ZlkBG/qROOcsmsOy8V/+ro0h2UvwQXVSmCYCkqw5M46rykoS84I= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:19 +0000 Subject: [PATCH v2 05/10] dt-bindings: interrupt-controller: Add SpacemiT K1 PLIC Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-5-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1319; i=dlan@gentoo.org; h=from:subject:message-id; bh=Sd2cefvtLvue4VbNU8TlhgwBKtDTSAfC6Dit7xBpOS8=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXtHABiNrlEMZ8H8PALGClDGbpzYcf5kjII5 gjtZqMg91GJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F7V8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277cTRD/wL9cUA+WtRnqxAtx pPkcr0X7+bD8Vm/RB6GWmre4+/fQQjJvnxmwXjgIdPdMZmbY6ZmvXZxX93QiuOp2prCvNZkn7T8 nZaDWvscXO0pjnGTWOeDpIWx0PZA5ZEkgBP5NW/PL9TVPvFydVF8kQ52Y4Xpm/sp3mEvNWhg7id uaXN+sdt7FTL57nEpx79gqWh1N951Mn7q7YsV/Y+f0pOdhrO/AJCnqU60+z6eYyiTbRWA8weq58 1hduSuS3p6I6RxhjL1WSW1NPkhGhOQyUQhw/5ZbfCdfA2BBfHv4txaXerbZu1qev1E8fiyHMqN0 aR5iGUUaNhhNJEAeiRmhmIIBtBBvVBuQHpbD+Z8T49ljE76LPsg+BwSyPLgoI94zLuyOLdTXtV/ uoyYgFTRXvCXo2WxTtXEHDEssgbLdlpZOszXc+lLcvwb2nc0jeuFYUe9cH+3pYg6fwRRsn7fSrt pKKIDtgUe0BG3y4BYINqUziWdt72MWRJZoRszv9ozTmA3wBnS8Szeg3IxgO9dXRH4YS6RL8I32T KRh90JCOmJakUjp7KFf+pKACEPjyWiHEEw3BK5NHUgqLkDe4lrdlfXWy/45rTYarHbjaP8ThlY1 p7ymVah3Qz5a27uqqA7h0ysWeGcq2ysI8NpsIfDBEvA5nmLX/r08zQDpg6xVtfVjE8hg== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Add compatible string for SpacemiT K1 PLIC. Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan --- .../devicetree/bindings/interrupt-controller/sifive,plic-1.0.0.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) 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 709b2211276bd..3d0426b569042 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 @@ -59,6 +59,7 @@ properties: - enum: - canaan,k210-plic - sifive,fu540-c000-plic + - spacemit,k1-plic - starfive,jh7100-plic - starfive,jh7110-plic - const: sifive,plic-1.0.0 @@ -71,7 +72,9 @@ properties: - thead,th1520-plic - const: thead,c900-plic - items: - - const: sifive,plic-1.0.0 + - enum: + - sifive,plic-1.0.0 + - spacemit,k1-plic - const: riscv,plic0 deprecated: true description: For the QEMU virt machine only From patchwork Thu Jun 27 15:31:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808483 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 31DB91990C8; Thu, 27 Jun 2024 15:33:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502388; cv=none; b=AmjYURdAqRt1yl61CEFzzTW07oXr1iNsYVwY3Lq1aeQj1ifwkaCG4rqEv6oqhn4Iq+S5jzQOF1wVERifQOXE/dLUP7XPc3JDNWbtatJ3eG0/g527F8XD0Oj+PqpJOwzN+tvw/E7lwrk7BaiZ4LqpVEf7M5u8KXlYWmkqXJxEJbc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502388; c=relaxed/simple; bh=PY2po3Bj1ntABWK9fjq/vZkGFvJuu4tsugdfHT2EW8c=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ERHotu1Yo8tdLem2g7xnvBAll55OLlIGhXaseAGXMW5caLLLCS46jPz7I6MN5VpiSORml4mYbe8y+MpBXROii3bUfmLPZ1tOSGYsJvODDhNFa1vqI/M+YuNHymrkJYPr+lnIaehq2a3b7km6vg4TTfc74x6BBRCo/kWgRBWnVnI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:20 +0000 Subject: [PATCH v2 06/10] dt-bindings: serial: 8250: Add SpacemiT K1 uart compatible Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-6-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=912; i=dlan@gentoo.org; h=from:subject:message-id; bh=PY2po3Bj1ntABWK9fjq/vZkGFvJuu4tsugdfHT2EW8c=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXw/GQEZbe7eW7M8+DhxCJ+QctBkEXA5bFaA iwAqjq4eJeJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F8F8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277WgPD/4+Xbup6V8OAAoD4k qsXY9JGINTyKvqveMpMIKBwYjhSI2xFLL6fQ5o/Qd5uVBa6NuyZnHSwXUqnKeVWnSa7nQ9AL6Li RRpZdXw9951HgEpzQwu93CUMha05DHboE+tgPOTKWiJZQ7w4sSUpX+X1Xm+uBupzejqXiARkMRM HPm00GsJtlXHPHIBdMNucOq6Vojshvt+bGldVGmncB6yjwMqIYmraJYAdhSSFxK2nWo1s2mW5aj v0V8UdidueFQM32jH8Eq0J/zfJ/hj7Cv3Shgrmw/xfA8C4MqD9H1PiT4i/kdQTKtF99cPTrN4QV pCcGKhKu58alylHYsf+4yw7vyfExK7TkhhuCylLOp2rRl73UM20OVokfG8EYUJLujBK4bs+xJUo QkoaPnBoK/pKp9J7i9VAzKGsaMSjZgkAYcS03exdLpbebNTykf8jTX3UuaaS/EthFTTSk+qhnJh eSU8relM4j7kbYb4fJSEY8kOyWUX4YxaYGc0RK0BP2F9BMvXxLyyviFzGrANrZg6TUI7rTph5lX p0WrOM2L0ptY3TS30TacRg8I2uwm0/U9dzheSh8V5Cf9wBFUsCcYX1NvmmtMjq31Rp3EYHea27Q ST3galSSdgOcT53TaAQTJDMQQ7sdXZUCT4Pj5+fAodawZig2K3sGNIm+npRfoDmSKVTQ== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 Found SpacemiT's K1 uart controller is compatible with Intel's Xscale uart, but it's still worth to introduce a new compatible. Signed-off-by: Yixun Lan --- Documentation/devicetree/bindings/serial/8250.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/serial/8250.yaml b/Documentation/devicetree/bindings/serial/8250.yaml index 692aa05500fd5..0bde2379e8647 100644 --- a/Documentation/devicetree/bindings/serial/8250.yaml +++ b/Documentation/devicetree/bindings/serial/8250.yaml @@ -111,7 +111,9 @@ properties: - mediatek,mt7623-btif - const: mediatek,mtk-btif - items: - - const: mrvl,mmp-uart + - enum: + - mrvl,mmp-uart + - spacemit,k1-uart - const: intel,xscale-uart - items: - enum: From patchwork Thu Jun 27 15:31:21 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808097 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 10BED1990D7; Thu, 27 Jun 2024 15:33:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502395; cv=none; b=el7N3AeUFK9AeYRy0X9EfZBrt07w7FcvgfdAH/L3ILbUVYfNie9MagmNOFsDqcK5a/2dyBsqvDAxfUJ1sndf0Z69ZI5SHOUMj3K4dznLO5UmHy8nrdNc6CnKam+vnUOrJ9P9asNHrfD5la0uwDkoDhylW61LkVcE9+T1/8HumGg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502395; c=relaxed/simple; bh=CAL0vdt0flm+CxBpNXo287Pud+nKkSL1SkpFxjKhTbw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=h2j9osOgdDEWLwYqSWp8uMxWL26u/zmGxDavA0VKQj6njZNKuslocJuXmCpGvVygDVCRYfV5ReaMQbopUA07+f3WzWq4phTaIeaHKzaz+Ol+ykihJDDri57SBtrWQ++aDykpCzxi+IZowdaTD0hKZ01xav2W4ezR/+r24C6C+2U= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:21 +0000 Subject: [PATCH v2 07/10] riscv: add SpacemiT SOC family Kconfig support Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-7-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=803; i=dlan@gentoo.org; h=from:subject:message-id; bh=QhxdebjQDEUABfeb5LjQhHiNUi7MTwtATrqBh8H66dg=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYXzmTS+2JpnJbJvoOONQhD++Wfb8XmCgGE/+ sYRZ006SfCJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F818UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277R2XD/9bCRE0TdkI2qNV+6 EysBBloVSrobHMW3LIZaChi7LyJbMzgp9FdMj5100Ha55aO4k7tA1k+Qpqb72fo5DmUvglFJrnC vGgFNiZPaN6xiXVwmXc41KxeecKuCkDAbt2CdhOE3ASyQIBBb5bltniozZps5tTmoigI3JsRELM OaN/KbI0Hp0Z0dwQT7XBLeIdU/uo1dcPR1neRyrp/xNFSwlsFx5q9jIgmfRZ5Zcu0exIFi+Wzl6 +bJsCc8VfLMNJkGKIekTEUZtw98eC/YYSEo1Bu0lh0G3pxLleCOTKD8wd58SDU59NXvot6orvxy s8nRqZU7MSmDVpcTc19vvUiECXCvGYtMRysOrZnAt8C+DWRdUwHGLE8IAkgnlDNJNTLqzWqmcDd 9CPY2wXpmItnKPW1aNFF8a4j890wvTlb1kki3nEvePjJpVAbqoSqUOrbtPX3RI8oiy8sMTx4Tth rjApkBWRW+K36NDdDncoe8ZUlXYqExyaS3iVGFLM509orSD1/t8yD5eMpsveflwClJMSZpmnsCw /HEhcMlUnD9KmZa3xVHZOMzylQjKEK8RVyzjhMKctzY8n/S8Zd1fRgNsDoxli6kJUR6o9tsRHn/ blu2ZX7wab3ziNdvbUBp++B4o/jn5BRgicz36Xy1s/wtjrYaEqvN54afcu2FeC/KBlVw== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen The first SoC in the SpacemiT series is K1, which contains 8 RISC-V cores with RISC-V Vector v1.0 support. Link: https://www.spacemit.com/en/spacemit-key-stone-2/ Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan --- arch/riscv/Kconfig.socs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/riscv/Kconfig.socs b/arch/riscv/Kconfig.socs index f51bb24bc84c6..1916cf7ba450e 100644 --- a/arch/riscv/Kconfig.socs +++ b/arch/riscv/Kconfig.socs @@ -24,6 +24,11 @@ config ARCH_SOPHGO help This enables support for Sophgo SoC platform hardware. +config ARCH_SPACEMIT + bool "SpacemiT SoCs" + help + This enables support for SpacemiT SoC platform hardware. + config ARCH_STARFIVE def_bool SOC_STARFIVE From patchwork Thu Jun 27 15:31:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808482 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id ACAD0199233; Thu, 27 Jun 2024 15:33:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502403; cv=none; b=YSHPkbVDMbLY3JnHx/VMi98Ei/i1Tr8CaIipTSRN8uPcb47kC8TleCSjW9PTWGlXdIJR/ETll5Q0GRHTlWP7WZtBS4Qy9FQu+mA3UItgJPnWqMZwXtBhOEI/1q2yfSo4aXsoINqQAOu0nX5ff0S8bNT36XGFVrPA0FJB7hVa6vA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502403; c=relaxed/simple; bh=z3fLiCJSdRgubps9W4RLfSbnpXl1zvy0tSgQVmdR+Wg=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=aeWwKjNvv6M+Tix3Y2KdhPfwOEov4NDCL2cBOYpY15sS/xGHfF4nvBJcucOUZjEM6P5j4djlP6IRm86VfUPBSpXr6uE3AnR60M3QbmhGwIu9qkemC0kDh9TNhQTnZBhpBl/XZV6bbXA5muBYh4zETXG8hxq0rIPudMZIcmY93RQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:22 +0000 Subject: [PATCH v2 08/10] riscv: dts: add initial SpacemiT K1 SoC device tree Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-8-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=13783; i=dlan@gentoo.org; h=from:subject:message-id; bh=84b45fPNb/ONvNlA2uWSp8nduFgNul1nN8A4r4JM+qE=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYX2whu8Wm+n1z858O/xksgm1qXxkMNKx2YRv gx95VAWd1uJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F9l8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277RxXD/4lS3DHNPzxRtLwWd OOgqzGbJ1CG7x/L/bW7uZ3C4vFDpu+1ULpzY1thn2ELC1QAuA8E/yT2dMuFTRbcS19/uMqf5mni 8YWGbx/In4B6el8piUGY/nIFgFeHB+tqcXZ1XJdhqXYz+Mxl3QKjof0+72ZlWjdalJm6teTrczQ fe2Jj1OJgpQGqhJCTFpyyF5k+PvBxPN1/UMXOSAwryxnoZyKxGKaA6MZqIaGSakYihCSRYvLKD+ Es1yEh9Wkn/bqrOGMKOcO+XO+AxGfeT9C3lsdiBtFSRUzjFqm/eNKRkPCBkPsJzbkW5WAiVjVwr Elx19N2BePpLSurCekA3RuCppso/UQ7VfW4xEQ+Z1p8+fioDCa/K/EEdDJrnpc8lWdNIG+Gt6Bi pazeI8Q//hom7TdXYP8NtF1QoCbcmcwch+RHvwe+ShBe/UC6yT8/Un9EO/ltA15W63uvq75X68B 3ThqCzgyJdaBss456uNL/aKGph6cZj7+Qo0MjaPXLxSFCm8KWj5N4BmZASmBHLT+bvSBMZzy92F fZXjSpbo9wsGYKA7ARv5S6eqFsj5SlFm1LRMAkgtSK/n120cKNIa3psF/xQo5lbyyMdCRv/l01N pc+WfkpJVEh84vjFF6KekMk0CHCVbJ3C9D64HClgAeb7t42oJtWvuFxFXR4jd1VSlf0w== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Banana Pi BPI-F3 motherboard is powered by SpacemiT K1[1]. Key features: - 4 cores per cluster, 2 clusters on chip - UART IP is Intel XScale UART Some key considerations: - ISA string is inferred from vendor documentation[2] - Cluster topology is inferred from datasheet[1] and L2 in vendor dts[3] - No coherent DMA on this board Inferred by taking vendor ethernet and MMC drivers to the mainline kernel. Without dma-noncoherent in soc node, the driver fails. - No cache nodes now The parameters from vendor dts are likely to be wrong. It has 512 sets for a 32KiB L1 Cache. In this case, each set is 64B in size. When the size of the cache line is 64B, it is a directly mapped cache rather than a set-associative cache, the latter is commonly used. Thus, I didn't use the parameters from vendor dts. Currently only support booting into console with only uart, other features will be added soon later. [1] https://docs.banana-pi.org/en/BPI-F3/SpacemiT_K1_datasheet [2] https://developer.spacemit.com/#/documentation?token=BWbGwbx7liGW21kq9lucSA6Vnpb [3] https://gitee.com/bianbu-linux/linux-6.1/blob/bl-v1.0.y/arch/riscv/boot/dts/spacemit/k1-x.dtsi Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan --- arch/riscv/boot/dts/spacemit/k1.dtsi | 378 +++++++++++++++++++++++++++++++++++ 1 file changed, 378 insertions(+) diff --git a/arch/riscv/boot/dts/spacemit/k1.dtsi b/arch/riscv/boot/dts/spacemit/k1.dtsi new file mode 100644 index 0000000000000..a46149b0b9ff8 --- /dev/null +++ b/arch/riscv/boot/dts/spacemit/k1.dtsi @@ -0,0 +1,378 @@ +// SPDX-License-Identifier: GPL-2.0 OR MIT +/* + * Copyright (C) 2024 Yangyu Chen + */ + +/dts-v1/; +/ { + #address-cells = <2>; + #size-cells = <2>; + model = "SpacemiT K1"; + compatible = "spacemit,k1"; + + aliases { + serial0 = &uart0; + serial1 = &uart2; + serial2 = &uart3; + serial3 = &uart4; + serial4 = &uart5; + serial5 = &uart6; + serial6 = &uart7; + serial7 = &uart8; + serial8 = &uart9; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + timebase-frequency = <24000000>; + + cpu-map { + cluster0 { + core0 { + cpu = <&cpu_0>; + }; + core1 { + cpu = <&cpu_1>; + }; + core2 { + cpu = <&cpu_2>; + }; + core3 { + cpu = <&cpu_3>; + }; + }; + + cluster1 { + core0 { + cpu = <&cpu_4>; + }; + core1 { + cpu = <&cpu_5>; + }; + core2 { + cpu = <&cpu_6>; + }; + core3 { + cpu = <&cpu_7>; + }; + }; + }; + + cpu_0: cpu@0 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <0>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu0_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_1: cpu@1 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <1>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu1_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_2: cpu@2 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <2>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu2_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_3: cpu@3 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <3>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu3_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_4: cpu@4 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <4>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu4_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_5: cpu@5 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <5>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu5_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_6: cpu@6 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <6>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu6_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + cpu_7: cpu@7 { + compatible = "spacemit,x60", "riscv"; + device_type = "cpu"; + reg = <7>; + riscv,isa = "rv64imafdcv_zicbom_zicbop_zicboz_zicntr_zicond_zicsr_zifencei_zihintpause_zihpm_zfh_zba_zbb_zbc_zbs_zkt_zvfh_zvkt_sscofpmf_sstc_svinval_svnapot_svpbmt"; + riscv,isa-base = "rv64i"; + riscv,isa-extensions = "i", "m", "a", "f", "d", "c", "v", "zicbom", + "zicbop", "zicboz", "zicntr", "zicond", "zicsr", + "zifencei", "zihintpause", "zihpm", "zfh", "zba", + "zbb", "zbc", "zbs", "zkt", "zvfh", "zvkt", + "sscofpmf", "sstc", "svinval", "svnapot", "svpbmt"; + riscv,cbom-block-size = <64>; + riscv,cbop-block-size = <64>; + riscv,cboz-block-size = <64>; + mmu-type = "riscv,sv39"; + + cpu7_intc: interrupt-controller { + compatible = "riscv,cpu-intc"; + interrupt-controller; + #interrupt-cells = <1>; + }; + }; + + }; + + soc { + compatible = "simple-bus"; + interrupt-parent = <&plic>; + #address-cells = <2>; + #size-cells = <2>; + dma-noncoherent; + ranges; + + plic: interrupt-controller@e0000000 { + compatible = "spacemit,k1-plic", "riscv,plic0"; + reg = <0x0 0xe0000000 0x0 0x4000000>; + interrupts-extended = <&cpu0_intc 11>, <&cpu0_intc 9>, + <&cpu1_intc 11>, <&cpu1_intc 9>, + <&cpu2_intc 11>, <&cpu2_intc 9>, + <&cpu3_intc 11>, <&cpu3_intc 9>, + <&cpu4_intc 11>, <&cpu4_intc 9>, + <&cpu5_intc 11>, <&cpu5_intc 9>, + <&cpu6_intc 11>, <&cpu6_intc 9>, + <&cpu7_intc 11>, <&cpu7_intc 9>; + interrupt-controller; + #address-cells = <0>; + #interrupt-cells = <1>; + riscv,ndev = <159>; + }; + + clint: timer@e4000000 { + compatible = "spacemit,k1-clint", "sifive,clint0"; + reg = <0x0 0xe4000000 0x0 0x10000>; + interrupts-extended = <&cpu0_intc 3>, <&cpu0_intc 7>, + <&cpu1_intc 3>, <&cpu1_intc 7>, + <&cpu2_intc 3>, <&cpu2_intc 7>, + <&cpu3_intc 3>, <&cpu3_intc 7>, + <&cpu4_intc 3>, <&cpu4_intc 7>, + <&cpu5_intc 3>, <&cpu5_intc 7>, + <&cpu6_intc 3>, <&cpu6_intc 7>, + <&cpu7_intc 3>, <&cpu7_intc 7>; + }; + + uart0: serial@d4017000 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017000 0x0 0x100>; + interrupts = <42>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + /* note: uart1 skipped */ + + uart2: uart@d4017100 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017100 0x0 0x100>; + interrupts = <44>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart3: uart@d4017200 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017200 0x0 0x100>; + interrupts = <45>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart4: uart@d4017300 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017300 0x0 0x100>; + interrupts = <46>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart5: uart@d4017400 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017400 0x0 0x100>; + interrupts = <47>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart6: uart@d4017500 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017500 0x0 0x100>; + interrupts = <48>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart7: uart@d4017600 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017600 0x0 0x100>; + interrupts = <49>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart8: uart@d4017700 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017700 0x0 0x100>; + interrupts = <50>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + + uart9: uart@d4017800 { + compatible = "spacemit,k1-uart", "intel,xscale-uart"; + reg = <0x0 0xd4017800 0x0 0x100>; + interrupts = <51>; + clock-frequency = <14857000>; + reg-shift = <2>; + reg-io-width = <4>; + status = "disabled"; + }; + }; +}; From patchwork Thu Jun 27 15:31:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808096 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A671C199233; Thu, 27 Jun 2024 15:33:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502409; cv=none; b=Qkt1N593P7MP9+rA7Vf+pb5ecncwtE9HuttEoABXaka4vN2G5gP7Rd7eh5irdsUjer9zklgXpNlli0u0l97bog+TUg5JCh3xFhn+f63OS/r+chOiZUaUDdxMkbBsNi2lK3SbImpQP4Rb0zj8XFwQSN61Pe0eZt1b0Xd1si2tanc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502409; c=relaxed/simple; bh=01mjDMhbjRjSEE5AA9vLXMq3HgswYmRlYpL7yJZwxco=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=oigLB4GrZelfwlqkcjvdZ5nWkMr5DWXBZdH3T0vowmi/8gYA2gAAhccpiktLbN3rCSehrxGImpHEPwHRZ8gukfZ7dkea93oieS3y98f+mzr/h4R6PsTPZgZF5mKxqOq+a9wdcdeTdArC1frdVpltyHGmCDHLT2XNryd67nAR1Xc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:23 +0000 Subject: [PATCH v2 09/10] riscv: dts: spacemit: add Banana Pi BPI-F3 board device tree Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-9-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1945; i=dlan@gentoo.org; h=from:subject:message-id; bh=XJLCzjRr75gc7h7vfB2sTI/M5qxrnuiigx/hYD6tFcQ=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYX6rt2CZqbs2ZrI1XnrgAw8eQgOlBFn3veuy wxEByUttOyJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F+l8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277fq3EACS0Y4Z9v5pkgv6R0 7/+nVsL1VELgHJIjkTzTAcDqJohWiTxGPEcNHA6Xaxz6p8AdpksBDPLFKS/GQIazltA3nV35GRz I9D9PmclgGdynhL6gQRpwqgwleEp6oa1x+bmf3+6eSR3NywdD2EOXHsM5MPVirdrKVLoXwND5Ks vCIkoOS1q5BegkuGgGTDHHfg535cCur9hR9lxCTXnZd+lsU4iDdzIR7qe9I4en2HWiCfQJbT+Qg sXjyXl0bh5BDzi5SNlYwkZPaDcSkgzwPztlWG/KfSe+uDRFBMHl6VO6REfl3EWHe+wRv1cEaHDl b9LZldNSZvrtQqN6TaKUAwPTDbUIILYF5siC1DUmtZ2JuOOV171SE7ZzqjyE+9JFfyVRYAtiGdP aSWU6u4BLIl4wdJRk3FQL7Ej2814CauoJQKvVG/vug8eVhpeltIq837wh3HkzE1KRr3Z1SwcX+B yzuGKfQ0SDxM57IeL+G75cvRS2V4+2ednw0N+tB3/9kxAAU1102xvafSz2IOUwfvDlzNpCO6zFS 6FhQyKo+beAmn6XFTb5/qfVXzJOcofj2Vs9N49hKFPQEPV2a1O0tkrrIrDS1Sz71kA/Ufnf1hiZ Oy+najVK0JGHMZ5L9y1gkjj4HGbSWuHF3nIsD+Oo7YU0iptWvUB0qPerkVBKu7OkH16Q== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Banana Pi BPI-F3 [1] is a industrial grade RISC-V development board, it design with SpacemiT K1 8 core RISC-V chip [2]. Currently only support booting into console with only uart enabled, other features will be added soon later. [1] https://docs.banana-pi.org/en/BPI-F3/BananaPi_BPI-F3 [2] https://www.spacemit.com/en/spacemit-key-stone-2/ Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan --- arch/riscv/boot/dts/Makefile | 1 + arch/riscv/boot/dts/spacemit/Makefile | 2 ++ arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts | 19 +++++++++++++++++++ 3 files changed, 22 insertions(+) diff --git a/arch/riscv/boot/dts/Makefile b/arch/riscv/boot/dts/Makefile index fdae05bbf5563..bff887d38abe4 100644 --- a/arch/riscv/boot/dts/Makefile +++ b/arch/riscv/boot/dts/Makefile @@ -5,6 +5,7 @@ subdir-y += microchip subdir-y += renesas subdir-y += sifive subdir-y += sophgo +subdir-y += spacemit subdir-y += starfive subdir-y += thead diff --git a/arch/riscv/boot/dts/spacemit/Makefile b/arch/riscv/boot/dts/spacemit/Makefile new file mode 100644 index 0000000000000..ac617319a5742 --- /dev/null +++ b/arch/riscv/boot/dts/spacemit/Makefile @@ -0,0 +1,2 @@ +# SPDX-License-Identifier: GPL-2.0 +dtb-$(CONFIG_ARCH_SPACEMIT) += k1-bananapi-f3.dtb diff --git a/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts b/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts new file mode 100644 index 0000000000000..023274189b492 --- /dev/null +++ b/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: GPL-2.0 OR MIT +/* + * Copyright (C) 2024 Yangyu Chen + */ + +#include "k1.dtsi" + +/ { + model = "Banana Pi BPI-F3"; + compatible = "bananapi,bpi-f3", "spacemit,k1"; + + chosen { + stdout-path = "serial0"; + }; +}; + +&uart0 { + status = "okay"; +}; From patchwork Thu Jun 27 15:31:24 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yixun Lan X-Patchwork-Id: 808481 Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EB44523BE; Thu, 27 Jun 2024 15:33:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502417; cv=none; b=dT9XlOKXcb7QENXFx5cH4FlMdPScpVXOsaO/vXZXwMadrQvF6vjc9L2WNvonR9zaHrL7dZVTIiQ/poRy8gjhjrTqaG31ZI2EpAROcpwpX8uEXipZczYKhbfU9rYrAw10p1IQk44nBGh31IZVtmJYOBAoK9OJUAFtu3HT/2kzWGw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1719502417; c=relaxed/simple; bh=sjhvfdn3QVidrXxxOLsJ8Iays3T/xDMwydCui3MqP+g=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=poT+OgS+LQUjqSvfgQjiCLPIbLLyzui/b4OLe8mw0UzYexoUMjpQXaIbG5W5HMybCvRScubVe0iPJrIF21EQCSo0TZvaYSKZL2HIBwqpKSzA735BOJt3nWzE96XO23t2Ws2dCxBCwPvya60vYJMaNwlcjKMGZKR2zCYdezNDdbw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org; spf=pass smtp.mailfrom=gentoo.org; arc=none smtp.client-ip=140.211.166.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gentoo.org From: Yixun Lan Date: Thu, 27 Jun 2024 15:31:24 +0000 Subject: [PATCH v2 10/10] riscv: defconfig: enable SpacemiT SoC Precedence: bulk X-Mailing-List: linux-serial@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240627-k1-01-basic-dt-v2-10-cc06c7555f07@gentoo.org> References: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> In-Reply-To: <20240627-k1-01-basic-dt-v2-0-cc06c7555f07@gentoo.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou , Daniel Lezcano , Thomas Gleixner , Samuel Holland , Anup Patel , Greg Kroah-Hartman , Jiri Slaby , Lubomir Rintel Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Palmer Dabbelt , linux-riscv@lists.infradead.org, linux-serial@vger.kernel.org, Inochi Amaoto , Meng Zhang , Yangyu Chen , Yixun Lan X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=694; i=dlan@gentoo.org; h=from:subject:message-id; bh=0K4ao+VU11AdvF+9uh5x4EN2IBtmFYnrwob9vqhF5jE=; b=owEBzQIy/ZANAwAKATGq6kdZTbvtAcsmYgBmfYX95TEqSfytY8nhsyKLbPKKtiu66fvm/DZGw igFFx7X+taJApMEAAEKAH0WIQS1urjJwxtxFWcCI9wxqupHWU277QUCZn2F/V8UgAAAAAAuAChp c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0QjVCQUI4QzlDMzF CNzExNTY3MDIyM0RDMzFBQUVBNDc1OTREQkJFRAAKCRAxqupHWU277Z0PEACbVCFa7pvmng4Xz0 58UY88QmMGAR0UL/tB5Ag4oPNQKQX0VdrLoYcRsv84toABHKLJJ02XgfR/xBKC6TmcFid+m8rro 5FDSCQxgNZgDCZJST95bu1b+90Z2F7lkZ0CeD6LiJ4WPSb8zUNbjg3EUFQ3z1i47vEnWSbi3Nv2 9Lep8tCguQudnUxrTUrSC+BckMqD6MZmvOxUwFu2qDahl7KFEIGklpwAX/8p4Qs9447MPdyGb7D jJO4znTG7VKvIyuLV6AcpanVkdNmr2+9346yhbKFCsNlX4t94cAW9+xjjbCuFDKTRoPG0PBgeNn f2dQc8GdrkjUUvqVIyJcd0TpwCIsQ+NQ0byZS1rZnXxAakNt1d1y0gixI2tUcZEek4eVAv+8gGZ YcGpF2CXHWfCoeQBEgUosB8GY+jiH7/8UG37ug3zuUZDWzaKxgZ5+jMjpb8oN/OaziKQoNwkjUp A2mcHuob7zMTgcgrTb3A6RSt1HRPruSyXpv8kVwLaWzasFZaKpUgKL2f2F8AxrSIJzKZFUMBRcZ ca9qPPkJ6oPJMSX/EyYkoBgQdsDV6eQtwlrOflRPYYOO0U0t3GBiUd3VN5MdAlblPZp0EZoAfZ1 MYiDvhsUVmTIkfuiv6I77pyQ5F+p5etJoK6N5BnfHVzp6k2XOKIt/GFe+cEWV0TkbTdQ== X-Developer-Key: i=dlan@gentoo.org; a=openpgp; fpr=50B03A1A5CBCD33576EF8CD7920C0DBCAABEFD55 From: Yangyu Chen Enable SpacemiT SoC config in defconfig to allow the default upstream kernel to boot on Banana Pi BPI-F3 board. Signed-off-by: Yangyu Chen Signed-off-by: Yixun Lan Reviewed-by: Conor Dooley --- arch/riscv/configs/defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/riscv/configs/defconfig b/arch/riscv/configs/defconfig index 12dc8c73a8acf..5287ae81bbb78 100644 --- a/arch/riscv/configs/defconfig +++ b/arch/riscv/configs/defconfig @@ -29,6 +29,7 @@ CONFIG_ARCH_MICROCHIP=y CONFIG_ARCH_RENESAS=y CONFIG_ARCH_SIFIVE=y CONFIG_ARCH_SOPHGO=y +CONFIG_ARCH_SPACEMIT=y CONFIG_SOC_STARFIVE=y CONFIG_ARCH_SUNXI=y CONFIG_ARCH_THEAD=y