Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp33430rdb; Mon, 22 Jan 2024 11:00:45 -0800 (PST) X-Google-Smtp-Source: AGHT+IGZwTI6brBd2mXvJCVEx5VKeaHeF0pgMTPUQKx8UYBcUYDHbXUe+F4vGB/aa6kQpuqmHGeV X-Received: by 2002:a05:6a00:88a:b0:6d9:bd17:1653 with SMTP id q10-20020a056a00088a00b006d9bd171653mr5222606pfj.37.1705950044726; Mon, 22 Jan 2024 11:00:44 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705950044; cv=pass; d=google.com; s=arc-20160816; b=QQsO7JHFT17sDZhAQgNWSErS2r4bP+cxfjEb2P7Cd2jJPtMzcGyJA2k0EKAsc3gyRP BTKqh9I8ofMAa8k47c1XWhy0psgeIiEf5DwlcQn7QcnB8vZ8G57eTq2fwZrY1vHHvl6Z qk3AFy2JoItiTXffeSttr8mLFscsvJqyxNnEt+yNT9LqbfJGsQrV3Uk3+YaUeSESwDVa MToW+p4eBNQp1R2BrK7t3uYSjnycyefIHI5eeARQQd6hReO20eXYP9PcZ5WFcZHqj13p k9r+8SwOXjr/9j0k3u4NPNONlxkwekZ9OzdAOHPCkGcRDWhYS1uPv8H+dAzCtMlj/VVZ eW0Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=seSyA5iReM1NqgZskzAi8Wn4GHqRGtgb/DICS2k3IYU=; fh=UWiig1s3fmMOlTSMGWrEATJpXuAxUBcuTQXgzYQfeCg=; b=ZOsCpRdhoVCFqdDQe+XmGwKAtWv3cCDqjrjjgAqBxgdlzu9gkoRCTOfGltPsS5oO6E eQiAuQYcQZvs2AZy3DY+Vs4QdoCgWb19BddxzrjW9FbvP9duJypZQeelc3m85q8Xo8yS 6cHyixF/iNdyy7/MeroPmhNuY0RVMZIOlFoxyhP1PBlZiqbIfYpiInUpaATblxNXAV6x 62jvkzd3QZXQMMWWlbqVdN62hnmy+J4jngdSCcgKu106z9lYMsqVGAagPOailG7nXDfQ LNLDltv17NF5V10fTh3gljWu09N5BgQsjUPni9ksbEr44kHmSxsf8kIHNykFOvUtyaX0 XXdQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aZVtshFo; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-33958-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-33958-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id w10-20020a056a0014ca00b006dbeb3ca3desi777001pfu.346.2024.01.22.11.00.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Jan 2024 11:00:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-33958-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aZVtshFo; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-33958-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-33958-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C389D286BF8 for ; Mon, 22 Jan 2024 18:51:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D73764779D; Mon, 22 Jan 2024 18:18:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="aZVtshFo" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 028253D99D; Mon, 22 Jan 2024 18:18:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705947499; cv=none; b=ak2Az8aBRxEeTiBmyz9E79qbRVvPFQ08I+Ky1u1791seyrF9a11pOKziAFsYAVzSOunjZOQjThmCfshHVXtmeUliIEAXa9lbqzZQT9kdWXdo/KuEZCCYmTXgl2TtIfVmPs1ADSuZ4cFHFtuDVN/LET6O6Dgb2gbYALOJs2MCz2Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705947499; c=relaxed/simple; bh=2usFrpfFbvgtllKuc13YKWjWHiLTD42R7HKFi/spe1M=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=FFmxQtwEqg8g6rUuZCY4C+NvxBlDMrbC/8fTPOV1rQ3rgHNvO7Gxr+s6jJ06/1cP6bypP0bOr6ExH2IRIvwNXeeSL+heRj9fizEA6GtjSGt/KuH/EfyGGxZR9Rb0qjryeePUWfeDiZuPW9ub/qOd3qcBe3hRESDlIjJ3tAQqIog= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=aZVtshFo; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id E9208C433F1; Mon, 22 Jan 2024 18:18:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1705947498; bh=2usFrpfFbvgtllKuc13YKWjWHiLTD42R7HKFi/spe1M=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=aZVtshFoH3qE8Y19hWmbNEnsrrQWORDUdoLvMqOpB8fuKw/mgCKX3F0AiOC5lDjD/ ip/FkCB0CCepVd83zeSbnpw476NSnJXYQZAkKcwACqPdF8vBthzE0RsLnzJ01we9Ic ICmqpLjOU3sIMMQp1LVNs6Hpg6hZchZVa+2RMVgF7qTI5Ht5FDOtbuMeqxVD2gh1k9 GbkOACxvO3PIHVNWRIIBJljZbAIDi3UQ10E0gUKi+Xq+SNqTL7lBEGZ4lw9YcDKeLt R4kS3B/h3x+DF05EQPPty7N61T7BmGXFz7POhZptSwXs6bR3MUkKBUjMf9YIOgMY7K tAEp+jU0a7CtQ== Date: Mon, 22 Jan 2024 18:18:12 +0000 From: Conor Dooley To: Chen-Yu Tsai Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jernej Skrabec , Samuel Holland , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Vinod Koul , Chen-Yu Tsai , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-sound@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/7] dt-bindings: dma: allwinner,sun50i-a64-dma: Add compatible for H616 Message-ID: <20240122-resemble-nearness-60dafde2e25d@spud> References: <20240122170518.3090814-1-wens@kernel.org> <20240122170518.3090814-5-wens@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="uMkVNq/eMDtdcPET" Content-Disposition: inline In-Reply-To: <20240122170518.3090814-5-wens@kernel.org> --uMkVNq/eMDtdcPET Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 23, 2024 at 01:05:15AM +0800, Chen-Yu Tsai wrote: > From: Chen-Yu Tsai >=20 > The DMA controllers found on the H616 and H618 are the same as the one > found on the H6. The only difference is the DMA endpoint (DRQ) layout. >=20 > Since the number of channels and endpoints are described with additional > generic properties, just add a new H616-specific compatible string and > fallback to the H6 one. >=20 > Signed-off-by: Chen-Yu Tsai > --- > .../bindings/dma/allwinner,sun50i-a64-dma.yaml | 15 +++++++++++---- > 1 file changed, 11 insertions(+), 4 deletions(-) >=20 > diff --git a/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-d= ma.yaml b/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.ya= ml > index ec2d7a789ffe..e5693be378bd 100644 > --- a/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml > +++ b/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml > @@ -28,6 +28,9 @@ properties: > - items: > - const: allwinner,sun8i-r40-dma > - const: allwinner,sun50i-a64-dma > + - items: > + - const: allwinner,sun50i-h616-dma > + - const: allwinner,sun50i-h6-dma > =20 > reg: > maxItems: 1 > @@ -59,10 +62,14 @@ required: > if: > properties: > compatible: > - enum: > - - allwinner,sun20i-d1-dma > - - allwinner,sun50i-a100-dma > - - allwinner,sun50i-h6-dma > + oneOf: > + - enum: > + - allwinner,sun20i-d1-dma > + - allwinner,sun50i-a100-dma > + - allwinner,sun50i-h6-dma > + - items: > + - const: allwinner,sun50i-h616-dma > + - const: allwinner,sun50i-h6-dma Instead of introducing this complexity, could you instead use "contains" here? Unless I am missing soemthing, you can achieve the same thing here with: |if: | properties: | compatible: | constains: | enum: | - allwinner,sun20i-d1-dma | - allwinner,sun50i-a100-dma | - allwinner,sun50i-h6-dma --uMkVNq/eMDtdcPET Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZa6xZAAKCRB4tDGHoIJi 0uhrAQCnxXs/YZMWmhTaL2/x37/8c6V1hW8i0Fcy+4pF/j9FagD+PzvoVb1uq4Xb caz2uxuyDai5nYCpKQMlFDgQp1wcIgs= =u1wG -----END PGP SIGNATURE----- --uMkVNq/eMDtdcPET--