From patchwork Thu Jun 15 22:50:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Conor Dooley X-Patchwork-Id: 108738 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp974558vqr; Thu, 15 Jun 2023 16:22:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ47KC4HjtQNNCkBwGLbHyroH6UIHhgGuBTH3DBwOJ2zWhwNDMrqpfmMnPPdB/QBDOO36mo7 X-Received: by 2002:a05:622a:14c6:b0:3f5:39a7:1b9e with SMTP id u6-20020a05622a14c600b003f539a71b9emr451698qtx.56.1686871357195; Thu, 15 Jun 2023 16:22:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686871357; cv=none; d=google.com; s=arc-20160816; b=1H1Xus97KCtncz/EjWei2B8h5xI/+2l59ueyTbiqI4TZDFuZwfuQLXR4ZmYAVQHsLu L3R9Y9EjI/01CZhbcch3LjwBFxmqLhiViyr0StSZEAGHcmRfxrEXn0GTZHk2pnelU0yr f+rXZMItQ0ae5nHj6Caa74ZtOaxgXLo140Q1XqbGqQaQptUK+PcXvllKa5g1/2PtEEOa q9EWnVnCm18VFSWLtUwS6E0grlPV8NEAisDdvemdymBxJVaCzwDh6y3vDXOSGqm4AsP0 PfJmJHwDfEhJb4uF4t/X8QeRYKIsYeAtCBQF4qW1Z7n16+iqrNZVoPY8mwX6fdQV9wsP s61g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=vdM6kuv2gqxqtvf5lNExvYL0MdxP231tZLkA104WBeU=; b=QuWSJ6jQHB2HVDCfQ78sGIIHhgS0Vt1k2uU5DFvpQYmzRnf9BGwdFsnoagCkzfvUVB 5ZDWp8+42gk8SpXtdK8PdepeZcfnjS46RUUwg5lO0fstxNFX4KF4apOJZoynJD/aZQGw 1aswXzHZRwonZJA5mwK3Z9jXgCDi4JLMhfBtKQkExT5wNriVTnK83oCcLFwIZSE4f/jg qmQKybnQxPwJEVxMVX1Ukntgf7GrIGgKD+8d1hxzyzuphTrUBw+1OQrH1PxWpNSE0+6X FdBu71VUDk2Gof8lW9EQWma2jpp1XwKEW3RnqTUdf2LcVXQ0pnrORIWH4cH965GntMAZ Z+aA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YlHWY7F7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 20-20020a631854000000b0053fc290934dsi13339707pgy.361.2023.06.15.16.22.21; Thu, 15 Jun 2023 16:22:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YlHWY7F7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239743AbjFOWy5 (ORCPT + 99 others); Thu, 15 Jun 2023 18:54:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37884 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238937AbjFOWyz (ORCPT ); Thu, 15 Jun 2023 18:54:55 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BCBA2272A; Thu, 15 Jun 2023 15:54:53 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 4BCE061BE6; Thu, 15 Jun 2023 22:54:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 89A2DC433C9; Thu, 15 Jun 2023 22:54:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686869692; bh=Df043vgm6CnnvUWCZd+vj+oFrnFuv7Ap9nxevuDGXJk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=YlHWY7F7AYPflO0rB6nuP/YL0uYkct0iT0RW4smQHkv38NoiU3x5EZpgJDHsw712j Vp38wT2BA44kvTWC/0jULlBRzX7oyJ0gqRvCwFmbRzF5+/Zn7D5gHIFdK7d8WePt7a q9c1djYEMs0r7zJj8s7xwGz0mv6MB8TYG89M7gUn8t4G8yg8Jnjb3x58NwsKpozVPm 3AaNRwGhHTGoBdtEBYI6wwLFK6egoozkefyYjD4OEu6DKSPMdZwVlAdas2A45Waq78 mY0ZCkVPBjhsKLbhiVAtMdc4vlY2tkNveEUAuQ8t2oMb7I/x4U9n6VaQtAffjJhkLp d/7f1X5bty+Pw== From: Conor Dooley To: palmer@dabbelt.com Cc: conor@kernel.org, Conor Dooley , Rob Herring , Krzysztof Kozlowski , Paul Walmsley , linux-riscv@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/2] dt-bindings: riscv: cpus: add a ref the common cpu schema Date: Thu, 15 Jun 2023 23:50:14 +0100 Message-Id: <20230615-dubiously-parasail-79d34cefedce@spud> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230615-creamer-emu-ade0fa0bdb68@spud> References: <20230615-creamer-emu-ade0fa0bdb68@spud> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1511; i=conor.dooley@microchip.com; h=from:subject:message-id; bh=xnf8UGz7+fdKaOoNLsbw78HDVnw230rwRyuBbYLfg8w=; b=owGbwMvMwCFWscWwfUFT0iXG02pJDCndUxebKtwsSK6TCBAy6ShyYUjtPmOi/sPXT+gG59cVH ceOzzzfUcrCIMbBICumyJJ4u69Fav0flx3OPW9h5rAygQxh4OIUgIlM9GT47xnJvjnj5KeFukfl DqfV74nYoee2pvqvxfIPrfsOlGcwTmVkmPxO+7B23oY3m97O6v5sfVKvI5D5qdWH0hm7Kkvl9bq K+QA= X-Developer-Key: i=conor.dooley@microchip.com; a=openpgp; fpr=F9ECA03CF54F12CD01F1655722E2C55B37CF380C X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768812820021978650?= X-GMAIL-MSGID: =?utf-8?q?1768812820021978650?= From: Conor Dooley To permit validation of RISC-V cpu nodes, "additionalProperties: true" needs to be swapped for "unevaluatedProperties: false". To facilitate this in a way that passes dt_binding_check, a reference to the cpu schema is required. Disallow the generic cache-op-block-size property that that drags in, since the RISC-V CBO extensions do not require a common size, and have individual properties. Signed-off-by: Conor Dooley Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/riscv/cpus.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Documentation/devicetree/bindings/riscv/cpus.yaml b/Documentation/devicetree/bindings/riscv/cpus.yaml index 3d2934b15e80..e89a10d9c06b 100644 --- a/Documentation/devicetree/bindings/riscv/cpus.yaml +++ b/Documentation/devicetree/bindings/riscv/cpus.yaml @@ -23,6 +23,9 @@ description: | two cores, each of which has two hyperthreads, could be described as having four harts. +allOf: + - $ref: /schemas/cpu.yaml# + properties: compatible: oneOf: @@ -98,6 +101,9 @@ properties: $ref: "/schemas/types.yaml#/definitions/string" pattern: ^rv(?:64|32)imaf?d?q?c?b?k?j?p?v?h?(?:[hsxz](?:[a-z])+)?(?:_[hsxz](?:[a-z])+)*$ + # RISC-V has multiple properties for cache op block sizes as the sizes + # differ between individual CBO extensions + cache-op-block-size: false # RISC-V requires 'timebase-frequency' in /cpus, so disallow it here timebase-frequency: false From patchwork Thu Jun 15 22:50:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Conor Dooley X-Patchwork-Id: 108734 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp966891vqr; Thu, 15 Jun 2023 16:06:17 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5P+7vuerIbNghMPOfWTw0EgqrSW+p7a8OX1jikyZ3sonMFpuHDD6g8jDIziRdl8gIDR3Lx X-Received: by 2002:a05:6a20:442a:b0:110:6146:1056 with SMTP id ce42-20020a056a20442a00b0011061461056mr1213169pzb.2.1686870377035; Thu, 15 Jun 2023 16:06:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686870377; cv=none; d=google.com; s=arc-20160816; b=f6jrK6tT3MvTELvhzD1pOVxB+wecG4wdbxK5O4Q2mKhmpMbNDQNPm4tyS76mL7YPTu 6zFm5p/3rHQrm5ntFh6T4yCq9fZepA4hfAH7BzjM8XrJyIbcMWikXrWBtTlJXV2phEwC V03jvqr3hl/OfQaiZhc48zdI0i8UYdLxNo/t6qn6ZDtJ1x6peR6luJ+QUkgl3rtD8aMY vlwpuNg0sWNd8a+s999syC4DOeiqtjWfqvgPlAGL2eXDLxzGC2b/6Ju9Npc4FYD8dQjs J1S8Z7YW7WOqu3oh7WLCqY4Ihp+puKOwH7SkZQu6HYAu2YgimnQSZlpYDGvtDdmngzbp i2cg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=KgCBjy0JEot0YMnR4yut0bGXfYvIYaL0Oi1yi181yQU=; b=Iif1rcIRtNeASCCBULetGDgo2vvDY4Jjokdqy+3Fi/j2N+XSCCvzqBy+ob9EQaVyTC 0YOs1Zu1GT3liGYVTxEpqfHEmJNvXv/yVP9AOOc/HHQucXjgUm13KxAnEldoht7l1BFq gSa1Gp+snDUgtcPk/yvxHpJUEQsBU2UGEBppcz/MOEL+NVjL/LLXuFNKnfgis5/yVJPv PmVPTpvJo0ZZ3JrgDsQbdV8Ub+w/zn7mh38yR4DR9HVyYMApHu3wSz5psvVuqxk4EOr1 cdu6E/YfTl6BrFovKZgY6BTdwsyTtykZl9n7+kerzW8UyiEhxgRUiOgm5vfL7jCr1R3s 6oIw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=E7dnoqhM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s19-20020a63af53000000b0052c688e6608si13982784pgo.505.2023.06.15.16.05.58; Thu, 15 Jun 2023 16:06:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=E7dnoqhM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239937AbjFOWzG (ORCPT + 99 others); Thu, 15 Jun 2023 18:55:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37896 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232234AbjFOWy5 (ORCPT ); Thu, 15 Jun 2023 18:54:57 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 49559270E; Thu, 15 Jun 2023 15:54:56 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C8EFE61F12; Thu, 15 Jun 2023 22:54:55 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F26B3C433CA; Thu, 15 Jun 2023 22:54:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686869695; bh=uOdg4scVwQQzL8UZnROnPCCRu7Nfdm5eCRa5kHL1u3w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=E7dnoqhMqsNpKE8pAOzKNBWZs2o3jqvpczL4+qj/AnHRAbA+aMbrugl5xHi0SGH8p 3QYW/NRiH3p1pwIvE0NvC5eh8etZ52ICkyfNOYgbr8KrpW772LN1+zxnN+Eo9bA0Ga Q9upHj2X2cnQhgXHBZpU5AB5u8MiwoxTXmTB7zsNL2O+hEWZW07vQdpsnWDulbEme3 EqlDOvJGX3X1Cf7tTaSBdH+Jet1qUPYP86nbYEMLxP1KrMutgAL3sKbgmfn4hA+sGv e4yiroGQHTlUV2ClVw69H4osMbp5083FmA45b+9n2lfWrh1IobvSzbBEs3fK0+rSLs Y21RKq4cMVWrA== From: Conor Dooley To: palmer@dabbelt.com Cc: conor@kernel.org, Conor Dooley , Rob Herring , Krzysztof Kozlowski , Paul Walmsley , linux-riscv@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/2] dt-bindings: riscv: cpus: switch to unevaluatedProperties: false Date: Thu, 15 Jun 2023 23:50:15 +0100 Message-Id: <20230615-viper-stoic-1ff8efd7d51d@spud> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230615-creamer-emu-ade0fa0bdb68@spud> References: <20230615-creamer-emu-ade0fa0bdb68@spud> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=729; i=conor.dooley@microchip.com; h=from:subject:message-id; bh=u/qrBFnL9e9PAex6e6NvnAWTZV+52ZOaw3F8Q/zOFMA=; b=owGbwMvMwCFWscWwfUFT0iXG02pJDCndUxdfseKvjwla7JCU5jYp+vURlY9nUq7/K9Hpfz5/1 v5sm8Z7HaUsDGIcDLJiiiyJt/tapNb/cdnh3PMWZg4rE8gQBi5OAZjI8ysMf4WPBhXM3/362eI7 DlOZuQsNDnz3a7r51NT3r8yktv6Xhy4x/E84uNkwqIsh666IkITAudpLDw9Ov2TN+aiVfedRdq6 MDnYA X-Developer-Key: i=conor.dooley@microchip.com; a=openpgp; fpr=F9ECA03CF54F12CD01F1655722E2C55B37CF380C X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768337676726955609?= X-GMAIL-MSGID: =?utf-8?q?1768811792883581181?= From: Conor Dooley To permit validation of cpu nodes, swap "additionalProperties: true" out for "unevaluatedProperties: false". Signed-off-by: Conor Dooley Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/riscv/cpus.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/riscv/cpus.yaml b/Documentation/devicetree/bindings/riscv/cpus.yaml index e89a10d9c06b..144da86718c1 100644 --- a/Documentation/devicetree/bindings/riscv/cpus.yaml +++ b/Documentation/devicetree/bindings/riscv/cpus.yaml @@ -143,7 +143,7 @@ required: - riscv,isa - interrupt-controller -additionalProperties: true +unevaluatedProperties: false examples: - |