Commit 492e9176 authored by Mark Brown's avatar Mark Brown
Browse files

Merge branch 'for-2.6.38' into for-2.6.39

parents 065ae678 c88c2823
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
config SND_BF5XX_I2S
	tristate "SoC I2S Audio for the ADI BF5xx chip"
	depends on BLACKFIN
	select SND_BF5XX_SOC_SPORT
	help
	  Say Y or M if you want to add support for codecs attached to
	  the Blackfin SPORT (synchronous serial ports) interface in I2S
@@ -35,6 +36,7 @@ config SND_BFIN_AD73311_SE
config SND_BF5XX_TDM
	tristate "SoC I2S(TDM mode) Audio for the ADI BF5xx chip"
	depends on (BLACKFIN && SND_SOC)
	select SND_BF5XX_SOC_SPORT
	help
	  Say Y or M if you want to add support for codecs attached to
	  the Blackfin SPORT (synchronous serial ports) interface in TDM
@@ -61,6 +63,10 @@ config SND_BF5XX_SOC_AD193X
config SND_BF5XX_AC97
	tristate "SoC AC97 Audio for the ADI BF5xx chip"
	depends on BLACKFIN
	select AC97_BUS
	select SND_SOC_AC97_BUS
	select SND_BF5XX_SOC_SPORT
	select SND_BF5XX_SOC_AC97
	help
	  Say Y or M if you want to add support for codecs attached to
	  the Blackfin SPORT (synchronous serial ports) interface in slot 16
@@ -122,17 +128,12 @@ config SND_BF5XX_SOC_SPORT

config SND_BF5XX_SOC_I2S
	tristate
	select SND_BF5XX_SOC_SPORT

config SND_BF5XX_SOC_TDM
	tristate
	select SND_BF5XX_SOC_SPORT

config SND_BF5XX_SOC_AC97
	tristate
	select AC97_BUS
	select SND_SOC_AC97_BUS
	select SND_BF5XX_SOC_SPORT

config SND_BF5XX_SPORT_NUM
	int "Set a SPORT for Sound chip"
