* [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
@ 2025-08-13 10:08 Baojun Xu
2025-08-13 15:44 ` Takashi Iwai
0 siblings, 1 reply; 5+ messages in thread
From: Baojun Xu @ 2025-08-13 10:08 UTC (permalink / raw)
To: tiwai
Cc: broonie, andriy.shevchenko, alsa-devel, shenghao-ding,
13916275206, linux-sound, linux-kernel, baojun.xu
Change the name of the kcontrol from "Gain" to "Volume".
Signed-off-by: Baojun Xu <baojun.xu@ti.com>
---
sound/hda/codecs/side-codecs/tas2781_hda_i2c.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
index 92aae19cfc8f..e4bc3bc756b0 100644
--- a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
+++ b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
@@ -256,7 +256,7 @@ static const struct snd_kcontrol_new tas2770_snd_controls[] = {
};
static const struct snd_kcontrol_new tas2781_snd_controls[] = {
- ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Gain", TAS2781_AMP_LEVEL,
+ ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Volume", TAS2781_AMP_LEVEL,
1, 0, 20, 0, tas2781_amp_getvol,
tas2781_amp_putvol, amp_vol_tlv),
ACARD_SINGLE_BOOL_EXT("Speaker Force Firmware Load", 0,
--
2.43.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
2025-08-13 10:08 [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name Baojun Xu
@ 2025-08-13 15:44 ` Takashi Iwai
2025-08-14 2:29 ` [EXTERNAL] " Xu, Baojun
0 siblings, 1 reply; 5+ messages in thread
From: Takashi Iwai @ 2025-08-13 15:44 UTC (permalink / raw)
To: Baojun Xu
Cc: broonie, andriy.shevchenko, alsa-devel, shenghao-ding,
13916275206, linux-sound, linux-kernel
On Wed, 13 Aug 2025 12:08:42 +0200,
Baojun Xu wrote:
>
> Change the name of the kcontrol from "Gain" to "Volume".
Could you describe "why this change is needed"?
thanks,
Takashi
>
> Signed-off-by: Baojun Xu <baojun.xu@ti.com>
> ---
> sound/hda/codecs/side-codecs/tas2781_hda_i2c.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> index 92aae19cfc8f..e4bc3bc756b0 100644
> --- a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> +++ b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> @@ -256,7 +256,7 @@ static const struct snd_kcontrol_new tas2770_snd_controls[] = {
> };
>
> static const struct snd_kcontrol_new tas2781_snd_controls[] = {
> - ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Gain", TAS2781_AMP_LEVEL,
> + ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Volume", TAS2781_AMP_LEVEL,
> 1, 0, 20, 0, tas2781_amp_getvol,
> tas2781_amp_putvol, amp_vol_tlv),
> ACARD_SINGLE_BOOL_EXT("Speaker Force Firmware Load", 0,
> --
> 2.43.0
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [EXTERNAL] Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
2025-08-13 15:44 ` Takashi Iwai
@ 2025-08-14 2:29 ` Xu, Baojun
2025-08-14 6:32 ` Takashi Iwai
0 siblings, 1 reply; 5+ messages in thread
From: Xu, Baojun @ 2025-08-14 2:29 UTC (permalink / raw)
To: Takashi Iwai
Cc: broonie@kernel.org, andriy.shevchenko@linux.intel.com,
alsa-devel@alsa-project.org, Ding, Shenghao, 13916275206@139.com,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org
Hi,
Answer in line.
> ________________________________________
> From: Takashi Iwai <tiwai@suse.de>
> Sent: 13 August 2025 23:44
> To: Xu, Baojun
> Cc: broonie@kernel.org; andriy.shevchenko@linux.intel.com; alsa-devel@alsa-project.org; Ding, Shenghao; 13916275206@139.com; linux-sound@vger.kernel.org; linux-kernel@vger.kernel.org
> Subject: [EXTERNAL] Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
>
> On Wed, 13 Aug 2025 12:08:42 +0200,
> Baojun Xu wrote:
> >
> > Change the name of the kcontrol from "Gain" to "Volume".
>
> Could you describe "why this change is needed"?
>
This name is in kcontrol, which is open to users.
Volume is more normalized and common.
Gain is a more professional term in smart amplifiers.
>
> thanks,
>
> Takashi
>
> >
> > Signed-off-by: Baojun Xu <baojun.xu@ti.com>
> > ---
>> sound/hda/codecs/side-codecs/tas2781_hda_i2c.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> > index 92aae19cfc8f..e4bc3bc756b0 100644
> > --- a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> > +++ b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> > @@ -256,7 +256,7 @@ static const struct snd_kcontrol_new tas2770_snd_controls[] = {
> > };
> >
> > static const struct snd_kcontrol_new tas2781_snd_controls[] = {
> > - ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Gain", TAS2781_AMP_LEVEL,
> > + ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Volume", TAS2781_AMP_LEVEL,
> > 1, 0, 20, 0, tas2781_amp_getvol,
>> tas2781_amp_putvol, amp_vol_tlv),
> > ACARD_SINGLE_BOOL_EXT("Speaker Force Firmware Load", 0,
> > --
> > 2.43.0
> >
>
>
Best Regards
Jim
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [EXTERNAL] Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
2025-08-14 2:29 ` [EXTERNAL] " Xu, Baojun
@ 2025-08-14 6:32 ` Takashi Iwai
2025-08-14 12:42 ` Takashi Iwai
0 siblings, 1 reply; 5+ messages in thread
From: Takashi Iwai @ 2025-08-14 6:32 UTC (permalink / raw)
To: Xu, Baojun
Cc: broonie@kernel.org, andriy.shevchenko@linux.intel.com,
alsa-devel@alsa-project.org, Ding, Shenghao, 13916275206@139.com,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org
On Thu, 14 Aug 2025 04:29:10 +0200,
Xu, Baojun wrote:
>
> Hi,
>
> Answer in line.
>
> > ________________________________________
> > From: Takashi Iwai <tiwai@suse.de>
> > Sent: 13 August 2025 23:44
> > To: Xu, Baojun
> > Cc: broonie@kernel.org; andriy.shevchenko@linux.intel.com; alsa-devel@alsa-project.org; Ding, Shenghao; 13916275206@139.com; linux-sound@vger.kernel.org; linux-kernel@vger.kernel.org
> > Subject: [EXTERNAL] Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
> >
> > On Wed, 13 Aug 2025 12:08:42 +0200,
> > Baojun Xu wrote:
> > >
> > > Change the name of the kcontrol from "Gain" to "Volume".
> >
> > Could you describe "why this change is needed"?
> >
> This name is in kcontrol, which is open to users.
> Volume is more normalized and common.
> Gain is a more professional term in smart amplifiers.
But did you realize that changing the control name may change the
user-space behavior completely?
e.g. alsa-lib implementation tries to group control elements per
prefix and suffix, and "Volume" is one of the standard suffix.
That is, with this change, it'll appear as "Speaker Analog" as a mixer
element name where the former name is "Speaker Analog Gain".
I'm not against the proposed rename. But please remember that control
names aren't something you can change easily because you don't feel
good; it's a thing to be more or less "fixed" once after defined in
the release products.
thanks,
Takashi
>
> >
> > thanks,
> >
> > Takashi
> >
> > >
> > > Signed-off-by: Baojun Xu <baojun.xu@ti.com>
> > > ---
> >> sound/hda/codecs/side-codecs/tas2781_hda_i2c.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> > > index 92aae19cfc8f..e4bc3bc756b0 100644
> > > --- a/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> > > +++ b/sound/hda/codecs/side-codecs/tas2781_hda_i2c.c
> > > @@ -256,7 +256,7 @@ static const struct snd_kcontrol_new tas2770_snd_controls[] = {
> > > };
> > >
> > > static const struct snd_kcontrol_new tas2781_snd_controls[] = {
> > > - ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Gain", TAS2781_AMP_LEVEL,
> > > + ACARD_SINGLE_RANGE_EXT_TLV("Speaker Analog Volume", TAS2781_AMP_LEVEL,
> > > 1, 0, 20, 0, tas2781_amp_getvol,
> >> tas2781_amp_putvol, amp_vol_tlv),
> > > ACARD_SINGLE_BOOL_EXT("Speaker Force Firmware Load", 0,
> > > --
> > > 2.43.0
> > >
> >
> >
>
> Best Regards
> Jim
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [EXTERNAL] Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
2025-08-14 6:32 ` Takashi Iwai
@ 2025-08-14 12:42 ` Takashi Iwai
0 siblings, 0 replies; 5+ messages in thread
From: Takashi Iwai @ 2025-08-14 12:42 UTC (permalink / raw)
To: Xu, Baojun
Cc: broonie@kernel.org, andriy.shevchenko@linux.intel.com,
alsa-devel@alsa-project.org, Ding, Shenghao, 13916275206@139.com,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org
On Thu, 14 Aug 2025 08:32:18 +0200,
Takashi Iwai wrote:
>
> On Thu, 14 Aug 2025 04:29:10 +0200,
> Xu, Baojun wrote:
> >
> > Hi,
> >
> > Answer in line.
> >
> > > ________________________________________
> > > From: Takashi Iwai <tiwai@suse.de>
> > > Sent: 13 August 2025 23:44
> > > To: Xu, Baojun
> > > Cc: broonie@kernel.org; andriy.shevchenko@linux.intel.com; alsa-devel@alsa-project.org; Ding, Shenghao; 13916275206@139.com; linux-sound@vger.kernel.org; linux-kernel@vger.kernel.org
> > > Subject: [EXTERNAL] Re: [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name
> > >
> > > On Wed, 13 Aug 2025 12:08:42 +0200,
> > > Baojun Xu wrote:
> > > >
> > > > Change the name of the kcontrol from "Gain" to "Volume".
> > >
> > > Could you describe "why this change is needed"?
> > >
> > This name is in kcontrol, which is open to users.
> > Volume is more normalized and common.
> > Gain is a more professional term in smart amplifiers.
>
> But did you realize that changing the control name may change the
> user-space behavior completely?
> e.g. alsa-lib implementation tries to group control elements per
> prefix and suffix, and "Volume" is one of the standard suffix.
> That is, with this change, it'll appear as "Speaker Analog" as a mixer
> element name where the former name is "Speaker Analog Gain".
>
> I'm not against the proposed rename. But please remember that control
> names aren't something you can change easily because you don't feel
> good; it's a thing to be more or less "fixed" once after defined in
> the release products.
Nevertheless I applied the patch now, as Mark already took for ASoC
side.
thanks,
Takashi
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-08-14 12:42 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-13 10:08 [PATCH v1] ALSA: hda/tas2781: Normalize the volume kcontrol name Baojun Xu
2025-08-13 15:44 ` Takashi Iwai
2025-08-14 2:29 ` [EXTERNAL] " Xu, Baojun
2025-08-14 6:32 ` Takashi Iwai
2025-08-14 12:42 ` Takashi Iwai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).