From: Mark Brown Subject: Re: mainline tlv320aic26 driver Date: Tue, 19 May 2009 19:19:06 +0100 Message-ID: <20090519181905.GA4476@sirena.org.uk> References: <4A11AC9D.10004@drewtech.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from cassiel.sirena.org.uk (cassiel.sirena.org.uk [80.68.93.111]) by alsa0.perex.cz (Postfix) with ESMTP id 72E8210380E for ; Tue, 19 May 2009 20:19:15 +0200 (CEST) Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Grant Likely Cc: alsa-devel , Joey Oravec List-Id: alsa-devel@alsa-project.org On Tue, May 19, 2009 at 10:09:50AM -0600, Grant Likely wrote: > I don't know the best way for your fabric driver to find the aic26 spi > device. It probably should use bus_find_device() and > dev_get_drvdata() to resolve to the value that codec_data should be > set to. With non-PowerPC platforms that don't use the of-simple bodge the machine driver finds the CODEC by referencing them from the data structures referenced from the snd_soc_device. You don't need to look up the struct device for the CODEC. For an AT91 example look at the sam9g20_wm8731.c driver - you want to replace the references to the wm8731 DAI and CODEC with those for the tlv320aic26.