aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/sound/soc/codecs/rt1016.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/codecs/rt1016.c')
-rw-r--r--sound/soc/codecs/rt1016.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/sound/soc/codecs/rt1016.c b/sound/soc/codecs/rt1016.c
index a23d368ab4da..919a1f25e584 100644
--- a/sound/soc/codecs/rt1016.c
+++ b/sound/soc/codecs/rt1016.c
@@ -16,7 +16,6 @@
#include <linux/i2c.h>
#include <linux/platform_device.h>
#include <linux/firmware.h>
-#include <linux/gpio.h>
#include <sound/core.h>
#include <sound/pcm.h>
#include <sound/pcm_params.h>
@@ -490,7 +489,7 @@ static int rt1016_set_component_pll(struct snd_soc_component *component,
ret = rl6231_pll_calc(freq_in, freq_out * 4, &pll_code);
if (ret < 0) {
- dev_err(component->dev, "Unsupport input clock %d\n", freq_in);
+ dev_err(component->dev, "Unsupported input clock %d\n", freq_in);
return ret;
}
@@ -500,10 +499,11 @@ static int rt1016_set_component_pll(struct snd_soc_component *component,
(pll_code.k_bp ? 0 : pll_code.k_code));
snd_soc_component_write(component, RT1016_PLL1,
- (pll_code.m_bp ? 0 : pll_code.m_code) << RT1016_PLL_M_SFT |
- pll_code.m_bp << RT1016_PLL_M_BP_SFT | pll_code.n_code);
+ ((pll_code.m_bp ? 0 : pll_code.m_code) << RT1016_PLL_M_SFT) |
+ (pll_code.m_bp << RT1016_PLL_M_BP_SFT) |
+ pll_code.n_code);
snd_soc_component_write(component, RT1016_PLL2,
- pll_code.k_bp << RT1016_PLL_K_BP_SFT |
+ (pll_code.k_bp << RT1016_PLL_K_BP_SFT) |
(pll_code.k_bp ? 0 : pll_code.k_code));
rt1016->pll_in = freq_in;
@@ -534,7 +534,7 @@ static void rt1016_remove(struct snd_soc_component *component)
#define RT1016_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE | \
SNDRV_PCM_FMTBIT_S24_LE | SNDRV_PCM_FMTBIT_S8)
-static struct snd_soc_dai_ops rt1016_aif_dai_ops = {
+static const struct snd_soc_dai_ops rt1016_aif_dai_ops = {
.hw_params = rt1016_hw_params,
.set_fmt = rt1016_set_dai_fmt,
};
@@ -594,7 +594,6 @@ static const struct snd_soc_component_driver soc_component_dev_rt1016 = {
.set_pll = rt1016_set_component_pll,
.use_pmdown_time = 1,
.endianness = 1,
- .non_legacy_dai_naming = 1,
};
static const struct regmap_config rt1016_regmap = {
@@ -623,15 +622,14 @@ MODULE_DEVICE_TABLE(of, rt1016_of_match);
#endif
#ifdef CONFIG_ACPI
-static struct acpi_device_id rt1016_acpi_match[] = {
+static const struct acpi_device_id rt1016_acpi_match[] = {
{"10EC1016", 0,},
{},
};
MODULE_DEVICE_TABLE(acpi, rt1016_acpi_match);
#endif
-static int rt1016_i2c_probe(struct i2c_client *i2c,
- const struct i2c_device_id *id)
+static int rt1016_i2c_probe(struct i2c_client *i2c)
{
struct rt1016_priv *rt1016;
int ret;