[alsa-devel] intel-hda patch for Dell Latitude D531

glogow at fbihome.de glogow at fbihome.de
Thu Oct 11 18:54:56 CEST 2007


Hi

I have attached three files to this mail:

1. patch_sigmatel.c.diff

I have a Latitude D531 which has a ATI SB600 with a STAC 9205. The  
chip is detected, but no config was read with the latest drivers. The  
problems are the dmic_nids arrays, which are ignored for auto config  
lookup. This calles is_in_nid_list, which expects a 0 terminated list,  
but these arrays are not.

Additionally I updated the dell_9205_m43_pin_configs with values from  
the latest win drivers.

2. create_dell_tables.pl

When looking into the ini files and comparing the nids and config  
values of the various tables, I got really confused, so I wrote a  
litte script to extract the values and build the table. This is the  
extended version, after I got my sound working. It extracts all pin  
infos from all ini files, generates the apropriate tables and prepends  
the Version.txt from the driver, resultiung in a kind of C header.  
Maybe it's usefull for you.

3. patch_sigmatel_dell.h

Output from running create_dell_tables.pl on the latest drivers for my  
D531 from  Dell.

HTH

Jan-Marek Glogowski


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

-------------- next part --------------
--- patch_sigmatel.c.orig	2007-10-10 20:17:29.000000000 +0200
+++ patch_sigmatel.c	2007-10-10 20:18:44.000000000 +0200
@@ -182,8 +182,11 @@
         0x02,
 };
 
-static hda_nid_t stac925x_dmic_nids[1] = {
-	0x15, 
+// DMic nids are ignored on auto config, so the array has to be NULL 
+// terminated for is_in_nid_list
+static int stac925x_dmic_nids_len = 1;
+static hda_nid_t stac925x_dmic_nids[stac925x_dmic_nids_len + 1] = {
+	0x15, 0x00,
 };
 
 static hda_nid_t stac922x_adc_nids[2] = {
@@ -210,8 +213,11 @@
         0x19, 0x1a
 };
 
-static hda_nid_t stac9205_dmic_nids[2] = {
-        0x17, 0x18,
+// DMic nids are ignored on auto config, so the array has to be NULL 
+// terminated for is_in_nid_list
+static int stac9205_dmic_nids_len = 2;
+static hda_nid_t stac9205_dmic_nids[stac9205_dmic_nids_len + 1] = {
+        0x17, 0x18, 0x00,
 };
 
 static hda_nid_t stac9200_pin_nids[8] = {
@@ -1146,9 +1152,10 @@
     10280201
 */
 static unsigned int dell_9205_m43_pin_configs[12] = {
-	0x0321101f, 0x03a11020, 0x90a70330, 0x90170310,
-	0x400000fe, 0x400000ff, 0x400000fd, 0x40f000f9,
-	0x400000fa, 0x400000fc, 0x0144131f, 0x40c003f8,
+	/* based on 92XXM4-3.ini from Dell Driver 5.10.0.5401 */
+	0x0321101f, 0x03a1102e, 0x90a70320, 0x90170310,
+	0x400000fe, 0x400000ff, 0x400000fd, 0x400000fb,
+	0x400000fa, 0x400000fc, 0x01441340, 0x400000f9,
 };
 
 static unsigned int dell_9205_m44_pin_configs[12] = {
@@ -2548,8 +2555,8 @@
 	case 0x83847633: /* STAC9202D */
 	case 0x83847636: /* STAC9251  */
 	case 0x83847637: /* STAC9251D */
-		spec->num_dmics = 1;
 		spec->dmic_nids = stac925x_dmic_nids;
+		spec->num_dmics = stac925x_dmic_nids_len;
 		break;
 	default:
 		spec->num_dmics = 0;
@@ -2798,7 +2805,7 @@
 	spec->mux_nids = stac9205_mux_nids;
 	spec->num_muxes = ARRAY_SIZE(stac9205_mux_nids);
 	spec->dmic_nids = stac9205_dmic_nids;
-	spec->num_dmics = ARRAY_SIZE(stac9205_dmic_nids);
+	spec->num_dmics = stac9205_dmic_nids_len;
 	spec->dmux_nid = 0x1d;
 
 	spec->init = stac9205_core_init;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch_sigmatel_dell.h
Type: text/x-chdr
Size: 13967 bytes
Desc: not available
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20071011/f90f594f/attachment-0001.h 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: create_dell_tables.pl
Type: text/x-perl
Size: 6302 bytes
Desc: not available
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20071011/f90f594f/attachment-0001.bin 


More information about the Alsa-devel mailing list