All of lore.kernel.org
 help / color / mirror / Atom feed
From: zhejiang <zhe.jiang@intel.com>
To: Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel@alsa-project.org
Subject: Re: patch for Dell 1210 which using stac9221 codec
Date: Thu, 01 Nov 2007 10:14:55 +0800	[thread overview]
Message-ID: <1193883295.5345.11.camel@localhost.localdomain> (raw)
In-Reply-To: <s5hve8noey5.wl%tiwai@suse.de>

On Wed, 2007-10-31 at 09:39 +0100, Takashi Iwai wrote:

> > So,we should patch the patch_sigmatel.c like that?
> 
> Yes, that's what I meant (almost same change I did in my local tree :)
> I'm going to split this to two pieces, the change of m82 pin config
> and the hack for multi-HP outs (also my last change to autocfg
> parser).
> 
> Anyway, could you give your sign-off?  Then I'll apply the patches to
> the HG tree for better testing.

Okay. Thanks

One minor issue:
The mic pin is always in the hp_outs and have the unsolicited response
ability.

If someone just plug the mic jack,the speaker will be muted.

How about this patch?
1.We may only return true in get_pin_presence() when it works as HP.
2.Trigger a unsol_event in stac92xx_io_switch_put();

Thanks!

diff -Nur a/alsa-driver-hg20071031/alsa-kernel/pci/hda/patch_sigmatel.c
b/alsa-driver-hg20071031/alsa-kernel/pci/hda/patch_sigmatel.c
--- a/alsa-driver-hg20071031/alsa-kernel/pci/hda/patch_sigmatel.c
2007-10-23 08:00:10.000000000 +0800
+++ b/alsa-driver-hg20071031/alsa-kernel/pci/hda/patch_sigmatel.c
2007-11-01 09:59:12.000000000 +0800
@@ -1552,6 +1552,9 @@
 			pinctl |= stac92xx_get_vref(codec, nid);
 		stac92xx_auto_set_pinctl(codec, nid, pinctl);
 	}
+
+	codec->patch_ops.unsol_event(codec, STAC_HP_EVENT << 26);
+
         return 1;
 }
 
@@ -2409,8 +2412,14 @@
 	if (!nid)
 		return 0;
 	if (snd_hda_codec_read(codec, nid, 0, AC_VERB_GET_PIN_SENSE, 0x00)
-	    & (1 << 31))
-		return 1;
+	    & (1 << 31)) {
+		if (snd_hda_codec_read(codec, nid,
+			0, AC_VERB_GET_PIN_WIDGET_CONTROL, 0x00) & AC_PINCTL_IN_EN)
+			return 0;
+		else
+			return 1;
+	}
+		
 	return 0;
 }
 


> 
> Thanks,
> 
> Takashi
> 

  parent reply	other threads:[~2007-11-01  2:18 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-18  2:49 patch for Dell 1210 which using stac9221 codec zhejiang
2007-10-18 14:55 ` Takashi Iwai
2007-10-19  6:02   ` zhejiang
2007-10-19  5:38     ` Takashi Iwai
2007-10-19  7:42       ` zhejiang
2007-10-19  8:39         ` Takashi Iwai
2007-10-22  6:08           ` zhejiang
2007-10-23  9:11             ` Takashi Iwai
2007-10-25  7:44               ` zhejiang
2007-10-25  9:07                 ` Takashi Iwai
2007-10-30  9:05                   ` zhejiang
2007-10-30 13:53                     ` Takashi Iwai
2007-10-31  8:49                       ` zhejiang
2007-10-31  8:39                         ` Takashi Iwai
2007-10-31 14:25                           ` Takashi Iwai
2007-11-01  2:14                           ` zhejiang [this message]
2007-11-08  7:06                           ` zhejiang
2007-11-08  4:48                             ` Takashi Iwai
2007-11-09  4:53                               ` zhejiang
2007-11-13  9:16                                 ` Jiang, Zhe
2007-11-13  8:10                                   ` Takashi Iwai
2007-10-30 15:48                 ` Tobin Davis
2007-10-30 13:51                   ` Takashi Iwai
2007-10-31  8:43                   ` zhejiang

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=1193883295.5345.11.camel@localhost.localdomain \
    --to=zhe.jiang@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=tiwai@suse.de \
    /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.