Commit f25bb39f authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus

* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: (22 commits)
  MIPS: Ignore vmlinux.*
  MIPS: Move vmlinux.ecoff to arch/mips/boot
  MIPS: cpumask_of_node() should handle -1 as a node
  MIPS: Octeon: Use non-overflowing arithmetic in sched_clock
  MIPS: Malta, PowerTV: Remove unnecessary "Linux started"
  MIPS: BCM63xx: Remove duplicate CONFIG_CMDLINE.
  MIPS: AR7: Remove unused prom_getchar()
  MIPS: PowerTV: Remove extra r4k_clockevent_init() call
  MIPS: Cobalt use strlcat() for the command line arguments
  MIPS: Octeon: Add sched_clock() to csrc-octeon.c
  MIPS: TXx9: Cleanup builtin-cmdline processing
  MIPS: PowerTV: simplify prom_init_cmdline() and merge into prom_init()
  MIPS: PowerTV: Remove unused platform_die()
  MIPS: PowerTV: Remove mips_machine_halt()
  MIPS: PowerTV: Remove unused ptv_memsize
  MIPS: PowerTV: Remove unused prom_getcmdline()
  MIPS: AR7: Remove kgdb_enabled
  MIPS: Alchemy: Correct code taking the size of a pointer
  MIPS: BCM63xx: Fix whitespace damaged board_bcm963xx.c
  MIPS: VR41xx: Use strlcat() for the command line arguments
  ...
