rpms/kernel/F-7 linux-2.6-alsa-toshiba-a100.patch, NONE, 1.1 kernel-2.6.spec, 1.3195, 1.3196

Dave Jones (davej) fedora-extras-commits at redhat.com
Thu May 24 15:17:08 UTC 2007


Author: davej

Update of /cvs/pkgs/rpms/kernel/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv13865

Modified Files:
	kernel-2.6.spec 
Added Files:
	linux-2.6-alsa-toshiba-a100.patch 
Log Message:
* Thu May 24 2007 Dave Jones <davej at redhat.com>
- [ALSA] hda-intel - Probe additional slots only
- [ALSA] hda-intel - Fix detection of audio codec


linux-2.6-alsa-toshiba-a100.patch:

--- NEW FILE linux-2.6-alsa-toshiba-a100.patch ---
>From davej  Wed May 23 16:44:42 2007
Return-Path: <cebbert at redhat.com>
X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on
	gelk.kernelslacker.org
X-Spam-Level: 
X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,
	UNPARSEABLE_RELAY autolearn=ham version=3.1.8
Received: from pobox.devel.redhat.com [10.11.255.8]
	by gelk.kernelslacker.org with IMAP (fetchmail-6.3.6)
	for <davej at localhost> (single-drop); Wed, 23 May 2007 16:44:42 -0400 (EDT)
Received: from pobox.devel.redhat.com ([unix socket])
	 by pobox.devel.redhat.com (Cyrus v2.2.12-Invoca-RPM-2.2.12-8.1.RHEL4) with LMTPA;
	 Wed, 23 May 2007 16:43:18 -0400
X-Sieve: CMU Sieve 2.2
Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254])
	by pobox.devel.redhat.com (8.13.1/8.13.1) with ESMTP id l4NKhIjN024005
	for <davej at pobox.devel.redhat.com>; Wed, 23 May 2007 16:43:18 -0400
Received: from mail.boston.redhat.com (mail.boston.redhat.com [172.16.76.12])
	by int-mx1.corp.redhat.com (8.13.1/8.13.1) with ESMTP id l4NKhIJR010324;
	Wed, 23 May 2007 16:43:18 -0400
Received: from [172.16.83.145] (dhcp83-145.boston.redhat.com [172.16.83.145])
	by mail.boston.redhat.com (8.13.1/8.13.1) with ESMTP id l4NKhHpd017535;
	Wed, 23 May 2007 16:43:17 -0400
Message-ID: <4654A765.6060902 at redhat.com>
Date: Wed, 23 May 2007 16:43:17 -0400
From: Chuck Ebbert <cebbert at redhat.com>
Organization: Red Hat
User-Agent: Thunderbird 1.5.0.10 (X11/20070302)
MIME-Version: 1.0
To: linux-stable <stable at kernel.org>
CC: Dave Jones <davej at redhat.com>, Takashi Iwai <tiwai at suse.de>
Subject: [stable][2.6.21][1/2] [ALSA] hda-intel - Probe additional slots only
 if necessary
Content-Type: multipart/mixed;
 boundary="------------010709030902010508030207"
Status: RO
Content-Length: 2963
Lines: 83

This is a multi-part message in MIME format.
--------------010709030902010508030207
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit


--------------010709030902010508030207
Content-Type: text/plain;
 name*0="linux-2.6-21.3a-hda_intel_probe_additional_slots_if_necessary.pa";
 name*1="tch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename*0="linux-2.6-21.3a-hda_intel_probe_additional_slots_if_necessar";
 filename*1="y.patch"

Gitweb:     http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=19a982b69442d39b3bb6e710677320182480576b
Commit:     19a982b69442d39b3bb6e710677320182480576b
Parent:     4505179c73197c39272e8e66a172ab788009e07e
Author:     Takashi Iwai <tiwai at suse.de>
AuthorDate: Wed Mar 21 15:14:35 2007 +0100
Committer:  Jaroslav Kysela <perex at suse.cz>
CommitDate: Fri May 11 16:55:52 2007 +0200

    [ALSA] hda-intel - Probe additional slots only if necessary
    
    Probing the codec slots on ATI controller causes problems on some
    devices like Acer laptops.  On these devices, reading from codec
    slot 3 results in the communication failure with the codec chip.
    Meanwhile, some laptops (e.g. Gateway) have the codec connection
    only on slot 3, and probing this slot is mandatory for them.
    The patch improves the probing robustness.  The additional slots
    are now checked only when no codecs are found in the primary three
    slots.
    
    Signed-off-by: Takashi Iwai <tiwai at suse.de>
    Signed-off-by: Jaroslav Kysela <perex at suse.cz>
