diff options
Diffstat (limited to 'arch/h8300/boot')
-rw-r--r-- | arch/h8300/boot/compressed/misc.c | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/arch/h8300/boot/compressed/misc.c b/arch/h8300/boot/compressed/misc.c index 845074588af0..51ab6cbd030f 100644 --- a/arch/h8300/boot/compressed/misc.c +++ b/arch/h8300/boot/compressed/misc.c | |||
@@ -67,8 +67,6 @@ static unsigned outcnt = 0; /* bytes in output buffer */ | |||
67 | static int fill_inbuf(void); | 67 | static int fill_inbuf(void); |
68 | static void flush_window(void); | 68 | static void flush_window(void); |
69 | static void error(char *m); | 69 | static void error(char *m); |
70 | static void gzip_mark(void **); | ||
71 | static void gzip_release(void **); | ||
72 | 70 | ||
73 | extern char input_data[]; | 71 | extern char input_data[]; |
74 | extern int input_len; | 72 | extern int input_len; |
@@ -77,11 +75,7 @@ static long bytes_out = 0; | |||
77 | static uch *output_data; | 75 | static uch *output_data; |
78 | static unsigned long output_ptr = 0; | 76 | static unsigned long output_ptr = 0; |
79 | 77 | ||
80 | static void *malloc(int size); | ||
81 | static void free(void *where); | ||
82 | static void error(char *m); | 78 | static void error(char *m); |
83 | static void gzip_mark(void **); | ||
84 | static void gzip_release(void **); | ||
85 | 79 | ||
86 | int puts(const char *); | 80 | int puts(const char *); |
87 | 81 | ||
@@ -98,38 +92,6 @@ static unsigned long free_mem_end_ptr; | |||
98 | #define TDR *((volatile unsigned char *)0xffff8b) | 92 | #define TDR *((volatile unsigned char *)0xffff8b) |
99 | #define SSR *((volatile unsigned char *)0xffff8c) | 93 | #define SSR *((volatile unsigned char *)0xffff8c) |
100 | 94 | ||
101 | static void *malloc(int size) | ||
102 | { | ||
103 | void *p; | ||
104 | |||
105 | if (size <0) error("Malloc error"); | ||
106 | if (free_mem_ptr == 0) error("Memory error"); | ||
107 | |||
108 | free_mem_ptr = (free_mem_ptr + 3) & ~3; /* Align */ | ||
109 | |||
110 | p = (void *)free_mem_ptr; | ||
111 | free_mem_ptr += size; | ||
112 | |||
113 | if (free_mem_ptr >= free_mem_end_ptr) | ||
114 | error("Out of memory"); | ||
115 | |||
116 | return p; | ||
117 | } | ||
118 | |||
119 | static void free(void *where) | ||
120 | { /* Don't care */ | ||
121 | } | ||
122 | |||
123 | static void gzip_mark(void **ptr) | ||
124 | { | ||
125 | *ptr = (void *) free_mem_ptr; | ||
126 | } | ||
127 | |||
128 | static void gzip_release(void **ptr) | ||
129 | { | ||
130 | free_mem_ptr = (long) *ptr; | ||
131 | } | ||
132 | |||
133 | int puts(const char *s) | 95 | int puts(const char *s) |
134 | { | 96 | { |
135 | return 0; | 97 | return 0; |