Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
ALSA: hda/realtek - Fix lost speaker volume controls
ALSA: hda/realtek - Create "Bass Speaker" for two speaker pins
ALSA: hda/realtek - Don't create extra controls with channel suffix
ALSA: hda - Fix remaining VREF mute-LED NID check in post-3.1 changes
ALSA: hda - Fix GPIO LED setup for IDT 92HD75 codecs
ASoC: Provide a more complete DMA driver stub
ASoC: Remove references to corgi and spitz from machine driver document
ASoC: Make SND_SOC_MX27VIS_AIC32X4 depend on I2C
ASoC: Fix dependency for SND_SOC_RAUMFELD and SND_PXA2XX_SOC_HX4700
ASoC: uda1380: Return proper error in uda1380_modinit failure path
ASoC: kirkwood: Make SND_KIRKWOOD_SOC_OPENRD and SND_KIRKWOOD_SOC_T5325 depend on I2C
ASoC: Mark WM8994 ADC muxes as virtual
ALSA: hda/realtek - Fix Oops in alc_mux_select()
ALSA: sis7019 - give slow codecs more time to reset

+173 -66
+2 -4
Documentation/sound/alsa/soc/machine.txt
··· 50 50 The machine DAI configuration glues all the codec and CPU DAIs together. It can 51 51 also be used to set up the DAI system clock and for any machine related DAI 52 52 initialisation e.g. the machine audio map can be connected to the codec audio 53 - map, unconnected codec pins can be set as such. Please see corgi.c, spitz.c 54 - for examples. 53 + map, unconnected codec pins can be set as such. 55 54 56 55 struct snd_soc_dai_link is used to set up each DAI in your machine. e.g. 57 56 ··· 82 83 The machine driver can optionally extend the codec power map and to become an 83 84 audio power map of the audio subsystem. This allows for automatic power up/down 84 85 of speaker/HP amplifiers, etc. Codec pins can be connected to the machines jack 85 - sockets in the machine init function. See soc/pxa/spitz.c and dapm.txt for 86 - details. 86 + sockets in the machine init function. 87 87 88 88 89 89 Machine Controls
+49 -16
sound/pci/hda/patch_realtek.c
··· 297 297 imux = &spec->input_mux[mux_idx]; 298 298 if (!imux->num_items && mux_idx > 0) 299 299 imux = &spec->input_mux[0]; 300 + if (!imux->num_items) 301 + return 0; 300 302 301 303 if (idx >= imux->num_items) 302 304 idx = imux->num_items - 1; ··· 2631 2629 case AUTO_PIN_SPEAKER_OUT: 2632 2630 if (cfg->line_outs == 1) 2633 2631 return "Speaker"; 2632 + if (cfg->line_outs == 2) 2633 + return ch ? "Bass Speaker" : "Speaker"; 2634 2634 break; 2635 2635 case AUTO_PIN_HP_OUT: 2636 2636 /* for multi-io case, only the primary out */ ··· 2906 2902 if (!nid) 2907 2903 continue; 2908 2904 if (found_in_nid_list(nid, spec->multiout.dac_nids, 2909 - spec->multiout.num_dacs)) 2905 + ARRAY_SIZE(spec->private_dac_nids))) 2910 2906 continue; 2911 2907 if (found_in_nid_list(nid, spec->multiout.hp_out_nid, 2912 2908 ARRAY_SIZE(spec->multiout.hp_out_nid))) ··· 2927 2923 return 0; 2928 2924 } 2929 2925 2926 + /* return 0 if no possible DAC is found, 1 if one or more found */ 2930 2927 static int alc_auto_fill_extra_dacs(struct hda_codec *codec, int num_outs, 2931 2928 const hda_nid_t *pins, hda_nid_t *dacs) 2932 2929 { ··· 2945 2940 if (!dacs[i]) 2946 2941 dacs[i] = alc_auto_look_for_dac(codec, pins[i]); 2947 2942 } 2948 - return 0; 2943 + return 1; 2949 2944 } 2950 2945 2951 2946 static int alc_auto_fill_multi_ios(struct hda_codec *codec, ··· 2955 2950 static int alc_auto_fill_dac_nids(struct hda_codec *codec) 2956 2951 { 2957 2952 struct alc_spec *spec = codec->spec; 2958 - const struct auto_pin_cfg *cfg = &spec->autocfg; 2953 + struct auto_pin_cfg *cfg = &spec->autocfg; 2959 2954 bool redone = false; 2960 2955 int i; 2961 2956 ··· 2966 2961 spec->multiout.extra_out_nid[0] = 0; 2967 2962 memset(spec->private_dac_nids, 0, sizeof(spec->private_dac_nids)); 2968 2963 spec->multiout.dac_nids = spec->private_dac_nids; 2964 + spec->multi_ios = 0; 2969 2965 2970 2966 /* fill hard-wired DACs first */ 2971 2967 if (!redone) { ··· 3000 2994 for (i = 0; i < cfg->line_outs; i++) { 3001 2995 if (spec->private_dac_nids[i]) 3002 2996 spec->multiout.num_dacs++; 3003 - else 2997 + else { 3004 2998 memmove(spec->private_dac_nids + i, 3005 2999 spec->private_dac_nids + i + 1, 3006 3000 sizeof(hda_nid_t) * (cfg->line_outs - i - 1)); 3001 + spec->private_dac_nids[cfg->line_outs - 1] = 0; 3002 + } 3007 3003 } 3008 3004 3009 3005 if (cfg->line_outs == 1 && cfg->line_out_type != AUTO_PIN_SPEAKER_OUT) { ··· 3027 3019 if (cfg->line_out_type != AUTO_PIN_HP_OUT) 3028 3020 alc_auto_fill_extra_dacs(codec, cfg->hp_outs, cfg->hp_pins, 3029 3021 spec->multiout.hp_out_nid); 3030 - if (cfg->line_out_type != AUTO_PIN_SPEAKER_OUT) 3031 - alc_auto_fill_extra_dacs(codec, cfg->speaker_outs, cfg->speaker_pins, 3032 - spec->multiout.extra_out_nid); 3022 + if (cfg->line_out_type != AUTO_PIN_SPEAKER_OUT) { 3023 + int err = alc_auto_fill_extra_dacs(codec, cfg->speaker_outs, 3024 + cfg->speaker_pins, 3025 + spec->multiout.extra_out_nid); 3026 + /* if no speaker volume is assigned, try again as the primary 3027 + * output 3028 + */ 3029 + if (!err && cfg->speaker_outs > 0 && 3030 + cfg->line_out_type == AUTO_PIN_HP_OUT) { 3031 + cfg->hp_outs = cfg->line_outs; 3032 + memcpy(cfg->hp_pins, cfg->line_out_pins, 3033 + sizeof(cfg->hp_pins)); 3034 + cfg->line_outs = cfg->speaker_outs; 3035 + memcpy(cfg->line_out_pins, cfg->speaker_pins, 3036 + sizeof(cfg->speaker_pins)); 3037 + cfg->speaker_outs = 0; 3038 + memset(cfg->speaker_pins, 0, sizeof(cfg->speaker_pins)); 3039 + cfg->line_out_type = AUTO_PIN_SPEAKER_OUT; 3040 + redone = false; 3041 + goto again; 3042 + } 3043 + } 3033 3044 3034 3045 return 0; 3035 3046 } ··· 3198 3171 } 3199 3172 3200 3173 static int alc_auto_create_extra_out(struct hda_codec *codec, hda_nid_t pin, 3201 - hda_nid_t dac, const char *pfx) 3174 + hda_nid_t dac, const char *pfx, 3175 + int cidx) 3202 3176 { 3203 3177 struct alc_spec *spec = codec->spec; 3204 3178 hda_nid_t sw, vol; ··· 3215 3187 if (is_ctl_used(spec->sw_ctls, val)) 3216 3188 return 0; /* already created */ 3217 3189 mark_ctl_usage(spec->sw_ctls, val); 3218 - return add_pb_sw_ctrl(spec, ALC_CTL_WIDGET_MUTE, pfx, val); 3190 + return __add_pb_sw_ctrl(spec, ALC_CTL_WIDGET_MUTE, pfx, cidx, val); 3219 3191 } 3220 3192 3221 3193 sw = alc_look_for_out_mute_nid(codec, pin, dac); 3222 3194 vol = alc_look_for_out_vol_nid(codec, pin, dac); 3223 - err = alc_auto_add_stereo_vol(codec, pfx, 0, vol); 3195 + err = alc_auto_add_stereo_vol(codec, pfx, cidx, vol); 3224 3196 if (err < 0) 3225 3197 return err; 3226 - err = alc_auto_add_stereo_sw(codec, pfx, 0, sw); 3198 + err = alc_auto_add_stereo_sw(codec, pfx, cidx, sw); 3227 3199 if (err < 0) 3228 3200 return err; 3229 3201 return 0; ··· 3264 3236 hda_nid_t dac = *dacs; 3265 3237 if (!dac) 3266 3238 dac = spec->multiout.dac_nids[0]; 3267 - return alc_auto_create_extra_out(codec, *pins, dac, pfx); 3239 + return alc_auto_create_extra_out(codec, *pins, dac, pfx, 0); 3268 3240 } 3269 3241 3270 3242 if (dacs[num_pins - 1]) { 3271 3243 /* OK, we have a multi-output system with individual volumes */ 3272 3244 for (i = 0; i < num_pins; i++) { 3273 - snprintf(name, sizeof(name), "%s %s", 3274 - pfx, channel_name[i]); 3275 - err = alc_auto_create_extra_out(codec, pins[i], dacs[i], 3276 - name); 3245 + if (num_pins >= 3) { 3246 + snprintf(name, sizeof(name), "%s %s", 3247 + pfx, channel_name[i]); 3248 + err = alc_auto_create_extra_out(codec, pins[i], dacs[i], 3249 + name, 0); 3250 + } else { 3251 + err = alc_auto_create_extra_out(codec, pins[i], dacs[i], 3252 + pfx, i); 3253 + } 3277 3254 if (err < 0) 3278 3255 return err; 3279 3256 }
+25 -22
sound/pci/hda/patch_sigmatel.c
··· 215 215 unsigned int gpio_mute; 216 216 unsigned int gpio_led; 217 217 unsigned int gpio_led_polarity; 218 + unsigned int vref_mute_led_nid; /* pin NID for mute-LED vref control */ 218 219 unsigned int vref_led; 219 220 220 221 /* stream */ ··· 4319 4318 spec->eapd_switch = val; 4320 4319 get_int_hint(codec, "gpio_led_polarity", &spec->gpio_led_polarity); 4321 4320 if (get_int_hint(codec, "gpio_led", &spec->gpio_led)) { 4322 - if (spec->gpio_led <= 8) { 4323 - spec->gpio_mask |= spec->gpio_led; 4324 - spec->gpio_dir |= spec->gpio_led; 4325 - if (spec->gpio_led_polarity) 4326 - spec->gpio_data |= spec->gpio_led; 4327 - } 4321 + spec->gpio_mask |= spec->gpio_led; 4322 + spec->gpio_dir |= spec->gpio_led; 4323 + if (spec->gpio_led_polarity) 4324 + spec->gpio_data |= spec->gpio_led; 4328 4325 } 4329 4326 } 4330 4327 ··· 4442 4443 /* power on when no jack detection is available */ 4443 4444 /* or when the VREF is used for controlling LED */ 4444 4445 if (!spec->hp_detect || 4445 - (spec->gpio_led > 8 && spec->gpio_led == nid)) { 4446 + spec->vref_mute_led_nid == nid) { 4446 4447 stac_toggle_power_map(codec, nid, 1); 4447 4448 continue; 4448 4449 } ··· 4914 4915 if (sscanf(dev->name, "HP_Mute_LED_%d_%x", 4915 4916 &spec->gpio_led_polarity, 4916 4917 &spec->gpio_led) == 2) { 4917 - if (spec->gpio_led < 4) 4918 + unsigned int max_gpio; 4919 + max_gpio = snd_hda_param_read(codec, codec->afg, 4920 + AC_PAR_GPIO_CAP); 4921 + max_gpio &= AC_GPIO_IO_COUNT; 4922 + if (spec->gpio_led < max_gpio) 4918 4923 spec->gpio_led = 1 << spec->gpio_led; 4924 + else 4925 + spec->vref_mute_led_nid = spec->gpio_led; 4919 4926 return 1; 4920 4927 } 4921 4928 if (sscanf(dev->name, "HP_Mute_LED_%d", ··· 5050 5045 struct sigmatel_spec *spec = codec->spec; 5051 5046 5052 5047 /* sync mute LED */ 5053 - if (spec->gpio_led) { 5054 - if (spec->gpio_led <= 8) { 5055 - stac_gpio_set(codec, spec->gpio_mask, 5056 - spec->gpio_dir, spec->gpio_data); 5057 - } else { 5058 - stac_vrefout_set(codec, 5059 - spec->gpio_led, spec->vref_led); 5060 - } 5061 - } 5048 + if (spec->vref_mute_led_nid) 5049 + stac_vrefout_set(codec, spec->vref_mute_led_nid, 5050 + spec->vref_led); 5051 + else if (spec->gpio_led) 5052 + stac_gpio_set(codec, spec->gpio_mask, 5053 + spec->gpio_dir, spec->gpio_data); 5062 5054 return 0; 5063 5055 } 5064 5056 ··· 5066 5064 struct sigmatel_spec *spec = codec->spec; 5067 5065 5068 5066 if (power_state == AC_PWRST_D3) { 5069 - if (spec->gpio_led > 8) { 5067 + if (spec->vref_mute_led_nid) { 5070 5068 /* with vref-out pin used for mute led control 5071 5069 * codec AFG is prevented from D3 state 5072 5070 */ ··· 5119 5117 } 5120 5118 } 5121 5119 /*polarity defines *not* muted state level*/ 5122 - if (spec->gpio_led <= 8) { 5120 + if (!spec->vref_mute_led_nid) { 5123 5121 if (muted) 5124 5122 spec->gpio_data &= ~spec->gpio_led; /* orange */ 5125 5123 else ··· 5137 5135 muted_lvl = spec->gpio_led_polarity ? 5138 5136 AC_PINCTL_VREF_GRD : AC_PINCTL_VREF_HIZ; 5139 5137 spec->vref_led = muted ? muted_lvl : notmtd_lvl; 5140 - stac_vrefout_set(codec, spec->gpio_led, spec->vref_led); 5138 + stac_vrefout_set(codec, spec->vref_mute_led_nid, 5139 + spec->vref_led); 5141 5140 } 5142 5141 return 0; 5143 5142 } ··· 5652 5649 5653 5650 #ifdef CONFIG_SND_HDA_POWER_SAVE 5654 5651 if (spec->gpio_led) { 5655 - if (spec->gpio_led <= 8) { 5652 + if (!spec->vref_mute_led_nid) { 5656 5653 spec->gpio_mask |= spec->gpio_led; 5657 5654 spec->gpio_dir |= spec->gpio_led; 5658 5655 spec->gpio_data |= spec->gpio_led; ··· 5965 5962 5966 5963 #ifdef CONFIG_SND_HDA_POWER_SAVE 5967 5964 if (spec->gpio_led) { 5968 - if (spec->gpio_led <= 8) { 5965 + if (!spec->vref_mute_led_nid) { 5969 5966 spec->gpio_mask |= spec->gpio_led; 5970 5967 spec->gpio_dir |= spec->gpio_led; 5971 5968 spec->gpio_data |= spec->gpio_led;
+54 -12
sound/pci/sis7019.c
··· 41 41 static int index = SNDRV_DEFAULT_IDX1; /* Index 0-MAX */ 42 42 static char *id = SNDRV_DEFAULT_STR1; /* ID for this card */ 43 43 static int enable = 1; 44 + static int codecs = 1; 44 45 45 46 module_param(index, int, 0444); 46 47 MODULE_PARM_DESC(index, "Index value for SiS7019 Audio Accelerator."); ··· 49 48 MODULE_PARM_DESC(id, "ID string for SiS7019 Audio Accelerator."); 50 49 module_param(enable, bool, 0444); 51 50 MODULE_PARM_DESC(enable, "Enable SiS7019 Audio Accelerator."); 51 + module_param(codecs, int, 0444); 52 + MODULE_PARM_DESC(codecs, "Set bit to indicate that codec number is expected to be present (default 1)"); 52 53 53 54 static DEFINE_PCI_DEVICE_TABLE(snd_sis7019_ids) = { 54 55 { PCI_DEVICE(PCI_VENDOR_ID_SI, 0x7019) }, ··· 143 140 dma_addr_t silence_dma_addr; 144 141 }; 145 142 143 + /* These values are also used by the module param 'codecs' to indicate 144 + * which codecs should be present. 145 + */ 146 146 #define SIS_PRIMARY_CODEC_PRESENT 0x0001 147 147 #define SIS_SECONDARY_CODEC_PRESENT 0x0002 148 148 #define SIS_TERTIARY_CODEC_PRESENT 0x0004 ··· 1084 1078 { 1085 1079 unsigned long io = sis->ioport; 1086 1080 void __iomem *ioaddr = sis->ioaddr; 1081 + unsigned long timeout; 1087 1082 u16 status; 1088 1083 int count; 1089 1084 int i; ··· 1111 1104 while ((inw(io + SIS_AC97_STATUS) & SIS_AC97_STATUS_BUSY) && --count) 1112 1105 udelay(1); 1113 1106 1114 - /* Now that we've finished the reset, find out what's attached. 1115 - */ 1116 - status = inl(io + SIS_AC97_STATUS); 1117 - if (status & SIS_AC97_STATUS_CODEC_READY) 1118 - sis->codecs_present |= SIS_PRIMARY_CODEC_PRESENT; 1119 - if (status & SIS_AC97_STATUS_CODEC2_READY) 1120 - sis->codecs_present |= SIS_SECONDARY_CODEC_PRESENT; 1121 - if (status & SIS_AC97_STATUS_CODEC3_READY) 1122 - sis->codecs_present |= SIS_TERTIARY_CODEC_PRESENT; 1123 - 1124 - /* All done, let go of the semaphore, and check for errors 1107 + /* Command complete, we can let go of the semaphore now. 1125 1108 */ 1126 1109 outl(SIS_AC97_SEMA_RELEASE, io + SIS_AC97_SEMA); 1127 - if (!sis->codecs_present || !count) 1110 + if (!count) 1128 1111 return -EIO; 1112 + 1113 + /* Now that we've finished the reset, find out what's attached. 1114 + * There are some codec/board combinations that take an extremely 1115 + * long time to come up. 350+ ms has been observed in the field, 1116 + * so we'll give them up to 500ms. 1117 + */ 1118 + sis->codecs_present = 0; 1119 + timeout = msecs_to_jiffies(500) + jiffies; 1120 + while (time_before_eq(jiffies, timeout)) { 1121 + status = inl(io + SIS_AC97_STATUS); 1122 + if (status & SIS_AC97_STATUS_CODEC_READY) 1123 + sis->codecs_present |= SIS_PRIMARY_CODEC_PRESENT; 1124 + if (status & SIS_AC97_STATUS_CODEC2_READY) 1125 + sis->codecs_present |= SIS_SECONDARY_CODEC_PRESENT; 1126 + if (status & SIS_AC97_STATUS_CODEC3_READY) 1127 + sis->codecs_present |= SIS_TERTIARY_CODEC_PRESENT; 1128 + 1129 + if (sis->codecs_present == codecs) 1130 + break; 1131 + 1132 + msleep(1); 1133 + } 1134 + 1135 + /* All done, check for errors. 1136 + */ 1137 + if (!sis->codecs_present) { 1138 + printk(KERN_ERR "sis7019: could not find any codecs\n"); 1139 + return -EIO; 1140 + } 1141 + 1142 + if (sis->codecs_present != codecs) { 1143 + printk(KERN_WARNING "sis7019: missing codecs, found %0x, expected %0x\n", 1144 + sis->codecs_present, codecs); 1145 + } 1129 1146 1130 1147 /* Let the hardware know that the audio driver is alive, 1131 1148 * and enable PCM slots on the AC-link for L/R playback (3 & 4) and ··· 1420 1389 rc = -ENOENT; 1421 1390 if (!enable) 1422 1391 goto error_out; 1392 + 1393 + /* The user can specify which codecs should be present so that we 1394 + * can wait for them to show up if they are slow to recover from 1395 + * the AC97 cold reset. We default to a single codec, the primary. 1396 + * 1397 + * We assume that SIS_PRIMARY_*_PRESENT matches bits 0-2. 1398 + */ 1399 + codecs &= SIS_PRIMARY_CODEC_PRESENT | SIS_SECONDARY_CODEC_PRESENT | 1400 + SIS_TERTIARY_CODEC_PRESENT; 1401 + if (!codecs) 1402 + codecs = SIS_PRIMARY_CODEC_PRESENT; 1423 1403 1424 1404 rc = snd_card_create(index, id, THIS_MODULE, sizeof(*sis), &card); 1425 1405 if (rc < 0)
+2 -2
sound/soc/codecs/uda1380.c
··· 863 863 864 864 static int __init uda1380_modinit(void) 865 865 { 866 - int ret; 866 + int ret = 0; 867 867 #if defined(CONFIG_I2C) || defined(CONFIG_I2C_MODULE) 868 868 ret = i2c_add_driver(&uda1380_i2c_driver); 869 869 if (ret != 0) 870 870 pr_err("Failed to register UDA1380 I2C driver: %d\n", ret); 871 871 #endif 872 - return 0; 872 + return ret; 873 873 } 874 874 module_init(uda1380_modinit); 875 875
+6 -6
sound/soc/codecs/wm8994.c
··· 1325 1325 }; 1326 1326 1327 1327 static const struct snd_soc_dapm_widget wm8994_adc_revd_widgets[] = { 1328 - SND_SOC_DAPM_MUX_E("ADCL Mux", WM8994_POWER_MANAGEMENT_4, 1, 0, &adcl_mux, 1329 - adc_mux_ev, SND_SOC_DAPM_PRE_PMU), 1330 - SND_SOC_DAPM_MUX_E("ADCR Mux", WM8994_POWER_MANAGEMENT_4, 0, 0, &adcr_mux, 1331 - adc_mux_ev, SND_SOC_DAPM_PRE_PMU), 1328 + SND_SOC_DAPM_VIRT_MUX_E("ADCL Mux", WM8994_POWER_MANAGEMENT_4, 1, 0, &adcl_mux, 1329 + adc_mux_ev, SND_SOC_DAPM_PRE_PMU), 1330 + SND_SOC_DAPM_VIRT_MUX_E("ADCR Mux", WM8994_POWER_MANAGEMENT_4, 0, 0, &adcr_mux, 1331 + adc_mux_ev, SND_SOC_DAPM_PRE_PMU), 1332 1332 }; 1333 1333 1334 1334 static const struct snd_soc_dapm_widget wm8994_adc_widgets[] = { 1335 - SND_SOC_DAPM_MUX("ADCL Mux", WM8994_POWER_MANAGEMENT_4, 1, 0, &adcl_mux), 1336 - SND_SOC_DAPM_MUX("ADCR Mux", WM8994_POWER_MANAGEMENT_4, 0, 0, &adcr_mux), 1335 + SND_SOC_DAPM_VIRT_MUX("ADCL Mux", WM8994_POWER_MANAGEMENT_4, 1, 0, &adcl_mux), 1336 + SND_SOC_DAPM_VIRT_MUX("ADCR Mux", WM8994_POWER_MANAGEMENT_4, 0, 0, &adcr_mux), 1337 1337 }; 1338 1338 1339 1339 static const struct snd_soc_dapm_widget wm8994_dapm_widgets[] = {
+1 -1
sound/soc/imx/Kconfig
··· 28 28 29 29 config SND_SOC_MX27VIS_AIC32X4 30 30 tristate "SoC audio support for Visstrim M10 boards" 31 - depends on MACH_IMX27_VISSTRIM_M10 31 + depends on MACH_IMX27_VISSTRIM_M10 && I2C 32 32 select SND_SOC_TLV320AIC32X4 33 33 select SND_MXC_SOC_MX2 34 34 help
+2 -1
sound/soc/kirkwood/Kconfig
··· 12 12 config SND_KIRKWOOD_SOC_OPENRD 13 13 tristate "SoC Audio support for Kirkwood Openrd Client" 14 14 depends on SND_KIRKWOOD_SOC && (MACH_OPENRD_CLIENT || MACH_OPENRD_ULTIMATE) 15 + depends on I2C 15 16 select SND_KIRKWOOD_SOC_I2S 16 17 select SND_SOC_CS42L51 17 18 help ··· 21 20 22 21 config SND_KIRKWOOD_SOC_T5325 23 22 tristate "SoC Audio support for HP t5325" 24 - depends on SND_KIRKWOOD_SOC && MACH_T5325 23 + depends on SND_KIRKWOOD_SOC && MACH_T5325 && I2C 25 24 select SND_KIRKWOOD_SOC_I2S 26 25 select SND_SOC_ALC5623 27 26 help
+2 -1
sound/soc/pxa/Kconfig
··· 151 151 config SND_SOC_RAUMFELD 152 152 tristate "SoC Audio support Raumfeld audio adapter" 153 153 depends on SND_PXA2XX_SOC && (MACH_RAUMFELD_SPEAKER || MACH_RAUMFELD_CONNECTOR) 154 + depends on I2C && SPI_MASTER 154 155 select SND_PXA_SOC_SSP 155 156 select SND_SOC_CS4270 156 157 select SND_SOC_AK4104 ··· 160 159 161 160 config SND_PXA2XX_SOC_HX4700 162 161 tristate "SoC Audio support for HP iPAQ hx4700" 163 - depends on SND_PXA2XX_SOC && MACH_H4700 162 + depends on SND_PXA2XX_SOC && MACH_H4700 && I2C 164 163 select SND_PXA2XX_SOC_I2S 165 164 select SND_SOC_AK4641 166 165 help
+30 -1
sound/soc/soc-utils.c
··· 58 58 } 59 59 EXPORT_SYMBOL_GPL(snd_soc_params_to_bclk); 60 60 61 - static struct snd_soc_platform_driver dummy_platform; 61 + static const struct snd_pcm_hardware dummy_dma_hardware = { 62 + .formats = 0xffffffff, 63 + .channels_min = 1, 64 + .channels_max = UINT_MAX, 65 + 66 + /* Random values to keep userspace happy when checking constraints */ 67 + .info = SNDRV_PCM_INFO_INTERLEAVED | 68 + SNDRV_PCM_INFO_BLOCK_TRANSFER, 69 + .buffer_bytes_max = 128*1024, 70 + .period_bytes_min = PAGE_SIZE, 71 + .period_bytes_max = PAGE_SIZE*2, 72 + .periods_min = 2, 73 + .periods_max = 128, 74 + }; 75 + 76 + static int dummy_dma_open(struct snd_pcm_substream *substream) 77 + { 78 + snd_soc_set_runtime_hwparams(substream, &dummy_dma_hardware); 79 + 80 + return 0; 81 + } 82 + 83 + static struct snd_pcm_ops dummy_dma_ops = { 84 + .open = dummy_dma_open, 85 + .ioctl = snd_pcm_lib_ioctl, 86 + }; 87 + 88 + static struct snd_soc_platform_driver dummy_platform = { 89 + .ops = &dummy_dma_ops, 90 + }; 62 91 63 92 static __devinit int snd_soc_dummy_probe(struct platform_device *pdev) 64 93 {