Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp128240iof; Sun, 5 Jun 2022 23:12:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyNqE1foeBjwQEJOkT6wWpFSpxCyYwIth41ASTKpe1TEtAU5qXvDjQAliX0kyqlvjiXo5MZ X-Received: by 2002:a63:f95c:0:b0:3fd:7e21:749e with SMTP id q28-20020a63f95c000000b003fd7e21749emr7590381pgk.49.1654495951778; Sun, 05 Jun 2022 23:12:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654495951; cv=none; d=google.com; s=arc-20160816; b=mU/rjNB9FzqN0c01nxFL7AwJrqcyMP+DE0JhbAFoy0Gj2nUfygXdvmOwbYzXK38tln 40VmmKKD5orYguyk9+XzAqpINulh8K8Iwmr9pYpUv354bq/jfEGrIJh8W+eI0mSUFzAr 8Wx0+oMDcY4wipQYKIGhLhltErFmXpNRw4SeVPzFd//RC8A3PJpS/tu+Esqbg+9vL01g Jd8so8eONiqMvqSv44QBSUymzRF2VVI8hF98i47OQn9j7j7Fug9SbKBmJuSa11myf2QT 61WtEE24yoMgS9lSz62VbLOBGLql0FqT3ltTli9CJQSN0EZNxE/8XdSbZIG+awTSoGRY OQDA== 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; bh=26LxzKjAtmzpLz3rQ+nBAAJwuvJnOiGpck4LgM4dlj8=; b=asQncEaESS4fu8T7+25kW2OxtoessTqY3x0JAwfeotyvJ+3TyDqotxybSPCUniL3SN gdfyAmEsXiM1srXYSvg06N67j8Q7VfDrBAHYxyBE7Eo1r95A01/crePDd8WmvYvSRVLR 0PaIzr8kXvRVGMOnN0xc41fIG+9Z+A4qQ1JCZVEBHaAkeCAUc/S+DH8H9vjdk5rLv933 Y3gWUd6KXnn5YKkSp2pXttvMWpNYvmhCLD5eOOqVsmd055kzW/EBMQzANn9FieF9qECm ZHNBXzZvxRfe0tRrNTvFQXWw/BHh4npAcXEiR6NkS3PrRWcUB6L1U502NF9FuM+qcdEY xcjg== ARC-Authentication-Results: i=1; mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id c81-20020a621c54000000b0051bfcba3bbbsi6981338pfc.232.2022.06.05.23.12.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Jun 2022 23:12:31 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 515175F93; Sun, 5 Jun 2022 21:51:37 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242065AbiFCBTs (ORCPT + 99 others); Thu, 2 Jun 2022 21:19:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50172 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240977AbiFCBTi (ORCPT ); Thu, 2 Jun 2022 21:19:38 -0400 Received: from mail-ot1-f48.google.com (mail-ot1-f48.google.com [209.85.210.48]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D11B13AA77; Thu, 2 Jun 2022 18:19:37 -0700 (PDT) Received: by mail-ot1-f48.google.com with SMTP id l9-20020a056830268900b006054381dd35so4613048otu.4; Thu, 02 Jun 2022 18:19:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=26LxzKjAtmzpLz3rQ+nBAAJwuvJnOiGpck4LgM4dlj8=; b=S4BL4OKa+jniJKXvGllQNRJYjpqaXHLxpJJHX7yFxdIJw9+zwzmJdDbVTW9MDcMbDA e016wsdN4rUfrPh//VniQ6l1uIOeWYDGRciq6+RlAaMDXSuNgadjbtdElx0GTR29PD/t Ozt/MZY+vZxgG9qLW/a45Fo619/IsUhn3m7YkUg1QM3xUUPenkOXbMiLkDBbZceGni7W Hhuk8hQo0vQ4V/3+QYXMjzpAkoo0m6pprid5eKraly5A+O85fJovtiNZu5QUyshDR+Fi gPxy0Zh6vyNsDQFKkGjtYjgMi6d6l3XKtiWLNlCrLFIcT6+ivnOAbq4xuhT/SvwPaFGb w2UA== X-Gm-Message-State: AOAM530Dr8DuEcp7NCYktfIbbVMhf7SLoxbJ60WgNKa1GpK8GM9re7+F Q7uXeh1RCrG+2+o6tafEeg== X-Received: by 2002:a05:6830:310b:b0:60b:1ebe:5c73 with SMTP id b11-20020a056830310b00b0060b1ebe5c73mr3185709ots.76.1654219176994; Thu, 02 Jun 2022 18:19:36 -0700 (PDT) Received: from xps15.. (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.googlemail.com with ESMTPSA id na14-20020a0568706c0e00b000f5d8d031b6sm2679746oab.49.2022.06.02.18.19.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Jun 2022 18:19:36 -0700 (PDT) From: Rob Herring To: Mathieu Poirier , Mike Leach , Leo Yan , Suzuki K Poulose , Krzysztof Kozlowski Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Krzysztof Kozlowski Subject: [PATCH v2 3/3] dt-bindings: arm: Convert CoreSight CPU debug to DT schema Date: Thu, 2 Jun 2022 20:19:33 -0500 Message-Id: <20220603011933.3277315-4-robh@kernel.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220603011933.3277315-1-robh@kernel.org> References: <20220603011933.3277315-1-robh@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Convert the CoreSight CPU debug binding to DT schema format. Reviewed-by: Leo Yan Reviewed-by: Krzysztof Kozlowski Signed-off-by: Rob Herring --- v2: - Update MAINTAINERS entry --- .../bindings/arm/arm,coresight-cpu-debug.yaml | 81 +++++++++++++++++++ .../bindings/arm/coresight-cpu-debug.txt | 49 ----------- MAINTAINERS | 1 - 3 files changed, 81 insertions(+), 50 deletions(-) create mode 100644 Documentation/devicetree/bindings/arm/arm,coresight-cpu-debug.yaml delete mode 100644 Documentation/devicetree/bindings/arm/coresight-cpu-debug.txt diff --git a/Documentation/devicetree/bindings/arm/arm,coresight-cpu-debug.yaml b/Documentation/devicetree/bindings/arm/arm,coresight-cpu-debug.yaml new file mode 100644 index 000000000000..0a6bc03ebe00 --- /dev/null +++ b/Documentation/devicetree/bindings/arm/arm,coresight-cpu-debug.yaml @@ -0,0 +1,81 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/arm/arm,coresight-cpu-debug.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: CoreSight CPU Debug Component + +maintainers: + - Mathieu Poirier + - Mike Leach + - Leo Yan + - Suzuki K Poulose + +description: | + CoreSight CPU debug component are compliant with the ARMv8 architecture + reference manual (ARM DDI 0487A.k) Chapter 'Part H: External debug'. The + external debug module is mainly used for two modes: self-hosted debug and + external debug, and it can be accessed from mmio region from Coresight and + eventually the debug module connects with CPU for debugging. And the debug + module provides sample-based profiling extension, which can be used to sample + CPU program counter, secure state and exception level, etc; usually every CPU + has one dedicated debug module to be connected. + +select: + properties: + compatible: + contains: + const: arm,coresight-cpu-debug + required: + - compatible + +allOf: + - $ref: /schemas/arm/primecell.yaml# + +properties: + compatible: + items: + - const: arm,coresight-cpu-debug + - const: arm,primecell + + reg: + maxItems: 1 + + clocks: + maxItems: 1 + + clock-names: + maxItems: 1 + + cpu: + description: + A phandle to the cpu this debug component is bound to. + $ref: /schemas/types.yaml#/definitions/phandle + + power-domains: + maxItems: 1 + description: + A phandle to the debug power domain if the debug logic has its own + dedicated power domain. CPU idle states may also need to be separately + constrained to keep CPU cores powered. + +required: + - compatible + - reg + - clocks + - clock-names + - cpu + +unevaluatedProperties: false + +examples: + - | + debug@f6590000 { + compatible = "arm,coresight-cpu-debug", "arm,primecell"; + reg = <0xf6590000 0x1000>; + clocks = <&sys_ctrl 1>; + clock-names = "apb_pclk"; + cpu = <&cpu0>; + }; +... diff --git a/Documentation/devicetree/bindings/arm/coresight-cpu-debug.txt b/Documentation/devicetree/bindings/arm/coresight-cpu-debug.txt deleted file mode 100644 index f1de3247c1b7..000000000000 --- a/Documentation/devicetree/bindings/arm/coresight-cpu-debug.txt +++ /dev/null @@ -1,49 +0,0 @@ -* CoreSight CPU Debug Component: - -CoreSight CPU debug component are compliant with the ARMv8 architecture -reference manual (ARM DDI 0487A.k) Chapter 'Part H: External debug'. The -external debug module is mainly used for two modes: self-hosted debug and -external debug, and it can be accessed from mmio region from Coresight -and eventually the debug module connects with CPU for debugging. And the -debug module provides sample-based profiling extension, which can be used -to sample CPU program counter, secure state and exception level, etc; -usually every CPU has one dedicated debug module to be connected. - -Required properties: - -- compatible : should be "arm,coresight-cpu-debug"; supplemented with - "arm,primecell" since this driver is using the AMBA bus - interface. - -- reg : physical base address and length of the register set. - -- clocks : the clock associated to this component. - -- clock-names : the name of the clock referenced by the code. Since we are - using the AMBA framework, the name of the clock providing - the interconnect should be "apb_pclk" and the clock is - mandatory. The interface between the debug logic and the - processor core is clocked by the internal CPU clock, so it - is enabled with CPU clock by default. - -- cpu : the CPU phandle the debug module is affined to. Do not assume it - to default to CPU0 if omitted. - -Optional properties: - -- power-domains: a phandle to the debug power domain. We use "power-domains" - binding to turn on the debug logic if it has own dedicated - power domain and if necessary to use "cpuidle.off=1" or - "nohlt" in the kernel command line or sysfs node to - constrain idle states to ensure registers in the CPU power - domain are accessible. - -Example: - - debug@f6590000 { - compatible = "arm,coresight-cpu-debug","arm,primecell"; - reg = <0 0xf6590000 0 0x1000>; - clocks = <&sys_ctrl HI6220_DAPB_CLK>; - clock-names = "apb_pclk"; - cpu = <&cpu0>; - }; diff --git a/MAINTAINERS b/MAINTAINERS index ac2e7163ab14..59042ecb3cbc 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -1971,7 +1971,6 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) S: Maintained T: git git://git.kernel.org/pub/scm/linux/kernel/git/coresight/linux.git F: Documentation/ABI/testing/sysfs-bus-coresight-devices-* -F: Documentation/devicetree/bindings/arm/coresight-cpu-debug.txt F: Documentation/devicetree/bindings/arm/arm,coresight-*.yaml F: Documentation/devicetree/bindings/arm/arm,embedded-trace-extension.yaml F: Documentation/devicetree/bindings/arm/arm,trace-buffer-extension.yaml -- 2.34.1