+2 −2
Original line number Diff line number Diff line
@@ -260,9 +260,9 @@ static int bf5xx_ac97_suspend(struct snd_soc_dai *dai)
	pr_debug("%s : sport %d\n", __func__, dai->id);
	if (!dai->active)
		return 0;
	if (dai->capture.active)
	if (dai->capture_active)
		sport_rx_stop(sport);
	if (dai->playback.active)
	if (dai->playback_active)
		sport_tx_stop(sport);
	return 0;
}
+5 −5
Original line number Diff line number Diff line
@@ -210,7 +210,7 @@ static int bf5xx_tdm_set_channel_map(struct snd_soc_dai *dai,
#ifdef CONFIG_PM
static int bf5xx_tdm_suspend(struct snd_soc_dai *dai)
{
	struct sport_device *sport = dai->private_data;
	struct sport_device *sport = snd_soc_dai_get_drvdata(dai);

	if (!dai->active)
		return 0;
@@ -235,13 +235,13 @@ static int bf5xx_tdm_resume(struct snd_soc_dai *dai)
		ret = -EBUSY;
	}

	ret = sport_config_rx(sport, IRFS, 0x1F, 0, 0);
	ret = sport_config_rx(sport, 0, 0x1F, 0, 0);
	if (ret) {
		pr_err("SPORT is busy!\n");
		ret = -EBUSY;
	}

	ret = sport_config_tx(sport, ITFS, 0x1F, 0, 0);
	ret = sport_config_tx(sport, 0, 0x1F, 0, 0);
	if (ret) {
		pr_err("SPORT is busy!\n");
		ret = -EBUSY;
@@ -303,14 +303,14 @@ static int __devinit bfin_tdm_probe(struct platform_device *pdev)
		goto sport_config_err;
	}

	ret = sport_config_rx(sport_handle, IRFS, 0x1F, 0, 0);
	ret = sport_config_rx(sport_handle, 0, 0x1F, 0, 0);
	if (ret) {
		pr_err("SPORT is busy!\n");
		ret = -EBUSY;
		goto sport_config_err;
	}

	ret = sport_config_tx(sport_handle, ITFS, 0x1F, 0, 0);
	ret = sport_config_tx(sport_handle, 0, 0x1F, 0, 0);
	if (ret) {
		pr_err("SPORT is busy!\n");
		ret = -EBUSY;
+1 −1
Original line number Diff line number Diff line
@@ -45,7 +45,7 @@ config SND_SOC_ALL_CODECS
	select SND_SOC_TWL6040 if TWL4030_CORE
	select SND_SOC_UDA134X
	select SND_SOC_UDA1380 if I2C
	select SND_SOC_WL1273 if WL1273_CORE
	select SND_SOC_WL1273 if RADIO_WL1273
	select SND_SOC_WM2000 if I2C
	select SND_SOC_WM8350 if MFD_WM8350
	select SND_SOC_WM8400 if MFD_WM8400
+12 −17
Original line number Diff line number Diff line
@@ -42,7 +42,7 @@ struct wl1273_priv {
static int snd_wl1273_fm_set_i2s_mode(struct wl1273_core *core,
				      int rate, int width)
{
	struct device *dev = &core->i2c_dev->dev;
	struct device *dev = &core->client->dev;
	int r = 0;
	u16 mode;

@@ -123,12 +123,12 @@ static int snd_wl1273_fm_set_i2s_mode(struct wl1273_core *core,
	dev_dbg(dev, "mode: 0x%04x\n", mode);

	if (core->i2s_mode != mode) {
		r = wl1273_fm_write_cmd(core, WL1273_I2S_MODE_CONFIG_SET, mode);
		r = core->write(core, WL1273_I2S_MODE_CONFIG_SET, mode);
		if (r)
			goto out;

		core->i2s_mode = mode;
		r = wl1273_fm_write_cmd(core, WL1273_AUDIO_ENABLE,
		r = core->write(core, WL1273_AUDIO_ENABLE,
				WL1273_AUDIO_ENABLE_I2S);
		if (r)
			goto out;
@@ -142,8 +142,7 @@ static int snd_wl1273_fm_set_i2s_mode(struct wl1273_core *core,
static int snd_wl1273_fm_set_channel_number(struct wl1273_core *core,
					    int channel_number)
{
	struct i2c_client *client = core->i2c_dev;
	struct device *dev = &client->dev;
	struct device *dev = &core->client->dev;
	int r = 0;

	dev_dbg(dev, "%s\n", __func__);
@@ -154,17 +153,13 @@ static int snd_wl1273_fm_set_channel_number(struct wl1273_core *core,
		goto out;

	if (channel_number == 1 && core->mode == WL1273_MODE_RX)
		r = wl1273_fm_write_cmd(core, WL1273_MOST_MODE_SET,
					WL1273_RX_MONO);
		r = core->write(core, WL1273_MOST_MODE_SET, WL1273_RX_MONO);
	else if (channel_number == 1 && core->mode == WL1273_MODE_TX)
		r = wl1273_fm_write_cmd(core, WL1273_MONO_SET,
					WL1273_TX_MONO);
		r = core->write(core, WL1273_MONO_SET, WL1273_TX_MONO);
	else if (channel_number == 2 && core->mode == WL1273_MODE_RX)
		r = wl1273_fm_write_cmd(core, WL1273_MOST_MODE_SET,
					WL1273_RX_STEREO);
		r = core->write(core, WL1273_MOST_MODE_SET, WL1273_RX_STEREO);
	else if (channel_number == 2 && core->mode == WL1273_MODE_TX)
		r = wl1273_fm_write_cmd(core, WL1273_MONO_SET,
					WL1273_TX_STEREO);
		r = core->write(core, WL1273_MONO_SET, WL1273_TX_STEREO);
	else
		r = -EINVAL;
out:
@@ -237,7 +232,7 @@ static int snd_wl1273_fm_audio_put(struct snd_kcontrol *kcontrol,
	if (wl1273->core->audio_mode == val)
		return 0;

	r = wl1273_fm_set_audio(wl1273->core, val);
	r = wl1273->core->set_audio(wl1273->core, val);
	if (r < 0)
		return r;

@@ -272,7 +267,7 @@ static int snd_wl1273_fm_volume_put(struct snd_kcontrol *kcontrol,

	dev_dbg(codec->dev, "%s: enter.\n", __func__);

	r = wl1273_fm_set_volume(wl1273->core,
	r = wl1273->core->set_volume(wl1273->core,
				     ucontrol->value.integer.value[0]);
	if (r)
		return r;
Loading