From: Takashi Iwai <tiwai@suse.de>
To: HyeongJun An <sammiee5311@gmail.com>
Cc: Mark Brown <broonie@kernel.org>, Takashi Iwai <tiwai@suse.com>,
Jaroslav Kysela <perex@perex.cz>, Shuah Khan <shuah@kernel.org>,
linux-sound@vger.kernel.org, linux-kselftest@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] selftests/alsa: Fix the step check for INTEGER controls
Date: Thu, 03 Sep 2026 18:07:55 +0200 [thread overview]
Message-ID: <87o6ee71yc.wl-tiwai@suse.de> (raw)
In-Reply-To: <20260903123832.97377-1-sammiee5311@gmail.com>
On Thu, 03 Sep 2026 14:38:32 +0200,
HyeongJun An wrote:
>
> The modulo sits inside the subtraction, so the check evaluates
> int_val - (min % step) rather than (int_val - min) % step. The
> INTEGER64 branch below it is parenthesised correctly.
>
> The written form passes only when the value equals min % step, and such
> a value is always on a step boundary, so it never misses a real
> violation. It only reports valid values as invalid.
>
> snd-aloop declares step 1 on four controls, so every non-zero value on
> them is reported. Before:
>
> # PCM Rate Shift 100000.0 value 100000 invalid for step 1 minimum 80000
> # Totals: pass:660 fail:101 xfail:0 xpass:0 skip:296 error:0
>
> After, same card, nothing else changed:
>
> # Totals: pass:740 fail:21 xfail:0 xpass:0 skip:296 error:0
>
> Eighteen files under sound/ declare a non-zero step.
>
> Fixes: 5aaf9efffc57 ("kselftest: alsa: Add simplistic test for ALSA mixer controls kselftest")
> Signed-off-by: HyeongJun An <sammiee5311@gmail.com>
> Assisted-by: Claude:claude-opus-5
Applied now. Thanks.
Takashi
prev parent reply other threads:[~2026-09-03 16:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-03 12:38 [PATCH] selftests/alsa: Fix the step check for INTEGER controls HyeongJun An
2026-09-03 16:07 ` Takashi Iwai [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87o6ee71yc.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=broonie@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=perex@perex.cz \
--cc=sammiee5311@gmail.com \
--cc=shuah@kernel.org \
--cc=tiwai@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.