Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp6107024pxv; Thu, 29 Jul 2021 06:42:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw3B8pGrYGFLeHsiW+218REA3SnA4BWNbkjjrtYQ68hB1iRbg44r1MIUapf3koLjr1NUKi5 X-Received: by 2002:a92:1813:: with SMTP id 19mr3753477ily.107.1627566140986; Thu, 29 Jul 2021 06:42:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627566140; cv=none; d=google.com; s=arc-20160816; b=EtxYARP/Zib2dnCGK98AQV9HQocaB26ae7Ml+zrEuAtXk0qC9IRWTYLvKh8komLe6I wIME1yC4NlbL7cJTqplQDMbOgZiHL7hoytCeE7coxQ6nZlcRA5xIpL4WJIuUJ8S1O0mK 8u26u9zLblARSVSUyeap4GaVlp0BHjJQabbkSB99dXn/2pHpdAgGoMP/OZxIUkMDy261 ikXhYtQLzhgTGeVQLTpzjeOlknnNzT+eY+VyUYZnkbQBkvIwp7VWtB/VBZL97JPcr1ib rfXXJIrepS4MaoSoQ9sCaiJJ0XkVemlPz1k4IR/iheIAahjtkxWTu3MGe2V/N2YdUB+2 QOdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=eMa0YczQh56TUFbbWyxfwHlTTQoGvHMpB6e+MNq/9K8=; b=inYuzYvrowNRVc38ULsi71GRnXfxLCYDP74dnrOnY6nsH2/BEMCLFSVWMNcxqx4rQM MOv0Y/PTlZ0XjHS4/6BrGL9WnvYikXe16DtLce4Lpz8Z7/fVrxfH4PalOapJCep/d/2A 3700ODAF6yU6GcS9J+QvUrFYgn4zw6l3/6ggTHsbAg8wl+RfVIhwr47g+e4wPPn4oOAL QPzKboU1vpqCN6J6kh+WvlSNU5T2+l7Tpe97LxyrAHqxRVB1HZ6iuZERJLh6uNbXRCFH WDTuEA43l1TDonXLnXkegl8/5pCtz5KgGPIpVfsxn9xyXwLXahfZyC4CaaAvt74ngCpT QeqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=h8kgfYDQ; 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 v13si3667668ilj.65.2021.07.29.06.42.00; Thu, 29 Jul 2021 06:42:20 -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; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=h8kgfYDQ; 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 S237580AbhG2Njy (ORCPT + 99 others); Thu, 29 Jul 2021 09:39:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49036 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237549AbhG2Njx (ORCPT ); Thu, 29 Jul 2021 09:39:53 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ACD06C061765; Thu, 29 Jul 2021 06:39:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=eMa0YczQh56TUFbbWyxfwHlTTQoGvHMpB6e+MNq/9K8=; b=h8kgfYDQp0cFRzhl/YiMK30XSA lVZ+YcItMsqqARcnt2J+RhnPymwOokLRVAoDXRA0M9jE8EDxAdanXojxuRYWNQOfhE0r7Bo8IQsnb AO10KyccKR6Rg+SS3J1I5tMCmWGG+rndlxRvMEmYL+nv5K/GckQRl7/QMgy3PFZoykbA25Kv1TP1Z zubzdQj3sKFAU/4EK3HYkeNxXivYGSP2kIbz0LFp9Vd/es6yxNAIvE+aF43C4Orp4RazGboKjbux7 sjCKJcsCAPrEsbAiQRY9aYOBv2KzpHkObKUN2SwYkwwjPNC2Zx+iuqGRrU4xh5tkuvvNPM/DSarnr pCXwDj6Q==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1m96Fa-00H7Ct-5C; Thu, 29 Jul 2021 13:39:16 +0000 Date: Thu, 29 Jul 2021 14:39:02 +0100 From: Matthew Wilcox To: Mel Gorman Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Christoph Hellwig Subject: Re: [PATCH v14 049/138] mm/memcg: Add folio_lruvec_relock_irq() and folio_lruvec_relock_irqsave() Message-ID: References: <20210715033704.692967-1-willy@infradead.org> <20210715033704.692967-50-willy@infradead.org> <20210729083644.GD3809@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210729083644.GD3809@techsingularity.net> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 29, 2021 at 09:36:44AM +0100, Mel Gorman wrote: > On Thu, Jul 15, 2021 at 04:35:35AM +0100, Matthew Wilcox (Oracle) wrote: > > These are the folio equivalents of relock_page_lruvec_irq() and > > folio_lruvec_relock_irqsave(). Also convert page_matches_lruvec() > > to folio_matches_lruvec(). > > > > Signed-off-by: Matthew Wilcox (Oracle) > > Reviewed-by: Christoph Hellwig > > When build testing what you had in your for-next branch, I got a new > warning for powerpc defconfig > > In file included from ./include/linux/mmzone.h:8, > from ./include/linux/gfp.h:6, > from ./include/linux/mm.h:10, > from mm/swap.c:17: > mm/swap.c: In function 'release_pages': > ./include/linux/spinlock.h:290:3: warning: 'flags' may be used uninitialized in this function [-Wmaybe-uninitialized] > 290 | _raw_spin_unlock_irqrestore(lock, flags); \ > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ > mm/swap.c:906:16: note: 'flags' was declared here > 906 | unsigned long flags; > | ^~~~~ > > I'm fairly sure it's a false positive and the compiler just cannot figure > out that flags are only accessed when lruvec is !NULL and once lruvec is > !NULL, flags are valid Yes, I read it over carefully and I can't see a way in which this can happen. Weird that this change made the compiler unable to figure that out. Pushed out a new for-next with your patch included. Thanks!