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: <20250829-sound-param-v1-1-3c2f67cd7c97@uniontech.com>
Date: Fri, 29 Aug 2025 13:10:59 +0800
From: Cryolitia PukNgae via B4 Relay <devnull+cryolitia.uniontech.com@...nel.org>
To: Jaroslav Kysela <perex@...ex.cz>, Takashi Iwai <tiwai@...e.com>, 
 Jonathan Corbet <corbet@....net>
Cc: linux-sound@...r.kernel.org, linux-kernel@...r.kernel.org, 
 Mingcong Bai <jeffbai@...c.io>, Kexy Biscuit <kexybiscuit@...c.io>, 
 Wang Yuli <wangyuli@...pin.org>, Guan Wentao <guanwentao@...ontech.com>, 
 Nie Cheng <niecheng1@...ontech.com>, Zhan Jun <zhanjun@...ontech.com>, 
 Celeste Liu <CoelacanthusHex@...il.com>, Guoli An <anguoli@...ontech.com>, 
 linux-doc@...r.kernel.org, Cryolitia PukNgae <cryolitia@...ontech.com>
Subject: [PATCH 1/2] ALSA: usb-audio: Add module param mixer_min_mute

From: Cryolitia PukNgae <cryolitia@...ontech.com>

As already discussed[1], a module parameter called mixer_min_mute is
added to make it easier for end users to debug the widespread problem
without recompiling the kernel, where USB audio devices are muted when
the volume is set to the minimum value.

1.
https://lore.kernel.org/all/20250827-sound-quirk-min-mute-v1-1-4717aa8a4f6a@uniontech.com/

Tested-by: Guoli An <anguoli@...ontech.com>
Signed-off-by: Cryolitia PukNgae <cryolitia@...ontech.com>
---
 sound/usb/card.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/sound/usb/card.c b/sound/usb/card.c
index 0265206a8e8cf31133e8463c98fe0497d8ace89e..bf65727ad213f2897d735c1f3c55bfc3f85971cf 100644
--- a/sound/usb/card.c
+++ b/sound/usb/card.c
@@ -74,6 +74,7 @@ static char *quirk_alias[SNDRV_CARDS];
 static char *delayed_register[SNDRV_CARDS];
 static bool implicit_fb[SNDRV_CARDS];
 static unsigned int quirk_flags[SNDRV_CARDS];
+static bool mixer_min_mute;
 
 bool snd_usb_use_vmalloc = true;
 bool snd_usb_skip_validation;
@@ -109,6 +110,9 @@ module_param_named(use_vmalloc, snd_usb_use_vmalloc, bool, 0444);
 MODULE_PARM_DESC(use_vmalloc, "Use vmalloc for PCM intermediate buffers (default: yes).");
 module_param_named(skip_validation, snd_usb_skip_validation, bool, 0444);
 MODULE_PARM_DESC(skip_validation, "Skip unit descriptor validation (default: no).");
+module_param(mixer_min_mute, bool, 0444);
+MODULE_PARM_DESC(mixer_min_mute,
+		 "Set minimum volume control value as mute (default: no).");
 
 /*
  * we keep the snd_usb_audio_t instances by ourselves for merging
@@ -959,6 +963,9 @@ static int usb_audio_probe(struct usb_interface *intf,
 	if (ignore_ctl_error)
 		chip->quirk_flags |= QUIRK_FLAG_IGNORE_CTL_ERROR;
 
+	if (mixer_min_mute)
+		chip->quirk_flags |= QUIRK_FLAG_MIXER_MIN_MUTE;
+
 	if (chip->quirk_flags & QUIRK_FLAG_DISABLE_AUTOSUSPEND)
 		usb_disable_autosuspend(interface_to_usbdev(intf));
 

-- 
2.51.0



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