diff options
Diffstat (limited to 'sound/soc/codecs/cx2072x.c')
| -rw-r--r-- | sound/soc/codecs/cx2072x.c | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/sound/soc/codecs/cx2072x.c b/sound/soc/codecs/cx2072x.c index e8e22b1a1963..b0033bf9be3a 100644 --- a/sound/soc/codecs/cx2072x.c +++ b/sound/soc/codecs/cx2072x.c @@ -63,11 +63,6 @@ static const DECLARE_TLV_DB_SCALE(adc_tlv, -7400, 100, 0); static const DECLARE_TLV_DB_SCALE(dac_tlv, -7400, 100, 0); static const DECLARE_TLV_DB_SCALE(boost_tlv, 0, 1200, 0); -struct cx2072x_eq_ctrl { - u8 ch; - u8 band; -}; - static const DECLARE_TLV_DB_RANGE(hpf_tlv, 0, 0, TLV_DB_SCALE_ITEM(120, 0, 0), 1, 63, TLV_DB_SCALE_ITEM(30, 30, 0) @@ -1346,8 +1341,8 @@ static int cx2072x_set_bias_level(struct snd_soc_component *codec, enum snd_soc_bias_level level) { struct cx2072x_priv *cx2072x = snd_soc_component_get_drvdata(codec); - const enum snd_soc_bias_level old_level = - snd_soc_component_get_bias_level(codec); + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(codec); + const enum snd_soc_bias_level old_level = snd_soc_dapm_get_bias_level(dapm); if (level == SND_SOC_BIAS_STANDBY && old_level == SND_SOC_BIAS_OFF) regmap_write(cx2072x->regmap, CX2072X_AFG_POWER_STATE, 0); @@ -1368,7 +1363,7 @@ static int cx2072x_set_bias_level(struct snd_soc_component *codec, static void cx2072x_enable_jack_detect(struct snd_soc_component *codec) { struct cx2072x_priv *cx2072x = snd_soc_component_get_drvdata(codec); - struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(codec); + struct snd_soc_dapm_context *dapm = snd_soc_component_to_dapm(codec); /* No-sticky input type */ regmap_write(cx2072x->regmap, CX2072X_GPIO_STICKY_MASK, 0x1f); @@ -1616,7 +1611,7 @@ static const struct regmap_config cx2072x_regmap = { .reg_write = cx2072x_reg_write, }; -static int __maybe_unused cx2072x_runtime_suspend(struct device *dev) +static int cx2072x_runtime_suspend(struct device *dev) { struct cx2072x_priv *cx2072x = dev_get_drvdata(dev); @@ -1624,7 +1619,7 @@ static int __maybe_unused cx2072x_runtime_suspend(struct device *dev) return 0; } -static int __maybe_unused cx2072x_runtime_resume(struct device *dev) +static int cx2072x_runtime_resume(struct device *dev) { struct cx2072x_priv *cx2072x = dev_get_drvdata(dev); @@ -1701,17 +1696,15 @@ MODULE_DEVICE_TABLE(acpi, cx2072x_acpi_match); #endif static const struct dev_pm_ops cx2072x_runtime_pm = { - SET_RUNTIME_PM_OPS(cx2072x_runtime_suspend, cx2072x_runtime_resume, - NULL) - SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, - pm_runtime_force_resume) + RUNTIME_PM_OPS(cx2072x_runtime_suspend, cx2072x_runtime_resume, NULL) + SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, pm_runtime_force_resume) }; static struct i2c_driver cx2072x_i2c_driver = { .driver = { .name = "cx2072x", .acpi_match_table = ACPI_PTR(cx2072x_acpi_match), - .pm = &cx2072x_runtime_pm, + .pm = pm_ptr(&cx2072x_runtime_pm), }, .probe = cx2072x_i2c_probe, .remove = cx2072x_i2c_remove, |
