From patchwork Thu May 16 07:59:26 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 10945839 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6A9AA112C for ; Thu, 16 May 2019 07:59:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5BF7C28A85 for ; Thu, 16 May 2019 07:59:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4F1A028A8B; Thu, 16 May 2019 07:59:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DFCB428A85 for ; Thu, 16 May 2019 07:59:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=nvAtOOT4GazoFW7eCi9EILRLOGmdnZAyEjBSrrU7/Yk=; b=fEfR7MtRCzoTxO Z66yNbNUd4WXFvz2cv7hAoZI9DvjXFEZLfbyKf7MZTBlfRSSNlId0yMNfunvUmz3Rcm5ztK/QhPrj 6bUb1dID9RfVBhHyTVtx2pb1qbTRs4L5bnQHSTDOIgConoMUXrOXG0dpRWNrLDjJkwFRQfo6TkM+Q BbL+mihMbmFl+Muzx0J0d3TzPpAtJ3YSjRN6jSq1HOY88x9oGV+OCHn7DqF4tQ99kCH2X1PnHeQVI pPtZEZANoQEXIMfxupgaz/Ej50PlfU6TJDC2QCnziQpmjR7jQ0piTSyf9nrdn9Q+ER/Bv9PHoLVbU nhk8o1ZR7HJEHrJOswHQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hRBIr-00039Q-1o; Thu, 16 May 2019 07:59:49 +0000 Received: from relay12.mail.gandi.net ([217.70.178.232]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hRBIn-00038g-Bx for linux-arm-kernel@lists.infradead.org; Thu, 16 May 2019 07:59:47 +0000 Received: from localhost (unknown [80.215.246.107]) (Authenticated sender: maxime.ripard@bootlin.com) by relay12.mail.gandi.net (Postfix) with ESMTPSA id 11CAA200008; Thu, 16 May 2019 07:59:34 +0000 (UTC) From: Maxime Ripard To: Mark Brown , Liam Girdwood , Mark Rutland , Rob Herring , Frank Rowand Subject: [PATCH v3 2/2] dt-bindings: sound: sun4i-spdif: Document that the RX channel can be missing Date: Thu, 16 May 2019 09:59:26 +0200 Message-Id: X-Mailer: git-send-email 2.21.0 In-Reply-To: <706cb97ae45cc9edc49c8709b2189ed786d2c7db.1557993523.git-series.maxime.ripard@bootlin.com> References: <706cb97ae45cc9edc49c8709b2189ed786d2c7db.1557993523.git-series.maxime.ripard@bootlin.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190516_005945_553281_8152450F X-CRM114-Status: GOOD ( 10.62 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Maxime Ripard , devicetree@vger.kernel.org, alsa-devel@alsa-project.org, Chen-Yu Tsai , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The H3 and compatibles controllers don't have any reception capabilities, even though it was never documented as such in the binding before. Therefore, on those controllers, we don't have the option to set an RX DMA channel. This was already done in the DTSI, but the binding itself was never updated. Let's add a special case in the schemas. Signed-off-by: Maxime Ripard Reviewed-by: Rob Herring --- Changes from v2: - Removed the expanded items description and rely on yaml-bindings tools to fill them - Fix typo in dmas property description Changes from v1: - switch to a draft7 conditional --- Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml | 38 ++++++++++++++++++++++++++++---------- 1 file changed, 28 insertions(+), 10 deletions(-) diff --git a/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml b/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml index 5d72d48e923e..a49ef2294a74 100644 --- a/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml +++ b/Documentation/devicetree/bindings/sound/allwinner,sun4i-a10-spdif.yaml @@ -44,19 +44,11 @@ properties: - const: apb - const: spdif - dmas: - items: - - description: RX DMA Channel - - description: TX DMA Channel - - dma-names: - items: - - const: rx - - const: tx - # Even though it only applies to subschemas under the conditionals, # not listing them here will trigger a warning because of the # additionalsProperties set to false. + dmas: true + dma-names: true resets: maxItems: 1 @@ -73,6 +65,32 @@ allOf: required: - resets + - if: + properties: + compatible: + contains: + const: allwinner,sun8i-h3-spdif + + then: + properties: + dmas: + description: TX DMA Channel + + dma-names: + const: tx + + else: + properties: + dmas: + items: + - description: RX DMA Channel + - description: TX DMA Channel + + dma-names: + items: + - const: rx + - const: tx + required: - "#sound-dai-cells" - compatible