---
 sound/pci/hda/hda_intel.c |   16 ++++++++++++++--
 1 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 517a8d7..5e478b9 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -198,6 +198,7 @@ enum { SDI0, SDI1, SDI2, SDI3, SDO0, SDO1, SDO2, SDO3 };
 #define RIRB_INT_MASK		0x05
 
 /* STATESTS int mask: SD2,SD1,SD0 */
+#define AZX_MAX_CODECS		3
 #define STATESTS_INT_MASK	0x07
 
 /* SD_CTL bits */
@@ -991,7 +992,7 @@ static int __devinit azx_codec_create(struct azx *chip, const char *model)
 		return err;
 
 	codecs = 0;
-	for (c = 0; c < azx_max_codecs[chip->driver_type]; c++) {
+	for (c = 0; c < AZX_MAX_CODECS; c++) {
 		if ((chip->codec_mask & (1 << c)) & probe_mask) {
 			err = snd_hda_codec_new(chip->bus, c, NULL);
 			if (err < 0)
@@ -999,7 +1000,18 @@ static int __devinit azx_codec_create(struct azx *chip, const char *model)
 			codecs++;
 		}
 	}
-	if (! codecs) {
+	if (!codecs) {
+		/* probe additional slots if no codec is found */
+		for (; c < azx_max_codecs[chip->driver_type]; c++) {
+			if ((chip->codec_mask & (1 << c)) & probe_mask) {
+				err = snd_hda_codec_new(chip->bus, c, NULL);
+				if (err < 0)
+					continue;
+				codecs++;
+			}
+		}
+	}
+	if (!codecs) {
 		snd_printk(KERN_ERR SFX "no codecs initialized\n");
 		return -ENXIO;
 	}

--------------010709030902010508030207--

>From davej  Wed May 23 16:44:44 2007
Return-Path: <cebbert at redhat.com>
X-Spam-Checker-Version: SpamAssassin 3.1.8 (2007-02-13) on
	gelk.kernelslacker.org
X-Spam-Level: 
X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,
	UNPARSEABLE_RELAY autolearn=ham version=3.1.8
Received: from pobox.devel.redhat.com [10.11.255.8]
	by gelk.kernelslacker.org with IMAP (fetchmail-6.3.6)
	for <davej at localhost> (single-drop); Wed, 23 May 2007 16:44:44 -0400 (EDT)
Received: from pobox.devel.redhat.com ([unix socket])
	 by pobox.devel.redhat.com (Cyrus v2.2.12-Invoca-RPM-2.2.12-8.1.RHEL4) with LMTPA;
	 Wed, 23 May 2007 16:44:37 -0400
X-Sieve: CMU Sieve 2.2
Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254])
	by pobox.devel.redhat.com (8.13.1/8.13.1) with ESMTP id l4NKiblY024110
	for <davej at pobox.devel.redhat.com>; Wed, 23 May 2007 16:44:37 -0400
Received: from mail.boston.redhat.com (mail.boston.redhat.com [172.16.76.12])
	by int-mx1.corp.redhat.com (8.13.1/8.13.1) with ESMTP id l4NKiaSu010754;
	Wed, 23 May 2007 16:44:36 -0400
Received: from [172.16.83.145] (dhcp83-145.boston.redhat.com [172.16.83.145])
	by mail.boston.redhat.com (8.13.1/8.13.1) with ESMTP id l4NKiaWM017648;
	Wed, 23 May 2007 16:44:36 -0400
Message-ID: <4654A7B4.4080309 at redhat.com>
Date: Wed, 23 May 2007 16:44:36 -0400
From: Chuck Ebbert <cebbert at redhat.com>
Organization: Red Hat
User-Agent: Thunderbird 1.5.0.10 (X11/20070302)
MIME-Version: 1.0
To: linux-stable <stable at kernel.org>, Dave Jones <davej at redhat.com>
CC: Takashi Iwai <tiwai at suse.de>
Subject: [stable][2.6.21][2/2] [ALSA] hda-intel - Fix detection of audio codec
 on Toshiba A100
Content-Type: multipart/mixed;
 boundary="------------000009080809070900090104"
Status: RO
Content-Length: 2686
Lines: 74

This is a multi-part message in MIME format.
--------------000009080809070900090104
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit


