Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 223583
b: refs/heads/master
c: 7693457
h: refs/heads/master
i:
  223581: acecbdb
  223579: 4990a0e
  223575: 6b8e17f
  223567: ed15cb6
  223551: 6d3bd61
v: v3
  • Loading branch information
Takashi Iwai committed Dec 23, 2010
1 parent 559f7de commit 4e26fcd
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7039c74cb54652ba6d726ad4d2a42dbac95a97be
refs/heads/master: 7693457547b729d9010a6014bbb8572b085f58d4
10 changes: 7 additions & 3 deletions trunk/sound/core/pcm_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -1070,8 +1070,10 @@ int snd_pcm_hw_rule_add(struct snd_pcm_runtime *runtime, unsigned int cond,
struct snd_pcm_hw_rule *new;
unsigned int new_rules = constrs->rules_all + 16;
new = kcalloc(new_rules, sizeof(*c), GFP_KERNEL);
if (!new)
if (!new) {
va_end(args);
return -ENOMEM;
}
if (constrs->rules) {
memcpy(new, constrs->rules,
constrs->rules_num * sizeof(*c));
Expand All @@ -1087,8 +1089,10 @@ int snd_pcm_hw_rule_add(struct snd_pcm_runtime *runtime, unsigned int cond,
c->private = private;
k = 0;
while (1) {
if (snd_BUG_ON(k >= ARRAY_SIZE(c->deps)))
if (snd_BUG_ON(k >= ARRAY_SIZE(c->deps))) {
va_end(args);
return -EINVAL;
}
c->deps[k++] = dep;
if (dep < 0)
break;
Expand All @@ -1097,7 +1101,7 @@ int snd_pcm_hw_rule_add(struct snd_pcm_runtime *runtime, unsigned int cond,
constrs->rules_num++;
va_end(args);
return 0;
}
}

EXPORT_SYMBOL(snd_pcm_hw_rule_add);

Expand Down
2 changes: 1 addition & 1 deletion trunk/sound/soc/codecs/wm8580.c
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@
static const u16 wm8580_reg[] = {
0x0121, 0x017e, 0x007d, 0x0014, /*R3*/
0x0121, 0x017e, 0x007d, 0x0194, /*R7*/
0x001c, 0x0002, 0x0002, 0x00c2, /*R11*/
0x0010, 0x0002, 0x0002, 0x00c2, /*R11*/
0x0182, 0x0082, 0x000a, 0x0024, /*R15*/
0x0009, 0x0000, 0x00ff, 0x0000, /*R19*/
0x00ff, 0x00ff, 0x00ff, 0x00ff, /*R23*/
Expand Down
3 changes: 2 additions & 1 deletion trunk/sound/soc/codecs/wm8904.c
Original file line number Diff line number Diff line change
Expand Up @@ -818,7 +818,8 @@ static int wm8904_get_deemph(struct snd_kcontrol *kcontrol,
struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol);
struct wm8904_priv *wm8904 = snd_soc_codec_get_drvdata(codec);

return wm8904->deemph;
ucontrol->value.enumerated.item[0] = wm8904->deemph;
return 0;
}

static int wm8904_put_deemph(struct snd_kcontrol *kcontrol,
Expand Down
3 changes: 2 additions & 1 deletion trunk/sound/soc/codecs/wm8955.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,8 @@ static int wm8955_get_deemph(struct snd_kcontrol *kcontrol,
struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol);
struct wm8955_priv *wm8955 = snd_soc_codec_get_drvdata(codec);

return wm8955->deemph;
ucontrol->value.enumerated.item[0] = wm8955->deemph;
return 0;
}

static int wm8955_put_deemph(struct snd_kcontrol *kcontrol,
Expand Down
3 changes: 2 additions & 1 deletion trunk/sound/soc/codecs/wm8960.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,8 @@ static int wm8960_get_deemph(struct snd_kcontrol *kcontrol,
struct snd_soc_codec *codec = snd_kcontrol_chip(kcontrol);
struct wm8960_priv *wm8960 = snd_soc_codec_get_drvdata(codec);

return wm8960->deemph;
ucontrol->value.enumerated.item[0] = wm8960->deemph;
return 0;
}

static int wm8960_put_deemph(struct snd_kcontrol *kcontrol,
Expand Down
3 changes: 3 additions & 0 deletions trunk/sound/soc/soc-dapm.c
Original file line number Diff line number Diff line change
Expand Up @@ -944,6 +944,9 @@ static int dapm_power_widgets(struct snd_soc_codec *codec, int event)
case SND_SOC_DAPM_STREAM_RESUME:
sys_power = 1;
break;
case SND_SOC_DAPM_STREAM_STOP:
sys_power = !!codec->active;
break;
case SND_SOC_DAPM_STREAM_SUSPEND:
sys_power = 0;
break;
Expand Down

0 comments on commit 4e26fcd

Please sign in to comment.