[patch 16/22] sound: oxygen: handle cards with missing EEPROM

From: Greg KH
Date: Thu Sep 10 2009 - 20:31:03 EST


2.6.30-stable review patch. If anyone has any objections, please let us know.

------------------
From: Clemens Ladisch <clemens@xxxxxxxxxx>

commit 92653453c3015c083b9fe0ad48261c6b2267d482 upstream.

The card model detection code introduced in 2.6.30 that tries to work
around partially broken EEPROM contents by reading the EEPROM directly
does not handle cards where the EEPROM has been omitted. In this case,
we have to use the default ID to allow the driver to load.

Signed-off-by: Clemens Ladisch <clemens@xxxxxxxxxx>
Reported-and-tested-by: Ozan Ã?aÄ?layan <ozan@xxxxxxxxxxxxx>
Signed-off-by: Takashi Iwai <tiwai@xxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxx>

---
sound/pci/oxygen/oxygen_lib.c | 3 +++
1 file changed, 3 insertions(+)

--- a/sound/pci/oxygen/oxygen_lib.c
+++ b/sound/pci/oxygen/oxygen_lib.c
@@ -260,6 +260,9 @@ oxygen_search_pci_id(struct oxygen *chip
* chip didn't if the first EEPROM word was overwritten.
*/
subdevice = oxygen_read_eeprom(chip, 2);
+ /* use default ID if EEPROM is missing */
+ if (subdevice == 0xffff)
+ subdevice = 0x8788;
/*
* We use only the subsystem device ID for searching because it is
* unique even without the subsystem vendor ID, which may have been


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/