From a22d543a95e82e5ad0ee1a44aad54fd6b6bf52a8 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Mon, 27 Jul 2009 12:54:26 +0200 Subject: ALSA: hda - Introduce get_wcaps_type() macro Add a helper macro to retrieve the widget type from wiget cap bits. Signed-off-by: Takashi Iwai --- sound/pci/hda/patch_ca0110.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'sound/pci/hda/patch_ca0110.c') diff --git a/sound/pci/hda/patch_ca0110.c b/sound/pci/hda/patch_ca0110.c index 019ca7cb56d..d08353d3bb7 100644 --- a/sound/pci/hda/patch_ca0110.c +++ b/sound/pci/hda/patch_ca0110.c @@ -459,8 +459,7 @@ static void parse_input(struct hda_codec *codec) nid = codec->start_nid; for (i = 0; i < codec->num_nodes; i++, nid++) { unsigned int wcaps = get_wcaps(codec, nid); - unsigned int type = (wcaps & AC_WCAP_TYPE) >> - AC_WCAP_TYPE_SHIFT; + unsigned int type = get_wcaps_type(wcaps); if (type != AC_WID_AUD_IN) continue; if (snd_hda_get_connections(codec, nid, &pin, 1) != 1) -- cgit v1.2.3