Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp284336imn; Fri, 29 Jul 2022 06:51:56 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tk9mitV+F0ubZ3dhJGgrRI6S8R/FIYfY6YXE64B5ae+cR8qOi4NJx1hQ+fIR02yNhr0h52 X-Received: by 2002:a17:907:60cc:b0:72b:40a8:a5b with SMTP id hv12-20020a17090760cc00b0072b40a80a5bmr2929718ejc.379.1659102716203; Fri, 29 Jul 2022 06:51:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659102716; cv=none; d=google.com; s=arc-20160816; b=qyD6pXEGWrOaPFSxECPtbEBJtEm7C0n8cR9nCqn6uCNWCY+AceGeNSed4pzp+6JtYc dxMRQ3Fy2gCEb05E001UiqGvK2A8hbs1jlJQHuVpqkMmV+QHDw1FNRB5fkpsNbiDJM/K 45JaM/qBG3JhQKG9rnD1y7qrZH2EygIUfz3cqxOkN8wi4K1/ZcLjoh+G+/Ft6rhsqbP0 fadX7k5ywwdMWdq8TWRM4DIFRUe2MqY7t0UPxvP2jDak7b7D5N7g0RUmb7MREPj/C+jt 67Rh4pg9+Hh8HrUqxZPWdc0SLNy0cXoplA3YZybJuSpmrEbCmlJysZVOs4AFIZOyDfW5 nMfg== 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 :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature:dkim-signature; bh=5FMeB7gNzDdPBcB0grv6dwqtsT3RsWnwrpI2BT3+73M=; b=c+03zwnQ6m3NpdPrFDwtwMsqn17ltSTOBgQC5OhsH0NCM6kN5ButF4s2GmMjOSHpKQ 2/muKeBazLeVxKOUo6uX/7fcLapsCMnFz2Ch8nVl9f8K6qm5846QlVPiKwrsbi415vej PEseVAh10jKEtD1D8tzP5FaWxIEEl3OfWDT3IlAtP2wwsm8zb0g2zF/HXC3s9vKvgEUl gSUXFAhF7cU0d/F9ySMmLQ4eCcNqT4W5rrVsfxNO6zlXioqImLlaOlNv/1adpD1exQsg KUolfDfsv8t2mbntnPB0p27eUdAvLykmR0WQb7K+SeMp2ZtI1lDFHbk7/dlVrk3Jj6gu ml+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=OyhcVXwJ; 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 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id jt4-20020a170906dfc400b00729e3430883si3040836ejc.768.2022.07.29.06.51.30; Fri, 29 Jul 2022 06:51:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=OyhcVXwJ; 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 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231976AbiG2NX4 (ORCPT + 99 others); Fri, 29 Jul 2022 09:23:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45548 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235820AbiG2NXy (ORCPT ); Fri, 29 Jul 2022 09:23:54 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1F0346759E for ; Fri, 29 Jul 2022 06:23:52 -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 BE9EA1FACC; Fri, 29 Jul 2022 13:23:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1659101030; 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=5FMeB7gNzDdPBcB0grv6dwqtsT3RsWnwrpI2BT3+73M=; b=OyhcVXwJEDTEnywR51HSrlFRd3VcmWxHiufTNsvD83+QpZ4KJZiDh79T+20FNSZyLp3Rix p3sZ1WJBG6t2S+VMiaQ/WT4rxYb+aZr55x5FqyXm18qX8/5yywgFz+Zp57pZdWCpIYi+I1 y0HyvAd553z2CmEWrxGmvLq1TfcUtuY= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1659101030; 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=5FMeB7gNzDdPBcB0grv6dwqtsT3RsWnwrpI2BT3+73M=; b=os5OdYUSfFMSQBT3slgxbpu2pzJSEDtwvJQygrEH95h25oYKy173Yqp9oc7kNH3TmM54BL de/nFXErN45gjdCg== 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 704EF13A8E; Fri, 29 Jul 2022 13:23:50 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id J9C5GWbf42JiSwAAMHmgww (envelope-from ); Fri, 29 Jul 2022 13:23:50 +0000 Date: Fri, 29 Jul 2022 15:23:49 +0200 From: Jean Delvare To: AngeloGioacchino Del Regno Cc: linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, Mark Brown , Liam Girdwood , Matthias Brugger , Chenglin Xu , Sean Wang Subject: Re: [PATCH RFC] regulator: mt6380: Fix unused array warning Message-ID: <20220729152349.6a4801a5@endymion.delvare> In-Reply-To: References: <20220727132637.76d6073f@endymion.delvare> Organization: SUSE Linux X-Mailer: Claws Mail 3.18.0 (GTK+ 2.24.32; x86_64-suse-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 28 Jul 2022 13:15:14 +0200, AngeloGioacchino Del Regno wrote: > Il 27/07/22 13:26, Jean Delvare ha scritto: > > With the following configuration options: > > CONFIG_OF is not set > > CONFIG_REGULATOR_MT6380=3Dy > > we get the following build warning: > >=20 > > CC drivers/regulator/mt6380-regulator.o > > drivers/regulator/mt6380-regulator.c:322:34: warning: =E2=80=98mt6380_o= f_match=E2=80=99 defined but not used [-Wunused-const-variable=3D] > >=20 > > Fix this by annotating that array with __maybe_unused, as done in > > various regulator drivers. =20 >=20 > I know I'm late to the party, but I would've preferred to see the > of_match_ptr() dropped instead of adding a __maybe_unused. Doing that for this driver would basically prevent the compiler from dropping out the variable in the !CONFIG_OF case. If this is a valid case (and I really would like Mediatek people to comment on that) then I can't see how that would be an improvement. --=20 Jean Delvare SUSE L3 Support