From: Jijiang Liu <jijiang.liu@intel.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH 2/3] lib/xen:DPDK dom0 Driver change
Date: Fri, 23 Jan 2015 13:35:39 +0800 [thread overview]
Message-ID: <1421991340-21960-3-git-send-email-jijiang.liu@intel.com> (raw)
In-Reply-To: <1421991340-21960-1-git-send-email-jijiang.liu@intel.com>
Fixed all the compilation issues due to using SUSE Linux 11 SP3.
Signed-off-by: Jijiang Liu <jijiang.liu@intel.com>
---
lib/librte_eal/linuxapp/xen_dom0/dom0_mm_misc.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/lib/librte_eal/linuxapp/xen_dom0/dom0_mm_misc.c b/lib/librte_eal/linuxapp/xen_dom0/dom0_mm_misc.c
index 543bf57..2715826 100644
--- a/lib/librte_eal/linuxapp/xen_dom0/dom0_mm_misc.c
+++ b/lib/librte_eal/linuxapp/xen_dom0/dom0_mm_misc.c
@@ -67,7 +67,7 @@
#include <linux/version.h>
#include <xen/xen.h>
-#include <xen/page.h>
+#include <asm/uaccess.h>
#include <xen/xen-ops.h>
#include <xen/interface/memory.h>
@@ -392,7 +392,7 @@ find_memseg(int count, struct dom0_mm_data * mm_data)
static int
dom0_memory_reserve(uint32_t rsv_size)
{
- uint64_t pfn, vstart, vaddr;
+ uint64_t pfn, mfn, vstart, vaddr;
uint32_t i, num_block, size, allocated_size = 0;
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 13, 0)
@@ -429,7 +429,8 @@ dom0_memory_reserve(uint32_t rsv_size)
size -= PAGE_SIZE;
}
- pfn = virt_to_pfn(vstart);
+ mfn = virt_to_mfn(vstart);
+ pfn = mfn_to_pfn(mfn);
rsv_mm_info[i].pfn = pfn;
rsv_mm_info[i].vir_addr = vstart;
rsv_mm_info[i + 1].pfn =
@@ -457,7 +458,8 @@ dom0_memory_reserve(uint32_t rsv_size)
vaddr += PAGE_SIZE;
size -= PAGE_SIZE;
}
- pfn = virt_to_pfn(vstart);
+ mfn = virt_to_mfn(vstart);
+ pfn = mfn_to_pfn(mfn);
rsv_mm_info[i].pfn = pfn;
rsv_mm_info[i].vir_addr = vstart;
}
--
1.7.7.6
next prev parent reply other threads:[~2015-01-23 5:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-23 5:35 [dpdk-dev] [PATCH 0/3] dpdk/xen:support DPDK running on Xen Dom0 of SUSE Linux Jijiang Liu
2015-01-23 5:35 ` [dpdk-dev] [PATCH 1/3] compilation:fix compilation issues of using gcc-4.3.4 Jijiang Liu
2015-01-23 5:35 ` Jijiang Liu [this message]
2015-01-23 5:35 ` [dpdk-dev] [PATCH 3/3] lib/eal:igb_uio driver change Jijiang Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1421991340-21960-3-git-send-email-jijiang.liu@intel.com \
--to=jijiang.liu@intel.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).