From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lars-Peter Clausen Subject: Re: [alsa-devel] [PATCH v2 1/3] ASoC: codecs: wm8904: add dt ids table Date: Mon, 26 Jan 2015 17:49:11 +0100 Message-ID: <54C67007.6000708@metafoo.de> References: <1418614273-2303-1-git-send-email-voice.shen@atmel.com> <20150115115425.GX3043@sirena.org.uk> <54B866B9.8000900@atmel.com> <54C65C36.9050106@atmel.com> <20150126164229.GB21293@sirena.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: In-Reply-To: <20150126164229.GB21293-GFdadSzt00ze9xe1eoZjHA@public.gmane.org> Sender: devicetree-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Mark Brown , Nicolas Ferre Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-sound-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Alexander Morozov , Bo Shen , linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org List-Id: alsa-devel@alsa-project.org On 01/26/2015 05:42 PM, Mark Brown wrote: > On Mon, Jan 26, 2015 at 04:24:38PM +0100, Nicolas Ferre wrote: >> Le 16/01/2015 02:17, Bo Shen a =E9crit : > >>>> Does this end up in the i2c_driver_id driver data or do we need so= me >>>> extra code when devtype is assigned to check for an of_node and lo= ok at >>>> the DT data instead? That certainly used to be the case... > >>> At the beginning I think as the same as you, and also add the code = to >>> get the data as I do in . However, as I >>> remember, I2C seems only use the compatible string after the comma,= that >>> means only for "wlf,wm8904", it uses "wm8904" to match. So, I remov= e all >>> the code I added, and just keep these, and it can get the device ty= pe >>> correctly. > >>> So, when I submit the patch and keep the code as simple as possible= =2E > >> I don't understand what's keeping this patch from being applied. Voi= ce, >> do you mind re-sending? > > I need to convince myself that the above actually works and is doing = the > right thing; the above explanation sounds like if it works it might b= e > relying on a bug. I'd call it a undocumented feature. But I wouldn't rely on it being aro= und=20 for ever. In my opinion to be future proof the driver should explicitly= =20 handle the OF case in the probe function. -- To unsubscribe from this list: send the line "unsubscribe devicetree" i= n the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lars-Peter Clausen Date: Mon, 26 Jan 2015 16:49:11 +0000 Subject: Re: [alsa-devel] [PATCH v2 1/3] ASoC: codecs: wm8904: add dt ids table Message-Id: <54C67007.6000708@metafoo.de> List-Id: References: <1418614273-2303-1-git-send-email-voice.shen@atmel.com> <20150115115425.GX3043@sirena.org.uk> <54B866B9.8000900@atmel.com> <54C65C36.9050106@atmel.com> <20150126164229.GB21293@sirena.org.uk> In-Reply-To: <20150126164229.GB21293@sirena.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: Mark Brown , Nicolas Ferre Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linux-sound@vger.kernel.org, Alexander Morozov , Bo Shen , linux-arm-kernel@lists.infradead.org On 01/26/2015 05:42 PM, Mark Brown wrote: > On Mon, Jan 26, 2015 at 04:24:38PM +0100, Nicolas Ferre wrote: >> Le 16/01/2015 02:17, Bo Shen a =E9crit : > >>>> Does this end up in the i2c_driver_id driver data or do we need some >>>> extra code when devtype is assigned to check for an of_node and look at >>>> the DT data instead? That certainly used to be the case... > >>> At the beginning I think as the same as you, and also add the code to >>> get the data as I do in . However, as I >>> remember, I2C seems only use the compatible string after the comma, that >>> means only for "wlf,wm8904", it uses "wm8904" to match. So, I remove all >>> the code I added, and just keep these, and it can get the device type >>> correctly. > >>> So, when I submit the patch and keep the code as simple as possible. > >> I don't understand what's keeping this patch from being applied. Voice, >> do you mind re-sending? > > I need to convince myself that the above actually works and is doing the > right thing; the above explanation sounds like if it works it might be > relying on a bug. I'd call it a undocumented feature. But I wouldn't rely on it being around = for ever. In my opinion to be future proof the driver should explicitly=20 handle the OF case in the probe function. From mboxrd@z Thu Jan 1 00:00:00 1970 From: lars@metafoo.de (Lars-Peter Clausen) Date: Mon, 26 Jan 2015 17:49:11 +0100 Subject: [alsa-devel] [PATCH v2 1/3] ASoC: codecs: wm8904: add dt ids table In-Reply-To: <20150126164229.GB21293@sirena.org.uk> References: <1418614273-2303-1-git-send-email-voice.shen@atmel.com> <20150115115425.GX3043@sirena.org.uk> <54B866B9.8000900@atmel.com> <54C65C36.9050106@atmel.com> <20150126164229.GB21293@sirena.org.uk> Message-ID: <54C67007.6000708@metafoo.de> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On 01/26/2015 05:42 PM, Mark Brown wrote: > On Mon, Jan 26, 2015 at 04:24:38PM +0100, Nicolas Ferre wrote: >> Le 16/01/2015 02:17, Bo Shen a ?crit : > >>>> Does this end up in the i2c_driver_id driver data or do we need some >>>> extra code when devtype is assigned to check for an of_node and look at >>>> the DT data instead? That certainly used to be the case... > >>> At the beginning I think as the same as you, and also add the code to >>> get the data as I do in . However, as I >>> remember, I2C seems only use the compatible string after the comma, that >>> means only for "wlf,wm8904", it uses "wm8904" to match. So, I remove all >>> the code I added, and just keep these, and it can get the device type >>> correctly. > >>> So, when I submit the patch and keep the code as simple as possible. > >> I don't understand what's keeping this patch from being applied. Voice, >> do you mind re-sending? > > I need to convince myself that the above actually works and is doing the > right thing; the above explanation sounds like if it works it might be > relying on a bug. I'd call it a undocumented feature. But I wouldn't rely on it being around for ever. In my opinion to be future proof the driver should explicitly handle the OF case in the probe function. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756374AbbAZQtT (ORCPT ); Mon, 26 Jan 2015 11:49:19 -0500 Received: from smtp-out-157.synserver.de ([212.40.185.157]:1068 "EHLO smtp-out-157.synserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755702AbbAZQtP (ORCPT ); Mon, 26 Jan 2015 11:49:15 -0500 X-SynServer-TrustedSrc: 1 X-SynServer-AuthUser: lars@metafoo.de X-SynServer-PPID: 22375 Message-ID: <54C67007.6000708@metafoo.de> Date: Mon, 26 Jan 2015 17:49:11 +0100 From: Lars-Peter Clausen User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.4.0 MIME-Version: 1.0 To: Mark Brown , Nicolas Ferre CC: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linux-sound@vger.kernel.org, Alexander Morozov , Bo Shen , linux-arm-kernel@lists.infradead.org Subject: Re: [alsa-devel] [PATCH v2 1/3] ASoC: codecs: wm8904: add dt ids table References: <1418614273-2303-1-git-send-email-voice.shen@atmel.com> <20150115115425.GX3043@sirena.org.uk> <54B866B9.8000900@atmel.com> <54C65C36.9050106@atmel.com> <20150126164229.GB21293@sirena.org.uk> In-Reply-To: <20150126164229.GB21293@sirena.org.uk> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/26/2015 05:42 PM, Mark Brown wrote: > On Mon, Jan 26, 2015 at 04:24:38PM +0100, Nicolas Ferre wrote: >> Le 16/01/2015 02:17, Bo Shen a écrit : > >>>> Does this end up in the i2c_driver_id driver data or do we need some >>>> extra code when devtype is assigned to check for an of_node and look at >>>> the DT data instead? That certainly used to be the case... > >>> At the beginning I think as the same as you, and also add the code to >>> get the data as I do in . However, as I >>> remember, I2C seems only use the compatible string after the comma, that >>> means only for "wlf,wm8904", it uses "wm8904" to match. So, I remove all >>> the code I added, and just keep these, and it can get the device type >>> correctly. > >>> So, when I submit the patch and keep the code as simple as possible. > >> I don't understand what's keeping this patch from being applied. Voice, >> do you mind re-sending? > > I need to convince myself that the above actually works and is doing the > right thing; the above explanation sounds like if it works it might be > relying on a bug. I'd call it a undocumented feature. But I wouldn't rely on it being around for ever. In my opinion to be future proof the driver should explicitly handle the OF case in the probe function.