Index: arch/v850/kernel/Makefile =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/Makefile,v retrieving revision 1.2 diff -u -r1.2 Makefile --- arch/v850/kernel/Makefile 2002/01/10 12:36:30 1.2 +++ arch/v850/kernel/Makefile 2002/03/26 05:29:02 @@ -15,8 +15,10 @@ O_TARGET := kernel.o obj-y := intv.o entry.o process.o syscalls.o time.o semaphore.o setup.o \ - signal.o irq.o mach.o ptrace.o v850_ksyms.o bug.o + signal.o irq.o mach.o ptrace.o bug.o +export-objs := v850_ksyms.o +obj-$(CONFIG_MODULES) += v850_ksyms.o # chip-specific code obj-$(CONFIG_V850E_MA1) += ma.o nb85e_utils.o nb85e_timer_d.o obj-$(CONFIG_V850E_NB85E) += nb85e.o Index: arch/v850/kernel/entry.S =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/entry.S,v retrieving revision 1.3 diff -u -r1.3 entry.S --- arch/v850/kernel/entry.S 2002/02/27 07:25:11 1.3 +++ arch/v850/kernel/entry.S 2002/03/26 05:29:03 @@ -447,7 +447,7 @@ bnh 1f; \ /* Figure out which function to use for this system call. */ \ shl 2, r12; \ - mov hilo(syscall_table), r19; \ + mov hilo(CSYM(sys_call_table)), r19; \ add r19, r12; \ ld.w 0[r12], r12; \ /* Make the system call. */ \ @@ -491,7 +491,7 @@ MAKE_SYS_CALL // Jump to the syscall function. 2: // For other traps, use a table lookup. - mov hilo(trap_table), r18 + mov hilo(CSYM(trap_table)), r18 add r19, r18 ld.w 0[r18], r18 jmp [r18] // Jump to the trap handler. @@ -772,7 +772,8 @@ .data __ALIGN -trap_table: + .globl CSYM(trap_table) +CSYM(trap_table): .long bad_trap_wrapper // trap 0, doesn't use trap table. .long syscall_long // trap 1, `long' syscall. .long bad_trap_wrapper @@ -793,7 +794,8 @@ .section .rodata __ALIGN -syscall_table: + .globl CSYM(sys_call_table) +CSYM(sys_call_table): .long CSYM(sys_ni_syscall) // 0 - old "setup()" system call .long CSYM(sys_exit) .long sys_fork_wrapper Index: arch/v850/kernel/nb85e_timer_d.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/nb85e_timer_d.c,v retrieving revision 1.1 diff -u -r1.1 nb85e_timer_d.c --- arch/v850/kernel/nb85e_timer_d.c 2001/10/22 13:38:58 1.1 +++ arch/v850/kernel/nb85e_timer_d.c 2002/03/26 05:29:03 @@ -2,8 +2,8 @@ * include/asm-v850/nb85e_timer_d.c -- `Timer D' component often used * with the NB85E cpu core * - * Copyright (C) 2001 NEC Corporation - * Copyright (C) 2001 Miles Bader + * Copyright (C) 2001,2002 NEC Corporation + * Copyright (C) 2001,2002 Miles Bader * * This file is subject to the terms and conditions of the GNU General * Public License. See the file COPYING in the main directory of this @@ -29,7 +29,8 @@ cpu_clock_freq, rate, NB85E_TIMER_D_TMCD_CS_MIN, NB85E_TIMER_D_TMCD_CS_MAX, 16, &divlog2, &count)) - printk ("Cannot find interval timer %d setting suitable" + printk (KERN_WARNING + "Cannot find interval timer %d setting suitable" " for rate of %dHz.\n" "Using rate of %ldHz instead.\n", timer, rate, (cpu_clock_freq >> divlog2) >> 16); Index: arch/v850/kernel/rte_cb.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/rte_cb.c,v retrieving revision 1.2 diff -u -r1.2 rte_cb.c --- arch/v850/kernel/rte_cb.c 2002/01/10 12:36:30 1.2 +++ arch/v850/kernel/rte_cb.c 2002/03/26 05:29:03 @@ -57,7 +57,8 @@ void __init mach_setup (char **cmdline) { - printk ("CPU: %s\n" + printk (KERN_INFO + "CPU: %s\n" "Platform: %s%s\n", CHIP_LONG, PLATFORM_LONG, @@ -75,7 +76,8 @@ if (*(volatile long *)MB_A_SRAM_ADDR == 0xDEADBEEF) { *(volatile long *)MB_A_SRAM_ADDR = 0x12345678; if (*(volatile long *)MB_A_SRAM_ADDR == 0x12345678) - printk (" NEC SolutionGear/Midas lab" + printk (KERN_INFO + " NEC SolutionGear/Midas lab" " RTE-MOTHER-A motherboard\n"); } Index: arch/v850/kernel/rte_nb85e_cb.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/rte_nb85e_cb.c,v retrieving revision 1.1 diff -u -r1.1 rte_nb85e_cb.c --- arch/v850/kernel/rte_nb85e_cb.c 2001/10/22 13:38:58 1.1 +++ arch/v850/kernel/rte_nb85e_cb.c 2002/03/26 05:29:04 @@ -1,8 +1,8 @@ /* * arch/v850/kernel/rte_nb85e_cb.c -- Midas labs RTE-V850E/NB85E-CB board * - * Copyright (C) 2001 NEC Corporation - * Copyright (C) 2001 Miles Bader + * Copyright (C) 2001,2002 NEC Corporation + * Copyright (C) 2001,2002 Miles Bader * * This file is subject to the terms and conditions of the GNU General * Public License. See the file COPYING in the main directory of this @@ -51,7 +51,8 @@ *ram_start += len; *ram_len -= len; } else - printk ("Blkmem0 in strange place: 0lx%x - 0x%lx!\n", + printk (KERN_WARNING + "Blkmem0 in strange place: 0lx%x - 0x%lx!\n", blkmem_0_start, blkmem_0_end); } } Index: arch/v850/kernel/setup.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/setup.c,v retrieving revision 1.2 diff -u -r1.2 setup.c --- arch/v850/kernel/setup.c 2002/01/10 12:36:30 1.2 +++ arch/v850/kernel/setup.c 2002/03/26 05:29:04 @@ -1,8 +1,8 @@ /* * arch/v850/kernel/setup.c -- Arch-dependent initialization functions * - * Copyright (C) 2001 NEC Corporation - * Copyright (C) 2001 Miles Bader + * Copyright (C) 2001,2002 NEC Corporation + * Copyright (C) 2001,2002 Miles Bader * * This file is subject to the terms and conditions of the GNU General * Public License. See the file COPYING in the main directory of this @@ -108,7 +108,8 @@ total_ram_pages = free_all_bootmem (); - printk ("Memory: %luK/%luK available" + printk (KERN_INFO + "Memory: %luK/%luK available" " (%luK kernel code, %luK data)\n", PAGE_TO_ADDR (nr_free_pages()) / 1024, ram_len / 1024, Index: arch/v850/kernel/sim.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/sim.c,v retrieving revision 1.3 diff -u -r1.3 sim.c --- arch/v850/kernel/sim.c 2002/01/29 22:29:43 1.3 +++ arch/v850/kernel/sim.c 2002/03/26 05:29:04 @@ -27,7 +27,7 @@ #include "mach.h" /* The (arbitrary) size of RAM for our simulated machine. */ -#define MEM_SIZE ((long)(8*1024*1024)) +#define MEM_SIZE ((long)(16*1024*1024)) /* The name of a file containing the root filesystem. */ #define ROOT_FS "blkmem0.image" @@ -48,7 +48,7 @@ { const char *err; - printk ("CPU: NEC v850e (GDB simulator)\n"); + printk (KERN_INFO "CPU: NEC v850e (GDB simulator)\n"); simcons_setup (); Index: arch/v850/kernel/simcons.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/simcons.c,v retrieving revision 1.1 diff -u -r1.1 simcons.c --- arch/v850/kernel/simcons.c 2001/10/22 13:38:58 1.1 +++ arch/v850/kernel/simcons.c 2002/03/26 05:29:04 @@ -1,8 +1,8 @@ /* * arch/v850/kernel/simcons.c -- Console I/O for GDB v850e simulator * - * Copyright (C) 2001 NEC Corporation - * Copyright (C) 2001 Miles Bader + * Copyright (C) 2001, 2002 NEC Corporation + * Copyright (C) 2001, 2002 Miles Bader * * This file is subject to the terms and conditions of the GNU General * Public License. See the file COPYING in the main directory of this @@ -159,5 +159,5 @@ { V850_SIM_SYSCALL (make_raw, 0); register_console (&simcons); - printk ("Console: GDB/v850e simulator stdio\n"); + printk (KERN_INFO "Console: GDB/v850e simulator stdio\n"); } Index: arch/v850/kernel/v850_ksyms.c =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/kernel/v850_ksyms.c,v retrieving revision 1.1 diff -u -r1.1 v850_ksyms.c --- arch/v850/kernel/v850_ksyms.c 2001/10/22 13:38:58 1.1 +++ arch/v850/kernel/v850_ksyms.c 2002/03/26 05:29:04 @@ -19,90 +19,62 @@ #include #include -//asmlinkage long long __ashrdi3 (long long, int); -//asmlinkage long long __lshrdi3 (long long, int); +extern void dump_thread (struct pt_regs *, struct user *); +extern int dump_fpu (elf_fpregset_t *); -extern void dump_thread(struct pt_regs *, struct user *); -extern int dump_fpu(elf_fpregset_t *); +extern void *trap_table; +EXPORT_SYMBOL (trap_table); /* platform dependent support */ +EXPORT_SYMBOL (dump_thread); +EXPORT_SYMBOL (kernel_thread); +EXPORT_SYMBOL (__bug); -EXPORT_SYMBOL(__ioremap); -EXPORT_SYMBOL(iounmap); -EXPORT_SYMBOL(dump_fpu); -EXPORT_SYMBOL(dump_thread); -EXPORT_SYMBOL(strnlen); -EXPORT_SYMBOL(strrchr); -EXPORT_SYMBOL(strstr); -EXPORT_SYMBOL(mach_enable_irq); -EXPORT_SYMBOL(mach_disable_irq); -EXPORT_SYMBOL(kernel_thread); - /* Networking helper routines. */ -EXPORT_SYMBOL(csum_partial_copy); - -/* The following are special because they're not called - explicitly (the C compiler generates them). Fortunately, - their interface isn't gonna change any time soon now, so - it's OK to leave it out of version control. */ -//EXPORT_SYMBOL_NOVERS(__ashrdi3); -//EXPORT_SYMBOL_NOVERS(__lshrdi3); -EXPORT_SYMBOL_NOVERS(memcpy); -EXPORT_SYMBOL_NOVERS(memset); -EXPORT_SYMBOL_NOVERS(memcmp); -EXPORT_SYMBOL_NOVERS(memscan); - -EXPORT_SYMBOL_NOVERS(__down_failed); -EXPORT_SYMBOL_NOVERS(__down_failed_interruptible); -EXPORT_SYMBOL_NOVERS(__down_failed_trylock); -EXPORT_SYMBOL_NOVERS(__up_wakeup); - -EXPORT_SYMBOL(get_wchan); +EXPORT_SYMBOL (csum_partial_copy); +EXPORT_SYMBOL (csum_partial_copy_from_user); +EXPORT_SYMBOL (ip_compute_csum); +EXPORT_SYMBOL (ip_fast_csum); + +/* string / mem functions */ +EXPORT_SYMBOL_NOVERS (strcpy); +EXPORT_SYMBOL_NOVERS (strncpy); +EXPORT_SYMBOL_NOVERS (strcat); +EXPORT_SYMBOL_NOVERS (strncat); +EXPORT_SYMBOL_NOVERS (strcmp); +EXPORT_SYMBOL_NOVERS (strncmp); +EXPORT_SYMBOL_NOVERS (strchr); +EXPORT_SYMBOL_NOVERS (strlen); +EXPORT_SYMBOL_NOVERS (strnlen); +EXPORT_SYMBOL_NOVERS (strpbrk); +EXPORT_SYMBOL_NOVERS (strtok); +EXPORT_SYMBOL_NOVERS (strrchr); +EXPORT_SYMBOL_NOVERS (strstr); +EXPORT_SYMBOL_NOVERS (memset); +EXPORT_SYMBOL_NOVERS (memcpy); +EXPORT_SYMBOL_NOVERS (memmove); +EXPORT_SYMBOL_NOVERS (memcmp); +EXPORT_SYMBOL_NOVERS (memscan); + +/* semaphores */ +EXPORT_SYMBOL_NOVERS (__down); +EXPORT_SYMBOL_NOVERS (__down_interruptible); +EXPORT_SYMBOL_NOVERS (__down_trylock); +EXPORT_SYMBOL_NOVERS (__up); /* * libgcc functions - functions that are used internally by the * compiler... (prototypes are not correct though, but that * doesn't really matter since they're not versioned). */ -extern void __gcc_bcmp(void); -extern void __ashldi3(void); -extern void __ashrdi3(void); -extern void __cmpdi2(void); -extern void __divdi3(void); -extern void __divsi3(void); -extern void __lshrdi3(void); -extern void __moddi3(void); -extern void __modsi3(void); -extern void __muldi3(void); -extern void __mulsi3(void); -extern void __negdi2(void); -extern void __ucmpdi2(void); -extern void __udivdi3(void); -extern void __udivmoddi4(void); -extern void __udivsi3(void); -extern void __umoddi3(void); -extern void __umodsi3(void); - - /* gcc lib functions */ -EXPORT_SYMBOL_NOVERS(__gcc_bcmp); -EXPORT_SYMBOL_NOVERS(__ashldi3); -EXPORT_SYMBOL_NOVERS(__ashrdi3); -EXPORT_SYMBOL_NOVERS(__cmpdi2); -EXPORT_SYMBOL_NOVERS(__divdi3); -EXPORT_SYMBOL_NOVERS(__divsi3); -EXPORT_SYMBOL_NOVERS(__lshrdi3); -EXPORT_SYMBOL_NOVERS(__moddi3); -EXPORT_SYMBOL_NOVERS(__modsi3); -EXPORT_SYMBOL_NOVERS(__muldi3); -EXPORT_SYMBOL_NOVERS(__mulsi3); -EXPORT_SYMBOL_NOVERS(__negdi2); -EXPORT_SYMBOL_NOVERS(__ucmpdi2); -EXPORT_SYMBOL_NOVERS(__udivdi3); -EXPORT_SYMBOL_NOVERS(__udivmoddi4); -EXPORT_SYMBOL_NOVERS(__udivsi3); -EXPORT_SYMBOL_NOVERS(__umoddi3); -EXPORT_SYMBOL_NOVERS(__umodsi3); - -EXPORT_SYMBOL_NOVERS(strlen); - -EXPORT_SYMBOL_NOVERS(_current_task); +extern void __ashldi3 (void); +extern void __ashrdi3 (void); +extern void __lshrdi3 (void); +extern void __muldi3 (void); +extern void __negdi2 (void); + +EXPORT_SYMBOL_NOVERS (__ashldi3); +EXPORT_SYMBOL_NOVERS (__ashrdi3); +EXPORT_SYMBOL_NOVERS (__lshrdi3); +EXPORT_SYMBOL_NOVERS (__muldi3); +EXPORT_SYMBOL_NOVERS (__negdi2); Index: arch/v850/sim/gdb-scripts/example.gdbinit =================================================================== RCS file: /var/cvs/uClinux-2.4.x/arch/v850/sim/gdb-scripts/example.gdbinit,v retrieving revision 1.2 diff -u -r1.2 example.gdbinit --- arch/v850/sim/gdb-scripts/example.gdbinit 2002/01/29 22:29:43 1.2 +++ arch/v850/sim/gdb-scripts/example.gdbinit 2002/03/26 05:29:04 @@ -12,7 +12,7 @@ sim architecture v850e sim memory delete all -sim memory region 0,0x800000 +sim memory region 0,0x1000000 sim memory region 0xFFFF0000,0x10000 # Protect the kernel's text segment against writing. These addresses Index: include/asm-v850/checksum.h =================================================================== RCS file: /var/cvs/uClinux-2.4.x/include/asm-v850/checksum.h,v retrieving revision 1.2 diff -u -r1.2 checksum.h --- include/asm-v850/checksum.h 2002/01/10 12:36:32 1.2 +++ include/asm-v850/checksum.h 2002/03/26 05:29:19 @@ -26,8 +26,8 @@ * * it's best to have buff aligned on a 32-bit boundary */ -unsigned int csum_partial (const unsigned char * buff, int len, - unsigned int sum); +extern unsigned int csum_partial (const unsigned char * buff, int len, + unsigned int sum); /* * the same as csum_partial, but copies from src while it Index: include/asm-v850/module.h =================================================================== RCS file: /var/cvs/uClinux-2.4.x/include/asm-v850/module.h,v retrieving revision 1.1 diff -u -r1.1 module.h --- include/asm-v850/module.h 2001/10/22 13:39:02 1.1 +++ include/asm-v850/module.h 2002/03/26 05:29:19 @@ -1,8 +1,22 @@ +/* + * include/asm-v850/module.h -- Architecture-specific module hooks + * + * Copyright (C) 2001,2002 NEC Corporation + * Copyright (C) 2001,2002 Miles Bader + * + * This file is subject to the terms and conditions of the GNU General + * Public License. See the file COPYING in the main directory of this + * archive for more details. + * + * Written by Miles Bader + */ + #ifndef __V850_MODULE_H__ #define __V850_MODULE_H__ -#define module_map(x) vmalloc(x) -#define module_unmap(x) vfree(x) -#define module_arch_init(x) ((void)0) +#define arch_init_modules(x) ((void)0) +#define module_arch_init(x) (0) +#define module_map(sz) vmalloc (sz) +#define module_unmap(sz) vfree (sz) #endif /* __V850_MODULE_H__ */ Index: include/asm-v850/unistd.h =================================================================== RCS file: /var/cvs/uClinux-2.4.x/include/asm-v850/unistd.h,v retrieving revision 1.2 diff -u -r1.2 unistd.h --- include/asm-v850/unistd.h 2002/02/27 07:25:12 1.2 +++ include/asm-v850/unistd.h 2002/03/26 05:29:19 @@ -114,7 +114,6 @@ #define __NR_profil 98 #define __NR_statfs 99 #define __NR_fstatfs 100 -#define __NR_ioperm 101 #define __NR_socketcall 102 #define __NR_syslog 103 #define __NR_setitimer 104