summaryrefslogtreecommitdiffstats
path: root/src/svm/svm.c
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2017-04-26 15:32:12 +0200
committerFlorin Coras <florin.coras@gmail.com>2017-05-09 17:52:43 +0000
commit7bee80c823ca77de3aca803fdede77e4c7385a52 (patch)
tree827e8815fe68d70a5220a3e2890d37c299845e6d /src/svm/svm.c
parentb0972cbb35550619483b90004a00566f9641f983 (diff)
Fix remaining 32-bit compile issues
Change-Id: I9664214652229b663c3e3ba7406b4ede96bfb123 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/svm/svm.c')
-rw-r--r--src/svm/svm.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/svm/svm.c b/src/svm/svm.c
index 97add5a786c..c96135cfd5b 100644
--- a/src/svm/svm.c
+++ b/src/svm/svm.c
@@ -491,7 +491,7 @@ svm_map_region (svm_map_region_args_t * a)
return (0);
}
- rp = mmap ((void *) a->baseva, a->size,
+ rp = mmap (uword_to_pointer (a->baseva, void *), a->size,
PROT_READ | PROT_WRITE, MAP_SHARED | MAP_FIXED, svm_fd, 0);
if (rp == (svm_region_t *) MAP_FAILED)
@@ -533,9 +533,10 @@ svm_map_region (svm_map_region_args_t * a)
rp->virtual_size = a->size;
rp->region_heap =
- mheap_alloc_with_flags ((void *) (a->baseva + MMAP_PAGESIZE),
- (a->pvt_heap_size != 0) ?
- a->pvt_heap_size : SVM_PVT_MHEAP_SIZE,
+ mheap_alloc_with_flags (uword_to_pointer
+ (a->baseva + MMAP_PAGESIZE, void *),
+ (a->pvt_heap_size !=
+ 0) ? a->pvt_heap_size : SVM_PVT_MHEAP_SIZE,
MHEAP_FLAG_DISABLE_VM);
oldheap = svm_push_pvt_heap (rp);
@@ -661,7 +662,7 @@ svm_map_region (svm_map_region_args_t * a)
a->size = rp->virtual_size;
munmap (rp, MMAP_PAGESIZE);
- rp = (void *) mmap ((void *) a->baseva, a->size,
+ rp = (void *) mmap (uword_to_pointer (a->baseva, void *), a->size,
PROT_READ | PROT_WRITE,
MAP_SHARED | MAP_FIXED, svm_fd, 0);
if ((uword) rp == (uword) MAP_FAILED)