Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp4888264imm; Tue, 9 Oct 2018 06:47:15 -0700 (PDT) X-Google-Smtp-Source: ACcGV60hIMxg7+ZFLlOMx2hVnoKn4bhbeIgrbMmSUCG8/FSacvGpSRX1zjxAf9KyD0IN9M9DyNUC X-Received: by 2002:a62:3047:: with SMTP id w68-v6mr5678264pfw.19.1539092835758; Tue, 09 Oct 2018 06:47:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539092835; cv=none; d=google.com; s=arc-20160816; b=GnnI3I214zClgZkxHT6gbqKDqHDlO1TTuARNpO+7vk/sO2rFzfW0QelXy0SxLLvaEL Eo1uXYGB6rHguH2aUSr8wfApjPcenkEktUcHmJt9S3LR2zGfEt00tECCpKRmtFtNaTCG 2uRZFIjOwEWguxbsz3EWD9Os7Bq4G6IbkLwYwZPaQTORI5iB9BwUxQWDfjGdQLPHyqqZ tppKFOpC8r9t0jO5spwyOVhgkLxT+hb76nuVy8/uhJcepXD6wYnE9sBa+UiFV/kEoszu hb9My2tdxeyv7NmyffP99jpKwEZRW1nvpAYAgbgAzNLG2xCaSEAcJVnVK7X/4k8a//vI ufOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=6EBObXY8HMfauc5Niy1G+Mwi7rrZlU8B2NFrm50/nx4=; b=r0u7sRMLdAT/Ln68RU0bT1d4LE3ULsX1xNfS9cBLqIUK4voHrujbeoI/xvYdMzrt5I x9XcB/7nl9RY8yZ09CzGPf4x2bSL3G7DtkaZGDA2kXrXIn0Kpi2103Pl/LHuYorKpoIX OLakGWk1KpTNT4da4JvcholX8LXzCFselORqCUIIe7YVsOTWgOLogFjkIX/nGnGy13xD HAr8uUs5t1TlJf003cL5X7T2PglJM7Jj3MVz9+Zcz55WCc7eP9OmWhzBzQlLJFi6Qxkr LSY7u57qnxPQUV49uMI4bQzmjV/drxrMnjlskX7G/9c0gGuH99aQDZx0QYtmYT2SCRpE LVEw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x27-v6si22114591pff.196.2018.10.09.06.47.00; Tue, 09 Oct 2018 06:47:15 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726754AbeJIVDd (ORCPT + 99 others); Tue, 9 Oct 2018 17:03:33 -0400 Received: from mx08-00178001.pphosted.com ([91.207.212.93]:43823 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726540AbeJIVDd (ORCPT ); Tue, 9 Oct 2018 17:03:33 -0400 Received: from pps.filterd (m0046660.ppops.net [127.0.0.1]) by mx08-.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id w99DjDnk030277; Tue, 9 Oct 2018 15:46:08 +0200 Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx08-00178001.pphosted.com with ESMTP id 2n0muxtqcd-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Tue, 09 Oct 2018 15:46:08 +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 2644734; Tue, 9 Oct 2018 13:46:08 +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 EC0E05219; Tue, 9 Oct 2018 13:46:07 +0000 (GMT) Received: from [10.201.23.236] (10.75.127.44) by SFHDAG5NODE2.st.com (10.75.127.14) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Tue, 9 Oct 2018 15:46:07 +0200 Subject: Re: [PATCH v3 1/7] dt-bindings: stm32-dma: Add DMA/MDMA chaining support bindings To: Vinod CC: Rob Herring , Mark Rutland , Alexandre Torgue , Maxime Coquelin , Dan Williams , , , , References: <1538139715-24406-1-git-send-email-pierre-yves.mordret@st.com> <1538139715-24406-2-git-send-email-pierre-yves.mordret@st.com> <20181007145722.GY2372@vkoul-mobl> <5d7a218c-9e96-3931-88ab-0b4dcb3ec4e5@st.com> <20181009085757.GI2372@vkoul-mobl> From: Pierre Yves MORDRET Message-ID: Date: Tue, 9 Oct 2018 15:46:06 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20181009085757.GI2372@vkoul-mobl> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.75.127.44] X-ClientProxiedBy: SFHDAG2NODE2.st.com (10.75.127.5) To SFHDAG5NODE2.st.com (10.75.127.14) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-10-09_09:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/09/2018 10:57 AM, Vinod wrote: > Hi Pierre, > > On 09-10-18, 09:18, Pierre Yves MORDRET wrote: > >>>> * DMA client >>>> @@ -68,7 +84,16 @@ channel: a phandle to the DMA controller plus the following four integer cells: >>>> 0x1: 1/2 full FIFO >>>> 0x2: 3/4 full FIFO >>>> 0x3: full FIFO >>>> - >>>> + -bit 2: Intermediate M2M transfer from/to DDR to/from SRAM throughout MDMA >>>> + 0: MDMA not used to generate an intermediate M2M transfer >>>> + 1: MDMA used to generate an intermediate M2M transfer. >>>> + -bit 3-4: indicated SRAM Buffer size in (2^order)*PAGE_SIZE. >>>> + PAGE_SIZE is given by Linux at 4KiB: include/asm-generic/page.h. >>>> + Order is given by those 2 bits starting at 0. >>>> + Valid only whether Intermediate M2M transfer is set. >>> >>> why do we need this as a property? >> >> In some UC, we need more than 4KiB in case of chaining for better performances. >> Chaining has to be enabled by client if performance is at sacks. > > Okay if that is the case why is the user not taking care of this? > Creating DMA txn and chaining them up and starting the chain? Why would > dmaengine driver need to do that? > User is using standard DMA API (single, sg or cyclic) and is agnostic on what is behind the scene(almost). As driver I just fulfill the request to transfer what he wants. My driver scatters transfer into SDRAM chunks defined by user. Unfortunately all transfer are not % the SDRAM size given in DT. This very last txn is to flush the last expected bytes. Whatever user set for chaining(bit 2) the DMA API remains the same at its side.