.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
---|
1 | 2 | /* |
---|
2 | 3 | * ALSA SoC TWL6040 codec driver |
---|
3 | 4 | * |
---|
4 | 5 | * Author: Misael Lopez Cruz <x0052729@ti.com> |
---|
5 | | - * |
---|
6 | | - * This program is free software; you can redistribute it and/or |
---|
7 | | - * modify it under the terms of the GNU General Public License |
---|
8 | | - * version 2 as published by the Free Software Foundation. |
---|
9 | | - * |
---|
10 | | - * This program is distributed in the hope that it will be useful, but |
---|
11 | | - * WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
12 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
13 | | - * General Public License for more details. |
---|
14 | | - * |
---|
15 | | - * You should have received a copy of the GNU General Public License |
---|
16 | | - * along with this program; if not, write to the Free Software |
---|
17 | | - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA |
---|
18 | | - * 02110-1301 USA |
---|
19 | | - * |
---|
20 | 6 | */ |
---|
21 | 7 | |
---|
22 | 8 | #include <linux/module.h> |
---|
.. | .. |
---|
1011 | 997 | } |
---|
1012 | 998 | } |
---|
1013 | 999 | |
---|
1014 | | -static int twl6040_digital_mute(struct snd_soc_dai *dai, int mute) |
---|
| 1000 | +static int twl6040_mute_stream(struct snd_soc_dai *dai, int mute, int direction) |
---|
1015 | 1001 | { |
---|
1016 | 1002 | switch (dai->id) { |
---|
1017 | 1003 | case TWL6040_DAI_LEGACY: |
---|
.. | .. |
---|
1034 | 1020 | .hw_params = twl6040_hw_params, |
---|
1035 | 1021 | .prepare = twl6040_prepare, |
---|
1036 | 1022 | .set_sysclk = twl6040_set_dai_sysclk, |
---|
1037 | | - .digital_mute = twl6040_digital_mute, |
---|
| 1023 | + .mute_stream = twl6040_mute_stream, |
---|
| 1024 | + .no_capture_mute = 1, |
---|
1038 | 1025 | }; |
---|
1039 | 1026 | |
---|
1040 | 1027 | static struct snd_soc_dai_driver twl6040_dai[] = { |
---|
.. | .. |
---|
1122 | 1109 | priv->component = component; |
---|
1123 | 1110 | |
---|
1124 | 1111 | priv->plug_irq = platform_get_irq(pdev, 0); |
---|
1125 | | - if (priv->plug_irq < 0) { |
---|
1126 | | - dev_err(component->dev, "invalid irq: %d\n", priv->plug_irq); |
---|
| 1112 | + if (priv->plug_irq < 0) |
---|
1127 | 1113 | return priv->plug_irq; |
---|
1128 | | - } |
---|
1129 | 1114 | |
---|
1130 | 1115 | INIT_DELAYED_WORK(&priv->hs_jack.work, twl6040_accessory_work); |
---|
1131 | 1116 | |
---|