Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp3074030rdb; Wed, 13 Sep 2023 00:43:50 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFRlLJJoMLbUiANZRN1xJ7M1pA0wjOR2rrygnIOlz++oGGj96zwx85FS58vdE/RVQNAXh+/ X-Received: by 2002:a05:6358:5290:b0:139:d277:354d with SMTP id g16-20020a056358529000b00139d277354dmr2508347rwa.22.1694591029988; Wed, 13 Sep 2023 00:43:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694591029; cv=none; d=google.com; s=arc-20160816; b=KsGESP/PWQ0pONa2ZluTrB2M1MmVkMeH8ZR+0vM23TB+4w68hqvu9U6587pOtU0ySV 6E3VLtHuIqsljq+i+nsO4FiqI0mOhmscHi2KkKMmLnmMYCQRvWnheF6BreHgydQbBpQN 2k5VyZn3KHkdI2nPWo0ZCqn8cYHE016BtQJTtvbftFW/A3SHi8inP2Z+CRZqcrHex3tk 9yhd0melyw5e8Oc1oy3IbRFxPtrCyFxe07rAqPUR7295JWGR5hbWOWBe0Kaaomh7qUu7 SGNABoIzAnHDq1ft6Qwy2nA/mqSkDVitmLiJ2cHOcSRoRpRVRi+6vTaWRQwkFSi+Xpol V9Ng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:subject:cc:to:from:message-id :date:dkim-signature:dkim-signature; bh=LqGSMVkAA4Ewp/wOJFgzYA6OwmPk0CC2NscF4DotmQA=; fh=FXqK766INBFC2j9956Oj51CGk4Bn6VGuGrJ7Sea3SRc=; b=DNKh+L3int5k/2043fyrFT7yrms/rt4w/5aImJ2AMLa2UedqFBACoWUGwdZP/7yGE3 oFyFGRblwAIsfmEPrFRakXHAw2p+ClESOU2qAgAhq3SwbmSC5oSliDIQpIfmNcwlVJcs iPtg92rYHEKGNCmFwlRrXCVbz9WFYx6rzB26vcFtTA61NmSVYCunGg9B6I0NlJN2Pk/F 2hvnTMd1i9IBTXtMeY5pSL3HRNPd8JfWUVyCR4D3juAf9WDXLa26wfGKwvLknERNpa6o QWXiKHyP4IIbGfPqIkT3iWLgThjVkt8ILAUtYCEwLIZpiVloftr8OB/RpxO16PBVDBuh cTsw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b="ZAi7Bt/4"; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id t31-20020a056a00139f00b0068fa8499af1si1953663pfg.11.2023.09.13.00.43.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 00:43:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b="ZAi7Bt/4"; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id CC3B381C804A; Wed, 13 Sep 2023 00:43:41 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238619AbjIMHnl (ORCPT + 99 others); Wed, 13 Sep 2023 03:43:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58114 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238601AbjIMHnk (ORCPT ); Wed, 13 Sep 2023 03:43:40 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7CFC11986 for ; Wed, 13 Sep 2023 00:43:36 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 319D01F45B; Wed, 13 Sep 2023 07:43:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1694591015; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LqGSMVkAA4Ewp/wOJFgzYA6OwmPk0CC2NscF4DotmQA=; b=ZAi7Bt/464oMhiiIs39kEjyATKaMlSMniG38aSFc9vmPpFCEPg3BbJBAXzFApg4em+prlk ukmbUJ7ahsCkbYs/fO8zHJ3+l9bb3G1S17FFVd/zqZwkov94Ijbdos8BrA7UouSqOuCccc Saod/u0m5THe+YzVFzv2f4H76d1I5bA= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1694591015; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LqGSMVkAA4Ewp/wOJFgzYA6OwmPk0CC2NscF4DotmQA=; b=fQquTscPU1Y2kAIPsR1Xt6FzlLFQAVMs4Z6gbNDTTTiR1tM5XjwuKiXeD+n0+f1+gLaKS/ ByxttswjXYqI+dCg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 0140013582; Wed, 13 Sep 2023 07:43:34 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id +vz0OiZoAWURDgAAMHmgww (envelope-from ); Wed, 13 Sep 2023 07:43:34 +0000 Date: Wed, 13 Sep 2023 09:43:34 +0200 Message-ID: <87y1ha4ixl.wl-tiwai@suse.de> From: Takashi Iwai To: Peter Ujfalusi Cc: tiwai@suse.com, perex@perex.cz, arnd@arndb.de, masahiroy@kernel.org, linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org, pierre-louis.bossart@linux.intel.com Subject: Re: [PATCH] ALSA: hda: intel-sdw-acpi: Use u8 type for link index In-Reply-To: <20230912162617.29178-1-peter.ujfalusi@linux.intel.com> References: <20230912162617.29178-1-peter.ujfalusi@linux.intel.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=ISO-8859-7 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Wed, 13 Sep 2023 00:43:42 -0700 (PDT) X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email On Tue, 12 Sep 2023 18:26:17 +0200, Peter Ujfalusi wrote: > > Use consistently u8 for sdw link index. The id is limited to 4, u8 is > adequate in size to store it. > > This change will also fixes the following compiler warning/error (W=1): > > sound/hda/intel-sdw-acpi.c: In function ?sdw_intel_acpi_scan?: > sound/hda/intel-sdw-acpi.c:34:35: error: ?-subproperties? directive output may be truncated writing 14 bytes into a region of size between 7 and 17 [-Werror=format-truncation=] > 34 | "mipi-sdw-link-%d-subproperties", i); > | ^~~~~~~~~~~~~~ > In function ?is_link_enabled?, > inlined from ?sdw_intel_scan_controller? at sound/hda/intel-sdw-acpi.c:106:8, > inlined from ?sdw_intel_acpi_scan? at sound/hda/intel-sdw-acpi.c:180:9: > sound/hda/intel-sdw-acpi.c:33:9: note: ?snprintf? output between 30 and 40 bytes into a destination of size 32 > 33 | snprintf(name, sizeof(name), > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ > 34 | "mipi-sdw-link-%d-subproperties", i); > | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > cc1: all warnings being treated as errors > > The warnings got brought to light by a recent patch upstream: > commit 6d4ab2e97dcf ("extrawarn: enable format and stringop overflow warnings in W=1") > > Signed-off-by: Peter Ujfalusi Thanks, applied now. Takashi