Lines Matching +full:codec +full:- +full:analog +full:- +full:controls

1 // SPDX-License-Identifier: GPL-2.0+
3 * This driver supports the analog controls for the internal codec
6 * Copyright (C) 2016 Chen-Yu Tsai <wens@csie.org>
10 * Based on sun8i-codec-analog.c
23 #include <sound/soc-dapm.h>
26 #include "sun8i-adda-pr-regmap.h"
28 /* Codec analog control register offsets and bit fields */
123 /* mixer controls */
147 /* ADC mixer controls */
172 -450, 150, 0);
178 static const DECLARE_TLV_DB_SCALE(sun50i_codec_hp_vol_scale, -6300, 100, 1);
182 2, 31, TLV_DB_SCALE_ITEM(-4350, 150, 0),
187 2, 31, TLV_DB_SCALE_ITEM(-4350, 150, 0),
190 /* volume / mute controls */
197 /* Mixer pre-gain */
207 /* Mixer pre-gain */
222 /* Mixer pre-gain */
312 * Due to this component and the codec belonging to separate DAPM
453 /* Line-out Routes */
477 return regmap_update_bits(component->regmap, SUN50I_ADDA_HP_CTRL, in sun50i_a64_codec_suspend()
484 return regmap_update_bits(component->regmap, SUN50I_ADDA_HP_CTRL, in sun50i_a64_codec_resume()
489 .controls = sun50i_a64_codec_controls,
501 .compatible = "allwinner,sun50i-a64-codec-analog",
515 dev_err(&pdev->dev, "Failed to map the registers\n"); in sun50i_codec_analog_probe()
519 regmap = sun8i_adda_pr_regmap_init(&pdev->dev, base); in sun50i_codec_analog_probe()
521 dev_err(&pdev->dev, "Failed to create regmap\n"); in sun50i_codec_analog_probe()
525 enable = device_property_read_bool(&pdev->dev, in sun50i_codec_analog_probe()
526 "allwinner,internal-bias-resistor"); in sun50i_codec_analog_probe()
531 return devm_snd_soc_register_component(&pdev->dev, in sun50i_codec_analog_probe()
538 .name = "sun50i-codec-analog",
545 MODULE_DESCRIPTION("Allwinner internal codec analog controls driver for A64");
548 MODULE_ALIAS("platform:sun50i-codec-analog");