From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 09F32C61DA3 for ; Fri, 24 Feb 2023 10:02:38 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 046FD832; Fri, 24 Feb 2023 11:01:46 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 046FD832 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1677232956; bh=qv1ebqxNKYeh2P2ahXxCf6dkKAslAGphNWhUKZ3rmH4=; h=Date:Subject:To:References:From:In-Reply-To:CC:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=fAsqEnn/phAytovp2JvSy71SEl1xUcOKGhd8UkygYfBhU2r23NNVjzzPUbFrz0xzv +Yus+SGeuCcF9nt8W6neNVSORq03vZ8UtLsCVuRtdaaT7tmeyTq3K4XZ0y//xgHSnw xGxGLiJjZRmubzLLiqyCuRZYee2Q/sk6bztmkuy0= Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 7E696F80534; Fri, 24 Feb 2023 11:00:37 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 4B57CF80496; Thu, 23 Feb 2023 21:15:10 +0100 (CET) Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 913FDF80038 for ; Thu, 23 Feb 2023 21:15:00 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 913FDF80038 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=BaLgVKhu Received: by mail-ed1-x52d.google.com with SMTP id cy6so41152562edb.5 for ; Thu, 23 Feb 2023 12:15:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677183298; h=content-transfer-encoding:in-reply-to:cc:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=kAb0qzqWSP/U+Kj5L5nLqdqYurAmo6JZhKfQvH683Pk=; b=BaLgVKhuX1clAmVVahaKedAK7xDb7n37VgbEl5j85och7Y9+re7M8ZB/GCXlN0iW4P RpY+bsTzN0egXJpJpNN6fArx526j4YSZMdYk9+RQAwoSaK8RddM/LoJ7NJ4WNge1jI4W 293i+uUBsLoU17XWO6XQoOMRekI+h/hSXlrVMYaHq9e9lyshfu5uXQ+L7ErgJk07+5VO wf5Y+moJHpgaDl2hpoPsc/ktmPyHoaI1J4Y6eO9UQJ0D8/75X+SR2Hgj3Kz+Q7PDGUwJ wEKJF4emYuhPovJsIuKN13NKtTWZayn5CQ7InFhtxFJueiuJvH7c89YgRPQnJjKVVYvb GSwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677183298; h=content-transfer-encoding:in-reply-to:cc:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=kAb0qzqWSP/U+Kj5L5nLqdqYurAmo6JZhKfQvH683Pk=; b=YDkMtUB7KhsB0IoqOYL4tFhZm5b9frvK46Als/9mz0d6AaGT6QQYjIMFTTryh1/z7D Odb15ecRk/AsfJVQRQwrk/85mgHWOJrvqHPnDVAKKJWDv0CwDrc769ujB9ryq1n6Hn9J Ea46Cm6GHl5YUmDgusR1TP4juzHkB8XB2VQCb1Ca5t/ELCB1Y0g88g0DN64W29xJ1MK+ gFint0A8gUEXEHbcOl1CCx4vDyBMUYC8TLFrmFa4Xzwta4snmVM9pGli+0A0Mz8j3Cgf VdGNNas/1vL9hcz7fzhjCDgRMsKmnkRW91lrKcJSUkY3JVdu15Wfi0xRtTJ7/8AnfnGw Tfhg== X-Gm-Message-State: AO0yUKXVGfAylqtERzi+k2C4N6/IIiP04pqA3YkV0aVV2RszZNPfTMKq gw1nfDJtxwHAARLsBeVnJFM= X-Google-Smtp-Source: AK7set+fyV8NY7swJO99sprnqCQsbhtz4OVtCCE4+qb/xglPT66O02/tvTfiEpZ9YzNZX/uhSq5ksQ== X-Received: by 2002:a05:6402:34d5:b0:4ac:8e63:300a with SMTP id w21-20020a05640234d500b004ac8e63300amr12695555edc.3.1677183298324; Thu, 23 Feb 2023 12:14:58 -0800 (PST) Received: from [192.168.88.131] ([37.252.81.68]) by smtp.gmail.com with ESMTPSA id s21-20020a50d495000000b004aee548b3e2sm5338830edi.69.2023.02.23.12.14.57 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 23 Feb 2023 12:14:58 -0800 (PST) Message-ID: <1db3bfe5-0982-b445-9c94-784478279028@gmail.com> Date: Thu, 23 Feb 2023 23:14:56 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 Subject: Re: [PATCH] Fix snprintf format warnings during 'alsa' kselftest compilation Content-Language: en-US To: Mark Brown References: <20230223143214.16564-1-ivan.orlov0322@gmail.com> From: Ivan Orlov In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-MailFrom: ivan.orlov0322@gmail.com X-Mailman-Rule-Hits: nonmember-moderation X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1 Message-ID-Hash: DN5EGZCYT5MZ45TJOP5JG4OMUXRSDPMV X-Message-ID-Hash: DN5EGZCYT5MZ45TJOP5JG4OMUXRSDPMV X-Mailman-Approved-At: Fri, 24 Feb 2023 10:00:14 +0000 CC: tiwai@suse.com, shuah@kernel.org, alsa-devel@alsa-project.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, skhan@linuxfoundation.org X-Mailman-Version: 3.3.8 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On 23.02.2023 18:05, Mark Brown wrote: > What warnings are you seeing in what configuration (arch, toolchain, any > custom options...)? I'm not seeing anything when I test. Are these > perhaps architecture dependent warnings? > > Please submit patches using subject lines reflecting the style for the > subsystem, this makes it easier for people to identify relevant patches. > Look at what existing commits in the area you're changing are doing and > make sure your subject lines visually resemble what they're doing. > There's no need to resubmit to fix this alone. Thank you for the review! I will follow the common subject lines style in the future. I compiled the test via gcc 11.3.0 without any custom options, the arch is x86_64. There were five warnings during the test compilation, and all of them were caused by incorrect format in 'snprintf' function calls. As I know, using incorrect format in 'snprintf' creates an undefined behavior. Maybe there is a point to fix it? From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B8E32C61DA4 for ; Thu, 23 Feb 2023 20:15:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229471AbjBWUPB (ORCPT ); Thu, 23 Feb 2023 15:15:01 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229436AbjBWUPB (ORCPT ); Thu, 23 Feb 2023 15:15:01 -0500 Received: from mail-ed1-x52e.google.com (mail-ed1-x52e.google.com [IPv6:2a00:1450:4864:20::52e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E1A244DE25; Thu, 23 Feb 2023 12:14:59 -0800 (PST) Received: by mail-ed1-x52e.google.com with SMTP id h16so46798776edz.10; Thu, 23 Feb 2023 12:14:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1677183298; h=content-transfer-encoding:in-reply-to:cc:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=kAb0qzqWSP/U+Kj5L5nLqdqYurAmo6JZhKfQvH683Pk=; b=BaLgVKhuX1clAmVVahaKedAK7xDb7n37VgbEl5j85och7Y9+re7M8ZB/GCXlN0iW4P RpY+bsTzN0egXJpJpNN6fArx526j4YSZMdYk9+RQAwoSaK8RddM/LoJ7NJ4WNge1jI4W 293i+uUBsLoU17XWO6XQoOMRekI+h/hSXlrVMYaHq9e9lyshfu5uXQ+L7ErgJk07+5VO wf5Y+moJHpgaDl2hpoPsc/ktmPyHoaI1J4Y6eO9UQJ0D8/75X+SR2Hgj3Kz+Q7PDGUwJ wEKJF4emYuhPovJsIuKN13NKtTWZayn5CQ7InFhtxFJueiuJvH7c89YgRPQnJjKVVYvb GSwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1677183298; h=content-transfer-encoding:in-reply-to:cc:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=kAb0qzqWSP/U+Kj5L5nLqdqYurAmo6JZhKfQvH683Pk=; b=vHiNqAvc/PccALmoQ0EPjlIY/OOZ0T01LA7r3KzASoyJEByGIW/NZH+tGAtqUSElAJ oLoYWD3vgMROaHvbYPmHWE8FlDLzWEkJdE8YcNPPgGKqLFccypZuJS1EfamoahoR7AFb V0HRvl49KfDJo1oqZOBrrDvotbcZxP7OyL0TdlJeUkX+WFJjkKKWjzYY/h0Z6XoCH5AD lCumtMaP8W6dYssV33AtZNI6jPeIt/7W/oR8vuT2NzxECTUMhOETYgwLinwIOWiTYKC/ L7R+HPg7+WyqrOTXovSMZ17OCejv66ti4tSgFp4FyogNaxlyGBKVfEa4WiBKq04XY7jL qPyg== X-Gm-Message-State: AO0yUKX6gTOje0S46Up/4t35JVEHzME9YEEBEzM1O9oh7+lbpnmwz7Rh A17AcOpU+FIoKXEXv1AjA7liXXlvyaA0VM71 X-Google-Smtp-Source: AK7set+fyV8NY7swJO99sprnqCQsbhtz4OVtCCE4+qb/xglPT66O02/tvTfiEpZ9YzNZX/uhSq5ksQ== X-Received: by 2002:a05:6402:34d5:b0:4ac:8e63:300a with SMTP id w21-20020a05640234d500b004ac8e63300amr12695555edc.3.1677183298324; Thu, 23 Feb 2023 12:14:58 -0800 (PST) Received: from [192.168.88.131] ([37.252.81.68]) by smtp.gmail.com with ESMTPSA id s21-20020a50d495000000b004aee548b3e2sm5338830edi.69.2023.02.23.12.14.57 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 23 Feb 2023 12:14:58 -0800 (PST) Message-ID: <1db3bfe5-0982-b445-9c94-784478279028@gmail.com> Date: Thu, 23 Feb 2023 23:14:56 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 Subject: Re: [PATCH] Fix snprintf format warnings during 'alsa' kselftest compilation Content-Language: en-US To: Mark Brown References: <20230223143214.16564-1-ivan.orlov0322@gmail.com> From: Ivan Orlov Cc: perex@perex.cz, tiwai@suse.com, shuah@kernel.org, alsa-devel@alsa-project.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, skhan@linuxfoundation.org In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org On 23.02.2023 18:05, Mark Brown wrote: > What warnings are you seeing in what configuration (arch, toolchain, any > custom options...)? I'm not seeing anything when I test. Are these > perhaps architecture dependent warnings? > > Please submit patches using subject lines reflecting the style for the > subsystem, this makes it easier for people to identify relevant patches. > Look at what existing commits in the area you're changing are doing and > make sure your subject lines visually resemble what they're doing. > There's no need to resubmit to fix this alone. Thank you for the review! I will follow the common subject lines style in the future. I compiled the test via gcc 11.3.0 without any custom options, the arch is x86_64. There were five warnings during the test compilation, and all of them were caused by incorrect format in 'snprintf' function calls. As I know, using incorrect format in 'snprintf' creates an undefined behavior. Maybe there is a point to fix it?