From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753058Ab2I0Jmg (ORCPT ); Thu, 27 Sep 2012 05:42:36 -0400 Received: from mga14.intel.com ([143.182.124.37]:29060 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751645Ab2I0Jmd (ORCPT ); Thu, 27 Sep 2012 05:42:33 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.80,494,1344236400"; d="scan'208";a="197849752" Subject: Re: [RFC PATCH 10/13] spi: omap2-mcspi: dma_request_slave_channel() support for DT platforms From: Vinod Koul To: Matt Porter Cc: Tony Lindgren , Arnd Bergmann , Linux DaVinci Kernel List , Linux OMAP List , Russell King , Benoit Cousson , Linux Documentation List , Linux MMC List , Devicetree Discuss , Mark Brown , Linux Kernel Mailing List , Rob Herring , Grant Likely , Rob Landley , Dan Williams , Linux SPI Devel List , Chris Ball , Linux ARM Kernel List In-Reply-To: <20120921183729.GI16522@beef> References: <1348152226-13588-1-git-send-email-mporter@ti.com> <1348152226-13588-11-git-send-email-mporter@ti.com> <20120920220931.GJ28835@atomide.com> <201209210816.01473.arnd@arndb.de> <20120921154247.GZ28835@atomide.com> <20120921183729.GI16522@beef> Content-Type: text/plain; charset="UTF-8" Date: Thu, 27 Sep 2012 15:06:34 +0530 Message-ID: <1348738594.1648.9.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 Fri, 2012-09-21 at 14:37 -0400, Matt Porter wrote: > On Fri, Sep 21, 2012 at 08:42:47AM -0700, Tony Lindgren wrote: > > > > Can't we come up with a version of dma_request_slave_channel that works > > both ways for now: > > > > mcspi_dma->dma_rx = > > dma_request_slave_channel_compat(mask, omap_dma_filter_fn, &sig, > > &master->dev, mcspi_dma->dma_rx_ch_name); > > ... > > > > Then it's just question of patching away two lines later on rather than > > having to add all this if else to all the drivers first, then patching > > it away again. > > I think that something like that is workable with the implementation > simply checking for of_node to do the right thing. Yes, I think it would be better to have common API but underneath two implementations in transitional phase. -- ~Vinod