parents 7113578a 9a3065c9
......@@ -613,7 +613,7 @@ u32 _au1xxx_dbdma_put_source(u32 chanid, void *buf, int nbytes, u32 flags)
dma_cache_wback_inv((unsigned long)buf, nbytes);
dp->dscr_cmd0 |= DSCR_CMD0_V; /* Let it rip */
au_sync();
dma_cache_wback_inv((unsigned long)dp, sizeof(dp));
dma_cache_wback_inv((unsigned long)dp, sizeof(*dp));
ctp->chan_ptr->ddma_dbell = 0;
/* Get next descriptor pointer. */
......@@ -676,7 +676,7 @@ _au1xxx_dbdma_put_dest(u32 chanid, void *buf, int nbytes, u32 flags)
dma_cache_inv((unsigned long)buf, nbytes);
dp->dscr_cmd0 |= DSCR_CMD0_V; /* Let it rip */
au_sync();
dma_cache_wback_inv((unsigned long)dp, sizeof(dp));
dma_cache_wback_inv((unsigned long)dp, sizeof(*dp));
ctp->chan_ptr->ddma_dbell = 0;
/* Get next descriptor pointer. */
......
......@@ -219,14 +219,6 @@ static void __init console_config(void)
if (strstr(prom_getcmdline(), "console="))
return;
#ifdef CONFIG_KGDB
if (!strstr(prom_getcmdline(), "nokgdb")) {
strcat(prom_getcmdline(), " console=kgdb");
kgdb_enabled = 1;
return;
}
#endif
s = prom_getenv("modetty0");
if (s) {
baud = simple_strtoul(s, &p, 10);
......@@ -280,13 +272,6 @@ static inline void serial_out(int offset, int value)
writel(value, (void *)PORT(offset));
}
char prom_getchar(void)
{
while (!(serial_in(UART_LSR) & UART_LSR_DR))
;
return serial_in(UART_RX);
}
int prom_putchar(char c)
{
while ((serial_in(UART_LSR) & UART_LSR_TEMT) == 0)
......
......@@ -363,7 +363,6 @@ static struct board_info __initdata board_FAST2404 = {
.force_duplex_full = 1,
},
.has_ohci0 = 1,
.has_pccard = 1,
.has_ehci0 = 1,
......
......@@ -40,9 +40,6 @@ void __init prom_init(void)
reg &= ~mask;
bcm_perf_writel(reg, PERF_CKCTL_REG);
/* assign command line from kernel config */
strcpy(arcs_cmdline, CONFIG_CMDLINE);
/* register gpiochip */
bcm63xx_gpio_init();
......
mkboot
elf2ecoff
vmlinux.*
zImage
zImage.tmp
......@@ -28,7 +28,7 @@ VMLINUX = vmlinux
all: vmlinux.ecoff vmlinux.srec
vmlinux.ecoff: $(obj)/elf2ecoff $(VMLINUX)
$(obj)/elf2ecoff $(VMLINUX) vmlinux.ecoff $(E2EFLAGS)
$(obj)/elf2ecoff $(VMLINUX) $(obj)/vmlinux.ecoff $(E2EFLAGS)
$(obj)/elf2ecoff: $(obj)/elf2ecoff.c
$(HOSTCC) -o $@ $^
......
......@@ -56,7 +56,7 @@ $(obj)/piggy.o: $(obj)/vmlinux.$(suffix_y) $(obj)/dummy.o
LDFLAGS_vmlinuz := $(LDFLAGS) -Ttext $(VMLINUZ_LOAD_ADDRESS) -T
vmlinuz: $(src)/ld.script $(obj-y) $(obj)/piggy.o
$(call if_changed,ld)
$(Q)$(OBJCOPY) $(OBJCOPYFLAGS) -R .comment -R .stab -R .stabstr -R .initrd -R .sysmap $@
$(Q)$(OBJCOPY) $(OBJCOPYFLAGS) $@
#
# Some DECstations need all possible sections of an ECOFF executable
......@@ -84,14 +84,11 @@ vmlinuz.ecoff: $(obj)/../elf2ecoff $(VMLINUZ)
$(obj)/../elf2ecoff: $(src)/../elf2ecoff.c
$(Q)$(HOSTCC) -o $@ $^
drop-sections = .reginfo .mdebug .comment .note .pdr .options .MIPS.options
strip-flags = $(addprefix --remove-section=,$(drop-sections))
OBJCOPYFLAGS_vmlinuz.bin := $(OBJCOPYFLAGS) -O binary $(strip-flags)
OBJCOPYFLAGS_vmlinuz.bin := $(OBJCOPYFLAGS) -O binary
vmlinuz.bin: vmlinuz
$(call if_changed,objcopy)
OBJCOPYFLAGS_vmlinuz.srec := $(OBJCOPYFLAGS) -S -O srec $(strip-flags)
OBJCOPYFLAGS_vmlinuz.srec := $(OBJCOPYFLAGS) -S -O srec
vmlinuz.srec: vmlinuz
$(call if_changed,objcopy)
......
......@@ -28,8 +28,6 @@ char *zimage_start;
/* The linker tells us where the image is. */
extern unsigned char __image_begin, __image_end;
extern unsigned char __ramdisk_begin, __ramdisk_end;
unsigned long initrd_size;
/* debug interfaces */
extern void puts(const char *s);
......@@ -102,14 +100,6 @@ void decompress_kernel(unsigned long boot_heap_start)
puthex((unsigned long)(zimage_size + zimage_start));
puts("\n");
if (initrd_size) {
puts("initrd at: ");
puthex((unsigned long)(&__ramdisk_begin));
puts(" ");
puthex((unsigned long)(&__ramdisk_end));
puts("\n");
}
/* this area are prepared for mallocing when decompressing */
free_mem_ptr = boot_heap_start;
free_mem_end_ptr = boot_heap_start + BOOT_HEAP_SIZE;
......
/*
* ld.script for compressed kernel support of MIPS
*
* Copyright (C) 2009 Lemote Inc.
* Author: Wu Zhangjin <wuzj@lemote.com>
*/
OUTPUT_ARCH(mips)
ENTRY(start)
SECTIONS
{
/* Read-only sections, merged into text segment: */
.init : { *(.init) } =0
.text :
{
/* . = VMLINUZ_LOAD_ADDRESS */
/* read-only */
_text = .; /* Text and read-only data */
.text : {
_ftext = . ;
*(.text)
*(.rodata)
*(.rodata1)
/* .gnu.warning sections are handled specially by elf32.em. */
*(.gnu.warning)
} =0
.kstrtab : { *(.kstrtab) }
. = ALIGN(16); /* Exception table */
__start___ex_table = .;
__ex_table : { *(__ex_table) }
__stop___ex_table = .;
__start___dbe_table = .; /* Exception table for data bus errors */
__dbe_table : { *(__dbe_table) }
__stop___dbe_table = .;
__start___ksymtab = .; /* Kernel symbol table */
__ksymtab : { *(__ksymtab) }
__stop___ksymtab = .;
_etext = .;
} = 0
_etext = .; /* End of text section */
. = ALIGN(8192);
.data.init_task : { *(.data.init_task) }
/* Startup code */
. = ALIGN(4096);
__init_begin = .;
.text.init : { *(.text.init) }
.data.init : { *(.data.init) }
. = ALIGN(16);
__setup_start = .;
.setup.init : { *(.setup.init) }
__setup_end = .;
__initcall_start = .;
.initcall.init : { *(.initcall.init) }
__initcall_end = .;
. = ALIGN(4096); /* Align double page for init_task_union */
__init_end = .;
. = ALIGN(4096);
.data.page_aligned : { *(.data.idt) }
. = ALIGN(32);
.data.cacheline_aligned : { *(.data.cacheline_aligned) }
.fini : { *(.fini) } =0
.reginfo : { *(.reginfo) }
/* Adjust the address for the data segment. We want to adjust up to
the same address within the page on the next page up. It would
be more correct to do this:
. = .;
The current expression does not correctly handle the case of a
text segment ending precisely at the end of a page; it causes the
data segment to skip a page. The above expression does not have
this problem, but it will currently (2/95) cause BFD to allocate
a single segment, combining both text and data, for this case.
This will prevent the text segment from being shared among
multiple executions of the program; I think that is more
important than losing a page of the virtual address space (note
that no actual memory is lost; the page which is skipped can not
be referenced). */
. = .;
.data :
{
/* writable */
.data : { /* Data */
_fdata = . ;
*(.data)
/* Put the compressed image here, so bss is on the end. */
__image_begin = .;
*(.image)
__image_end = .;
/* Align the initial ramdisk image (INITRD) on page boundaries. */
. = ALIGN(4096);
__ramdisk_begin = .;
*(.initrd)
__ramdisk_end = .;
. = ALIGN(4096);
CONSTRUCTORS
}
.data1 : { *(.data1) }
_gp = . + 0x8000;
.lit8 : { *(.lit8) }
.lit4 : { *(.lit4) }
.ctors : { *(.ctors) }
.dtors : { *(.dtors) }
.got : { *(.got.plt) *(.got) }
.dynamic : { *(.dynamic) }
/* We want the small data sections together, so single-instruction offsets
can access them all, and initialized data all before uninitialized, so
we can shorten the on-disk segment size. */
.sdata : { *(.sdata) }
. = ALIGN(4);
_edata = .;
PROVIDE (edata = .);
_edata = .; /* End of data section */
/* BSS */
__bss_start = .;
_fbss = .;
.sbss : { *(.sbss) *(.scommon) }
.bss :
{
.bss : {
*(.dynbss)
*(.bss)
*(COMMON)
}
. = ALIGN(4);
_end = . ;
PROVIDE (end = .);
}
/* Sections to be discarded */
/DISCARD/ :
{
*(.text.exit)
*(.data.exit)
*(.exitcall.exit)
}
/* These are needed for ELF backends which have not yet been converted
* to the new style linker. */
/* This is the MIPS specific mdebug section. */
.mdebug : { *(.mdebug) }
/* These are needed for ELF backends which have not yet been
converted to the new style linker. */
.stab 0 : { *(.stab) }
.stabstr 0 : { *(.stabstr) }
/* DWARF debug sections.
Symbols in the .debug DWARF section are relative to the beginning of the
section so we begin .debug at 0. It's not clear yet what needs to happen
for the others. */
.debug 0 : { *(.debug) }
.debug_srcinfo 0 : { *(.debug_srcinfo) }
.debug_aranges 0 : { *(.debug_aranges) }
.debug_pubnames 0 : { *(.debug_pubnames) }
.debug_sfnames 0 : { *(.debug_sfnames) }
.line 0 : { *(.line) }
/* These must appear regardless of . */
.gptab.sdata : { *(.gptab.data) *(.gptab.sdata) }
.gptab.sbss : { *(.gptab.bss) *(.gptab.sbss) }
.comment : { *(.comment) }
.note : { *(.note) }
/* Sections to be discarded */
/DISCARD/ : {
*(.MIPS.options)
*(.options)
*(.pdr)
*(.reginfo)
*(.comment)
*(.note)
}
}
......@@ -50,6 +50,38 @@ static struct clocksource clocksource_mips = {
.flags = CLOCK_SOURCE_IS_CONTINUOUS,
};
unsigned long long notrace sched_clock(void)
{
/* 64-bit arithmatic can overflow, so use 128-bit. */
#if (__GNUC__ < 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ <= 3))
u64 t1, t2, t3;
unsigned long long rv;
u64 mult = clocksource_mips.mult;
u64 shift = clocksource_mips.shift;
u64 cnt = read_c0_cvmcount();
asm (
"dmultu\t%[cnt],%[mult]\n\t"
"nor\t%[t1],$0,%[shift]\n\t"
"mfhi\t%[t2]\n\t"
"mflo\t%[t3]\n\t"
"dsll\t%[t2],%[t2],1\n\t"
"dsrlv\t%[rv],%[t3],%[shift]\n\t"
"dsllv\t%[t1],%[t2],%[t1]\n\t"
"or\t%[rv],%[t1],%[rv]\n\t"
: [rv] "=&r" (rv), [t1] "=&r" (t1), [t2] "=&r" (t2), [t3] "=&r" (t3)
: [cnt] "r" (cnt), [mult] "r" (mult), [shift] "r" (shift)
: "hi", "lo");
return rv;
#else
/* GCC > 4.3 do it the easy way. */
unsigned int __attribute__((mode(TI))) t;
t = read_c0_cvmcount();
t = t * clocksource_mips.mult;
return (unsigned long long)(t >> clocksource_mips.shift);
#endif
}
void __init plat_time_init(void)
{
clocksource_mips.rating = 300;
......
......@@ -97,26 +97,18 @@ void __init plat_mem_setup(void)
void __init prom_init(void)
{
int narg, indx, posn, nchr;
unsigned long memsz;
int argc, i;
char **argv;
memsz = fw_arg0 & 0x7fff0000;
narg = fw_arg0 & 0x0000ffff;
if (narg) {
arcs_cmdline[0] = '\0';
argv = (char **) fw_arg1;
posn = 0;
for (indx = 1; indx < narg; ++indx) {
nchr = strlen(argv[indx]);
if (posn + 1 + nchr + 1 > sizeof(arcs_cmdline))
break;
if (posn)
arcs_cmdline[posn++] = ' ';
strcpy(arcs_cmdline + posn, argv[indx]);
posn += nchr;
}
argc = fw_arg0 & 0x0000ffff;
argv = (char **)fw_arg1;
for (i = 1; i < argc; i++) {
strlcat(arcs_cmdline, argv[i], COMMAND_LINE_SIZE);
if (i < (argc - 1))
strlcat(arcs_cmdline, " ", COMMAND_LINE_SIZE);
}
add_memory_region(0x0, memsz, BOOT_MEM_RAM);
......
......@@ -24,7 +24,9 @@ extern struct cpuinfo_ip27 sn_cpu_info[NR_CPUS];
#define cpu_to_node(cpu) (sn_cpu_info[(cpu)].p_nodeid)
#define parent_node(node) (node)
#define cpumask_of_node(node) (&hub_data(node)->h_cpus)
#define cpumask_of_node(node) ((node) == -1 ? \
cpu_all_mask : \
&hub_data(node)->h_cpus)
struct pci_bus;
extern int pcibus_to_node(struct pci_bus *);
......
......@@ -49,9 +49,6 @@ void __init plat_mem_setup(void)
set_io_port_base(0xbfd00000);
serial_init();
pr_info("Linux started...\n");
}
extern struct plat_smp_ops ssmtc_smp_ops;
......@@ -60,7 +57,6 @@ void __init prom_init(void)
{
set_io_port_base(0xbfd00000);
pr_info("\nLINUX started...\n");
prom_meminit();
#ifdef CONFIG_MIPS_MT_SMP
......
......@@ -73,9 +73,6 @@ static int __cpuinit m4kc_tlbp_war(void)
enum label_id {
label_second_part = 1,
label_leave,
#ifdef MODULE_START
label_module_alloc,
#endif
label_vmalloc,
label_vmalloc_done,
label_tlbw_hazard,
......@@ -92,9 +89,6 @@ enum label_id {
UASM_L_LA(_second_part)
UASM_L_LA(_leave)
#ifdef MODULE_START
UASM_L_LA(_module_alloc)
#endif
UASM_L_LA(_vmalloc)
UASM_L_LA(_vmalloc_done)
UASM_L_LA(_tlbw_hazard)
......@@ -818,8 +812,6 @@ static void __cpuinit build_r4000_tlb_refill_handler(void)
} else {
#if defined(CONFIG_HUGETLB_PAGE)
const enum label_id ls = label_tlb_huge_update;
#elif defined(MODULE_START)
const enum label_id ls = label_module_alloc;
#else
const enum label_id ls = label_vmalloc;
#endif
......
......@@ -355,7 +355,6 @@ void __init prom_init(void)
board_nmi_handler_setup = mips_nmi_setup;
board_ejtag_handler_setup = mips_ejtag_setup;
pr_info("\nLINUX started...\n");
prom_init_cmdline();
prom_meminit();
#ifdef CONFIG_SERIAL_8250_CONSOLE
......
......@@ -23,6 +23,6 @@
# under Linux.
#
obj-y += cmdline.o init.o memory.o reset.o time.o powertv_setup.o asic/ pci/
obj-y += init.o memory.o reset.o time.o powertv_setup.o asic/ pci/
EXTRA_CFLAGS += -Wall -Werror
/*
* Carsten Langgaard, carstenl@mips.com
* Copyright (C) 1999,2000 MIPS Technologies, Inc. All rights reserved.
* Portions copyright (C) 2009 Cisco Systems, Inc.
*
* This program is free software; you can distribute it and/or modify it
* under the terms of the GNU General Public License (Version 2) as
* published by the Free Software Foundation.
*
* This program is distributed in the hope it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* for more details.
*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
* 59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
*
* Kernel command line creation using the prom monitor (YAMON) argc/argv.
*/
#include <linux/init.h>
#include <linux/string.h>
#include <asm/bootinfo.h>
#include "init.h"
/*
* YAMON (32-bit PROM) pass arguments and environment as 32-bit pointer.
* This macro take care of sign extension.
*/
#define prom_argv(index) ((char *)(long)_prom_argv[(index)])
char * __init prom_getcmdline(void)
{
return &(arcs_cmdline[0]);
}
void __init prom_init_cmdline(void)
{
int len;
if (prom_argc != 1)
return;
len = strlen(arcs_cmdline);
arcs_cmdline[len] = ' ';
strlcpy(arcs_cmdline + len + 1, (char *)_prom_argv,
COMMAND_LINE_SIZE - len - 1);
}
......@@ -34,10 +34,7 @@
#include <asm/mips-boards/generic.h>
#include <asm/mach-powertv/asic.h>
#include "init.h"
int prom_argc;
int *_prom_argv, *_prom_envp;
static int *_prom_envp;
unsigned long _prom_memsize;
/*
......@@ -109,16 +106,20 @@ static void __init mips_ejtag_setup(void)
void __init prom_init(void)
{
int prom_argc;
char *prom_argv;
prom_argc = fw_arg0;
_prom_argv = (int *) fw_arg1;
prom_argv = (char *) fw_arg1;
_prom_envp = (int *) fw_arg2;
_prom_memsize = (unsigned long) fw_arg3;
board_nmi_handler_setup = mips_nmi_setup;
board_ejtag_handler_setup = mips_ejtag_setup;
pr_info("\nLINUX started...\n");
prom_init_cmdline();
if (prom_argc == 1)
strlcat(arcs_cmdline, prom_argv, COMMAND_LINE_SIZE);
configure_platform();
prom_meminit();
......
......@@ -22,7 +22,5 @@
#ifndef _POWERTV_INIT_H
#define _POWERTV_INIT_H
extern int prom_argc;
extern int *_prom_argv;
extern unsigned long _prom_memsize;
#endif
......@@ -42,8 +42,6 @@
#define BOOT_MEM_SIZE KIBIBYTE(256) /* Memory reserved for bldr */
#define PHYS_MEM_START 0x10000000 /* Start of physical memory */
unsigned long ptv_memsize;
char __initdata cmdline[COMMAND_LINE_SIZE];
void __init prom_meminit(void)
......@@ -87,9 +85,6 @@ void __init prom_meminit(void)
}
}
/* Store memsize for diagnostic purposes */
ptv_memsize = memsize;
physend = PFN_ALIGN(&_end) - 0x80000000;
if (memsize > LOW_MEM_MAX) {
low_mem = LOW_MEM_MAX;
......
......@@ -64,9 +64,6 @@
#define REG_SIZE "4" /* In bytes */
#endif
static struct pt_regs die_regs;
static bool have_die_regs;
static void register_panic_notifier(void);
static int panic_handler(struct notifier_block *notifier_block,
unsigned long event, void *cause_string);
......@@ -218,24 +215,6 @@ static int panic_handler(struct notifier_block *notifier_block,
return NOTIFY_DONE;
}
/**
* Platform-specific handling of oops
* @str: Pointer to the oops string
* @regs: Pointer to the oops registers
* All we do here is to save the registers for subsequent printing through
* the panic notifier.
*/
void platform_die(const char *str, const struct pt_regs *regs)
{
/* If we already have saved registers, don't overwrite them as they
* they apply to the initial fault */
if (!have_die_regs) {
have_die_regs = true;
die_regs = *regs;
}
}
/* Information about the RF MAC address, if one was supplied on the
* command line. */
static bool have_rfmac;
......
......@@ -28,9 +28,6 @@
#include <asm/mach-powertv/asic_regs.h>
#include "reset.h"
static void mips_machine_restart(char *command);
static void mips_machine_halt(void);
static void mips_machine_restart(char *command)
{
#ifdef CONFIG_BOOTLOADER_DRIVER
......@@ -44,22 +41,7 @@ static void mips_machine_restart(char *command)
#endif
}
static void mips_machine_halt(void)
{
#ifdef CONFIG_BOOTLOADER_DRIVER
/*
* Call the bootloader's reset function to ensure
* that persistent data is flushed before hard reset
*/
kbldr_SetCauseAndReset();
#else
writel(0x1, asic_reg_addr(watchdog));
#endif
}
void mips_reboot_setup(void)
{
_machine_restart = mips_machine_restart;
_machine_halt = mips_machine_halt;
pm_power_off = mips_machine_halt;
}
......@@ -33,5 +33,4 @@ unsigned int __cpuinit get_c0_compare_int(void)
void __init plat_time_init(void)
{
powertv_clocksource_init();
r4k_clockevent_init();
}
......@@ -160,7 +160,6 @@ static void __init prom_init_cmdline(void)
int argc;
int *argv32;
int i; /* Always ignore the "-c" at argv[0] */
static char builtin[COMMAND_LINE_SIZE] __initdata;
if (fw_arg0 >= CKSEG0 || fw_arg1 < CKSEG0) {
/*
......@@ -174,20 +173,6 @@ static void __init prom_init_cmdline(void)
argv32 = (int *)fw_arg1;
}
/* ignore all built-in args if any f/w args given */
/*
* But if built-in strings was started with '+', append them
* to command line args. If built-in was started with '-',
* ignore all f/w args.
*/
builtin[0] = '\0';
if (arcs_cmdline[0] == '+')
strcpy(builtin, arcs_cmdline + 1);
else if (arcs_cmdline[0] == '-') {
strcpy(builtin, arcs_cmdline + 1);
argc = 0;
} else if (argc <= 1)
strcpy(builtin, arcs_cmdline);
arcs_cmdline[0] = '\0';
for (i = 1; i < argc; i++) {
......@@ -201,12 +186,6 @@ static void __init prom_init_cmdline(void)
} else
strcat(arcs_cmdline, str);
}
/* append saved builtin args */
if (builtin[0]) {
if (arcs_cmdline[0])
strcat(arcs_cmdline, " ");
strcat(arcs_cmdline, builtin);
}
}
static int txx9_ic_disable __initdata;
......
/*
* init.c, Common initialization routines for NEC VR4100 series.
*
* Copyright (C) 2003-2008 Yoichi Yuasa <yuasa@linux-mips.org>
* Copyright (C) 2003-2009 Yoichi Yuasa <yuasa@linux-mips.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -66,9 +66,9 @@ void __init prom_init(void)
argv = (char **)fw_arg1;
for (i = 1; i < argc; i++) {
strcat(arcs_cmdline, argv[i]);
strlcat(arcs_cmdline, argv[i], COMMAND_LINE_SIZE);
if (i < (argc - 1))
strcat(arcs_cmdline, " ");
strlcat(arcs_cmdline, " ", COMMAND_LINE_SIZE);
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment