From patchwork Tue Jun 19 06:05:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Williams X-Patchwork-Id: 10473335 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id DF6A660383 for ; Tue, 19 Jun 2018 06:15:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DFFE228C14 for ; Tue, 19 Jun 2018 06:15:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D4E2428C2B; Tue, 19 Jun 2018 06:15:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6C75F28C14 for ; Tue, 19 Jun 2018 06:15:21 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 0DD956B0266; Tue, 19 Jun 2018 02:15:20 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 08B376B0269; Tue, 19 Jun 2018 02:15:19 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id E6E6A6B026A; Tue, 19 Jun 2018 02:15:19 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-pf0-f200.google.com (mail-pf0-f200.google.com [209.85.192.200]) by kanga.kvack.org (Postfix) with ESMTP id A48106B0266 for ; Tue, 19 Jun 2018 02:15:19 -0400 (EDT) Received: by mail-pf0-f200.google.com with SMTP id a12-v6so9715603pfn.12 for ; Mon, 18 Jun 2018 23:15:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-original-authentication-results:x-gm-message-state:subject:from :to:cc:date:message-id:in-reply-to:references:user-agent :mime-version:content-transfer-encoding; bh=oooovwzV4zz/taxcfu+sK4FapwTPtZhk/y9HjhI9AGs=; b=J4BhlUHqwd4oAk8GC7OmD6ATPbEjni9iizdGtB1+5T4Rdjlwqg1k49JytZNXbGamDa HMRzOHIuGa6d1IZcl9IPlEWhsLmneURVz9tW9ykJArBYmj4kd0BrjMMm4Y5ryc9KKRcN BJGMgTHsmnEgObbivZi0ZwZUpDwmTrsXy4ahQyQVkvviCSzu+R9NoID7GWgG4oOT0coU wo1UXVenDTsmDABv4hdIruTNcJG5QHsuwjTUe2OVauAQDatZInWBb1AkxLqcmE1rWx3Y uXWBJBZF8tBNWtSpf6JmawRZWh5XHodRlkoLYWIew5f3Bk7UXVxabEImuiU6t8bTiHjf EZ/A== X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of dan.j.williams@intel.com designates 134.134.136.65 as permitted sender) smtp.mailfrom=dan.j.williams@intel.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com X-Gm-Message-State: APt69E19UhTQOkKOshK10WaHj4aTcckcpxqxRPd4pxytWCM86kmctQyn H/xCmw6MAhxN9fSwPo6vy/HHVgwTIQmtBgeAaATWd5m3eK0coOBHwiYoErTS6YzChpcIMqMs8PB KkO2qTCurUOCl+HSolKPWBb0rsiWMtkoERJL5s+uQ42S+8/lMAXFCa8i1A4SxC3Mj6w== X-Received: by 2002:a17:902:9b92:: with SMTP id y18-v6mr17027944plp.57.1529388919375; Mon, 18 Jun 2018 23:15:19 -0700 (PDT) X-Google-Smtp-Source: ADUXVKITD/y6xdIakS3D82jsQ44KegVKlfzAGsJqeTkhmv2cucjP6dVvtDP0npS9NxT17ir0/EX+ X-Received: by 2002:a17:902:9b92:: with SMTP id y18-v6mr17027905plp.57.1529388918723; Mon, 18 Jun 2018 23:15:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529388918; cv=none; d=google.com; s=arc-20160816; b=I9l/KG+GabRORa/9hXpagZiTdEd2ki7P+UY1qrLOEiw2GGvX0mno4v2Z7fvKXjSUHP o3XRBcWiCxLFJEOkxbczUt2ei9pB38c5BlLJCJ9x0Ibzb37M2lCRouGjOOBg1yx4lW0C MoMgsVXwXaBq21mU9+7i7FrItsqWN96Q0Sm0aNROzwr0m5ZAzkZeanoENFL2HGNShsmh qKP7DN109NDh1Wl1oTD6bOBM2dMthKk6HAT6D5dC8v1CJoPp4zkezoFCK/VOC2riB+dB ASogbS4n2MFz76QEPVVHjfgK+RkuFSVfzw8uizyfiIdaQ8IbGfHJXYW+1vaK9hOCxLZ4 sjvA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:user-agent:references :in-reply-to:message-id:date:cc:to:from:subject :arc-authentication-results; bh=oooovwzV4zz/taxcfu+sK4FapwTPtZhk/y9HjhI9AGs=; b=qxb+BwAChccPLbeefRpCHvVUcvL3YPa4BzZuIF55x5WsENcEq7ym4WmqedP27oRO0L RoYwTTBVKYty96SaAwKw+LbBzuQdG+elmIhdubfNVuDwTWSC3adisSINhiN+4GT2y7xf eaf3802OzEbKPbiLPUMftpPUEv6lBX9Op5j/4u63FA+oocIwtgWbq98QA/V1bvH1r7Lh UJJpw6Lg1TwadA64x97JZCnATLlJkmD9pKw/f9wQYBRa6QDWEn+9XKwAFJh5M4UY+O+5 p3BvIX2wqmjxMGaGVkC2P010yk5ocv706YNZgF3Nk8Ch2IVagfI9I/1bEN6dJphx3zkx 9Bbg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of dan.j.williams@intel.com designates 134.134.136.65 as permitted sender) smtp.mailfrom=dan.j.williams@intel.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from mga03.intel.com (mga03.intel.com. [134.134.136.65]) by mx.google.com with ESMTPS id z14-v6si13744202pgr.62.2018.06.18.23.15.18 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 18 Jun 2018 23:15:18 -0700 (PDT) Received-SPF: pass (google.com: domain of dan.j.williams@intel.com designates 134.134.136.65 as permitted sender) client-ip=134.134.136.65; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dan.j.williams@intel.com designates 134.134.136.65 as permitted sender) smtp.mailfrom=dan.j.williams@intel.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 18 Jun 2018 23:15:18 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,242,1526367600"; d="scan'208";a="50079006" Received: from dwillia2-desk3.jf.intel.com (HELO dwillia2-desk3.amr.corp.intel.com) ([10.54.39.16]) by orsmga007.jf.intel.com with ESMTP; 18 Jun 2018 23:15:17 -0700 Subject: [PATCH v3 8/8] mm: Fix exports that inadvertently make put_page() EXPORT_SYMBOL_GPL From: Dan Williams To: akpm@linux-foundation.org Cc: Joe Gorse , John Hubbard , hch@lst.de, linux-mm@kvack.org, linux-kernel@vger.kernel.org Date: Mon, 18 Jun 2018 23:05:20 -0700 Message-ID: <152938832086.17797.4538943238207602944.stgit@dwillia2-desk3.amr.corp.intel.com> In-Reply-To: <152938827880.17797.439879736804291936.stgit@dwillia2-desk3.amr.corp.intel.com> References: <152938827880.17797.439879736804291936.stgit@dwillia2-desk3.amr.corp.intel.com> User-Agent: StGit/0.18-2-gc94f MIME-Version: 1.0 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: X-Virus-Scanned: ClamAV using ClamSMTP Now that all producers of dev_pagemap instances in the kernel are properly converted to EXPORT_SYMBOL_GPL, fix up implicit consumers that interact with dev_pagemap owners via put_page(). To reiterate, dev_pagemap producers are EXPORT_SYMBOL_GPL because they adopt and modify core memory management interfaces such that the dev_pagemap owner can interact with all other kernel infrastructure and sub-systems (drivers, filesystems, etc...) that consume page structures. Fixes: e76384884344 ("mm: introduce MEMORY_DEVICE_FS_DAX and CONFIG_DEV_PAGEMAP_OPS") Reported-by: Joe Gorse Reported-by: John Hubbard Signed-off-by: Dan Williams --- kernel/memremap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/memremap.c b/kernel/memremap.c index 16141b608b63..ecee37b44aa1 100644 --- a/kernel/memremap.c +++ b/kernel/memremap.c @@ -330,7 +330,7 @@ EXPORT_SYMBOL_GPL(get_dev_pagemap); #ifdef CONFIG_DEV_PAGEMAP_OPS DEFINE_STATIC_KEY_FALSE(devmap_managed_key); -EXPORT_SYMBOL_GPL(devmap_managed_key); +EXPORT_SYMBOL(devmap_managed_key); static atomic_t devmap_enable; /* @@ -371,5 +371,5 @@ void __put_devmap_managed_page(struct page *page) } else if (!count) __put_page(page); } -EXPORT_SYMBOL_GPL(__put_devmap_managed_page); +EXPORT_SYMBOL(__put_devmap_managed_page); #endif /* CONFIG_DEV_PAGEMAP_OPS */