Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp8114002imu; Tue, 4 Dec 2018 03:14:28 -0800 (PST) X-Google-Smtp-Source: AFSGD/WB8VwQ8taLn6BPo4aIa91mlOmbUPMwtDxq8tyGLzjULnSBPybwTtoMk6IXuY/wSpsjBMQR X-Received: by 2002:a62:5884:: with SMTP id m126mr19557243pfb.177.1543922068927; Tue, 04 Dec 2018 03:14:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543922068; cv=none; d=google.com; s=arc-20160816; b=vdEuiqNN9g0r1x4DhWcxlsPFQdAFPoWb3GaKet+x8cxU9XigzfuQJ4KGRL1AdSEKJ7 5Az8OUjg2bk5wh+PtlLYyLXRkEhGyENA2HGUci3JjPIAifZwFnrxYduGE7T9khlaB/ct psbi2B+FdNOQ3ScwgMJD0HrjP9SxVPM2JdUGGSgPj3h+Lt97RDaYQgU37z5QCFg8FA/e Su2iN7MvHVe/DP3e3dBFMw/lKDabL/jCmKICom9eKw8YIPXuR03ftXt7tlVdEBdDfHUy agumwipBL4Zm1LkwLDIv60R9sRH1vfpgjKiPrx6GtaKbx8GKJOtL/uDfdEl/EFwiO9sW sD6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=B3QKU57vZFj5pOvv1iv8OYLjo70I5knBveCzCSR0REk=; b=r7kxMjpHNLbeYPuYmB7pI7eBPV6oa9Zjcym3fZ2dRtYJ9DbrHlRgBVeatpQGOpuuX+ whQ7ktaXZ/Dyu2ItulJKFVnhm1iv+V0sIadyzCQx2Yrh98H9duQPDTWdO7YVDPIzh1Fs Sg5fbOcvOCyzQf7ee/Z0+i4LJGGGfh2KhTa00MO7rGsmc2l6WqVFhvNsjEgQedKQM7FM 73rVlptO0qqBcV836XaW5AlCTgN2oZ8NWVDWZ1ZTa81YCYuMtEnRmgrLYP2ZtGO+HYCX scm5NGL6HABuc1jv2KIM95BtY21hJUI6TqPU6LKk8Wencok7okp+clC6zrMpS0OiQDfp Yh/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=fGYRABpy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x16si15199188pga.407.2018.12.04.03.14.14; Tue, 04 Dec 2018 03:14:28 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=fGYRABpy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728219AbeLDLN1 (ORCPT + 99 others); Tue, 4 Dec 2018 06:13:27 -0500 Received: from mail.kernel.org ([198.145.29.99]:56714 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727075AbeLDLHf (ORCPT ); Tue, 4 Dec 2018 06:07:35 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5700E2082D; Tue, 4 Dec 2018 11:07:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1543921655; bh=DkxVrxYuyzZnZetkH00MMsg8jbXaBo5o8+mKvl3mPWA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=fGYRABpyuZ+Hc2l856LRi6IIBBuKSc7jIJKLB0zRpcKbZy0kHR+MFpICJxl4zqRIN ZdrqaSktFlKeJhDjKUu69BQP8rKzM7DZe6ZpIWjtun8opi+aCOfQUeIPKEdUrEGy27 LYA81IcqU4zY7N8dOMr6Lf0mQQuo4ZKeFFryhLTc= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hugh Dickins , "Kirill A. Shutemov" , Jerome Glisse , Konstantin Khlebnikov , Matthew Wilcox , Andrew Morton , Linus Torvalds , Sasha Levin Subject: [PATCH 4.9 01/50] mm/huge_memory: rename freeze_page() to unmap_page() Date: Tue, 4 Dec 2018 11:49:56 +0100 Message-Id: <20181204103714.548141343@linuxfoundation.org> X-Mailer: git-send-email 2.19.2 In-Reply-To: <20181204103714.485546262@linuxfoundation.org> References: <20181204103714.485546262@linuxfoundation.org> User-Agent: quilt/0.65 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ commit 906f9cdfc2a0800f13683f9e4ebdfd08c12ee81b upstream. The term "freeze" is used in several ways in the kernel, and in mm it has the particular meaning of forcing page refcount temporarily to 0. freeze_page() is just too confusing a name for a function that unmaps a page: rename it unmap_page(), and rename unfreeze_page() remap_page(). Went to change the mention of freeze_page() added later in mm/rmap.c, but found it to be incorrect: ordinary page reclaim reaches there too; but the substance of the comment still seems correct, so edit it down. Link: http://lkml.kernel.org/r/alpine.LSU.2.11.1811261514080.2275@eggly.anvils Fixes: e9b61f19858a5 ("thp: reintroduce split_huge_page()") Signed-off-by: Hugh Dickins Acked-by: Kirill A. Shutemov Cc: Jerome Glisse Cc: Konstantin Khlebnikov Cc: Matthew Wilcox Cc: [4.8+] Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Sasha Levin --- mm/huge_memory.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/mm/huge_memory.c b/mm/huge_memory.c index 9f7bba700e4e..583ad61cc2f1 100644 --- a/mm/huge_memory.c +++ b/mm/huge_memory.c @@ -1839,7 +1839,7 @@ void vma_adjust_trans_huge(struct vm_area_struct *vma, } } -static void freeze_page(struct page *page) +static void unmap_page(struct page *page) { enum ttu_flags ttu_flags = TTU_IGNORE_MLOCK | TTU_IGNORE_ACCESS | TTU_RMAP_LOCKED; @@ -1862,7 +1862,7 @@ static void freeze_page(struct page *page) VM_BUG_ON_PAGE(ret, page + i - 1); } -static void unfreeze_page(struct page *page) +static void remap_page(struct page *page) { int i; @@ -1971,7 +1971,7 @@ static void __split_huge_page(struct page *page, struct list_head *list, spin_unlock_irqrestore(zone_lru_lock(page_zone(head)), flags); - unfreeze_page(head); + remap_page(head); for (i = 0; i < HPAGE_PMD_NR; i++) { struct page *subpage = head + i; @@ -2138,7 +2138,7 @@ int split_huge_page_to_list(struct page *page, struct list_head *list) } /* - * Racy check if we can split the page, before freeze_page() will + * Racy check if we can split the page, before unmap_page() will * split PMDs */ if (total_mapcount(head) != page_count(head) - extra_pins - 1) { @@ -2147,7 +2147,7 @@ int split_huge_page_to_list(struct page *page, struct list_head *list) } mlocked = PageMlocked(page); - freeze_page(head); + unmap_page(head); VM_BUG_ON_PAGE(compound_mapcount(head), head); /* Make sure the page is not on per-CPU pagevec as it takes pin */ @@ -2199,7 +2199,7 @@ int split_huge_page_to_list(struct page *page, struct list_head *list) fail: if (mapping) spin_unlock(&mapping->tree_lock); spin_unlock_irqrestore(zone_lru_lock(page_zone(head)), flags); - unfreeze_page(head); + remap_page(head); ret = -EBUSY; } -- 2.17.1