aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/boot/compressed/misc_64.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sh/boot/compressed/misc_64.c')
-rw-r--r--arch/sh/boot/compressed/misc_64.c40
1 files changed, 0 insertions, 40 deletions
diff --git a/arch/sh/boot/compressed/misc_64.c b/arch/sh/boot/compressed/misc_64.c
index a006ef89b9dd..2941657e18aa 100644
--- a/arch/sh/boot/compressed/misc_64.c
+++ b/arch/sh/boot/compressed/misc_64.c
@@ -72,8 +72,6 @@ static unsigned outcnt = 0; /* bytes in output buffer */
72static int fill_inbuf(void); 72static int fill_inbuf(void);
73static void flush_window(void); 73static void flush_window(void);
74static void error(char *m); 74static void error(char *m);
75static void gzip_mark(void **);
76static void gzip_release(void **);
77 75
78extern char input_data[]; 76extern char input_data[];
79extern int input_len; 77extern int input_len;
@@ -82,11 +80,7 @@ static long bytes_out = 0;
82static uch *output_data; 80static uch *output_data;
83static unsigned long output_ptr = 0; 81static unsigned long output_ptr = 0;
84 82
85static void *malloc(int size);
86static void free(void *where);
87static void error(char *m); 83static void error(char *m);
88static void gzip_mark(void **);
89static void gzip_release(void **);
90 84
91static void puts(const char *); 85static void puts(const char *);
92 86
@@ -99,40 +93,6 @@ static unsigned long free_mem_end_ptr;
99 93
100#include "../../../../lib/inflate.c" 94#include "../../../../lib/inflate.c"
101 95
102static void *malloc(int size)
103{
104 void *p;
105
106 if (size < 0)
107 error("Malloc error\n");
108 if (free_mem_ptr == 0)
109 error("Memory error\n");
110
111 free_mem_ptr = (free_mem_ptr + 3) & ~3; /* Align */
112
113 p = (void *) free_mem_ptr;
114 free_mem_ptr += size;
115
116 if (free_mem_ptr >= free_mem_end_ptr)
117 error("\nOut of memory\n");
118
119 return p;
120}
121
122static void free(void *where)
123{ /* Don't care */
124}
125
126static void gzip_mark(void **ptr)
127{
128 *ptr = (void *) free_mem_ptr;
129}
130
131static void gzip_release(void **ptr)
132{
133 free_mem_ptr = (long) *ptr;
134}
135
136void puts(const char *s) 96void puts(const char *s)
137{ 97{
138} 98}