lkml.org 
[lkml]   [2012]   [Jul]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/5] ASoC: dapm: If one widget fails, do not force all subsequent widgets to fail too
On 31/07/12 15:56, Mark Brown wrote:
> On Tue, Jul 31, 2012 at 03:45:40PM +0100, Lee Jones wrote:
>> If a list of widgets is provided and one of them fails to be added as
>> a control, the present semantics fail all subsequent widgets. A better
>> solution would be to only fail that widget, but pursue in attempting
>> to add the rest of the list.
>
> To reiterate, this is in *no* way urgent or even a bug fix.

It fixes sound in our driver.

Without this the card failes to instantiate.

>> dev_err(dapm->dev,
>> "ASoC: Failed to create DAPM control %s\n",
>> widget->name);
>> - ret = -ENOMEM;
>> - break;
>
> Indeed, removing the error return is a regression.

Isn't the return code incorrect? There are a multitude of reasons why
snd_soc_dapm_new_control() would fail. No-memory is just one of them, so
why do we force this probable lie?

--
Lee Jones
Linaro ST-Ericsson Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2012-07-31 18:01    [W:0.093 / U:0.144 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site