[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] tools/libs/call: Avoid xc_memalign in netbsd and solaris backends
commit bf8f8fdeb4195badf2ebb9049825ea9da200d447 Author: Ian Campbell <ian.campbell@xxxxxxxxxx> AuthorDate: Tue Sep 22 12:40:51 2015 +0100 Commit: Ian Campbell <ian.campbell@xxxxxxxxxx> CommitDate: Fri Jan 22 12:24:21 2016 +0000 tools/libs/call: Avoid xc_memalign in netbsd and solaris backends These are already arch specific, so just use the appropriate interfaces (as determined by looking at the xc_memalign backend). Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> Acked-by: Wei Liu <wei.liu2@xxxxxxxxxx> --- tools/libs/call/netbsd.c | 4 ++-- tools/libs/call/solaris.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/libs/call/netbsd.c b/tools/libs/call/netbsd.c index 2aa02f1..e96fbf1 100644 --- a/tools/libs/call/netbsd.c +++ b/tools/libs/call/netbsd.c @@ -74,8 +74,8 @@ void *osdep_alloc_hypercall_buffer(xencall_handle *xcall, size_t npages) size_t size = npages * XC_PAGE_SIZE; void *p; - p = xc_memalign(xcall, XC_PAGE_SIZE, size); - if (!p) + ret = posix_memalign(&p, XC_PAGE_SIZE, size); + if ( ret != 0 || !p ) return NULL; if ( mlock(p, size) < 0 ) diff --git a/tools/libs/call/solaris.c b/tools/libs/call/solaris.c index 945d867..5aa330e 100644 --- a/tools/libs/call/solaris.c +++ b/tools/libs/call/solaris.c @@ -71,7 +71,7 @@ int osdep_xencall_close(xencall_handle *xcall) void *osdep_alloc_hypercall_buffer(xencall_handle *xcall, size_t npages) { - return xc_memalign(xcall, XC_PAGE_SIZE, npages * XC_PAGE_SIZE); + return memalign(XC_PAGE_SIZE, npages * XC_PAGE_SIZE); } void osdep_free_hypercall_buffer(xencall_handle *xcall, void *ptr, -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |