Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp2350830pxb; Sun, 5 Sep 2021 16:22:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxdWstIDp0R3JZiBc5Vs82O302qckccdBfaCCnGVuy2jpat0F9kkct41nG0+jLbygHvdTEM X-Received: by 2002:a05:6e02:1c2b:: with SMTP id m11mr6152755ilh.242.1630884126708; Sun, 05 Sep 2021 16:22:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630884126; cv=none; d=google.com; s=arc-20160816; b=rb7Wn77OE19oxd8NQ4W9PoZ7mGnOiEFRKtAzfUkMsYoXofyQSsrpNJQnQoF0pZ2Bkw 5SrEskIL+Mtz5l/WVn+IWlCEZk5tQMEhVi/CR2N0H2GpBbV8lplGajh3CZS0+Qgy1gRv chYAjZ6XgjDLNcv8fKEM2vCj0KMvBNXrek7CkqErYCcDJMy3wJYVtDY8bhdLAuO6Q5JQ /OzGP1IcafiaSB3+bYA4FfQ5L1MOWwmRrF+aqgEOQkxUG/ZYjnnPJtRaowhDLQH2fCHj PldpvMFABc2NUtqbhgaWd3V6xn/AXXYPxXjlaXcFIEjwDX6sxeV7OY0Yz9Uu02ZKujgt n6kQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=7BZXdqPIIbX0lmfQ4SwtNY8oiLwmuMvBZoqm565+qZM=; b=L4OfzOD7ISFj223Fo540oLYSMQJ5ZxBNJTv8CU5MyZv7s+3eRwapxouEGsyFhZWGIe Pe7fg2d0hEqbA1aPJXO10aJVA/eO1zqZmpZAIjRn8wHUgkY0K6Cr4lRWyhbTyRN2okfe qMGITkX1CiYHuvmagJwwtZ2vBGBlDTBhfeimr91ALVixU7f0RtMXY0S80gFJE+Q4dupt 41YbJWkE5u+1E6Ex6pn21you44nd6WaRStj0ZUPCCkfZLyIG8n6yD45sL6XofS3dDXUU Pzg1t679Ir8unlklM6rqXlIzva8IFLPdIaLSxnvuWKsZ/rVfcVx7r8R+alGcyefGJ8Sb DJTQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b="MJSm/ehK"; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z11si5930398ilb.65.2021.09.05.16.21.39; Sun, 05 Sep 2021 16:22:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b="MJSm/ehK"; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232759AbhIEXUw (ORCPT + 99 others); Sun, 5 Sep 2021 19:20:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53842 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232745AbhIEXUw (ORCPT ); Sun, 5 Sep 2021 19:20:52 -0400 Received: from mail-pl1-x631.google.com (mail-pl1-x631.google.com [IPv6:2607:f8b0:4864:20::631]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E6B3AC061575; Sun, 5 Sep 2021 16:19:48 -0700 (PDT) Received: by mail-pl1-x631.google.com with SMTP id u1so2834660plq.5; Sun, 05 Sep 2021 16:19:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=7BZXdqPIIbX0lmfQ4SwtNY8oiLwmuMvBZoqm565+qZM=; b=MJSm/ehKryiK4KHSbaVd1Bq9pjHb6JwWb4gkXn/IJsRe6yPqfykinE6UE8Koi4DMvf BTz8DtzdBUophSXgxJqKXEL9HiHjM8W25/w4Cv9gznDkiw7d3+So26uM6pvsHgOPr49o j8MrSVf1rAUTWtIH0Ot2cwQcYVxu3pPtDr8jASbgL/cQHsC731RX7adz1bxJCRcqxwjd Kzbug6y3/2StJO5YRBbBIsvpMwTjN6K3ykHkICuV+E2+gZZR9z1AiIIkE9/aBxkT2f80 xJjXOlaHmoqCiTI8PZpoEVjcHvXnCOp03q3+sh+EQ8X1T7+wGTtZLh4nCg5vMOtNnZ3a 9llw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=7BZXdqPIIbX0lmfQ4SwtNY8oiLwmuMvBZoqm565+qZM=; b=SAlKL2kJLXebt7DiVn9I/ogrggrPO9rA7CLcsy1INYHMmPP8rviHL55iNBeEE5YSy1 l+CNIRnNPQl4Yywamj3KZV9FAYD5gztRnmTT1o5qp7fx+HJ1+3T2fJVVCwzhG2DlCAmx xFM7bEA5axXI7e6Rw2izC+heT4XLSM5NL/vPFS7UTL6MDLTdaD5ru5BPrws3M88myEhZ FJtk93g6/8BYuWtF54J9lRrznhXECGQdbL9uTwq93AIU1sJc9PxOnrJd9VBwv7n1Qbrg qI+iOGV4f/4VQpDoC4vmxhewYgP7Kjv8QzdUJ2A8wz83a43etiGlJZiILhBeWLVcIlf4 4JaQ== X-Gm-Message-State: AOAM531ubdNS3rpe6aHu43OgQUubC4p04FJrmSkyjppMnDoyLgYCNAlO ZDDRZu9xchjsDbSq/zPd/92moUYtBZsSn8kD7f4= X-Received: by 2002:a17:90b:1085:: with SMTP id gj5mr10789472pjb.66.1630883988225; Sun, 05 Sep 2021 16:19:48 -0700 (PDT) MIME-Version: 1.0 References: <20210824034929.GA13415@raspberrypi> In-Reply-To: <20210824034929.GA13415@raspberrypi> From: Austin Kim Date: Mon, 6 Sep 2021 08:19:38 +0900 Message-ID: Subject: Re: [PATCH] ext4: remove an unused variable warning with CONFIG_QUOTA=n To: "Theodore Y. Ts'o" , adilger.kernel@dilger.ca Cc: linux-ext4@vger.kernel.org, Linux Kernel Mailing List , =?UTF-8?B?6rmA64+Z7ZiE?= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org 2021=EB=85=84 8=EC=9B=94 24=EC=9D=BC (=ED=99=94) =EC=98=A4=ED=9B=84 12:49, = Austin Kim =EB=8B=98=EC=9D=B4 =EC=9E=91=EC=84=B1: > > The 'enable_quota' variable is only used in an CONFIG_QUOTA. > With CONFIG_QUOTA=3Dn, compiler causes a harmless warning: > > fs/ext4/super.c: In function =E2=80=98ext4_remount=E2=80=99: > fs/ext4/super.c:5840:6: warning: variable =E2=80=98enable_quota=E2=80=99 = set but not used > [-Wunused-but-set-variable] > int enable_quota =3D 0; > ^~~~~ > > Move 'enable_quota' into the same #ifdef CONFIG_QUOTA block > to remove an unused variable warning. > > Signed-off-by: Austin Kim > --- > fs/ext4/super.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/fs/ext4/super.c b/fs/ext4/super.c > index 6b03e4281f6f..6adb570f4b31 100644 > --- a/fs/ext4/super.c > +++ b/fs/ext4/super.c > @@ -5845,10 +5845,10 @@ static int ext4_remount(struct super_block *sb, i= nt *flags, char *data) > struct ext4_sb_info *sbi =3D EXT4_SB(sb); > unsigned long old_sb_flags, vfs_flags; > struct ext4_mount_options old_opts; > - int enable_quota =3D 0; > ext4_group_t g; > int err =3D 0; > #ifdef CONFIG_QUOTA > + int enable_quota =3D 0; > int i, j; > char *to_free[EXT4_MAXQUOTAS]; > #endif > @@ -6053,7 +6053,9 @@ static int ext4_remount(struct super_block *sb, int= *flags, char *data) > err =3D -EROFS; > goto restore_opts; > } > +#ifdef CONFIG_QUOTA > enable_quota =3D 1; > +#endif > } > } > > -- > 2.20.1 > If you are available, would you please review this patch? It will not take long. BR, Austin Kim