Message ID | 20230327034149.942-1-thunder.leizhen@huawei.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1268205vqo; Sun, 26 Mar 2023 21:35:33 -0700 (PDT) X-Google-Smtp-Source: AKy350YTt89e1FvX4syYpi93pJM4+PCD2OepUuCVQC8Dpx/4ykxNucK23l1eA3xfLwW6yxQxZG5D X-Received: by 2002:a62:7904:0:b0:5df:9809:2e95 with SMTP id u4-20020a627904000000b005df98092e95mr11080899pfc.11.1679891732916; Sun, 26 Mar 2023 21:35:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679891732; cv=none; d=google.com; s=arc-20160816; b=VKjIM/bwRRkc7cR4pyxrgdxLBnJu8QB8cz0HrwhRRKeGJVX0oDnAo4fSu2b/f7xJ2v Z7L2MJLEs+36abMooSNXtU3BaMlifTWPSvkEQgiElzeCxfktTFZXkLh3ZjkqRIj7yALI iM5jzlH3znDc+KJMGf21oLVYvHh5PTd7ocNKUiX8YIutgrs8pYEEiKqLW5P4Ko3OGgJ2 7HHzxa8waOv2Iq2Qyb8Ppd0RQWJWYndw4SveA+Wt4uZkqqNVuR2TvfHHz24rdcLOo8r+ YjzIsKWTonNp2rnmaUdWiB+r3nOcdHDvHpLrtls+k4A8r7buTjJPIAKm730p200LtVZ7 HOJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=hHtIkdZcgKJHiusW3p25nmgnoJpfPHJgOBjS5cAzEEc=; b=h9AU0KW74dBTnT1wgiUB8W8zXyJvoAUjuzQMiL1r6IDYZFbLeElOekKXhJakDWHbRO 9kNSiqvfRLZTqK7kRg7kIP9L1uVT7iqiLAeH8h6nBfdUymRksTabcXXckDSgHka3k4RK 1b0gV++D5tSMS0HMsc8nUpA8GOmfOv6XpRn0xq+DbteqqI95KlYc2TQPMjOWuNQl/TwO YkCo9Fr9nJepbe7MdVXV6e6G4ZWfOStOdpcxErvioGj9OEfBp1kGkER968KxC0a9vl9X FwRrFAOxp8XbW/sMZsu7QStMw2IXrG/vZclORD2I7pOtEQ0U/HnU5CWmuhw2uwpKW3y9 JYQQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f189-20020a6238c6000000b00627dd2b5307si9902083pfa.102.2023.03.26.21.35.20; Sun, 26 Mar 2023 21:35:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232043AbjC0DqA (ORCPT <rfc822;makky5685@gmail.com> + 99 others); Sun, 26 Mar 2023 23:46:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49462 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229577AbjC0Dp6 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Sun, 26 Mar 2023 23:45:58 -0400 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 559D93C31 for <linux-kernel@vger.kernel.org>; Sun, 26 Mar 2023 20:45:56 -0700 (PDT) Received: from dggpemm500006.china.huawei.com (unknown [172.30.72.55]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4PlJby6q14zL66b; Mon, 27 Mar 2023 11:45:02 +0800 (CST) Received: from thunder-town.china.huawei.com (10.174.178.55) by dggpemm500006.china.huawei.com (7.185.36.236) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Mon, 27 Mar 2023 11:45:29 +0800 From: Zhen Lei <thunder.leizhen@huawei.com> To: Alexander Potapenko <glider@google.com>, Marco Elver <elver@google.com>, Dmitry Vyukov <dvyukov@google.com>, Andrew Morton <akpm@linux-foundation.org>, <kasan-dev@googlegroups.com>, <linux-mm@kvack.org>, <linux-kernel@vger.kernel.org> CC: Zhen Lei <thunder.leizhen@huawei.com> Subject: [PATCH] kmsan: fix a stale comment in kmsan_save_stack_with_flags() Date: Mon, 27 Mar 2023 11:41:49 +0800 Message-ID: <20230327034149.942-1-thunder.leizhen@huawei.com> X-Mailer: git-send-email 2.37.3.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.174.178.55] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To dggpemm500006.china.huawei.com (7.185.36.236) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1761494153361286545?= X-GMAIL-MSGID: =?utf-8?q?1761494153361286545?= |
Series |
kmsan: fix a stale comment in kmsan_save_stack_with_flags()
|
|
Commit Message
Zhen Lei
March 27, 2023, 3:41 a.m. UTC
After commit 446ec83805dd ("mm/page_alloc: use might_alloc()") and
commit 84172f4bb752 ("mm/page_alloc: combine __alloc_pages and
__alloc_pages_nodemask"), the comment is no longer accurate.
Flag '__GFP_DIRECT_RECLAIM' is clear enough on its own, so remove the
comment rather than update it.
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
---
mm/kmsan/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On Mon, Mar 27, 2023 at 5:45 AM Zhen Lei <thunder.leizhen@huawei.com> wrote: > > After commit 446ec83805dd ("mm/page_alloc: use might_alloc()") and > commit 84172f4bb752 ("mm/page_alloc: combine __alloc_pages and > __alloc_pages_nodemask"), the comment is no longer accurate. > Flag '__GFP_DIRECT_RECLAIM' is clear enough on its own, so remove the > comment rather than update it. > > Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com> Reviewed-by: Alexander Potapenko <glider@google.com> > > nr_entries = stack_trace_save(entries, KMSAN_STACK_DEPTH, 0); > > - /* Don't sleep (see might_sleep_if() in __alloc_pages_nodemask()). */ > + /* Don't sleep. */ Thanks for spotting this!
diff --git a/mm/kmsan/core.c b/mm/kmsan/core.c index f710257d68670ee..7d1e4aa30bae622 100644 --- a/mm/kmsan/core.c +++ b/mm/kmsan/core.c @@ -73,7 +73,7 @@ depot_stack_handle_t kmsan_save_stack_with_flags(gfp_t flags, nr_entries = stack_trace_save(entries, KMSAN_STACK_DEPTH, 0); - /* Don't sleep (see might_sleep_if() in __alloc_pages_nodemask()). */ + /* Don't sleep. */ flags &= ~__GFP_DIRECT_RECLAIM; handle = __stack_depot_save(entries, nr_entries, flags, true);