From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755799Ab2CTHH1 (ORCPT ); Tue, 20 Mar 2012 03:07:27 -0400 Received: from mga09.intel.com ([134.134.136.24]:33499 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754967Ab2CTHH0 (ORCPT ); Tue, 20 Mar 2012 03:07:26 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.67,351,1309762800"; d="scan'208";a="122789022" Subject: Re: [PATCH/RFC] dmaengine: add a slave parameter to __dma_request_channel() From: Vinod Koul To: Guennadi Liakhovetski Cc: Russell King - ARM Linux , linux-kernel@vger.kernel.org, "'Jassi Brar'" , Linus Walleij , Magnus Damm , Paul Mundt In-Reply-To: References: <1331101687.24656.319.camel@vkoul-udesk3> <20120307093026.GM17370@n2100.arm.linux.org.uk> <20120307103112.GP17370@n2100.arm.linux.org.uk> <20120307124620.GT17370@n2100.arm.linux.org.uk> <20120307142634.GA18787@n2100.arm.linux.org.uk> <20120307162755.GB18787@n2100.arm.linux.org.uk> <1331188201.4657.51.camel@vkoul-udesk3> <1331204128.4657.54.camel@vkoul-udesk3> <1331206459.4657.59.camel@vkoul-udesk3> <1331211513.4657.67.camel@vkoul-udesk3> <1331284918.4657.69.camel@vkoul-udesk3> <1331285959.4657.76.camel@vkoul-udesk3> <1331520476.4657.79.camel@vkoul-udesk3> <1332157021.7180.5.camel@vkoul-udesk3> <1332164062.7180.19.camel@vkoul-udesk3> <1332165604.7180.24.camel@vkoul-udesk3> <1332166938.7180.38.camel@vkoul-udesk3> <1332174036.12110.15.camel@vkoul-udesk3> Content-Type: text/plain; charset="UTF-8" Date: Tue, 20 Mar 2012 12:41:33 +0530 Message-ID: <1332227493.12110.21.camel@vkoul-udesk3> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2012-03-19 at 17:32 +0100, Guennadi Liakhovetski wrote: > Sure. In the datasheet we have: to configure a channel for client 1 write > value X to register A and value Y to register B. That's it. One of them is > really just a magic slave ID. Another one has several fields with values > like bus width and transfer size. They could be passed "properly," but > since those fields also vary between DMAC versions, it is easier to just > fix the whole register value per client and pass it from the platform > data. In any case, at least the slave ID is really just a constant, that > cannot be calculated and has to be passed from platform data. I think I like the idea of having the these slave IDs coming from platform map. That way drivers can be agnostic... -- ~Vinod