ia64/xen-unstable

changeset 11999:21905d2497d6

[LIBXC] Add -Wmissing-prototypes to CFLAGS, fix warnings resulting from that.

Signed-off-by: Gerd Hoffmann <kraxel@suse.de>
author kfraser@localhost.localdomain
date Wed Oct 25 15:25:13 2006 +0100 (2006-10-25)
parents 3db344ea8070
children 1e6b0a8a0822
files tools/libxc/Makefile tools/libxc/xc_linux_build.c tools/libxc/xc_linux_restore.c tools/libxc/xc_linux_save.c tools/libxc/xc_private.c
line diff
     1.1 --- a/tools/libxc/Makefile	Wed Oct 25 15:17:40 2006 +0100
     1.2 +++ b/tools/libxc/Makefile	Wed Oct 25 15:25:13 2006 +0100
     1.3 @@ -31,7 +31,7 @@ GUEST_SRCS-$(CONFIG_HVM) += xc_hvm_build
     1.4  
     1.5  -include $(XEN_TARGET_ARCH)/Makefile
     1.6  
     1.7 -CFLAGS   += -Werror
     1.8 +CFLAGS   += -Werror -Wmissing-prototypes
     1.9  CFLAGS   += -fno-strict-aliasing
    1.10  CFLAGS   += $(INCLUDES) -I.
    1.11  
     2.1 --- a/tools/libxc/xc_linux_build.c	Wed Oct 25 15:17:40 2006 +0100
     2.2 +++ b/tools/libxc/xc_linux_build.c	Wed Oct 25 15:25:13 2006 +0100
     2.3 @@ -128,7 +128,7 @@ static int probeimageformat(const char *
     2.4      return 0;
     2.5  }
     2.6  
     2.7 -int load_initrd(int xc_handle, domid_t dom,
     2.8 +static int load_initrd(int xc_handle, domid_t dom,
     2.9                  struct initrd_info *initrd,
    2.10                  unsigned long physbase,
    2.11                  xen_pfn_t *phys_to_mach)
     3.1 --- a/tools/libxc/xc_linux_restore.c	Wed Oct 25 15:17:40 2006 +0100
     3.2 +++ b/tools/libxc/xc_linux_restore.c	Wed Oct 25 15:25:13 2006 +0100
     3.3 @@ -57,7 +57,7 @@ read_exact(int fd, void *buf, size_t cou
     3.4  ** This function inverts that operation, replacing the pfn values with
     3.5  ** the (now known) appropriate mfn values.
     3.6  */
     3.7 -int uncanonicalize_pagetable(unsigned long type, void *page)
     3.8 +static int uncanonicalize_pagetable(unsigned long type, void *page)
     3.9  {
    3.10      int i, pte_last;
    3.11      unsigned long pfn;
     4.1 --- a/tools/libxc/xc_linux_save.c	Wed Oct 25 15:17:40 2006 +0100
     4.2 +++ b/tools/libxc/xc_linux_save.c	Wed Oct 25 15:25:13 2006 +0100
     4.3 @@ -413,7 +413,7 @@ static int suspend_and_state(int (*suspe
     4.4  ** which entries do not require canonicalization (in particular, those
     4.5  ** entries which map the virtual address reserved for the hypervisor).
     4.6  */
     4.7 -int canonicalize_pagetable(unsigned long type, unsigned long pfn,
     4.8 +static int canonicalize_pagetable(unsigned long type, unsigned long pfn,
     4.9                             const void *spage, void *dpage)
    4.10  {
    4.11  
     5.1 --- a/tools/libxc/xc_private.c	Wed Oct 25 15:17:40 2006 +0100
     5.2 +++ b/tools/libxc/xc_private.c	Wed Oct 25 15:25:13 2006 +0100
     5.3 @@ -6,6 +6,7 @@
     5.4  
     5.5  #include <inttypes.h>
     5.6  #include "xc_private.h"
     5.7 +#include "xg_private.h"
     5.8  
     5.9  int lock_pages(void *addr, size_t len)
    5.10  {
    5.11 @@ -35,23 +36,6 @@ int xc_get_pfn_type_batch(int xc_handle,
    5.12      return do_domctl(xc_handle, &domctl);
    5.13  }
    5.14  
    5.15 -#define GETPFN_ERR (~0U)
    5.16 -unsigned int get_pfn_type(int xc_handle,
    5.17 -                          unsigned long mfn,
    5.18 -                          uint32_t dom)
    5.19 -{
    5.20 -    DECLARE_DOMCTL;
    5.21 -    domctl.cmd = XEN_DOMCTL_getpageframeinfo;
    5.22 -    domctl.u.getpageframeinfo.gmfn   = mfn;
    5.23 -    domctl.domain = (domid_t)dom;
    5.24 -    if ( do_domctl(xc_handle, &domctl) < 0 )
    5.25 -    {
    5.26 -        PERROR("Unexpected failure when getting page frame info!");
    5.27 -        return GETPFN_ERR;
    5.28 -    }
    5.29 -    return domctl.u.getpageframeinfo.type;
    5.30 -}
    5.31 -
    5.32  int xc_mmuext_op(
    5.33      int xc_handle,
    5.34      struct mmuext_op *op,