From patchwork Wed Oct 16 06:41:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 13837793 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1329AD206A0 for ; Wed, 16 Oct 2024 06:51:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References :Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=feT/7XmQcrVtoa6vvcgiQdzp+mqlGEZb5gary+Ro0Ac=; b=phP1poFZL5J0+H37ByKdavMkCn gfsbvuQG/I1rApjRauW8PFZfA77eD7T2uNsNrKN3TvtOlU2qTz254W7yUQqDSJiiXnM8L2CFXjtaj hv0qWNsF6WFP7zhmbfa/F434DVx5lpI40Ew+MF7ol9FdhX+GZxowYa9CmgfNXEgdJT0tbxnNqaRvn FxykLA/zgcfqq9S2AW3uRBEeEnGeSZrrtGx6zgt++MERbHckEBswzDKEq7WQCRCEszUunn66By8U5 yy2LuECztZJ3AeyJ7mqMJj4LVF3LrTF1L1R4DelsATiH9jtwFzDFfBbFXH/gXJk6ikAYxl3SKEOOi 0KySDkOg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t0xsS-0000000Ajd3-3Dsi; Wed, 16 Oct 2024 06:51:24 +0000 Received: from mail-lj1-x232.google.com ([2a00:1450:4864:20::232]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t0xif-0000000Ai4T-05k3 for linux-arm-kernel@lists.infradead.org; Wed, 16 Oct 2024 06:41:19 +0000 Received: by mail-lj1-x232.google.com with SMTP id 38308e7fff4ca-2f7657f9f62so61213031fa.3 for ; Tue, 15 Oct 2024 23:41:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1729060875; x=1729665675; darn=lists.infradead.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=feT/7XmQcrVtoa6vvcgiQdzp+mqlGEZb5gary+Ro0Ac=; b=r9ctN1rJB2RwkKVtzV7SPTZ/d3zfI/Cv1paX5wZeYikktu85d6gnBrB1QzDL7RCCbk 5DuUP1k0KY5wMoEIR7iMgMxy+Kqn1XBnkU2sQhbuEz4T53BGTH9wud8fAAu7Gc7CvuVO XY0Q1ez6Cdd19dmdoViUma5UUcSYMVWgKFL2iFpOFOTp1kJG8UrD9x0S4GM+y1E7n1dU udlqu0jix9/YOFEne7NTMilSF9KAYufankaREn1wOh5qjavor4Sh+hjV1hKgjZ75e6cM 3yRB+bruvT2UprIyAq2pSUD9tEdjHmZsL3qV4C7Sj9G8x+WW5S4uxM76WXB+0VQBS9SM NgDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729060875; x=1729665675; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=feT/7XmQcrVtoa6vvcgiQdzp+mqlGEZb5gary+Ro0Ac=; b=lFPR1T/h4BR9fiHi9bP6Ic+paDrz9ey+yaKPwhAhDCdp38fVrMGq4mDXRJQBn3GfQi rl0KEJPoW9WwAWBNXxyxGHhIenYq5u6NxSbRLQAsYwUWxjyLT/qz1B0m42AX8H7m4EbN la08aSx76V1OQSdrpp8EeaPUhGRuxlZvcsH/4m/rrWMIfDcQAOoakf4MaCvwHzFc5/un Opkbf8VpMB/pBmGfeJUIdEOpnxsDa6zaAqdqmXYPIii+IG523BIy+CC/P5+ZOaRuL/j6 sKcOu7uJQZJDVnPDctWImyz/i0QU0+nX0EBgti+aKq7sRhOjfeOJn99O1/cVQL/PKj/c sZvA== X-Forwarded-Encrypted: i=1; AJvYcCVzK6IwVa1xot0K4ExGVfYrZb8Mbzn4757AkZ+rDANhp5napgDgrm8GbElTijCV6OGu2ZnrH5Qoa8o2hZfEyLPc@lists.infradead.org X-Gm-Message-State: AOJu0Yyc7rU+JCFIVeB51aTwTjC/9VfnvP0QFlVTLpXoQyT2WAHi9vnS K6K2ElMjmiPwZZdccEXHOajFY7Z6FhCwb0r5l8jGmRz0aNrfiy1O7w9HTZzjCvBfWHCEOUJhlDg 1 X-Google-Smtp-Source: AGHT+IEcOSxSHiOL67XtheXoGabAKLmm5j7st4EBhXlI+whhH2LShcIJ5e0wxd2agXFBbk4Z7L/63A== X-Received: by 2002:a05:6512:b02:b0:539:fd10:f07b with SMTP id 2adb3069b0e04-53a03f96215mr2013640e87.55.1729060874721; Tue, 15 Oct 2024 23:41:14 -0700 (PDT) Received: from lino.lan ([85.235.12.238]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-539ffff3a50sm357455e87.144.2024.10.15.23.41.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 23:41:13 -0700 (PDT) From: Linus Walleij Date: Wed, 16 Oct 2024 08:41:06 +0200 Subject: [PATCH v2 6/9] ARM: dts: bcm6846: Add ARM PL081 DMA block MIME-Version: 1.0 Message-Id: <20241016-genexis-xg6846b-base-v2-6-6a7cc2ee57eb@linaro.org> References: <20241016-genexis-xg6846b-base-v2-0-6a7cc2ee57eb@linaro.org> In-Reply-To: <20241016-genexis-xg6846b-base-v2-0-6a7cc2ee57eb@linaro.org> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , William Zhang , Anand Gore , Kursad Oney , Florian Fainelli , =?utf-8?b?UmFmYcWCIE1p?= =?utf-8?b?xYJlY2tp?= , Benjamin Larsson , Broadcom internal kernel review list Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Linus Walleij X-Mailer: b4 0.14.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241015_234117_251088_5FC97EFD X-CRM114-Status: GOOD ( 15.26 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The ARM PL081 DMA controller can be found in the BCM6846 memory map, and it turns out to work. The block may be used as DMA engine for some of the peripherals (maybe the EMMC controller found in the same group of peripherals?) but it can always be used as a memcpy engine, which is a generic "blitter". I tested it with the dmatest module, and it copies lots of data very fast and fires hundreds of thousands of interrupts so it works just fine. Add it to the BCM6846 DTSI file. Signed-off-by: Linus Walleij --- arch/arm/boot/dts/broadcom/bcm6846.dtsi | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/arch/arm/boot/dts/broadcom/bcm6846.dtsi b/arch/arm/boot/dts/broadcom/bcm6846.dtsi index 371c16af27f3..131e1802bd86 100644 --- a/arch/arm/boot/dts/broadcom/bcm6846.dtsi +++ b/arch/arm/boot/dts/broadcom/bcm6846.dtsi @@ -240,5 +240,18 @@ mdio: mdio@2060 { #address-cells = <0>; status = "disabled"; }; + + pl081_dma: dma-controller@59000 { + compatible = "arm,pl081", "arm,primecell"; + // The magic B105F00D info is missing + arm,primecell-periphid = <0x00041081>; + reg = <0x59000 0x1000>; + interrupts = ; + memcpy-burst-size = <256>; + memcpy-bus-width = <32>; + clocks = <&periph_clk>; + clock-names = "apb_pclk"; + #dma-cells = <2>; + }; }; };