From patchwork Tue Nov 17 01:33:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rob Herring (Arm)" X-Patchwork-Id: 1401275 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by ozlabs.org (Postfix) with ESMTP id 4CZpPx5k50z9sVD for ; Tue, 17 Nov 2020 12:34:13 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726086AbgKQBdz (ORCPT ); Mon, 16 Nov 2020 20:33:55 -0500 Received: from mail-oo1-f54.google.com ([209.85.161.54]:34192 "EHLO mail-oo1-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725554AbgKQBdy (ORCPT ); Mon, 16 Nov 2020 20:33:54 -0500 Received: by mail-oo1-f54.google.com with SMTP id q28so4384249oof.1 for ; Mon, 16 Nov 2020 17:33:52 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=qK36A5rVThIRP81jEbeCpq/j9+HO/HBCjgD8p63pIAY=; b=aVDiJRoHDjcVNWqkzZaMosqQNpokVA3MvyozHJLhIjOTk9vU3PiUtbK2dvPNdmbrZ1 exFxQLlSfYITAcbge8Hzy3yJuRQoIAGzu10wl2I8hADd6PzqdPfb66TvJyA3zPNWAlzz RwR8toJ6fOlUMnXuBf7oBDpSBzd98ROdREn0tZsetok6k2fpUElQRpH6n0Z+PiIa2NQX sVlSLhzpfJf94g4GwqWkBDNjmOZrm58/ZrLk61zsbZi0F4qnlIAVwS90THky2R7qN13n hbBLk9dQvXtdtNfa161DiRVg6Tin56rk3HHFVrtaXjczckmx+ykBod8G/uGiLCgheagi eWJA== X-Gm-Message-State: AOAM533RkgLR9kK+dY1mBSU3xYUKIYLPrIaly3KigkzzQdjbstQR/930 hlX10T8CrrxX0DxsBR6NgfStTG3iqg== X-Google-Smtp-Source: ABdhPJykb52AnSl4SEA/E7nSB7S68jQee/nKPxZolW8lsORhSo9gx3/n5M5AC1cckKrEW8rbVno8Ww== X-Received: by 2002:a4a:e09a:: with SMTP id w26mr1528078oos.18.1605576831640; Mon, 16 Nov 2020 17:33:51 -0800 (PST) Received: from xps15.herring.priv (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.googlemail.com with ESMTPSA id j9sm3861325oij.44.2020.11.16.17.33.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2020 17:33:51 -0800 (PST) From: Rob Herring To: Mark Brown Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, Liam Girdwood , Kuninori Morimoto , Lubomir Rintel , Sameer Pujar Subject: [PATCH 1/4] ASoC: audio-graph-card: Refactor schema Date: Mon, 16 Nov 2020 19:33:46 -0600 Message-Id: <20201117013349.2458416-2-robh@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201117013349.2458416-1-robh@kernel.org> References: <20201117013349.2458416-1-robh@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Sameer Pujar There can be customized sound cards which are based on generic audio graph. In such cases most of the stuff is reused from generic audio graph. To facilitate this, refactor audio graph schema into multiple files and the base schema can be reused for specific sound cards. The graph card nodes and port nodes are separate entities, so they should be separate schemas. Signed-off-by: Sameer Pujar Cc: Kuninori Morimoto [robh: Split out port schema. Add graph.yaml in subsequent commit] Signed-off-by: Rob Herring Acked-by: Sameer Pujar --- .../bindings/sound/audio-graph-card.yaml | 106 +----------------- .../bindings/sound/audio-graph-port.yaml | 86 ++++++++++++++ .../bindings/sound/audio-graph.yaml | 45 ++++++++ .../bindings/sound/renesas,rsnd.yaml | 12 +- 4 files changed, 141 insertions(+), 108 deletions(-) create mode 100644 Documentation/devicetree/bindings/sound/audio-graph-port.yaml create mode 100644 Documentation/devicetree/bindings/sound/audio-graph.yaml diff --git a/Documentation/devicetree/bindings/sound/audio-graph-card.yaml b/Documentation/devicetree/bindings/sound/audio-graph-card.yaml index 2329aeb91db7..109e55f9e597 100644 --- a/Documentation/devicetree/bindings/sound/audio-graph-card.yaml +++ b/Documentation/devicetree/bindings/sound/audio-graph-card.yaml @@ -4,120 +4,24 @@ $id: http://devicetree.org/schemas/sound/audio-graph-card.yaml# $schema: http://devicetree.org/meta-schemas/core.yaml# -title: Audio Graph Card Driver Device Tree Bindings +title: Audio Graph Card Device Tree Bindings maintainers: - Kuninori Morimoto +allOf: + - $ref: /schemas/sound/audio-graph.yaml# + properties: compatible: enum: - audio-graph-card - audio-graph-scu-card - dais: - $ref: /schemas/types.yaml#/definitions/phandle-array - label: - maxItems: 1 - prefix: - description: "device name prefix" - $ref: /schemas/types.yaml#/definitions/string - routing: - description: | - A list of the connections between audio components. - Each entry is a pair of strings, the first being the - connection's sink, the second being the connection's source. - $ref: /schemas/types.yaml#/definitions/non-unique-string-array - widgets: - description: User specified audio sound widgets. - $ref: /schemas/types.yaml#/definitions/non-unique-string-array - convert-rate: - description: CPU to Codec rate convert. - $ref: /schemas/types.yaml#/definitions/uint32 - convert-channels: - description: CPU to Codec rate channels. - $ref: /schemas/types.yaml#/definitions/uint32 - pa-gpios: - maxItems: 1 - hp-det-gpio: - maxItems: 1 - mic-det-gpio: - maxItems: 1 - - port: - description: single OF-Graph subnode - type: object - properties: - reg: - maxItems: 1 - prefix: - description: "device name prefix" - $ref: /schemas/types.yaml#/definitions/string - convert-rate: - description: CPU to Codec rate convert. - $ref: /schemas/types.yaml#/definitions/uint32 - convert-channels: - description: CPU to Codec rate channels. - $ref: /schemas/types.yaml#/definitions/uint32 - patternProperties: - "^endpoint(@[0-9a-f]+)?": - type: object - properties: - remote-endpoint: - maxItems: 1 - mclk-fs: - description: | - Multiplication factor between stream rate and codec mclk. - When defined, mclk-fs property defined in dai-link sub nodes are ignored. - $ref: /schemas/types.yaml#/definitions/uint32 - frame-inversion: - description: dai-link uses frame clock inversion - $ref: /schemas/types.yaml#/definitions/flag - bitclock-inversion: - description: dai-link uses bit clock inversion - $ref: /schemas/types.yaml#/definitions/flag - frame-master: - description: Indicates dai-link frame master. - $ref: /schemas/types.yaml#/definitions/phandle-array - maxItems: 1 - bitclock-master: - description: Indicates dai-link bit clock master - $ref: /schemas/types.yaml#/definitions/phandle-array - maxItems: 1 - dai-format: - description: audio format. - items: - enum: - - i2s - - right_j - - left_j - - dsp_a - - dsp_b - - ac97 - - pdm - - msb - - lsb - convert-rate: - description: CPU to Codec rate convert. - $ref: /schemas/types.yaml#/definitions/uint32 - convert-channels: - description: CPU to Codec rate channels. - $ref: /schemas/types.yaml#/definitions/uint32 - required: - - remote-endpoint - - ports: - description: multi OF-Graph subnode - type: object - patternProperties: - "^port(@[0-9a-f]+)?": - $ref: "#/properties/port" - required: - compatible - - dais -additionalProperties: false +unevaluatedProperties: false examples: - | diff --git a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml new file mode 100644 index 000000000000..9db19d4edc6a --- /dev/null +++ b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml @@ -0,0 +1,86 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/audio-graph-port.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Audio Graph Card 'port' Node Bindings + +maintainers: + - Kuninori Morimoto + +select: false + +properties: + port: + description: single OF-Graph subnode + type: object + properties: + reg: + maxItems: 1 + prefix: + description: "device name prefix" + $ref: /schemas/types.yaml#/definitions/string + convert-rate: + description: CPU to Codec rate convert. + $ref: /schemas/types.yaml#/definitions/uint32 + convert-channels: + description: CPU to Codec rate channels. + $ref: /schemas/types.yaml#/definitions/uint32 + patternProperties: + "^endpoint(@[0-9a-f]+)?": + type: object + properties: + remote-endpoint: + maxItems: 1 + mclk-fs: + description: | + Multiplication factor between stream rate and codec mclk. + When defined, mclk-fs property defined in dai-link sub nodes are + ignored. + $ref: /schemas/types.yaml#/definitions/uint32 + frame-inversion: + description: dai-link uses frame clock inversion + $ref: /schemas/types.yaml#/definitions/flag + bitclock-inversion: + description: dai-link uses bit clock inversion + $ref: /schemas/types.yaml#/definitions/flag + frame-master: + description: Indicates dai-link frame master. + $ref: /schemas/types.yaml#/definitions/phandle-array + maxItems: 1 + bitclock-master: + description: Indicates dai-link bit clock master + $ref: /schemas/types.yaml#/definitions/phandle-array + maxItems: 1 + dai-format: + description: audio format. + items: + enum: + - i2s + - right_j + - left_j + - dsp_a + - dsp_b + - ac97 + - pdm + - msb + - lsb + convert-rate: + description: CPU to Codec rate convert. + $ref: /schemas/types.yaml#/definitions/uint32 + convert-channels: + description: CPU to Codec rate channels. + $ref: /schemas/types.yaml#/definitions/uint32 + + required: + - remote-endpoint + + ports: + description: multi OF-Graph subnode + type: object + patternProperties: + "^port(@[0-9a-f]+)?": + $ref: "#/properties/port" + +additionalProperties: true diff --git a/Documentation/devicetree/bindings/sound/audio-graph.yaml b/Documentation/devicetree/bindings/sound/audio-graph.yaml new file mode 100644 index 000000000000..4b46794e5153 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/audio-graph.yaml @@ -0,0 +1,45 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/sound/audio-graph.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Audio Graph Device Tree Bindings + +maintainers: + - Kuninori Morimoto + +properties: + dais: + $ref: /schemas/types.yaml#/definitions/phandle-array + label: + maxItems: 1 + prefix: + description: "device name prefix" + $ref: /schemas/types.yaml#/definitions/string + routing: + description: | + A list of the connections between audio components. + Each entry is a pair of strings, the first being the + connection's sink, the second being the connection's source. + $ref: /schemas/types.yaml#/definitions/non-unique-string-array + widgets: + description: User specified audio sound widgets. + $ref: /schemas/types.yaml#/definitions/non-unique-string-array + convert-rate: + description: CPU to Codec rate convert. + $ref: /schemas/types.yaml#/definitions/uint32 + convert-channels: + description: CPU to Codec rate channels. + $ref: /schemas/types.yaml#/definitions/uint32 + pa-gpios: + maxItems: 1 + hp-det-gpio: + maxItems: 1 + mic-det-gpio: + maxItems: 1 + +required: + - dais + +additionalProperties: true diff --git a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml index 51f4dcaa970d..cbfd5914b432 100644 --- a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml +++ b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml @@ -9,6 +9,10 @@ title: Renesas R-Car Sound Driver Device Tree Bindings maintainers: - Kuninori Morimoto +allOf: + - $ref: audio-graph.yaml# + - $ref: audio-graph-port.yaml# + properties: compatible: @@ -111,13 +115,7 @@ properties: - pattern: '^dvc\.[0-1]$' - pattern: '^clk_(a|b|c|i)$' - port: - description: OF-Graph subnode - $ref: "audio-graph-card.yaml#/properties/port" - - ports: - description: multi OF-Graph subnode - $ref: "audio-graph-card.yaml#/properties/ports" + port: true # use patternProperties to avoid naming "xxx,yyy" issue patternProperties: From patchwork Tue Nov 17 01:33:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rob Herring (Arm)" X-Patchwork-Id: 1401276 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by ozlabs.org (Postfix) with ESMTP id 4CZpPy2YRJz9sPB for ; Tue, 17 Nov 2020 12:34:14 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725554AbgKQBdz (ORCPT ); Mon, 16 Nov 2020 20:33:55 -0500 Received: from mail-oi1-f196.google.com ([209.85.167.196]:33162 "EHLO mail-oi1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725764AbgKQBdz (ORCPT ); Mon, 16 Nov 2020 20:33:55 -0500 Received: by mail-oi1-f196.google.com with SMTP id k26so20981141oiw.0 for ; Mon, 16 Nov 2020 17:33:53 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=spsmauWvc5A5SYudUomXMMzn+PeDbEjuioZTNAq65wc=; b=chSW+a7s6EDVNtJRtItM2JmE1I4hlMlgSfnFw6C+sZWLKNBmy7NkIj2RHYAWU9dnxi aKHBQhuGX/ASdLc/BdWMD9L7jGJtYXFbxzB/J0AZtk1F8njWfpXS+YA7eRwZxEYq3dX/ y4NuSS6FhybOb71oSy3ks6UHFxEs5kEC681WG7Nip+uQ5muWoACIlVuYJCVTlAQVlnP2 ADytPXEmpJ/HMESfkuEMb0GAbvrHG6AfQjg9dSbjuk8s1VX/YEp/xep7g6G6q9NcaRUo vx3Jlnwi6dSKYVfnHxdauEU7iPzDHZHQ08kSjVnE43dz75lHSGc2Uky0xTi59d5iR/Ll t3kg== X-Gm-Message-State: AOAM532BZlFn5DPbT2Wsfi9SUaVGJ4CsN0rXo/6jQRJbZsL3UxtHsVQL rEc7RBSPVDddvpxw/HEeLX7e0Mlc+w== X-Google-Smtp-Source: ABdhPJwAoktwKb9CWVlc2LS2AAtpaWZoLT4ef5gt28xJSOD8nEazcXh9uwt/ZK7/G6xwTypii9uUJA== X-Received: by 2002:aca:fcd5:: with SMTP id a204mr970460oii.161.1605576832729; Mon, 16 Nov 2020 17:33:52 -0800 (PST) Received: from xps15.herring.priv (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.googlemail.com with ESMTPSA id j9sm3861325oij.44.2020.11.16.17.33.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2020 17:33:52 -0800 (PST) From: Rob Herring To: Mark Brown Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, Liam Girdwood , Kuninori Morimoto , Lubomir Rintel , Sameer Pujar Subject: [PATCH 2/4] ASoC: dt-bindings: Use OF graph schema Date: Mon, 16 Nov 2020 19:33:47 -0600 Message-Id: <20201117013349.2458416-3-robh@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201117013349.2458416-1-robh@kernel.org> References: <20201117013349.2458416-1-robh@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Now that we have an OF graph schema, let's use it for the audio-graph-port schema. There's no need to define 'ports' nodes as specific bindings must define that and port numbering of the child 'port' nodes. Signed-off-by: Rob Herring --- Note that graph.yaml is part of dtschema now intead of the kernel tree. --- .../bindings/sound/audio-graph-port.yaml | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml index 9db19d4edc6a..c05d5643b10e 100644 --- a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml +++ b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml @@ -13,11 +13,9 @@ select: false properties: port: - description: single OF-Graph subnode + $ref: /schemas/graph.yaml#/properties/port type: object properties: - reg: - maxItems: 1 prefix: description: "device name prefix" $ref: /schemas/types.yaml#/definitions/string @@ -31,8 +29,6 @@ properties: "^endpoint(@[0-9a-f]+)?": type: object properties: - remote-endpoint: - maxItems: 1 mclk-fs: description: | Multiplication factor between stream rate and codec mclk. @@ -73,14 +69,6 @@ properties: description: CPU to Codec rate channels. $ref: /schemas/types.yaml#/definitions/uint32 - required: - - remote-endpoint - - ports: - description: multi OF-Graph subnode - type: object - patternProperties: - "^port(@[0-9a-f]+)?": - $ref: "#/properties/port" + additionalProperties: false additionalProperties: true From patchwork Tue Nov 17 01:33:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rob Herring (Arm)" X-Patchwork-Id: 1401274 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by ozlabs.org (Postfix) with ESMTP id 4CZpPx2H53z9sTR for ; Tue, 17 Nov 2020 12:34:13 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725901AbgKQBdz (ORCPT ); Mon, 16 Nov 2020 20:33:55 -0500 Received: from mail-oi1-f193.google.com ([209.85.167.193]:36194 "EHLO mail-oi1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725730AbgKQBdy (ORCPT ); Mon, 16 Nov 2020 20:33:54 -0500 Received: by mail-oi1-f193.google.com with SMTP id d9so20942509oib.3 for ; Mon, 16 Nov 2020 17:33:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=wNb4ssqi6GnjfKnwrQ0BaPlK7z2Z97OJHzDNpZ85994=; b=h4BlmDhJpDrJn0FTVc1gNJkJFh7pXxdDu53wEc4sfIlHyaXwv+oF+hxT/DFxjbjdD6 aWvG0Nt0ni5gMw+f33bi3sDHDY8wZd5NNvHaluUhAiunxMlWg0oFM74Rwhj1TO2WVTCD DenAUn5AcC/U0QC19Hp03XzJJ4IzDNbmqz3Gj+mNSOoYbDL4thzK55C3ieEvb0tdpN1b vGhPqTe9ZodUZQqSVsd6Q72e+85rQrhAxVd9wL+Q8iYcRPdXv31VMdC1K6c+unawsekA dBzKNgu1ecUv71AqwpRbI6VZ4DY7kcsLtty5Vq9cEI+E4MeIamysvWq8TMBXHr0Bp5Xs yvVA== X-Gm-Message-State: AOAM5315GpodZ/pMl8zTGuoPUwO9iEL8Ipru/04/WCfskOwd5TQ+VTo1 AjkJlRIZDSGLDK5fs1qnuw== X-Google-Smtp-Source: ABdhPJyDkvsLj4rCoRr0stY/uAY+Ho1h7TjbcsWWN9IwYjbAu6/wt1w8uWs//J0UNqwvW85u68w85A== X-Received: by 2002:aca:cd17:: with SMTP id d23mr917590oig.171.1605576833830; Mon, 16 Nov 2020 17:33:53 -0800 (PST) Received: from xps15.herring.priv (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.googlemail.com with ESMTPSA id j9sm3861325oij.44.2020.11.16.17.33.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2020 17:33:53 -0800 (PST) From: Rob Herring To: Mark Brown Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, Liam Girdwood , Kuninori Morimoto , Lubomir Rintel , Sameer Pujar Subject: [PATCH 3/4] ASoC: dt-bindings: marvell,mmp-sspa: Use audio-graph-port schema Date: Mon, 16 Nov 2020 19:33:48 -0600 Message-Id: <20201117013349.2458416-4-robh@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201117013349.2458416-1-robh@kernel.org> References: <20201117013349.2458416-1-robh@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Now that we have a graph schema, reference it from the marvell,mmp-sspa schema. Signed-off-by: Rob Herring Acked-by: Lubomir Rintel --- .../bindings/sound/marvell,mmp-sspa.yaml | 25 +++---------------- 1 file changed, 3 insertions(+), 22 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/marvell,mmp-sspa.yaml b/Documentation/devicetree/bindings/sound/marvell,mmp-sspa.yaml index 6d20a24a2ae9..234f64a32184 100644 --- a/Documentation/devicetree/bindings/sound/marvell,mmp-sspa.yaml +++ b/Documentation/devicetree/bindings/sound/marvell,mmp-sspa.yaml @@ -9,6 +9,9 @@ title: Marvel SSPA Digital Audio Interface Bindings maintainers: - Lubomir Rintel +allOf: + - $ref: audio-graph-port.yaml# + properties: $nodename: pattern: "^audio-controller(@.*)?$" @@ -58,29 +61,9 @@ properties: type: object properties: - remote-endpoint: true - - frame-master: - type: boolean - description: SoC generates the frame clock - - bitclock-master: - type: boolean - description: SoC generates the bit clock - dai-format: - $ref: /schemas/types.yaml#/definitions/string - description: The digital audio format const: i2s - required: - - remote-endpoint - - required: - - endpoint - - additionalProperties: false - required: - "#sound-dai-cells" - compatible @@ -112,8 +95,6 @@ examples: port { endpoint { remote-endpoint = <&rt5631_0>; - frame-master; - bitclock-master; dai-format = "i2s"; }; }; From patchwork Tue Nov 17 01:33:49 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rob Herring (Arm)" X-Patchwork-Id: 1401277 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by ozlabs.org (Postfix) with ESMTP id 4CZpPy60wrz9sSs for ; Tue, 17 Nov 2020 12:34:14 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725764AbgKQBd4 (ORCPT ); Mon, 16 Nov 2020 20:33:56 -0500 Received: from mail-oi1-f194.google.com ([209.85.167.194]:34331 "EHLO mail-oi1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725730AbgKQBd4 (ORCPT ); Mon, 16 Nov 2020 20:33:56 -0500 Received: by mail-oi1-f194.google.com with SMTP id w188so20947876oib.1 for ; Mon, 16 Nov 2020 17:33:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=7v83U4ZReYBGAfYOQtO/dOb1BUnzpl5ihuyBngAA7CU=; b=EecZlb3J7Pto7goRpE5JD871h9MQ3gvbyhqIG2QZaFgXfkh6yG3Ep0iX0TXoscSlHY bBVVpzga8M4bXPCt6uUmeg+Uwl9G1E7iTjNuiCx7e7dN3KG0G0Q75PbS2dw5dN1Sfd62 ZsQWPtozmoxWDYlSFKoSCBYBgo6+0lhw0oIF+NjMHIziJ32yARFFCY13+NHdjCNRjG/P 9t8FNz/KXDYwH4/7t77Kj6MizqAfMKr8sQ4Y5miKPEsJ/TvNojOTT4spwYjQFCXwVkCm dKUNMzW2rIHmyZbcTQWmzUlGJRc+Uw1EfwrPew9SPeeADZS5EH3ANs9Nw8tVUXuZHjH3 fDQg== X-Gm-Message-State: AOAM533lYjs//jWNRLwxyrWEB+DAbafQ8Hbo9useV5ZXR69dbnK+Yf5m xJPLg0E4/5TBKD1nii9L5g== X-Google-Smtp-Source: ABdhPJzyi1Pq1zCgJvRLk5tSHnQcHJ5b4OUkT8Xd8ewHIyt1yL8BzhAIJOyKkE7LJYcFknVYD6ujrA== X-Received: by 2002:aca:486:: with SMTP id 128mr997880oie.19.1605576834952; Mon, 16 Nov 2020 17:33:54 -0800 (PST) Received: from xps15.herring.priv (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.googlemail.com with ESMTPSA id j9sm3861325oij.44.2020.11.16.17.33.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2020 17:33:54 -0800 (PST) From: Rob Herring To: Mark Brown Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, Liam Girdwood , Kuninori Morimoto , Lubomir Rintel , Sameer Pujar Subject: [PATCH 4/4] ASoC: dt-bindings: Refine 'frame-master' and 'bitclock-master' type Date: Mon, 16 Nov 2020 19:33:49 -0600 Message-Id: <20201117013349.2458416-5-robh@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201117013349.2458416-1-robh@kernel.org> References: <20201117013349.2458416-1-robh@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org 'frame-master' and 'bitclock-master' are only a single phandle, so use the more specific 'phandle' type definition instead. Signed-off-by: Rob Herring Acked-by: Sameer Pujar --- .../devicetree/bindings/sound/audio-graph-port.yaml | 6 ++---- Documentation/devicetree/bindings/sound/simple-card.yaml | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml index c05d5643b10e..7c13ca41d41f 100644 --- a/Documentation/devicetree/bindings/sound/audio-graph-port.yaml +++ b/Documentation/devicetree/bindings/sound/audio-graph-port.yaml @@ -43,12 +43,10 @@ properties: $ref: /schemas/types.yaml#/definitions/flag frame-master: description: Indicates dai-link frame master. - $ref: /schemas/types.yaml#/definitions/phandle-array - maxItems: 1 + $ref: /schemas/types.yaml#/definitions/phandle bitclock-master: description: Indicates dai-link bit clock master - $ref: /schemas/types.yaml#/definitions/phandle-array - maxItems: 1 + $ref: /schemas/types.yaml#/definitions/phandle dai-format: description: audio format. items: diff --git a/Documentation/devicetree/bindings/sound/simple-card.yaml b/Documentation/devicetree/bindings/sound/simple-card.yaml index 35e669020296..45fd9fd9eb54 100644 --- a/Documentation/devicetree/bindings/sound/simple-card.yaml +++ b/Documentation/devicetree/bindings/sound/simple-card.yaml @@ -13,13 +13,11 @@ definitions: frame-master: description: Indicates dai-link frame master. - $ref: /schemas/types.yaml#/definitions/phandle-array - maxItems: 1 + $ref: /schemas/types.yaml#/definitions/phandle bitclock-master: description: Indicates dai-link bit clock master - $ref: /schemas/types.yaml#/definitions/phandle-array - maxItems: 1 + $ref: /schemas/types.yaml#/definitions/phandle frame-inversion: description: dai-link uses frame clock inversion