From patchwork Thu Feb 9 16:39:17 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 9565111 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 8D8C96020C for ; Thu, 9 Feb 2017 16:40:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7BF572857C for ; Thu, 9 Feb 2017 16:40:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 70BFD2857F; Thu, 9 Feb 2017 16:40:54 +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=-1.9 required=2.0 tests=BAYES_00 autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 139A92857C for ; Thu, 9 Feb 2017 16:40:54 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cbrm5-0006NQ-Lu; Thu, 09 Feb 2017 16:40:49 +0000 Received: from mail.free-electrons.com ([62.4.15.54]) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cbrlB-0004P8-D3 for linux-arm-kernel@lists.infradead.org; Thu, 09 Feb 2017 16:39:59 +0000 Received: by mail.free-electrons.com (Postfix, from userid 110) id 1E03F20C2B; Thu, 9 Feb 2017 17:39:32 +0100 (CET) Received: from localhost (LFbn-1-2281-83.w90-76.abo.wanadoo.fr [90.76.98.83]) by mail.free-electrons.com (Postfix) with ESMTPSA id E901B20B77; Thu, 9 Feb 2017 17:39:31 +0100 (CET) From: Maxime Ripard To: Rob Herring , Mark Rutland , Chen-Yu Tsai , Maxime Ripard , Greg Kroah-Hartman Subject: [PATCH 3/8] mm: cma: Export a few symbols Date: Thu, 9 Feb 2017 17:39:17 +0100 Message-Id: <2dee6c0baaf08e2c7d48ceb7e97e511c914d0f87.1486655917.git-series.maxime.ripard@free-electrons.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: References: In-Reply-To: References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170209_083953_691883_7C975B82 X-CRM114-Status: GOOD ( 10.42 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Petazzoni , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Modules might want to check their CMA pool size and address for debugging and / or have additional checks. The obvious way to do this would be through dev_get_cma_area and cma_get_base and cma_get_size, that are currently not exported, which results in a build failure. Export them to prevent such a failure. Signed-off-by: Maxime Ripard --- drivers/base/dma-contiguous.c | 1 + mm/cma.c | 2 ++ 2 files changed, 3 insertions(+), 0 deletions(-) diff --git a/drivers/base/dma-contiguous.c b/drivers/base/dma-contiguous.c index e167a1e1bccb..60f5c2591ccd 100644 --- a/drivers/base/dma-contiguous.c +++ b/drivers/base/dma-contiguous.c @@ -35,6 +35,7 @@ #endif struct cma *dma_contiguous_default_area; +EXPORT_SYMBOL(dma_contiguous_default_area); /* * Default global CMA area size can be defined in kernel's .config. diff --git a/mm/cma.c b/mm/cma.c index c960459eda7e..b50245282a18 100644 --- a/mm/cma.c +++ b/mm/cma.c @@ -47,11 +47,13 @@ phys_addr_t cma_get_base(const struct cma *cma) { return PFN_PHYS(cma->base_pfn); } +EXPORT_SYMBOL(cma_get_base); unsigned long cma_get_size(const struct cma *cma) { return cma->count << PAGE_SHIFT; } +EXPORT_SYMBOL(cma_get_size); static unsigned long cma_bitmap_aligned_mask(const struct cma *cma, int align_order)