From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8501BC43215 for ; Tue, 19 Nov 2019 12:25:06 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 549CC20730 for ; Tue, 19 Nov 2019 12:25:06 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 549CC20730 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.alibaba.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 045B66B026F; Tue, 19 Nov 2019 07:25:06 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id F387F6B0270; Tue, 19 Nov 2019 07:25:05 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id E4E946B0271; Tue, 19 Nov 2019 07:25:05 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0120.hostedemail.com [216.40.44.120]) by kanga.kvack.org (Postfix) with ESMTP id D23C36B026F for ; Tue, 19 Nov 2019 07:25:05 -0500 (EST) Received: from smtpin07.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with SMTP id 9646D8249980 for ; Tue, 19 Nov 2019 12:25:05 +0000 (UTC) X-FDA: 76172946570.07.love65_2c37703b8f750 X-HE-Tag: love65_2c37703b8f750 X-Filterd-Recvd-Size: 2513 Received: from out30-54.freemail.mail.aliyun.com (out30-54.freemail.mail.aliyun.com [115.124.30.54]) by imf37.hostedemail.com (Postfix) with ESMTP for ; Tue, 19 Nov 2019 12:25:03 +0000 (UTC) X-Alimail-AntiSpam:AC=PASS;BC=-1|-1;BR=01201311R141e4;CH=green;DM=||false|;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04394;MF=alex.shi@linux.alibaba.com;NM=1;PH=DS;RN=14;SR=0;TI=SMTPD_---0TiZ7z2i_1574166245; Received: from localhost(mailfrom:alex.shi@linux.alibaba.com fp:SMTPD_---0TiZ7z2i_1574166245) by smtp.aliyun-inc.com(127.0.0.1); Tue, 19 Nov 2019 20:24:05 +0800 From: Alex Shi To: cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, akpm@linux-foundation.org, mgorman@techsingularity.net, tj@kernel.org, hughd@google.com, khlebnikov@yandex-team.ru, daniel.m.jordan@oracle.com, yang.shi@linux.alibaba.com, willy@infradead.org, shakeelb@google.com, hannes@cmpxchg.org Cc: Alex Shi Subject: [PATCH v4 2/9] mm/huge_memory: fix uninitialized compiler warning Date: Tue, 19 Nov 2019 20:23:16 +0800 Message-Id: <1574166203-151975-3-git-send-email-alex.shi@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1574166203-151975-1-git-send-email-alex.shi@linux.alibaba.com> References: <1574166203-151975-1-git-send-email-alex.shi@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: ../mm/huge_memory.c: In function =E2=80=98split_huge_page_to_list=E2=80=99= : ../mm/huge_memory.c:2766:9: warning: =E2=80=98flags=E2=80=99 may be used = uninitialized in this function [-Wmaybe-uninitialized] lruvec =3D lock_page_lruvec_irqsave(head, pgdata, flags); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Signed-off-by: Alex Shi Cc: Andrew Morton Cc: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org --- mm/huge_memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/huge_memory.c b/mm/huge_memory.c index 13cc93785006..4cdfdbeb6b2b 100644 --- a/mm/huge_memory.c +++ b/mm/huge_memory.c @@ -2699,7 +2699,7 @@ int split_huge_page_to_list(struct page *page, stru= ct list_head *list) struct address_space *mapping =3D NULL; int count, mapcount, extra_pins, ret; bool mlocked; - unsigned long flags; + unsigned long flags =3D 0; pgoff_t end; =20 VM_BUG_ON_PAGE(is_huge_zero_page(page), page); --=20 1.8.3.1