ALSA: hda - Reword information messages for BIOS auto-probing mode
[pandora-kernel.git] / sound / pci / hda / patch_realtek.c
index e1563f4..6794d02 100644 (file)
@@ -415,7 +415,7 @@ static int alc_mux_enum_put(struct snd_kcontrol *kcontrol,
        mux_idx = adc_idx >= spec->num_mux_defs ? 0 : adc_idx;
        imux = &spec->input_mux[mux_idx];
 
-       type = (get_wcaps(codec, nid) & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+       type = get_wcaps_type(get_wcaps(codec, nid));
        if (type == AC_WID_AUD_MIX) {
                /* Matrix-mixer style (e.g. ALC882) */
                unsigned int *cur_val = &spec->cur_mux[adc_idx];
@@ -4584,8 +4584,8 @@ static int patch_alc880(struct hda_codec *codec)
                                                  alc880_models,
                                                  alc880_cfg_tbl);
        if (board_config < 0) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC880_AUTO;
        }
 
@@ -4623,7 +4623,7 @@ static int patch_alc880(struct hda_codec *codec)
                /* check whether NID 0x07 is valid */
                unsigned int wcap = get_wcaps(codec, alc880_adc_nids[0]);
                /* get type */
-               wcap = (wcap & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+               wcap = get_wcaps_type(wcap);
                if (wcap != AC_WID_AUD_IN) {
                        spec->adc_nids = alc880_adc_nids_alt;
                        spec->num_adc_nids = ARRAY_SIZE(alc880_adc_nids_alt);
@@ -6228,8 +6228,7 @@ static int patch_alc260(struct hda_codec *codec)
                                                  alc260_models,
                                                  alc260_cfg_tbl);
        if (board_config < 0) {
-               snd_printd(KERN_INFO "hda_codec: Unknown model for %s, "
-                          "trying auto-probe from BIOS...\n",
+               snd_printd(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
                           codec->chip_name);
                board_config = ALC260_AUTO;
        }
@@ -6266,7 +6265,7 @@ static int patch_alc260(struct hda_codec *codec)
        if (!spec->adc_nids && spec->input_mux) {
                /* check whether NID 0x04 is valid */
                unsigned int wcap = get_wcaps(codec, 0x04);
-               wcap = (wcap & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+               wcap = get_wcaps_type(wcap);
                /* get type */
                if (wcap != AC_WID_AUD_IN || spec->input_mux->num_items == 1) {
                        spec->adc_nids = alc260_adc_nids_alt;
@@ -9460,7 +9459,7 @@ static int alc882_parse_auto_config(struct hda_codec *codec)
        spec->init_verbs[0] = alc883_auto_init_verbs;
        /* if ADC 0x07 is available, initialize it, too */
        wcap = get_wcaps(codec, 0x07);
-       wcap = (wcap & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+       wcap = get_wcaps_type(wcap);
        if (wcap == AC_WID_AUD_IN)
                add_verb(spec, alc882_adc1_init_verbs);
 
@@ -9526,8 +9525,7 @@ static int patch_alc882(struct hda_codec *codec)
                        ALC882_MODEL_LAST, alc882_models, alc882_ssid_cfg_tbl);
 
        if (board_config < 0 || board_config >= ALC882_MODEL_LAST) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n",
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
                       codec->chip_name);
                board_config = ALC882_AUTO;
        }
@@ -9577,7 +9575,7 @@ static int patch_alc882(struct hda_codec *codec)
                        hda_nid_t nid = alc882_adc_nids[i];
                        unsigned int wcap = get_wcaps(codec, nid);
                        /* get type */
-                       wcap = (wcap & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+                       wcap = get_wcaps_type(wcap);
                        if (wcap != AC_WID_AUD_IN)
                                continue;
                        spec->private_adc_nids[spec->num_adc_nids] = nid;
@@ -11406,8 +11404,8 @@ static int patch_alc262(struct hda_codec *codec)
                                                  alc262_cfg_tbl);
 
        if (board_config < 0) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC262_AUTO;
        }
 
@@ -11460,7 +11458,7 @@ static int patch_alc262(struct hda_codec *codec)
                        unsigned int wcap = get_wcaps(codec, 0x07);
 
                        /* get type */
-                       wcap = (wcap & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+                       wcap = get_wcaps_type(wcap);
                        if (wcap != AC_WID_AUD_IN) {
                                spec->adc_nids = alc262_adc_nids_alt;
                                spec->num_adc_nids =
@@ -12479,8 +12477,8 @@ static int patch_alc268(struct hda_codec *codec)
                                                  alc268_cfg_tbl);
 
        if (board_config < 0 || board_config >= ALC268_MODEL_LAST) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC268_AUTO;
        }
 
@@ -12536,7 +12534,7 @@ static int patch_alc268(struct hda_codec *codec)
                int i;
 
                /* get type */
-               wcap = (wcap & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
+               wcap = get_wcaps_type(wcap);
                if (wcap != AC_WID_AUD_IN || spec->input_mux->num_items == 1) {
                        spec->adc_nids = alc268_adc_nids_alt;
                        spec->num_adc_nids = ARRAY_SIZE(alc268_adc_nids_alt);
@@ -13297,8 +13295,8 @@ static int patch_alc269(struct hda_codec *codec)
                                                  alc269_cfg_tbl);
 
        if (board_config < 0) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC269_AUTO;
        }
 
@@ -13991,8 +13989,7 @@ static hda_nid_t alc861_look_for_dac(struct hda_codec *codec, hda_nid_t pin)
                return 0;
        for (i = 0; i < num; i++) {
                unsigned int type;
-               type = (get_wcaps(codec, srcs[i]) & AC_WCAP_TYPE)
-                       >> AC_WCAP_TYPE_SHIFT;
+               type = get_wcaps_type(get_wcaps(codec, srcs[i]));
                if (type != AC_WID_AUD_OUT)
                        continue;
                for (j = 0; j < spec->multiout.num_dacs; j++)
@@ -14449,8 +14446,8 @@ static int patch_alc861(struct hda_codec *codec)
                                                  alc861_cfg_tbl);
 
        if (board_config < 0) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC861_AUTO;
        }
 
@@ -15373,8 +15370,8 @@ static int patch_alc861vd(struct hda_codec *codec)
                                                  alc861vd_cfg_tbl);
 
        if (board_config < 0 || board_config >= ALC861VD_MODEL_LAST) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC861VD_AUTO;
        }
 
@@ -17297,8 +17294,8 @@ static int patch_alc662(struct hda_codec *codec)
                                                  alc662_models,
                                                  alc662_cfg_tbl);
        if (board_config < 0) {
-               printk(KERN_INFO "hda_codec: Unknown model for %s, "
-                      "trying auto-probe from BIOS...\n", codec->chip_name);
+               printk(KERN_INFO "hda_codec: %s: BIOS auto-probing.\n",
+                      codec->chip_name);
                board_config = ALC662_AUTO;
        }