• T
    ALSA: hda - Introduce snd_hda_set_pin_ctl*() helper functions · cdd03ced
    Takashi Iwai 提交于
    For setting the pin-control values more safely to match with the
    actual pin capability bits, a copule of new helper functions,
    snd_hda_set_pin_ctl() and snd_hda_set_pin_ctl_cache(), are
    introduced.  These are simple replacement of the codec verb write with
    AC_VERB_SET_PIN_WIDGET but do more sanity checks and filter out
    superfluous pin-control bits if they don't fit with the corresponding
    pin capabilities.
    
    Some codecs are screwed up or ignore the command when such a wrong bit
    is set.  These helpers will avoid such secret errors.
    Signed-off-by: NTakashi Iwai <tiwai@suse.de>
    cdd03ced
patch_via.c 103.9 KB