aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/txx9/generic
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/txx9/generic')
-rw-r--r--arch/mips/txx9/generic/setup.c28
-rw-r--r--arch/mips/txx9/generic/smsc_fdc37m81x.c2
2 files changed, 5 insertions, 25 deletions
diff --git a/arch/mips/txx9/generic/setup.c b/arch/mips/txx9/generic/setup.c
index c860810722c0..e27809b6d04f 100644
--- a/arch/mips/txx9/generic/setup.c
+++ b/arch/mips/txx9/generic/setup.c
@@ -85,7 +85,7 @@ int txx9_ccfg_toeon __initdata = 1;
85struct clk *clk_get(struct device *dev, const char *id) 85struct clk *clk_get(struct device *dev, const char *id)
86{ 86{
87 if (!strcmp(id, "spi-baseclk")) 87 if (!strcmp(id, "spi-baseclk"))
88 return (struct clk *)((unsigned long)txx9_gbus_clock / 2 / 4); 88 return (struct clk *)((unsigned long)txx9_gbus_clock / 2 / 2);
89 if (!strcmp(id, "imbus_clk")) 89 if (!strcmp(id, "imbus_clk"))
90 return (struct clk *)((unsigned long)txx9_gbus_clock / 2); 90 return (struct clk *)((unsigned long)txx9_gbus_clock / 2);
91 return ERR_PTR(-ENOENT); 91 return ERR_PTR(-ENOENT);
@@ -160,7 +160,6 @@ static void __init prom_init_cmdline(void)
160 int argc; 160 int argc;
161 int *argv32; 161 int *argv32;
162 int i; /* Always ignore the "-c" at argv[0] */ 162 int i; /* Always ignore the "-c" at argv[0] */
163 char builtin[CL_SIZE];
164 163
165 if (fw_arg0 >= CKSEG0 || fw_arg1 < CKSEG0) { 164 if (fw_arg0 >= CKSEG0 || fw_arg1 < CKSEG0) {
166 /* 165 /*
@@ -174,20 +173,6 @@ static void __init prom_init_cmdline(void)
174 argv32 = (int *)fw_arg1; 173 argv32 = (int *)fw_arg1;
175 } 174 }
176 175
177 /* ignore all built-in args if any f/w args given */
178 /*
179 * But if built-in strings was started with '+', append them
180 * to command line args. If built-in was started with '-',
181 * ignore all f/w args.
182 */
183 builtin[0] = '\0';
184 if (arcs_cmdline[0] == '+')
185 strcpy(builtin, arcs_cmdline + 1);
186 else if (arcs_cmdline[0] == '-') {
187 strcpy(builtin, arcs_cmdline + 1);
188 argc = 0;
189 } else if (argc <= 1)
190 strcpy(builtin, arcs_cmdline);
191 arcs_cmdline[0] = '\0'; 176 arcs_cmdline[0] = '\0';
192 177
193 for (i = 1; i < argc; i++) { 178 for (i = 1; i < argc; i++) {
@@ -201,12 +186,6 @@ static void __init prom_init_cmdline(void)
201 } else 186 } else
202 strcat(arcs_cmdline, str); 187 strcat(arcs_cmdline, str);
203 } 188 }
204 /* append saved builtin args */
205 if (builtin[0]) {
206 if (arcs_cmdline[0])
207 strcat(arcs_cmdline, " ");
208 strcat(arcs_cmdline, builtin);
209 }
210} 189}
211 190
212static int txx9_ic_disable __initdata; 191static int txx9_ic_disable __initdata;
@@ -315,7 +294,7 @@ static inline void txx9_cache_fixup(void)
315 294
316static void __init preprocess_cmdline(void) 295static void __init preprocess_cmdline(void)
317{ 296{
318 char cmdline[CL_SIZE]; 297 static char cmdline[COMMAND_LINE_SIZE] __initdata;
319 char *s; 298 char *s;
320 299
321 strcpy(cmdline, arcs_cmdline); 300 strcpy(cmdline, arcs_cmdline);
@@ -817,7 +796,8 @@ void __init txx9_iocled_init(unsigned long baseaddr,
817out_pdev: 796out_pdev:
818 platform_device_put(pdev); 797 platform_device_put(pdev);
819out_gpio: 798out_gpio:
820 gpio_remove(&iocled->chip); 799 if (gpiochip_remove(&iocled->chip))
800 return;
821out_unmap: 801out_unmap:
822 iounmap(iocled->mmioaddr); 802 iounmap(iocled->mmioaddr);
823out_free: 803out_free:
diff --git a/arch/mips/txx9/generic/smsc_fdc37m81x.c b/arch/mips/txx9/generic/smsc_fdc37m81x.c
index a2b2d62d88e3..8ebc3848f3ac 100644
--- a/arch/mips/txx9/generic/smsc_fdc37m81x.c
+++ b/arch/mips/txx9/generic/smsc_fdc37m81x.c
@@ -117,7 +117,7 @@ unsigned long __init smsc_fdc37m81x_init(unsigned long port)
117 if (chip_id == SMSC_FDC37M81X_CHIP_ID) 117 if (chip_id == SMSC_FDC37M81X_CHIP_ID)
118 smsc_fdc37m81x_config_end(); 118 smsc_fdc37m81x_config_end();
119 else { 119 else {
120 printk(KERN_WARNING "%s: unknow chip id 0x%02x\n", __func__, 120 printk(KERN_WARNING "%s: unknown chip id 0x%02x\n", __func__,
121 chip_id); 121 chip_id);
122 g_smsc_fdc37m81x_base = 0; 122 g_smsc_fdc37m81x_base = 0;
123 } 123 }