Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: ALSA development <alsa-devel@alsa-project.org>
Subject: Re: hda-intel channels hibernate bug
Date: Wed, 15 Apr 2009 16:12:16 +0200	[thread overview]
Message-ID: <s5h63h60zwf.wl%tiwai@suse.de> (raw)
In-Reply-To: <1239716613.22047.2.camel@johannes.local>

At Tue, 14 Apr 2009 15:43:33 +0200,
Johannes Berg wrote:
> 
> On Tue, 2009-04-14 at 15:40 +0200, Takashi Iwai wrote:
> 
> > >  Node 0x0d [Audio Mixer] wcaps 0x20010f: Stereo Amp-In Amp-Out
> > >    Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
> > > -  Amp-In vals:  [0x00 0x00] [0x00 0x00]
> > > +  Amp-In vals:  [0x80 0x80] [0x00 0x00]
> > >    Amp-Out caps: ofs=0x40, nsteps=0x40, stepsize=0x03, mute=0
> > >    Amp-Out vals:  [0x25 0x25]
> > >    Connection: 2
> > 
> > So the widget 0x0d is muted.  Maybe the channel mode control
> > doesn't do caching the value properly...
> 
> No idea :)
> 
> > Could you give the raw alsa-info.sh output?
> 
> Sure, below (before hibernating).

Thanks.  Could you try the patch below?

> Mind you -- mbp3 isn't really the correct thing for my machine, the
> microphone also seems to be bad when using it -- but I haven't gotten
> around to writing a proper description or trying to find it even.

Hm, could you be a bit more specific?  "seems to be bad" is relatively
subjective expression :)


Takashi

---
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index a4e5e59..fd6e6f3 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -2250,7 +2250,11 @@ int snd_hda_codec_write_cache(struct hda_codec *codec, hda_nid_t nid,
 	err = bus->ops.command(bus, res);
 	if (!err) {
 		struct hda_cache_head *c;
-		u32 key = build_cmd_cache_key(nid, verb);
+		u32 key;
+		/* parm may contain the verb stuff for get/set amp */
+		verb = verb | (parm >> 8);
+		parm &= 0xff;
+		key = build_cmd_cache_key(nid, verb);
 		c = get_alloc_hash(&codec->cmd_cache, key);
 		if (c)
 			c->val = parm;

  parent reply	other threads:[~2009-04-15 14:12 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-05  8:55 hda-intel channels hibernate bug Johannes Berg
2009-04-14 13:13 ` Takashi Iwai
2009-04-14 13:27   ` Johannes Berg
2009-04-14 13:40     ` Takashi Iwai
2009-04-14 13:43       ` Johannes Berg
2009-04-14 15:45         ` Mackenzie Morgan
2009-04-15 14:12         ` Takashi Iwai [this message]
2009-04-15 15:30           ` Johannes Berg
2009-04-15 15:37             ` Takashi Iwai
2009-04-15 15:42               ` Johannes Berg
2009-04-15 16:00               ` Johannes Berg
2009-04-15 16:08                 ` Johannes Berg
2009-04-15 15:40           ` Johannes Berg
2009-04-15 15:54             ` Takashi Iwai
2009-04-15 15:59               ` Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=s5h63h60zwf.wl%tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=johannes@sipsolutions.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox