diff options
Diffstat (limited to 'arch/m32r/boot')
-rw-r--r-- | arch/m32r/boot/compressed/misc.c | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/arch/m32r/boot/compressed/misc.c b/arch/m32r/boot/compressed/misc.c index 600d40e33495..d394292498c0 100644 --- a/arch/m32r/boot/compressed/misc.c +++ b/arch/m32r/boot/compressed/misc.c | |||
@@ -70,8 +70,6 @@ static unsigned outcnt = 0; /* bytes in output buffer */ | |||
70 | static int fill_inbuf(void); | 70 | static int fill_inbuf(void); |
71 | static void flush_window(void); | 71 | static void flush_window(void); |
72 | static void error(char *m); | 72 | static void error(char *m); |
73 | static void gzip_mark(void **); | ||
74 | static void gzip_release(void **); | ||
75 | 73 | ||
76 | static unsigned char *input_data; | 74 | static unsigned char *input_data; |
77 | static int input_len; | 75 | static int input_len; |
@@ -82,9 +80,6 @@ static unsigned long output_ptr = 0; | |||
82 | 80 | ||
83 | #include "m32r_sio.c" | 81 | #include "m32r_sio.c" |
84 | 82 | ||
85 | static void *malloc(int size); | ||
86 | static void free(void *where); | ||
87 | |||
88 | static unsigned long free_mem_ptr; | 83 | static unsigned long free_mem_ptr; |
89 | static unsigned long free_mem_end_ptr; | 84 | static unsigned long free_mem_end_ptr; |
90 | 85 | ||
@@ -92,38 +87,6 @@ static unsigned long free_mem_end_ptr; | |||
92 | 87 | ||
93 | #include "../../../../lib/inflate.c" | 88 | #include "../../../../lib/inflate.c" |
94 | 89 | ||
95 | static void *malloc(int size) | ||
96 | { | ||
97 | void *p; | ||
98 | |||
99 | if (size <0) error("Malloc error"); | ||
100 | if (free_mem_ptr == 0) error("Memory error"); | ||
101 | |||
102 | free_mem_ptr = (free_mem_ptr + 3) & ~3; /* Align */ | ||
103 | |||
104 | p = (void *)free_mem_ptr; | ||
105 | free_mem_ptr += size; | ||
106 | |||
107 | if (free_mem_ptr >= free_mem_end_ptr) | ||
108 | error("Out of memory"); | ||
109 | |||
110 | return p; | ||
111 | } | ||
112 | |||
113 | static void free(void *where) | ||
114 | { /* Don't care */ | ||
115 | } | ||
116 | |||
117 | static void gzip_mark(void **ptr) | ||
118 | { | ||
119 | *ptr = (void *) free_mem_ptr; | ||
120 | } | ||
121 | |||
122 | static void gzip_release(void **ptr) | ||
123 | { | ||
124 | free_mem_ptr = (long) *ptr; | ||
125 | } | ||
126 | |||
127 | void* memset(void* s, int c, size_t n) | 90 | void* memset(void* s, int c, size_t n) |
128 | { | 91 | { |
129 | int i; | 92 | int i; |