diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-11 12:45:59 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-11 12:45:59 -0700 |
commit | 0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec (patch) | |
tree | 76eed01d088080863f5bf97e37ae4ec1adf9d0a5 /sound/soc/samsung | |
parent | 0edcd16a4def296bd6492ae0c10a3c4aef9ef7c0 (diff) | |
parent | 42d4ab832d843b5a512b373c86e70caa43a041c8 (diff) | |
download | linux-stable-0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec.tar.gz linux-stable-0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec.tar.bz2 linux-stable-0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec.zip |
Merge tag 'sound-3.11' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
Pull sound fixes from Takashi Iwai:
"A few small fixes (and cleanups) for HD-audio, USB-audio and ASoC"
* tag 'sound-3.11' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
ALSA: usb-audio: fix regression for fixed stream quirk
ALSA: hda - Keep halting ALC5505 DSP
ASoC: wm8962: fix NULL pdata pointer
ASoC: imx-sgtl5000: return E_PROBE_DEFER if ssi/codec not found
ASoC: Samsung: Remove redundant comment
ALSA: hda - Fix EAPD vmaster hook for AD1884 & co
ASoC: samsung: Remove obsolete GPIO based DT pinmuxing
ASoC: mxs: register saif mclk to clock framework
Diffstat (limited to 'sound/soc/samsung')
-rw-r--r-- | sound/soc/samsung/i2s.c | 66 | ||||
-rw-r--r-- | sound/soc/samsung/s3c-i2s-v2.c | 4 |
2 files changed, 5 insertions, 65 deletions
diff --git a/sound/soc/samsung/i2s.c b/sound/soc/samsung/i2s.c index 82ebb1a51479..7a1734697434 100644 --- a/sound/soc/samsung/i2s.c +++ b/sound/soc/samsung/i2s.c @@ -1016,52 +1016,6 @@ static struct i2s_dai *i2s_alloc_dai(struct platform_device *pdev, bool sec) return i2s; } -#ifdef CONFIG_OF -static int samsung_i2s_parse_dt_gpio(struct i2s_dai *i2s) -{ - struct device *dev = &i2s->pdev->dev; - int index, gpio, ret; - - for (index = 0; index < 7; index++) { - gpio = of_get_gpio(dev->of_node, index); - if (!gpio_is_valid(gpio)) { - dev_err(dev, "invalid gpio[%d]: %d\n", index, gpio); - goto free_gpio; - } - - ret = gpio_request(gpio, dev_name(dev)); - if (ret) { - dev_err(dev, "gpio [%d] request failed\n", gpio); - goto free_gpio; - } - i2s->gpios[index] = gpio; - } - return 0; - -free_gpio: - while (--index >= 0) - gpio_free(i2s->gpios[index]); - return -EINVAL; -} - -static void samsung_i2s_dt_gpio_free(struct i2s_dai *i2s) -{ - unsigned int index; - for (index = 0; index < 7; index++) - gpio_free(i2s->gpios[index]); -} -#else -static int samsung_i2s_parse_dt_gpio(struct i2s_dai *dai) -{ - return -EINVAL; -} - -static void samsung_i2s_dt_gpio_free(struct i2s_dai *dai) -{ -} - -#endif - static const struct of_device_id exynos_i2s_match[]; static inline int samsung_i2s_get_driver_data(struct platform_device *pdev) @@ -1235,18 +1189,10 @@ static int samsung_i2s_probe(struct platform_device *pdev) pri_dai->sec_dai = sec_dai; } - if (np) { - if (samsung_i2s_parse_dt_gpio(pri_dai)) { - dev_err(&pdev->dev, "Unable to configure gpio\n"); - ret = -EINVAL; - goto err; - } - } else { - if (i2s_pdata->cfg_gpio && i2s_pdata->cfg_gpio(pdev)) { - dev_err(&pdev->dev, "Unable to configure gpio\n"); - ret = -EINVAL; - goto err; - } + if (i2s_pdata && i2s_pdata->cfg_gpio && i2s_pdata->cfg_gpio(pdev)) { + dev_err(&pdev->dev, "Unable to configure gpio\n"); + ret = -EINVAL; + goto err; } snd_soc_register_component(&pri_dai->pdev->dev, &samsung_i2s_component, @@ -1267,14 +1213,10 @@ static int samsung_i2s_remove(struct platform_device *pdev) { struct i2s_dai *i2s, *other; struct resource *res; - struct s3c_audio_pdata *i2s_pdata = pdev->dev.platform_data; i2s = dev_get_drvdata(&pdev->dev); other = i2s->pri_dai ? : i2s->sec_dai; - if (!i2s_pdata->cfg_gpio && pdev->dev.of_node) - samsung_i2s_dt_gpio_free(i2s->pri_dai); - if (other) { other->pri_dai = NULL; other->sec_dai = NULL; diff --git a/sound/soc/samsung/s3c-i2s-v2.c b/sound/soc/samsung/s3c-i2s-v2.c index 20e98d1dded2..e5e81b111001 100644 --- a/sound/soc/samsung/s3c-i2s-v2.c +++ b/sound/soc/samsung/s3c-i2s-v2.c @@ -1,6 +1,4 @@ -/* sound/soc/samsung/s3c-i2c-v2.c - * - * ALSA Soc Audio Layer - I2S core for newer Samsung SoCs. +/* ALSA Soc Audio Layer - I2S core for newer Samsung SoCs. * * Copyright (c) 2006 Wolfson Microelectronics PLC. * Graeme Gregory graeme.gregory@wolfsonmicro.com |