From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arnd Bergmann Subject: Re: linux-next: build warning after merge of the akpm tree Date: Tue, 1 Aug 2017 23:15:48 +0200 Message-ID: References: <20170801160257.0b1306b2@canb.auug.org.au> <87bmnzizjy.fsf@yhuang-dev.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: Received: from mail-oi0-f45.google.com ([209.85.218.45]:35856 "EHLO mail-oi0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751912AbdHAVPt (ORCPT ); Tue, 1 Aug 2017 17:15:49 -0400 In-Reply-To: <87bmnzizjy.fsf@yhuang-dev.intel.com> Sender: linux-next-owner@vger.kernel.org List-ID: To: "Huang, Ying" Cc: Stephen Rothwell , Andrew Morton , Linux-Next Mailing List , Linux Kernel Mailing List On Tue, Aug 1, 2017 at 8:15 AM, Huang, Ying wrote: > From 7a7ff76d7bcbd7affda169b29abcf3dafa38052e Mon Sep 17 00:00:00 2001 > From: Huang Ying > Date: Tue, 1 Aug 2017 14:12:21 +0800 > Subject: [PATCH] mm, THP, swap: Silence a compiler warning > > To fix the following compiler warning, > > mm/swapfile.c: In function 'reuse_swap_page': > mm/swapfile.c:1429:16: warning: 'offset' may be used uninitialized in this function [-Wmaybe-uninitialized] > unsigned long offset; > ^ > > This is a false positive report, but we should silence it anyway. Looks ok, I ran into this too, and came to the same conclusion. I normally try to find a way to reorganize the code without adding a bogus initialization, but here I could not find come up with anything better than what you did. Arnd