--------------000009080809070900090104
Content-Type: text/plain;
 name*0="linux-2.6-21.3a-hda_intel_fix_detection_of_toshiba_laptop.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename*0="linux-2.6-21.3a-hda_intel_fix_detection_of_toshiba_laptop.pa";
 filename*1="tch"

Gitweb:     http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=bccad14e9a931027b72f20fe7caba68fea760e7b
Commit:     bccad14e9a931027b72f20fe7caba68fea760e7b
Parent:     baba8ee9d12d17cac1042a5c816aef7d6610a6c3
Author:     Takashi Iwai <tiwai at suse.de>
AuthorDate: Tue Apr 24 12:23:53 2007 +0200
Committer:  Jaroslav Kysela <perex at suse.cz>
CommitDate: Fri May 11 16:56:09 2007 +0200

    [ALSA] hda-intel - Fix detection of audio codec on Toshiba A100
    
    Some boards have the audio codec on slot #3 while the modem codec
    on slot #0.  The driver should continue to probe the slots when
    no audio codec is found.
    This fixes the problem of no device on Toshiba A100 (and some other
    ATI SB450 devices).
    
    Signed-off-by: Takashi Iwai <tiwai at suse.de>
    Signed-off-by: Jaroslav Kysela <perex at suse.cz>
---
 sound/pci/hda/hda_intel.c |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 5e478b9..d409515 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -979,7 +979,7 @@ static unsigned int azx_max_codecs[] __devinitdata = {
 static int __devinit azx_codec_create(struct azx *chip, const char *model)
 {
 	struct hda_bus_template bus_temp;
-	int c, codecs, err;
+	int c, codecs, audio_codecs, err;
 
 	memset(&bus_temp, 0, sizeof(bus_temp));
 	bus_temp.private_data = chip;
@@ -991,16 +991,19 @@ static int __devinit azx_codec_create(struct azx *chip, const char *model)
 	if ((err = snd_hda_bus_new(chip->card, &bus_temp, &chip->bus)) < 0)
 		return err;
 
-	codecs = 0;
+	codecs = audio_codecs = 0;
 	for (c = 0; c < AZX_MAX_CODECS; c++) {
 		if ((chip->codec_mask & (1 << c)) & probe_mask) {
-			err = snd_hda_codec_new(chip->bus, c, NULL);
+			struct hda_codec *codec;
+			err = snd_hda_codec_new(chip->bus, c, &codec);
 			if (err < 0)
 				continue;
 			codecs++;
+			if (codec->afg)
+				audio_codecs++;
 		}
 	}
-	if (!codecs) {
+	if (!audio_codecs) {
 		/* probe additional slots if no codec is found */
 		for (; c < azx_max_codecs[chip->driver_type]; c++) {
 			if ((chip->codec_mask & (1 << c)) & probe_mask) {

--------------000009080809070900090104--



Index: kernel-2.6.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-7/kernel-2.6.spec,v
retrieving revision 1.3195
retrieving revision 1.3196
diff -u -r1.3195 -r1.3196
--- kernel-2.6.spec	24 May 2007 15:13:52 -0000	1.3195
+++ kernel-2.6.spec	24 May 2007 15:16:33 -0000	1.3196
@@ -583,6 +583,7 @@
 Patch1730: linux-2.6-suspend-ordering.patch
 Patch1740: linux-2.6-softlockup-disable.patch
 Patch1750: linux-2.6-singlethread-freezable-workqueues.patch
+Patch1760: linux-2.6-alsa-toshiba-a100.patch
 Patch1770: linux-2.6-optimise-spinlock-debug.patch
 Patch1771: linux-2.6-silence-noise.patch
 Patch1780: linux-2.6-prevent-idle-softirq.patch
@@ -1340,6 +1341,9 @@
 %patch1740 -p1
 # Make freezable workqueues single threaded.
 %patch1750 -p1
+# [ALSA] hda-intel - Probe additional slots only
+# [ALSA] hda-intel - Fix detection of audio codec
+%patch1760 -p1
 # Speed up spinlock debug.
 %patch1770 -p1
 # Silence some useless messages that still get printed with 'quiet'
@@ -2408,6 +2412,10 @@
 
 %changelog
 * Thu May 24 2007 Dave Jones <davej at redhat.com>
+- [ALSA] hda-intel - Probe additional slots only
+- [ALSA] hda-intel - Fix detection of audio codec
+
+* Thu May 24 2007 Dave Jones <davej at redhat.com>
 - Add Dell e520 to shutdown DMI blacklist.
 
 * Wed May 23 2007 Dave Jones <davej at redhat.com>




More information about the fedora-extras-commits mailing list