Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp8518812ybi; Thu, 6 Jun 2019 13:52:36 -0700 (PDT) X-Google-Smtp-Source: APXvYqxDU6zXGsOJ0bBQW69YnDugef1OrJQ7ioCsa/z90GfDT3sWVMfeRb8mpa1ru8k7FCbIZ1m2 X-Received: by 2002:a65:4209:: with SMTP id c9mr422599pgq.111.1559854356849; Thu, 06 Jun 2019 13:52:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559854356; cv=none; d=google.com; s=arc-20160816; b=eYWSpftMQZ1DGmpf8d4SDFeJmzvwb0lETzTUndJDWo5OSI4inzqPvGTHlwHqJgC1br hA11HKnIu0jpAERlANbztLF+AgVRAdCygy8RKElcQACI6U80N4iyuSWAIp1Eh8hJVzie ALXKTL7jTyZKYp5UL78kcF32p085LjFRene8kqA92nZ0yXAxeBup75MNdG4jrl9ER9lI OUiN7WJsm1UesjguCd4nZ5SU36N00IupRoG+4DAkhvUPq2C1SBbZqIrpb8uqWtTA1B6o eX+anaYhRmRSXCySKtuZRymhZgVGqgF0YeR7cdR8y3as6zCihnzY23b3I1W2Ktvb1SxD m4hA== 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:dkim-signature; bh=NBsMfRuKTrjUWRbWIua1fvZvKysXDdRrLhHLJlMCHME=; b=q2U10/8OgHLwoEO6vRLeWJxNf0xfghN9zFKmgQYqSlx3eCChgflIEstx1Xm2Alg+IV kTX8J0mxJF7JGkle/xQcR07e8QTVmL15oFVUih9RVn5oO2TwK2X//hgb8RWJcYovuVWM EdfFK2bQMVMq6P8OdUZsN8wtWebrEa07mbukDkwMxrBzqH0RGUR12ssSAbk3gJbqB4vI a8Zua27+LUBWvdcUMt29yqLfMfXuM3YFm5a5rfuj4NEhFe3UlVoIGPZZWH7RNLOz2EQh 0T1NnZpx8qMOaOEHDidVTn/mXnkbRcUdzFKhDBzY6n3CAgMFazxEOAYMJqh7PeR1CDZ2 CFHw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=rBk2vwzm; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h194si12370pfe.95.2019.06.06.13.52.19; Thu, 06 Jun 2019 13:52:36 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=rBk2vwzm; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727478AbfFFQor (ORCPT + 99 others); Thu, 6 Jun 2019 12:44:47 -0400 Received: from mail-io1-f49.google.com ([209.85.166.49]:37243 "EHLO mail-io1-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726744AbfFFQoq (ORCPT ); Thu, 6 Jun 2019 12:44:46 -0400 Received: by mail-io1-f49.google.com with SMTP id e5so732769iok.4; Thu, 06 Jun 2019 09:44:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=NBsMfRuKTrjUWRbWIua1fvZvKysXDdRrLhHLJlMCHME=; b=rBk2vwzme22eGy5imGJ247qFBWoJ2gbU50Z7FWsuQ0q4oaeHHYONAUgT6DnLDG1wm0 oYPOfSTQv42gC65LEmlkkBCbpaX/M28gMmBmywM8CtrRa0xNbnV5NEd8n+8RhFg5gDxk Nz0ik41bbd8/bLyoH5BiyqHziN2cmIGz1o/oejb9i73pFK9JvOWRZMOxcZPB8Z3UHQSJ A47IF4D9+KY/k5tXGgm6qyvDj4CP31xSYc0le7S31MEEsUqEZe8NbxbGIDHSn0/4jIH2 WiTs5ErFEpCzFvsMTZEcPgPukKfm9UUcU7m5P2RaX6Iz4gaUa6KRzJtBl0wun2OvqTGg +HLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=NBsMfRuKTrjUWRbWIua1fvZvKysXDdRrLhHLJlMCHME=; b=VN2s55ujDiwhuvsG6fhW8ieBnE5sF9Dms2MCL90udmB5M7cFhcTCvVmc+P6a3UNsS9 37A4WagMrBnsW+af3FXaUpuYuJGu7kg+/DZarroRIAuL3IepGBNP41KIZpWMczAQ3uVE 5H+dvv9kFFKc7TJ22kDDJtbHOC61pTIPbv/SE25+LK8vT4VlfT+qfhC4PCh7kMxGAVZ8 FzVcvgNAkCs6dJe4U/g+zPZYmGyGC3jf4xTmLO+Ydda6rrmackaiyTn5jknkA0YMoks2 BnqWhpYfJCGSLt63C26t6DcDDPJXl84zrhGAFT+cmc4ZaPqocz5qnFrYI4GoSAOTVyFF XdGw== X-Gm-Message-State: APjAAAXVkUS1V9vg+fnG4McJwswLDILqMaqraXcMijRUa5y2Vyyr04VH R/oBCt/Tw78jgcheNaULQmTSkh8J X-Received: by 2002:a5e:8704:: with SMTP id y4mr28492011ioj.135.1559839485574; Thu, 06 Jun 2019 09:44:45 -0700 (PDT) Received: from [192.168.2.145] ([94.29.35.141]) by smtp.googlemail.com with ESMTPSA id 143sm1156389itw.9.2019.06.06.09.44.42 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 06 Jun 2019 09:44:45 -0700 (PDT) Subject: Re: [PATCH] [RFC] dmaengine: add fifo_size member To: Jon Hunter , Peter Ujfalusi , Sameer Pujar , Vinod Koul Cc: dan.j.williams@intel.com, tiwai@suse.com, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, sharadg@nvidia.com, rlokhande@nvidia.com, dramesh@nvidia.com, mkumard@nvidia.com, linux-tegra References: <1556623828-21577-1-git-send-email-spujar@nvidia.com> <20190502060446.GI3845@vkoul-mobl.Dlink> <20190502122506.GP3845@vkoul-mobl.Dlink> <3368d1e1-0d7f-f602-5b96-a978fcf4d91b@nvidia.com> <20190504102304.GZ3845@vkoul-mobl.Dlink> <20190506155046.GH3845@vkoul-mobl.Dlink> <4cab47d0-41c3-5a87-48e1-d7f085c2e091@nvidia.com> <8a5b84db-c00b-fff4-543f-69d90c245660@nvidia.com> <3f836a10-eaf3-f59b-7170-6fe937cf2e43@ti.com> <4593f37c-5e89-8559-4e80-99dbfe4235de@nvidia.com> <50e1f9ed-1ea0-38f6-1a77-febd6a3a0848@gmail.com> <4b098fb6-1a5b-1100-ae16-978a887c9535@nvidia.com> From: Dmitry Osipenko Message-ID: Date: Thu, 6 Jun 2019 19:44:41 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <4b098fb6-1a5b-1100-ae16-978a887c9535@nvidia.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 06.06.2019 19:32, Jon Hunter пишет: > > On 06/06/2019 16:18, Dmitry Osipenko wrote: > > ... > >>>> If I understood everything correctly, the FIFO buffer is shared among >>>> all of the ADMA clients and hence it should be up to the ADMA driver to >>>> manage the quotas of the clients. So if there is only one client that >>>> uses ADMA at a time, then this client will get a whole FIFO buffer, but >>>> once another client starts to use ADMA, then the ADMA driver will have >>>> to reconfigure hardware to split the quotas. >>> >>> The FIFO quotas are managed by the ADMAIF driver (does not exist in >>> mainline currently but we are working to upstream this) because it is >>> this device that owns and needs to configure the FIFOs. So it is really >>> a means to pass the information from the ADMAIF to the ADMA. >> >> So you'd want to reserve a larger FIFO for an audio channel that has a >> higher audio rate since it will perform reads more often. You could also >> prioritize one channel over the others, like in a case of audio call for >> example. >> >> Is the shared buffer smaller than may be needed by clients in a worst >> case scenario? If you could split the quotas statically such that each >> client won't ever starve, then seems there is no much need in the >> dynamic configuration. > > Actually, this is still very much relevant for the static case. Even if > we defined a static configuration of the FIFO mapping in the ADMAIF > driver we still need to pass this information to the ADMA. I don't > really like the idea of having it statically defined in two different > drivers. Ah, so you need to apply the same configuration in two places. Correct? Are ADMAIF and ADMA really two different hardware blocks? Or you artificially decoupled the ADMA driver?