Lines Matching +full:brownout +full:- +full:attack +full:- +full:hold +full:- +full:ms

1 // SPDX-License-Identifier: GPL-2.0
23 struct snd_soc_component *component = snd_soc_dapm_to_component(w->dapm); in max98373_dac_event()
28 regmap_update_bits(max98373->regmap, in max98373_dac_event()
34 regmap_update_bits(max98373->regmap, in max98373_dac_event()
38 max98373->tdm_mode = false; in max98373_dac_event()
85 static DECLARE_TLV_DB_SCALE(max98373_digital_tlv, -6350, 50, 1);
101 0, 1, TLV_DB_SCALE_ITEM(-3000, 500, 0),
102 2, 4, TLV_DB_SCALE_ITEM(-2200, 200, 0),
103 5, 6, TLV_DB_SCALE_ITEM(-1500, 300, 0),
104 7, 9, TLV_DB_SCALE_ITEM(-1000, 200, 0),
105 10, 13, TLV_DB_SCALE_ITEM(-500, 100, 0),
106 14, 15, TLV_DB_SCALE_ITEM(-100, 50, 0),
109 0, 15, TLV_DB_SCALE_ITEM(-1500, 100, 0),
113 0, 60, TLV_DB_SCALE_ITEM(-1500, 25, 0),
135 "45ms", "225ms", "450ms", "1150ms",
136 "2250ms", "3100ms", "4500ms", "6750ms"
145 "160us", "320us", "640us", "1.28ms",
146 "2.56ms", "5.12ms", "10.24ms", "20.48ms",
147 "40.96ms", "81.92ms", "16.384ms", "32.768ms"
156 "640us", "1.28ms", "2.56ms", "5.120ms",
157 "10.24ms", "20.48ms", "40.96ms", "81.92ms",
158 "163.84ms", "327.68ms", "655.36ms", "1310.72ms"
178 (struct soc_mixer_control *)kcontrol->private_value; in max98373_feedback_get()
187 for (i = 0; i < max98373->cache_num; i++) { in max98373_feedback_get()
188 if (mc->reg == max98373->cache[i].reg) { in max98373_feedback_get()
189 ucontrol->value.integer.value[0] = max98373->cache[i].val; in max98373_feedback_get()
236 SOC_SINGLE_TLV("DHT Attack Step Volume", MAX98373_R20D2_DHT_ATTACK_CFG,
240 SOC_ENUM("DHT Attack Rate", max98373_dht_attack_rate_enum),
257 /* Brownout Detection Engine */
261 SOC_SINGLE("BDE LVL4 Hold Switch", MAX98373_R20B2_BDE_L4_CFG_2,
271 SOC_SINGLE("BDE Hold Time", MAX98373_R2090_BDE_LVL_HOLD, 0, 0xFF, 0),
272 SOC_SINGLE("BDE Attack Rate", MAX98373_R2091_BDE_GAIN_ATK_REL_RATE, 4, 0xF, 0),
305 SOC_ENUM("Limiter Attack Rate", max98373_limiter_attack_rate_enum),
329 ret = regmap_update_bits(max98373->regmap, in max98373_reset()
340 ret = regmap_read(max98373->regmap, in max98373_reset()
357 max98373_reset(max98373, component->dev); in max98373_probe()
360 regmap_write(max98373->regmap, in max98373_probe()
363 regmap_write(max98373->regmap, in max98373_probe()
367 regmap_write(max98373->regmap, in max98373_probe()
370 regmap_write(max98373->regmap, in max98373_probe()
374 regmap_write(max98373->regmap, in max98373_probe()
378 regmap_write(max98373->regmap, in max98373_probe()
382 regmap_write(max98373->regmap, in max98373_probe()
384 (max98373->i_slot << MAX98373_PCM_TX_CH_SRC_A_I_SHIFT | in max98373_probe()
385 max98373->v_slot) & 0xFF); in max98373_probe()
386 if (max98373->v_slot < 8) in max98373_probe()
387 regmap_update_bits(max98373->regmap, in max98373_probe()
389 1 << max98373->v_slot, 0); in max98373_probe()
391 regmap_update_bits(max98373->regmap, in max98373_probe()
393 1 << (max98373->v_slot - 8), 0); in max98373_probe()
395 if (max98373->i_slot < 8) in max98373_probe()
396 regmap_update_bits(max98373->regmap, in max98373_probe()
398 1 << max98373->i_slot, 0); in max98373_probe()
400 regmap_update_bits(max98373->regmap, in max98373_probe()
402 1 << (max98373->i_slot - 8), 0); in max98373_probe()
405 regmap_write(max98373->regmap, in max98373_probe()
410 regmap_write(max98373->regmap, in max98373_probe()
412 max98373->spkfb_slot & 0xFF); in max98373_probe()
415 if (max98373->interleave_mode) in max98373_probe()
416 regmap_update_bits(max98373->regmap, in max98373_probe()
422 regmap_update_bits(max98373->regmap, in max98373_probe()
446 ret = pm_runtime_resume(component->dev); in max98373_sdw_probe()
447 if (ret < 0 && ret != -EACCES) in max98373_sdw_probe()
471 if (!device_property_read_u32(dev, "maxim,vmon-slot-no", &value)) in max98373_slot_config()
472 max98373->v_slot = value & 0xF; in max98373_slot_config()
474 max98373->v_slot = 0; in max98373_slot_config()
476 if (!device_property_read_u32(dev, "maxim,imon-slot-no", &value)) in max98373_slot_config()
477 max98373->i_slot = value & 0xF; in max98373_slot_config()
479 max98373->i_slot = 1; in max98373_slot_config()
482 max98373->reset = devm_gpiod_get_optional(dev, in max98373_slot_config()
485 if (IS_ERR(max98373->reset)) { in max98373_slot_config()
487 PTR_ERR(max98373->reset)); in max98373_slot_config()
492 if (max98373->reset) { in max98373_slot_config()
493 gpiod_set_consumer_name(max98373->reset ,"MAX98373_RESET"); in max98373_slot_config()
494 gpiod_direction_output(max98373->reset, 1); in max98373_slot_config()
496 gpiod_direction_output(max98373->reset, 0); in max98373_slot_config()
500 if (!device_property_read_u32(dev, "maxim,spkfb-slot-no", &value)) in max98373_slot_config()
501 max98373->spkfb_slot = value & 0xF; in max98373_slot_config()
503 max98373->spkfb_slot = 2; in max98373_slot_config()