lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CADiBU3-X5n3b-ZUCFf48C=5oD6RC1E9MD+M6demMLoHzZ3CEBA@mail.gmail.com>
Date:   Tue, 12 Oct 2021 10:47:05 +0800
From:   ChiYuan Huang <u0084500@...il.com>
To:     Mark Brown <broonie@...nel.org>
Cc:     oder_chiou@...ltek.com, perex@...ex.cz, tiwai@...e.com,
        Rob Herring <robh+dt@...nel.org>,
        Liam Girdwood <lgirdwood@...il.com>,
        alsa-devel@...a-project.org, lkml <linux-kernel@...r.kernel.org>,
        cy_huang <cy_huang@...htek.com>,
        "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
        <devicetree@...r.kernel.org>, allen lin <allen_lin@...htek.com>
Subject: Re: [PATCH v3 2/2] ASoC: rt9120: Add rt9210 audio amplifier support

Mark Brown <broonie@...nel.org> 於 2021年10月8日 週五 下午8:51寫道:
>
> On Fri, Oct 08, 2021 at 12:50:12PM +0800, cy_huang wrote:
>
> > +static const struct snd_kcontrol_new rt9120_snd_controls[] = {
> > +     SOC_SINGLE_TLV("MS Volume", RT9120_REG_MSVOL, 0, 2047, 1, digital_gain),
> > +     SOC_SINGLE("SPK Gain", RT9120_REG_SPKGAIN, 0, 7, 0),
>
> Volume controls should end in Volume even if they don't have TLV
> information so applications know how to render them.  I'll fix
> this up as I apply.

It's not linear mapping analog gain and cannot use the TLV as you said.
Mappling table is listed like as below
0 -> 6dB
1 -> 8dB
2 -> 10dB
3 -> 12dB
4 -> 13dB
5 -> 14dB
6 -> 15dB
7 -> 16dB

Do I just need to change it to 'SPK Gain Volume' to present this control item?
Or is there any table mapping for the nonlinear TLV information?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