[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[xen staging] libs/foreignmemory: fix MiniOS build



commit 389d4c12a1a9af7fc20dfd2e97f7bae9f37d932c
Author:     Roger Pau Monné <roger.pau@xxxxxxxxxx>
AuthorDate: Fri Jan 29 09:09:05 2021 +0100
Commit:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CommitDate: Fri Jan 29 08:14:08 2021 +0000

    libs/foreignmemory: fix MiniOS build
    
    Keep the dummy handlers for restrict, map_resource and unmap_resource
    for MiniOS, or else the build breaks with:
    
    ld: 
/home/osstest/build.158759.build-amd64/xen/stubdom/mini-os-x86_64-xenstore/mini-os.o:
 in function `xenforeignmemory_restrict':
    
/home/osstest/build.158759.build-amd64/xen/stubdom/libs-x86_64/foreignmemory/core.c:137:
 undefined reference to `osdep_xenforeignmemory_restrict'
    ld: 
/home/osstest/build.158759.build-amd64/xen/stubdom/mini-os-x86_64-xenstore/mini-os.o:
 in function `xenforeignmemory_map_resource':
    
/home/osstest/build.158759.build-amd64/xen/stubdom/libs-x86_64/foreignmemory/core.c:171:
 undefined reference to `osdep_xenforeignmemory_map_resource'
    ld: 
/home/osstest/build.158759.build-amd64/xen/stubdom/mini-os-x86_64-xenstore/mini-os.o:
 in function `xenforeignmemory_unmap_resource':
    
/home/osstest/build.158759.build-amd64/xen/stubdom/libs-x86_64/foreignmemory/core.c:185:
 undefined reference to `osdep_xenforeignmemory_unmap_resource'
    ld: 
/home/osstest/build.158759.build-amd64/xen/stubdom/mini-os-x86_64-xenstore/mini-os.o:
 in function `xenforeignmemory_resource_size':
    
/home/osstest/build.158759.build-amd64/xen/stubdom/libs-x86_64/foreignmemory/core.c:200:
 undefined reference to `osdep_xenforeignmemory_map_resource'
    
    Fixes: 2b4b33ffe7d67 ('libs/foreignmemory: Implement on NetBSD')
    Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
    Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
---
 tools/libs/foreignmemory/private.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/libs/foreignmemory/private.h 
b/tools/libs/foreignmemory/private.h
index 7e734ac61e..1ee3626dd2 100644
--- a/tools/libs/foreignmemory/private.h
+++ b/tools/libs/foreignmemory/private.h
@@ -54,7 +54,7 @@ struct xenforeignmemory_resource_handle {
     int flags;
 };
 
-#ifdef __sun__
+#if defined(__sun__) || defined(__MINIOS__)
 static inline int osdep_xenforeignmemory_restrict(xenforeignmemory_handle 
*fmem,
                                                   domid_t domid)
 {
--
generated by git-patchbot for /home/xen/git/xen.git#staging



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.