- allow multiple ac97 quirks for one piece of hardware
PATCH 1/1 - allow multiple ac97 quirks for one piece of hardware
snd_ac97_tune_hardware currently exits after applying a single ac97 quirk. There are bits of hardware (current HPs, for instance) that probably want two - MUTE_LED and HP_ONLY. The following trivial patch only exits if a quirk fails to apply. I'll send patches adding the quirks when I've made sure they work as expected on these machines.
sound/pci/ac97/ac97_codec.c renamed from pci/ac97/ac97_codec.c.orig +3 -2
@@ -2551,9 +2551,10 @@ int snd_ac97_tune_hardware(ac97_t *ac97,continue ;snd_printdd ("ac97 quirk for %s (%04x:%04x)\n" , quirk->name, ac97->subsystem_vendor, ac97->subsystem_device); result =apply_quirk (ac97, quirk->type); -if (result <0 ) +if (result <0 ) {snd_printk (KERN_ERR "applying quirk type %d for %s failed (%d)\n" , quirk->type, quirk->name, result); -return result; +return result; + } } }return 0 ;
Signature · 8 lines
Matthew Garrett | [email protected] ------------------------------------------------------- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
At Tue, 13 Sep 2005 15:52:47 +0100,
Quoted 6 lines · Matthew Garrett
snd_ac97_tune_hardwarecurrently exits after applying a single ac97 quirk. There are bits of hardware (current HPs, for instance) that probably want two -MUTE_LEDandHP_ONLY. The following trivial patch only exits if a quirk fails to apply. I'll send patches adding the quirks when I've made sure they work as expected on these machines.
Thanks, the patch looks OK (and Andrew already took it :)
But how about a bit flag, AC97_TUNE_CONTINUE, to indicate to continue the quirk-parsing, instead of always continueing?
Takashi
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php