From patchwork Wed Oct 18 14:03:35 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Lagerwall X-Patchwork-Id: 10014789 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 66D13601E7 for ; Wed, 18 Oct 2017 14:07:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 56E9C28BE3 for ; Wed, 18 Oct 2017 14:07:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4B99728BEA; Wed, 18 Oct 2017 14:07:26 +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=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id F339628BDB for ; Wed, 18 Oct 2017 14:07:25 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e4oyC-0007qQ-Un; Wed, 18 Oct 2017 14:05:16 +0000 Received: from mail6.bemta6.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e4oyB-0007ps-K3 for xen-devel@lists.xen.org; Wed, 18 Oct 2017 14:05:15 +0000 Received: from [193.109.254.147] by server-1.bemta-6.messagelabs.com id 6E/74-31121-A9F57E95; Wed, 18 Oct 2017 14:05:14 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprAIsWRWlGSWpSXmKPExsXitHSDve6s+Oe RBl/mKlks+biYxYHR4+ju30wBjFGsmXlJ+RUJrBldHU3MBa08FRsmBTQwTufsYuTkkBDwl/gx 9zkbiM0mYCBx69J3ZhBbREBd4nTHRdYuRi4OZoHXTBK3Wv6DJYQFHCX2TLrE2MXIwcEioCpxe boqSJhXwE6i70MnG8RMOYk9F2ewg9icAvYSs9v6wWwhoJo112ayQdhqEm+Xn2GB6BWUODnzCZ jNLCAhcfDFC+YJjLyzkKRmIUktYGRaxahRnFpUllqka2Spl1SUmZ5RkpuYmaNraGCml5taXJy YnpqTmFSsl5yfu4kRGDoMQLCD8cCiwEOMkhxMSqK8ugeeRQrxJeWnVGYkFmfEF5XmpBYfYpTh 4FCS4F0c9zxSSLAoNT21Ii0zBxjEMGkJDh4lEd7vsUBp3uKCxNzizHSI1ClGXY6Om3f/MAmx5 OXnpUqJ8wqBzBAAKcoozYMbAYuoS4yyUsK8jEBHCfEUpBblZpagyr9iFOdgVBLmtQSZwpOZVw K36RXQEUxAR6xzegJyREkiQkqqgdGgb37sNtf8ih+9R6vSL/D/mfTXb47I88M7X5q7cbbc6ss Viyo0fV0pbCHYpfz05rHiA9K92WyL5qxqPve1svSMTfevRAl2ro4dvIdbWPfdva20it2jnkMl WCwyuTl46hWJd9v4wiP+Flm7nMnrWLrm6iLxU9pnvJ22/Ft/80XlUhGeA6zTVymxFGckGmoxF xUnAgDxQaF7owIAAA== X-Env-Sender: prvs=457f25213=ross.lagerwall@citrix.com X-Msg-Ref: server-3.tower-27.messagelabs.com!1508335509!111976702!3 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 9.4.45; banners=-,-,- X-VirusChecked: Checked Received: (qmail 10330 invoked from network); 18 Oct 2017 14:05:14 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-3.tower-27.messagelabs.com with RC4-SHA encrypted SMTP; 18 Oct 2017 14:05:14 -0000 X-IronPort-AV: E=Sophos;i="5.43,397,1503360000"; d="scan'208";a="454799338" From: Ross Lagerwall To: Xen-devel Date: Wed, 18 Oct 2017 15:03:35 +0100 Message-ID: <20171018140339.13888-2-ross.lagerwall@citrix.com> X-Mailer: git-send-email 2.9.5 In-Reply-To: <20171018140339.13888-1-ross.lagerwall@citrix.com> References: <20171018140339.13888-1-ross.lagerwall@citrix.com> MIME-Version: 1.0 Cc: Stefano Stabellini , Wei Liu , Konrad Rzeszutek Wilk , George Dunlap , Andrew Cooper , Ian Jackson , Tim Deegan , Ross Lagerwall , Jan Beulich Subject: [Xen-devel] [PATCH v1 1/5] xen/mm: Make xenmem_add_to_physmap global X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP Make it global in preparation to be called by a new dmop. Signed-off-by: Ross Lagerwall Reviewed-by: Paul Durrant --- xen/common/memory.c | 5 ++--- xen/include/xen/mm.h | 3 +++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/xen/common/memory.c b/xen/common/memory.c index ad987e0..c4f05c7 100644 --- a/xen/common/memory.c +++ b/xen/common/memory.c @@ -741,9 +741,8 @@ static long memory_exchange(XEN_GUEST_HANDLE_PARAM(xen_memory_exchange_t) arg) return rc; } -static int xenmem_add_to_physmap(struct domain *d, - struct xen_add_to_physmap *xatp, - unsigned int start) +int xenmem_add_to_physmap(struct domain *d, struct xen_add_to_physmap *xatp, + unsigned int start) { unsigned int done = 0; long rc = 0; diff --git a/xen/include/xen/mm.h b/xen/include/xen/mm.h index e813c07..0e0e511 100644 --- a/xen/include/xen/mm.h +++ b/xen/include/xen/mm.h @@ -579,6 +579,9 @@ int xenmem_add_to_physmap_one(struct domain *d, unsigned int space, union xen_add_to_physmap_batch_extra extra, unsigned long idx, gfn_t gfn); +int xenmem_add_to_physmap(struct domain *d, struct xen_add_to_physmap *xatp, + unsigned int start); + /* Return 0 on success, or negative on error. */ int __must_check guest_remove_page(struct domain *d, unsigned long gmfn); int __must_check steal_page(struct domain *d, struct page_info *page,