Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp230823pxk; Thu, 17 Sep 2020 01:10:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwaRpaV+3qpbsGKoYWLiNS/LCCJYacw5ahHugdu/pQiCqBam50L8pyk/Er0ldNwoFs+M6Ai X-Received: by 2002:a17:906:eb11:: with SMTP id mb17mr28910091ejb.255.1600330219183; Thu, 17 Sep 2020 01:10:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600330219; cv=none; d=google.com; s=arc-20160816; b=BFL4hMzhj7teENjNTmZQi2PqFsCnL4Fb8/9ceJUMYV2utnOTD9t1QmF8TYaAChPF5y UIN4AjcZqymExSvhF2d4v8QdRS6imG6f6AZBpsf4wnWw/iOvFleQRfF30EwHsOnZoETK BM/NEH/URNYuBrsvtxKOaBdGgEmnQBKFIdZMccwXfVRcFUVXc+bmv9rzyoU1JoT4AiQK dtay7URYSrxSd220lyqy5pbSnXYpbp8sb66fsw/7YbQX6nDmlxqPxDZ9YLlhgdNAzDEz 9yhnQMVMV7qejejNO08zcqnPLWAJeDXvQ3vLpDrTfvlI55ZmSMvObDarnPkrEAYFWcFE fkFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=u0rzkgkVJ7Dtdo7S5xlPftF7zHtcZ9pTqx7qZ+Fat7g=; b=pQX21phhb837TlMxfQvq1QPnpgGXEjyaBmMwfpl7RGgREi5ujuHDijSuEIfz5dB1hA R7GKl2jGtAcm439ggR794ihPFXh+zoETpfGiStWWHZ8gfdnYZTMGCGnvObrFULeqlBtk z0l7v8+jN/NAObVAjkMlQCGL+cI78eOwqOBjlfHnHTr3sIU/N3YWzhBzVtuA1YwbXiXb an/rexb/RHVeGq9vvX23t8j+xq74S4nkTqZL1URnD82/k2oU8F4K0gk1TRRvfXSREn+l PmjMRi6GZQFlgMGavI/yRetMT8a6C8Us2E53gdET+HyLhyz6bh5fjE8yYQu04Gbi0DRi BNhQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c15si9985458ejk.111.2020.09.17.01.09.55; Thu, 17 Sep 2020 01:10:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726514AbgIQIID (ORCPT + 99 others); Thu, 17 Sep 2020 04:08:03 -0400 Received: from mx2.suse.de ([195.135.220.15]:33874 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726502AbgIQIH6 (ORCPT ); Thu, 17 Sep 2020 04:07:58 -0400 X-Greylist: delayed 823 seconds by postgrey-1.27 at vger.kernel.org; Thu, 17 Sep 2020 04:07:58 EDT X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id E01A8B1AA; Thu, 17 Sep 2020 07:54:15 +0000 (UTC) Date: Thu, 17 Sep 2020 09:53:58 +0200 From: Oscar Salvador To: Liu Shixin Cc: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH -next] mm/madvise: Remove set but not used variable 'zone' Message-ID: <20200917075354.GA27201@linux> References: <20200917071757.1915501-1-liushixin2@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200917071757.1915501-1-liushixin2@huawei.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 17, 2020 at 03:17:57PM +0800, Liu Shixin wrote: > Fixes gcc '-Wunused-but-set-variable' warning: > > mm/madvise.c: In function 'madvise_inject_error': > mm/madvise.c:882:15: warning: unused variable 'zone' [-Wunused-variable] > > After 4b63fdbe2b25 ("mm: remove the now-unnecessary mmget_still_valid() > hack"), variable 'zone' is never used. Remove it to avoid build warning. Hi Liu, Andrew already fixed that in the mmotm tree. Thanks anyway > > Signed-off-by: Liu Shixin > --- > mm/madvise.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/mm/madvise.c b/mm/madvise.c > index 460e19d60ba3..94b9d17331b9 100644 > --- a/mm/madvise.c > +++ b/mm/madvise.c > @@ -879,7 +879,6 @@ static long madvise_remove(struct vm_area_struct *vma, > static int madvise_inject_error(int behavior, > unsigned long start, unsigned long end) > { > - struct zone *zone; > unsigned long size; > > if (!capable(CAP_SYS_ADMIN)) > -- > 2.25.1 > > -- Oscar Salvador SUSE L3