All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vasily Khoruzhick <anarsoul@gmail.com>
To: alsa-devel@alsa-project.org
Subject: Re: 1.0.15rc3 patch_analog.s bug + fix
Date: Tue, 16 Oct 2007 10:58:19 +0300	[thread overview]
Message-ID: <200710161058.19929.anarsoul@gmail.com> (raw)
In-Reply-To: <20071015203421.GA6047@jay.phy.queensu.ca>

> > Hmm, the code logic looks correct to me.  If HP jack is present, the
> > internal speaker should be muted.  Otherwise it follows the state of
> > HP jack (muted/unmuted, that acts as a master switch).

Original patch:
	present = snd_hda_codec_read(codec, 0x1a, 0,
				     AC_VERB_GET_PIN_SENSE, 0) & 0x80000000;
 
Code in alsa (patch-analog.c line 614):

	present = snd_hda_codec_read(codec, 0x1a, 0, AC_VERB_GET_PIN_SENSE, 0);
	spec->jack_present = (present & 0x80000000) != 0;

Seems to have quite different logic, don't it?

Should be:

	present = snd_hda_codec_read(codec, 0x1a, 0, AC_VERB_GET_PIN_SENSE, 0);
	spec->jack_present = (present & 0x80000000) == 0;

P.S. It's very sad that you've released 1.0.15 with that bug :(

  parent reply	other threads:[~2007-10-16  7:58 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-15  2:53 1.0.15rc3 patch_analog.s bug + fix Peter Skensved
2007-10-15 11:29 ` Takashi Iwai
2007-10-15 20:34   ` Peter Skensved
2007-10-16  7:39     ` Vasily Khoruzhick
2007-10-16 11:25       ` Takashi Iwai
2007-10-16 18:30         ` Vasily Khoruzhick
2007-10-17  7:34           ` Takashi Iwai
2007-10-17 16:10             ` Василий
2007-10-17 15:43               ` Takashi Iwai
2007-10-16  7:58     ` Vasily Khoruzhick [this message]
2007-10-16 11:32       ` Takashi Iwai
2007-10-16 12:14         ` Ma Begaj
2007-10-16 11:38     ` Takashi Iwai
2007-10-17 14:55       ` Peter Skensved

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=200710161058.19929.anarsoul@gmail.com \
    --to=anarsoul@gmail.com \
    --cc=alsa-devel@alsa-project.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.