diff options
author | kaf24@scramble.cl.cam.ac.uk <kaf24@scramble.cl.cam.ac.uk> | 2004-01-28 18:29:04 +0000 |
---|---|---|
committer | kaf24@scramble.cl.cam.ac.uk <kaf24@scramble.cl.cam.ac.uk> | 2004-01-28 18:29:04 +0000 |
commit | a2a4fd60d08cd4894a779051918f4d706f3e923c (patch) | |
tree | b999a9fed307a4b53daac326b3dc38f84a13e932 /extras/mini-os | |
parent | b88b24c645cf013a9dad3f70ba4ef23369ad1191 (diff) | |
download | xen-a2a4fd60d08cd4894a779051918f4d706f3e923c.tar.gz xen-a2a4fd60d08cd4894a779051918f4d706f3e923c.tar.bz2 xen-a2a4fd60d08cd4894a779051918f4d706f3e923c.zip |
bitkeeper revision 1.695 (4017ff70oJV8517inpGbN1CixN6csw)
Many files:
Clean up compile warnings. Added stricter gcc options for Xen build.
Diffstat (limited to 'extras/mini-os')
-rw-r--r-- | extras/mini-os/Makefile | 4 | ||||
-rw-r--r-- | extras/mini-os/lib/malloc.c | 11 |
2 files changed, 5 insertions, 10 deletions
diff --git a/extras/mini-os/Makefile b/extras/mini-os/Makefile index 2e4d08e9d0..41d6785c00 100644 --- a/extras/mini-os/Makefile +++ b/extras/mini-os/Makefile @@ -5,9 +5,7 @@ LD := ld # Linker should relocate monitor to this address MONITOR_BASE := 0xE0100000 -# NB. '-Wstrict-prototypes -Wredundant-decls -Wpointer-arith -Winline -ansi' -# might all be okay to add to Xen. '-Wnested-externs' is a maybe. -# '-Wcast-qual' is evil. +# NB. '-Wcast-qual' is nasty, so I omitted it. CFLAGS := -fno-builtin -O3 -Wall -Ih/ -Wredundant-decls CFLAGS += -Wstrict-prototypes -Wnested-externs -Wpointer-arith -Winline -ansi diff --git a/extras/mini-os/lib/malloc.c b/extras/mini-os/lib/malloc.c index 68af1581cb..e9169b11dc 100644 --- a/extras/mini-os/lib/malloc.c +++ b/extras/mini-os/lib/malloc.c @@ -2637,17 +2637,12 @@ static void malloc_init_state(av) mstate av; Other internal utilities operating on mstates */ -#if __STD_C static Void_t* sYSMALLOc(INTERNAL_SIZE_T, mstate); +#ifndef MORECORE_CANNOT_TRIM static int sYSTRIm(size_t, mstate); +#endif static void malloc_consolidate(mstate); static Void_t** iALLOc(size_t, size_t*, int, Void_t**); -#else -static Void_t* sYSMALLOc(); -static int sYSTRIm(); -static void malloc_consolidate(); -static Void_t** iALLOc(); -#endif /* Debugging support @@ -3420,6 +3415,7 @@ static Void_t* sYSMALLOc(nb, av) INTERNAL_SIZE_T nb; mstate av; +#ifndef MORECORE_CANNOT_TRIM /* sYSTRIm is an inverse of sorts to sYSMALLOc. It gives memory back to the system (via negative arguments to sbrk) if there is unused @@ -3485,6 +3481,7 @@ static int sYSTRIm(pad, av) size_t pad; mstate av; } return 0; } +#endif /* ------------------------------ malloc ------------------------------ |