From patchwork Thu Sep 7 11:52:44 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre Yves MORDRET X-Patchwork-Id: 810991 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3xnzQ94MP2z9t2W for ; Thu, 7 Sep 2017 21:54:25 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754882AbdIGLyY (ORCPT ); Thu, 7 Sep 2017 07:54:24 -0400 Received: from mx07-00178001.pphosted.com ([62.209.51.94]:46277 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755038AbdIGLyA (ORCPT ); Thu, 7 Sep 2017 07:54:00 -0400 Received: from pps.filterd (m0046037.ppops.net [127.0.0.1]) by mx07-.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v87Bmb2K014184; Thu, 7 Sep 2017 13:53:01 +0200 Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 2csteq6r1q-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 07 Sep 2017 13:53:01 +0200 Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 2BBA531; Thu, 7 Sep 2017 11:52:59 +0000 (GMT) Received: from Webmail-eu.st.com (sfhdag5node2.st.com [10.75.127.14]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id F0BE925AA; Thu, 7 Sep 2017 11:52:58 +0000 (GMT) Received: from localhost (10.75.127.47) by SFHDAG5NODE2.st.com (10.75.127.14) with Microsoft SMTP Server (TLS) id 15.0.1178.4; Thu, 7 Sep 2017 13:52:58 +0200 From: Pierre-Yves MORDRET To: Vinod Koul , Rob Herring , Mark Rutland , Maxime Coquelin , Alexandre Torgue , Russell King , Dan Williams , "M'boumba Cedric Madianga" , Fabrice GASNIER , Herbert Xu , Fabien DESSENNE , Amelie Delaunay , Pierre-Yves MORDRET , , , , Subject: [PATCH v4 0/4] Add STM32 DMAMUX support Date: Thu, 7 Sep 2017 13:52:44 +0200 Message-ID: <1504785168-26572-1-git-send-email-pierre-yves.mordret@st.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 X-Originating-IP: [10.75.127.47] X-ClientProxiedBy: SFHDAG5NODE1.st.com (10.75.127.13) To SFHDAG5NODE2.st.com (10.75.127.14) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-07_08:, , signatures=0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This patchset adds support for the STM32 DMA multiplexer. It allows to map any peripheral DMA request to any channel of the product DMAs. This IP has been introduced with STM32H7 SoC. --- Version history: v4: * Add multi-master ability for STM32 DMAMUX * Get rid of st,dmamux property and custom API between STM32 DMAMUX and DMA. Bindings has changed. DMAMUX will read DMA masters from Device Tree from now on. Merely one DMAMUX node is needed now. * Only STM32 DMA are allowed to be connected onto DMAMUX * channelID is computed locally within the driver and crafted in dma_psec to be passed toward DMA master. DMAMUX router sorts out which DMA master will serve the request automatically. * This version forbids the use of DMA in standalone and DMAMUX at the same time : all clients need to be connected either on DMA or DMAMUX ; no mix up v3: * change compatible to st,stm32h7-dmamux to be mode Soc specific * add verbosity in dma-cells --- Pierre-Yves MORDRET (4): dt-bindings: Document the STM32 DMAMUX bindings dmaengine: Add STM32 DMAMUX driver dt-bindings: stm32-dma: add a property to handle STM32 DMAMUX ARM: configs: stm32: Add MDMA support in STM32 defconfig .../devicetree/bindings/dma/stm32-dma.txt | 4 +- .../devicetree/bindings/dma/stm32-dmamux.txt | 84 ++++++ arch/arm/configs/stm32_defconfig | 1 + drivers/dma/Kconfig | 9 + drivers/dma/Makefile | 1 + drivers/dma/stm32-dmamux.c | 321 +++++++++++++++++++++ 6 files changed, 419 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/dma/stm32-dmamux.txt create mode 100644 drivers/dma/stm32-dmamux.c