From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-oo1-f45.google.com (mail-oo1-f45.google.com [209.85.161.45]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D55B2123; Fri, 8 Dec 2023 12:24:38 -0800 (PST) Received: by mail-oo1-f45.google.com with SMTP id 006d021491bc7-58a7d13b00bso1199267eaf.1; Fri, 08 Dec 2023 12:24:38 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702067078; x=1702671878; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=LeRUCnhIs+MjcZMf3INslFBDe93yrMCfKLt3hZl/RSc=; b=nZoFGw6gw9S8zD1MRl1q4u0bJ6Zm/ALRjtgGDCdIL/tZtwcsBO4awm6opzQtYSnvt8 hhntsgdpO1Vaycy537f0+AR0aeU2NuDT1WWoMmrGxW6CkmqFXL/IvFrGnz4tjdjsutRA 7LOEoHAy74va2Sfmjqe0oMI/sTMJnvyAHcxmZbOwGtlbVU8ilRU/pyYrMmBixDnbpBJe DtDNyjbvUQFRDsHu+Ze8JtfnIiZ93qVC1D2Kv6EYFbVd8g5AbnQJsf6y30UUlSVLY1Dq n8ws1kxtTCSfI08O3FYVCS6ejINvR2C1LrH9WBYeQsTe+Bgl7cVu9HGndCuxYG/d6H0i molA== X-Gm-Message-State: AOJu0YxEEQQ3jnHehqMXJI+9is886uBGnVriShLFigfWA7cVGiwAkPjN HKnMeT9GKHFtOq600goBcA== X-Google-Smtp-Source: AGHT+IGz484CJxbMb/7Ut+O1ziOtwwClOSy6kCgdo6DSvH32Bmk/xC2cWOZaQtMZG0tYjzEef8Zf0A== X-Received: by 2002:a05:6820:2294:b0:590:6b74:3bc3 with SMTP id ck20-20020a056820229400b005906b743bc3mr817431oob.2.1702067078109; Fri, 08 Dec 2023 12:24:38 -0800 (PST) Received: from herring.priv (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id t9-20020a4a7609000000b0058d76e8ce0dsm430434ooc.36.2023.12.08.12.24.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Dec 2023 12:24:37 -0800 (PST) Received: (nullmailer pid 2644655 invoked by uid 1000); Fri, 08 Dec 2023 20:24:36 -0000 Date: Fri, 8 Dec 2023 14:24:36 -0600 From: Rob Herring To: Krzysztof Kozlowski Cc: Suzuki K Poulose , Mike Leach , James Clark , Krzysztof Kozlowski , Conor Dooley , Andy Gross , Bjorn Andersson , Konrad Dybcio , Mao Jinlong , Hao Zhang , Tao Zhang , coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: Re: [PATCH 1/3] dt-bindings: arm: coresight: restrict single port subnodes Message-ID: <20231208202436.GA2627018-robh@kernel.org> References: <20231206115332.22712-1-krzysztof.kozlowski@linaro.org> Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231206115332.22712-1-krzysztof.kozlowski@linaro.org> On Wed, Dec 06, 2023 at 12:53:30PM +0100, Krzysztof Kozlowski wrote: > "in-ports" and "out-ports" with single "port" subnode should use > "additionalProperties: false" to disallow any other properties mentioned > by graph schema which are not applicable for this case, e.g. > "address-cells". The graph schema should already check this case with this subschema: oneOf: - required: - port - required: - "#address-cells" - "#size-cells" However, I now see this would allow port and #address-cells if #size-cells is omitted. (#address-cells is a dependency for ##size-cells, but not vice-versa because interrupt-controllers can have ##just #address-cells). Perhaps this should instead be: oneOf: - required: - port - anyOf: - required: - "#address-cells" - required: - "#size-cells" We're missing a similar check on endpoint. Or I'm forgetting why I didn't add it. I suspect there are a lot more cases if we fixed these in the users. Rob 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 B4D9DC4167B for ; Fri, 8 Dec 2023 20:25:07 +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=3Gh63KtAsYO9wF+ED2h+sh7OZRSFX7B8cf5PY6qS9kM=; b=jeFGOpt9mdhb23 hgT2J9bKxtMX+BF7Lo746s20CCYR3zYZg1ye+4fH4VUQNmEXNoR3v0ElzkqOo9LpCLZS4yBwamu7U 36zGSQVKKwcJjd4+08/2vctL/X3CQ9OMb7cSRr2OcD4CbBxAuZnleXsEFPtS94+nzuANoKAfP3NLU oqV6whewlnuByvZU83CWdd3VSraejgT5BDwqKvYdJO6hGQvA/OWlJq3SJU6HMaBeo9eWZ4s3dG3FN 1prrGcrFlS0qVTd0Tn1yfBvAIkL1kuG+UIT2z11zMpfROsaEqOezHA5s2pTieWdfF3NSV9Of81T9x ZhB7NlxWih01QF3KHjrw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rBhOt-00GTzP-0n; Fri, 08 Dec 2023 20:24:43 +0000 Received: from mail-oo1-f45.google.com ([209.85.161.45]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rBhOq-00GTyr-0k for linux-arm-kernel@lists.infradead.org; Fri, 08 Dec 2023 20:24:41 +0000 Received: by mail-oo1-f45.google.com with SMTP id 006d021491bc7-5906eac104bso1188425eaf.2 for ; Fri, 08 Dec 2023 12:24:38 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702067078; x=1702671878; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=LeRUCnhIs+MjcZMf3INslFBDe93yrMCfKLt3hZl/RSc=; b=NhT5C0MAoWTw67NQiqhFkn4pqCJdvevHc5iohHyja3siSgN/11/YCVxIu+73PMIS3X w0dab1lHIlBTkbOMxNflvGY2ttnnqgm4yct9VIcJx1dPZxKJziT49WHR54zLaadv4LhE /RXQt5E5pEj+eIzYYDoYk1BUIocpsEskz7X0i52gz/ihtH0d8h7Nayw/2Z26C5mSenoL 1noY//HfnMSbUmnSh4m9Kgw1HYgBBgHFpx/HHlwvTfXj31Ci9Gt5+sjqEHWtkB05Iu+0 QJteGoWPD97zLg9VWwIUyI/2hojiw/TFjkPPGSTzqonEN1mnGu7dclV4oMMGFEwrJhc9 ydQw== X-Gm-Message-State: AOJu0YxT/Z8+pofGWVxtijQvm3nZPuWOiw3fdrTLzLbYIGkUw4B9ZiqE JSck6pex2TNmWHIZc362mw== X-Google-Smtp-Source: AGHT+IGz484CJxbMb/7Ut+O1ziOtwwClOSy6kCgdo6DSvH32Bmk/xC2cWOZaQtMZG0tYjzEef8Zf0A== X-Received: by 2002:a05:6820:2294:b0:590:6b74:3bc3 with SMTP id ck20-20020a056820229400b005906b743bc3mr817431oob.2.1702067078109; Fri, 08 Dec 2023 12:24:38 -0800 (PST) Received: from herring.priv (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id t9-20020a4a7609000000b0058d76e8ce0dsm430434ooc.36.2023.12.08.12.24.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Dec 2023 12:24:37 -0800 (PST) Received: (nullmailer pid 2644655 invoked by uid 1000); Fri, 08 Dec 2023 20:24:36 -0000 Date: Fri, 8 Dec 2023 14:24:36 -0600 From: Rob Herring To: Krzysztof Kozlowski Cc: Suzuki K Poulose , Mike Leach , James Clark , Krzysztof Kozlowski , Conor Dooley , Andy Gross , Bjorn Andersson , Konrad Dybcio , Mao Jinlong , Hao Zhang , Tao Zhang , coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: Re: [PATCH 1/3] dt-bindings: arm: coresight: restrict single port subnodes Message-ID: <20231208202436.GA2627018-robh@kernel.org> References: <20231206115332.22712-1-krzysztof.kozlowski@linaro.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20231206115332.22712-1-krzysztof.kozlowski@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231208_122440_292175_CE62DBC3 X-CRM114-Status: GOOD ( 10.95 ) X-BeenThere: linux-arm-kernel@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-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Dec 06, 2023 at 12:53:30PM +0100, Krzysztof Kozlowski wrote: > "in-ports" and "out-ports" with single "port" subnode should use > "additionalProperties: false" to disallow any other properties mentioned > by graph schema which are not applicable for this case, e.g. > "address-cells". The graph schema should already check this case with this subschema: oneOf: - required: - port - required: - "#address-cells" - "#size-cells" However, I now see this would allow port and #address-cells if #size-cells is omitted. (#address-cells is a dependency for ##size-cells, but not vice-versa because interrupt-controllers can have ##just #address-cells). Perhaps this should instead be: oneOf: - required: - port - anyOf: - required: - "#address-cells" - required: - "#size-cells" We're missing a similar check on endpoint. Or I'm forgetting why I didn't add it. I suspect there are a lot more cases if we fixed these in the users. Rob _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel