diff options
-rw-r--r-- | include/sound/soc-dapm.h | 1 | ||||
-rw-r--r-- | sound/soc/soc-dapm.c | 20 |
2 files changed, 21 insertions, 0 deletions
diff --git a/include/sound/soc-dapm.h b/include/sound/soc-dapm.h index c1b26fcc0b5c..ca699a3017f3 100644 --- a/include/sound/soc-dapm.h +++ b/include/sound/soc-dapm.h | |||
@@ -240,6 +240,7 @@ int snd_soc_dapm_sys_add(struct device *dev); | |||
240 | /* dapm audio pin control and status */ | 240 | /* dapm audio pin control and status */ |
241 | int snd_soc_dapm_enable_pin(struct snd_soc_codec *codec, char *pin); | 241 | int snd_soc_dapm_enable_pin(struct snd_soc_codec *codec, char *pin); |
242 | int snd_soc_dapm_disable_pin(struct snd_soc_codec *codec, char *pin); | 242 | int snd_soc_dapm_disable_pin(struct snd_soc_codec *codec, char *pin); |
243 | int snd_soc_dapm_nc_pin(struct snd_soc_codec *codec, char *pin); | ||
243 | int snd_soc_dapm_get_pin_status(struct snd_soc_codec *codec, char *pin); | 244 | int snd_soc_dapm_get_pin_status(struct snd_soc_codec *codec, char *pin); |
244 | int snd_soc_dapm_sync(struct snd_soc_codec *codec); | 245 | int snd_soc_dapm_sync(struct snd_soc_codec *codec); |
245 | 246 | ||
diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c index 9ca9c08610fa..83fa9c47b660 100644 --- a/sound/soc/soc-dapm.c +++ b/sound/soc/soc-dapm.c | |||
@@ -1484,6 +1484,26 @@ int snd_soc_dapm_disable_pin(struct snd_soc_codec *codec, char *pin) | |||
1484 | EXPORT_SYMBOL_GPL(snd_soc_dapm_disable_pin); | 1484 | EXPORT_SYMBOL_GPL(snd_soc_dapm_disable_pin); |
1485 | 1485 | ||
1486 | /** | 1486 | /** |
1487 | * snd_soc_dapm_nc_pin - permanently disable pin. | ||
1488 | * @codec: SoC codec | ||
1489 | * @pin: pin name | ||
1490 | * | ||
1491 | * Marks the specified pin as being not connected, disabling it along | ||
1492 | * any parent or child widgets. At present this is identical to | ||
1493 | * snd_soc_dapm_disable_pin() but in future it will be extended to do | ||
1494 | * additional things such as disabling controls which only affect | ||
1495 | * paths through the pin. | ||
1496 | * | ||
1497 | * NOTE: snd_soc_dapm_sync() needs to be called after this for DAPM to | ||
1498 | * do any widget power switching. | ||
1499 | */ | ||
1500 | int snd_soc_dapm_nc_pin(struct snd_soc_codec *codec, char *pin) | ||
1501 | { | ||
1502 | return snd_soc_dapm_set_pin(codec, pin, 0); | ||
1503 | } | ||
1504 | EXPORT_SYMBOL_GPL(snd_soc_dapm_nc_pin); | ||
1505 | |||
1506 | /** | ||
1487 | * snd_soc_dapm_get_pin_status - get audio pin status | 1507 | * snd_soc_dapm_get_pin_status - get audio pin status |
1488 | * @codec: audio codec | 1508 | * @codec: audio codec |
1489 | * @pin: audio signal pin endpoint (or start point) | 1509 | * @pin: audio signal pin endpoint (or start point) |