From patchwork Fri Jan 14 09:17:40 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zong Li X-Patchwork-Id: 532353 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2DB7BC4332F for ; Fri, 14 Jan 2022 09:17:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239772AbiANJRz (ORCPT ); Fri, 14 Jan 2022 04:17:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35466 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239756AbiANJRz (ORCPT ); Fri, 14 Jan 2022 04:17:55 -0500 Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D6BCFC061401 for ; Fri, 14 Jan 2022 01:17:54 -0800 (PST) Received: by mail-pj1-x1035.google.com with SMTP id l10-20020a17090a384a00b001b22190e075so21382002pjf.3 for ; Fri, 14 Jan 2022 01:17:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=95yOM2oPjDW4I8teUQkYRlUXa8kIk+GmIx7gO72jBTY=; b=YPEZ7ukMzI2cN/31vBowmfQTiXMWclpljDXP5gx0881agK7JAmHUVY9q42xB0ig2sz G+JyRiZ6CP9KFEzGsvCZTn+9VGV7e3bS76bD7Mrkyu1blZVp4jGMillm7mL8+h0/9Uuw UAH3zINjhF1GKPTpYEoelai6zo6X3Mg4G4ymZHOqyAmxnygG3BdqsAkX4yR87t7RGODz IRHxnTz8fFK3SyL+f8ExbfdTi2FOpmMiW0kplgbiJ2gLFUMwBgKD9YXT848RdGbVbCzH p/ih7UBtp26Hxy3VATbG+fbJuJeBXFTcVxcKRM+ukRA9rjqxgp0CkMZGM+h1UQ6Y0BKG u4GA== 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=95yOM2oPjDW4I8teUQkYRlUXa8kIk+GmIx7gO72jBTY=; b=0VPLsJzuR/pDYFhxeSev7fYEhGdDMB8eyGUN6b7kx6w1e6aEu0894xAQcbh9hXoHdI gvmN2A22ZVo9DOr/Cu5WsXZPyXIhnK7w0V3Zjzn5V5cf+OCGi/uqAnzePqUtHOE9xdue IZZPMMpUbOKKSsXRXecwZGzNvR3rwa0jQM/PjPdccoxuiY9njMsxTMwZ2zvXgZSelpOt 4/djLeVbTHygURTdWbjbQXsCkt3L4c8Lvzdc2bu1mHOmh1wLcOdq0/XAIT0eA6cP3Ofy 6kq01fqgHacSsVrMQ6spo/Nba/jbiTMv/bExRHGmo97p1TfyH3BjdzkLFTa6GlfVe+Zi uZCw== X-Gm-Message-State: AOAM532d7nvfOx9az2SQw4hCURaGPQG6J34djJZOuHMUmWR9SI/E0frZ QxuvauFGXyLsha5FEN9sGNJ7kQ== X-Google-Smtp-Source: ABdhPJwT/nt0sujPYxFREq4ukryghTeohQvw9hI58l80zXnLp1SZJVKh4R2Mb5hKDbfGttEkklp60A== X-Received: by 2002:a17:90b:4a8e:: with SMTP id lp14mr5351158pjb.6.1642151874394; Fri, 14 Jan 2022 01:17:54 -0800 (PST) Received: from hsinchu16.internal.sifive.com (59-124-168-89.hinet-ip.hinet.net. [59.124.168.89]) by smtp.gmail.com with ESMTPSA id z3sm4237179pgc.45.2022.01.14.01.17.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Jan 2022 01:17:53 -0800 (PST) From: Zong Li To: robh+dt@kernel.org, paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu, krzysztof.kozlowski@canonical.com, conor.dooley@microchip.com, geert@linux-m68k.org, bin.meng@windriver.com, green.wan@sifive.com, vkoul@kernel.org, dmaengine@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org Cc: Zong Li Subject: [PATCH v3 2/3] dt-bindings: Add dma-channels for pdma device node Date: Fri, 14 Jan 2022 17:17:40 +0800 Message-Id: <5db314b798cd9cfcb5cb61bc56515220b7d50315.1642151791.git.zong.li@sifive.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add dma-channels property, then we can determine how many channels there by device tree, rather than statically defines it in PDMA driver Signed-off-by: Zong Li --- .../devicetree/bindings/dma/sifive,fu540-c000-pdma.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Documentation/devicetree/bindings/dma/sifive,fu540-c000-pdma.yaml b/Documentation/devicetree/bindings/dma/sifive,fu540-c000-pdma.yaml index d32a71b975fe..3dbb8caefc17 100644 --- a/Documentation/devicetree/bindings/dma/sifive,fu540-c000-pdma.yaml +++ b/Documentation/devicetree/bindings/dma/sifive,fu540-c000-pdma.yaml @@ -34,6 +34,12 @@ properties: minItems: 1 maxItems: 8 + dma-channels: + description: For backwards-compatible, the default value is 4 + minimum: 1 + maximum: 4 + default: 4 + '#dma-cells': const: 1 @@ -50,6 +56,7 @@ examples: dma@3000000 { compatible = "sifive,fu540-c000-pdma"; reg = <0x3000000 0x8000>; + dma-channels = <4>; interrupts = <23 24 25 26 27 28 29 30>; #dma-cells = <1>; };