From patchwork Tue Mar 30 14:02:24 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miaohe Lin X-Patchwork-Id: 12172649 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=-11.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,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 21067C433DB for ; Tue, 30 Mar 2021 14:03:32 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id C02476044F for ; Tue, 30 Mar 2021 14:03:31 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C02476044F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 57BA76B0080; Tue, 30 Mar 2021 10:03:31 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 552686B0082; Tue, 30 Mar 2021 10:03:31 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 441076B0083; Tue, 30 Mar 2021 10:03:31 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0047.hostedemail.com [216.40.44.47]) by kanga.kvack.org (Postfix) with ESMTP id 2AC336B0080 for ; Tue, 30 Mar 2021 10:03:31 -0400 (EDT) Received: from smtpin34.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id DDAD681ED for ; Tue, 30 Mar 2021 14:03:30 +0000 (UTC) X-FDA: 77976708180.34.0F800CA Received: from szxga05-in.huawei.com (szxga05-in.huawei.com [45.249.212.191]) by imf15.hostedemail.com (Postfix) with ESMTP id 01B30A0003B7 for ; Tue, 30 Mar 2021 14:03:25 +0000 (UTC) Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4F8rgq679xzPmtQ; Tue, 30 Mar 2021 22:00:39 +0800 (CST) Received: from huawei.com (10.175.104.175) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.498.0; Tue, 30 Mar 2021 22:03:07 +0800 From: Miaohe Lin To: , CC: , , Subject: [PATCH 0/4] Cleanup and fixup for ksm Date: Tue, 30 Mar 2021 10:02:24 -0400 Message-ID: <20210330140228.45635-1-linmiaohe@huawei.com> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 X-Originating-IP: [10.175.104.175] X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: 01B30A0003B7 X-Stat-Signature: otr9cda5snq418ryequtjf4shx8rigcb X-Rspamd-Server: rspam02 Received-SPF: none (huawei.com>: No applicable sender policy available) receiver=imf15; identity=mailfrom; envelope-from=""; helo=szxga05-in.huawei.com; client-ip=45.249.212.191 X-HE-DKIM-Result: none/none X-HE-Tag: 1617113005-486872 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: Hi all, This series contains cleanups to remove unnecessary VM_BUG_ON_PAGE and dedicated macro KSM_FLAG_MASK. Also this fixes potential missing rmap_item for stable_node which would result in failed rmap_walk_ksm(). More details can be found in the respective changelogs. Thanks! Miaohe Lin (4): ksm: remove redundant VM_BUG_ON_PAGE() on stable_tree_search() ksm: use GET_KSM_PAGE_NOLOCK to get ksm page in remove_rmap_item_from_tree() ksm: remove dedicated macro KSM_FLAG_MASK ksm: fix potential missing rmap_item for stable_node mm/ksm.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-)