Skip to content

Commit 3f47c1e

Browse files
Mirsad Todorovactiwai
authored andcommitted
kselftest/alsa - mixer-test: Fix the print format specifier warning
The GCC 13.2.0 compiler issued the following warning: mixer-test.c: In function ‘ctl_value_index_valid’: mixer-test.c:322:79: warning: format ‘%lld’ expects argument of type ‘long long int’, \ but argument 5 has type ‘long int’ [-Wformat=] 322 | ksft_print_msg("%s.%d value %lld more than maximum %lld\n", | ~~~^ | | | long long int | %ld 323 | ctl->name, index, int64_val, 324 | snd_ctl_elem_info_get_max(ctl->info)); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | long int Fixing the format specifier as advised by the compiler suggestion removes the warning. Fixes: 3f48b13 ("kselftest: alsa: Factor out check that values meet constraints") Cc: Mark Brown <broonie@kernel.org> Cc: Jaroslav Kysela <perex@perex.cz> Cc: Takashi Iwai <tiwai@suse.com> Cc: Shuah Khan <shuah@kernel.org> Cc: linux-sound@vger.kernel.org Cc: linux-kselftest@vger.kernel.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Mirsad Todorovac <mirsad.todorovac@alu.unizg.hr> Acked-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20240107173704.937824-3-mirsad.todorovac@alu.unizg.hr Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 8c51c13 commit 3f47c1e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tools/testing/selftests/alsa/mixer-test.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ static bool ctl_value_index_valid(struct ctl_data *ctl,
319319
}
320320

321321
if (int64_val > snd_ctl_elem_info_get_max64(ctl->info)) {
322-
ksft_print_msg("%s.%d value %lld more than maximum %lld\n",
322+
ksft_print_msg("%s.%d value %lld more than maximum %ld\n",
323323
ctl->name, index, int64_val,
324324
snd_ctl_elem_info_get_max(ctl->info));
325325
return false;

0 commit comments

Comments
 (0)