From patchwork Sat Mar 13 07:57:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yu Zhao X-Patchwork-Id: 12136571 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=-26.3 required=3.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT,USER_IN_DEF_DKIM_WL 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 8CDE3C433E0 for ; Sat, 13 Mar 2021 07:58:03 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 3751C64F1E for ; Sat, 13 Mar 2021 07:58:03 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3751C64F1E Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 25EF86B0070; Sat, 13 Mar 2021 02:58:02 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 238F76B0071; Sat, 13 Mar 2021 02:58:02 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 017D66B0072; Sat, 13 Mar 2021 02:58:01 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0124.hostedemail.com [216.40.44.124]) by kanga.kvack.org (Postfix) with ESMTP id DC9326B0070 for ; Sat, 13 Mar 2021 02:58:01 -0500 (EST) Received: from smtpin13.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 94E23824805A for ; Sat, 13 Mar 2021 07:58:01 +0000 (UTC) X-FDA: 77914097562.13.8CBB174 Received: from mail-qk1-f202.google.com (mail-qk1-f202.google.com [209.85.222.202]) by imf17.hostedemail.com (Postfix) with ESMTP id 16DE3400805D for ; Sat, 13 Mar 2021 07:57:59 +0000 (UTC) Received: by mail-qk1-f202.google.com with SMTP id k68so19900295qke.2 for ; Fri, 12 Mar 2021 23:58:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:in-reply-to:message-id:mime-version:references:subject:from:to :cc; bh=BUGHWaLOgbBXMks9MxevCFPE+HJdHu8WtN3Ad5BKa2E=; b=EmtSmNZcxIc0Qq98PvQLlh/Je74+I9pGiId+AoSzt2WN66X/7gqva2AkM1Z6ZrqWlC qMCo9fu+KgWIl13K9lL0hfZkSMTr33It30mFN/3/xwUcpWXiUy2ttup7BflThw89akrm ipCdNg7GP9J1lKGO0+Ae8TZbHboXPO6EU2DcK5O1kt2ZE3NOFthikv0X6/opyUBdeUKR Q3HhM/pgOA+vQ4UMR7hzNtEDZcmVDtrPgTwq9zDoYDV/KHqaCvxRPvrkCfwY3MbDN9Yc Dm0TaDfpoFKrj/syFqJ/83hwIk0G3OPLs6DbY/I2HkHJ6cbjakxVLFDyXybDitO9MyGA /tow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=BUGHWaLOgbBXMks9MxevCFPE+HJdHu8WtN3Ad5BKa2E=; b=TNZXVYmBp3YCqO85h0QmgHBnUL7rHJoHUKynFHGUnyyGdJYr+T29Cst9T2ROfQSvrn 2NmHz1yJDsI6W6eKav6hK/v6USInGbia3DLKkk+7goD09dEUuAGwhfIKRpxUJMfgNiCc Cvk6q9Mhv1URE5uL7qIAL6f9+NKSHaE5E0tZnmc62QBJdxKv/UgJPXpVR0J6PMjqmH+o vxWV23L5UdjodcHVSwstfXPtOeyZCbmuorfPIPesRSshkB6G0REkVvx6L+RpA93TLfhu B6WjPQjM8LFgU8Tg0uBP8Cozjiz2stfuVQgJVJEOGsmpvhcCTjGe54FYD5cDmlwdTNQV 7YNw== X-Gm-Message-State: AOAM530bUnHNwvzpcdss8RrT1s7PGpFiIJZTPcw3PSZ9+VfUoJqsMiag s89IT4vZYbzeYqetV6FmsOb/rx9ZOE6gskPwpIvVQsH57WIz73/wA7r+GnhA8iIZQO14/EewiqC YIx0FncbawELwNx2LMtzhFewF7AN9wWiYLMjf6TObgcuVMHcDvQdHCEM6 X-Google-Smtp-Source: ABdhPJzJJ1SnzBtj3bVJq+tnpS8mvob3Iwgd7McsgFl/pDIRa/R9w7/nQuY0bxlcdhV2mXDJvzzuC77PvVA= X-Received: from yuzhao.bld.corp.google.com ([2620:15c:183:200:f931:d3e4:faa0:4f74]) (user=yuzhao job=sendgmr) by 2002:a05:6214:4b3:: with SMTP id w19mr1750690qvz.26.1615622280155; Fri, 12 Mar 2021 23:58:00 -0800 (PST) Date: Sat, 13 Mar 2021 00:57:36 -0700 In-Reply-To: <20210313075747.3781593-1-yuzhao@google.com> Message-Id: <20210313075747.3781593-4-yuzhao@google.com> Mime-Version: 1.0 References: <20210313075747.3781593-1-yuzhao@google.com> X-Mailer: git-send-email 2.31.0.rc2.261.g7f71774620-goog Subject: [PATCH v1 03/14] include/linux/huge_mm.h: define is_huge_zero_pmd() if !CONFIG_TRANSPARENT_HUGEPAGE From: Yu Zhao To: linux-mm@kvack.org Cc: Alex Shi , Andrew Morton , Dave Hansen , Hillf Danton , Johannes Weiner , Joonsoo Kim , Matthew Wilcox , Mel Gorman , Michal Hocko , Roman Gushchin , Vlastimil Babka , Wei Yang , Yang Shi , Ying Huang , linux-kernel@vger.kernel.org, page-reclaim@google.com, Yu Zhao X-Stat-Signature: joc6fzug3wrwkmiufsu8xf4edkn5ycnz X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 16DE3400805D Received-SPF: none (flex--yuzhao.bounces.google.com>: No applicable sender policy available) receiver=imf17; identity=mailfrom; envelope-from="<3iHBMYAYKCKMbXcKDRJRRJOH.FRPOLQXa-PPNYDFN.RUJ@flex--yuzhao.bounces.google.com>"; helo=mail-qk1-f202.google.com; client-ip=209.85.222.202 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1615622279-813684 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: Currently is_huge_zero_pmd() only exists when CONFIG_TRANSPARENT_HUGEPAGE=y. This patch defines the function for the !CONFIG_TRANSPARENT_HUGEPAGE case. Signed-off-by: Yu Zhao --- include/linux/huge_mm.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/linux/huge_mm.h b/include/linux/huge_mm.h index ba973efcd369..0ba7b3f9029c 100644 --- a/include/linux/huge_mm.h +++ b/include/linux/huge_mm.h @@ -443,6 +443,11 @@ static inline bool is_huge_zero_page(struct page *page) return false; } +static inline bool is_huge_zero_pmd(pmd_t pmd) +{ + return false; +} + static inline bool is_huge_zero_pud(pud_t pud) { return false;