Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 27140
b: refs/heads/master
c: 1b41526
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds committed Jun 5, 2006
1 parent 09d2195 commit 47c073e
Show file tree
Hide file tree
Showing 63 changed files with 380 additions and 235 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a7d14f875f03cb78992da8387be81a4c9197f101
refs/heads/master: 1b41526975d8318ca17c93f724893884d03a0560
12 changes: 12 additions & 0 deletions trunk/MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -568,6 +568,18 @@ L: linuxppc-dev@ozlabs.org
W: http://www.penguinppc.org/ppc64/
S: Supported

BROADCOM BNX2 GIGABIT ETHERNET DRIVER
P: Michael Chan
M: mchan@broadcom.com
L: netdev@vger.kernel.org
S: Supported

BROADCOM TG3 GIGABIT ETHERNET DRIVER
P: Michael Chan
M: mchan@broadcom.com
L: netdev@vger.kernel.org
S: Supported

BTTV VIDEO4LINUX DRIVER
P: Mauro Carvalho Chehab
M: mchehab@infradead.org
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/alpha/kernel/alpha_ksyms.c
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,6 @@ EXPORT_SYMBOL(smp_num_cpus);
EXPORT_SYMBOL(smp_call_function);
EXPORT_SYMBOL(smp_call_function_on_cpu);
EXPORT_SYMBOL(_atomic_dec_and_lock);
EXPORT_SYMBOL(cpu_present_mask);
#endif /* CONFIG_SMP */

/*
Expand Down
6 changes: 3 additions & 3 deletions trunk/arch/alpha/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ common_shutdown_1(void *generic_ptr)
if (cpuid != boot_cpuid) {
flags |= 0x00040000UL; /* "remain halted" */
*pflags = flags;
clear_bit(cpuid, &cpu_present_mask);
cpu_clear(cpuid, cpu_present_map);
halt();
}
#endif
Expand All @@ -120,8 +120,8 @@ common_shutdown_1(void *generic_ptr)

#ifdef CONFIG_SMP
/* Wait for the secondaries to halt. */
cpu_clear(boot_cpuid, cpu_possible_map);
while (cpus_weight(cpu_possible_map))
cpu_clear(boot_cpuid, cpu_present_map);
while (cpus_weight(cpu_present_map))
barrier();
#endif

Expand Down
14 changes: 4 additions & 10 deletions trunk/arch/alpha/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ enum ipi_message_type {
static int smp_secondary_alive __initdata = 0;

/* Which cpus ids came online. */
cpumask_t cpu_present_mask;
cpumask_t cpu_online_map;

EXPORT_SYMBOL(cpu_online_map);
Expand Down Expand Up @@ -439,7 +438,7 @@ setup_smp(void)
if ((cpu->flags & 0x1cc) == 0x1cc) {
smp_num_probed++;
/* Assume here that "whami" == index */
cpu_set(i, cpu_present_mask);
cpu_set(i, cpu_present_map);
cpu->pal_revision = boot_cpu_palrev;
}

Expand All @@ -450,11 +449,10 @@ setup_smp(void)
}
} else {
smp_num_probed = 1;
cpu_set(boot_cpuid, cpu_present_mask);
}

printk(KERN_INFO "SMP: %d CPUs probed -- cpu_present_mask = %lx\n",
smp_num_probed, cpu_possible_map.bits[0]);
printk(KERN_INFO "SMP: %d CPUs probed -- cpu_present_map = %lx\n",
smp_num_probed, cpu_present_map.bits[0]);
}

/*
Expand All @@ -473,7 +471,7 @@ smp_prepare_cpus(unsigned int max_cpus)

/* Nothing to do on a UP box, or when told not to. */
if (smp_num_probed == 1 || max_cpus == 0) {
cpu_present_mask = cpumask_of_cpu(boot_cpuid);
cpu_present_map = cpumask_of_cpu(boot_cpuid);
printk(KERN_INFO "SMP mode deactivated.\n");
return;
}
Expand All @@ -486,10 +484,6 @@ smp_prepare_cpus(unsigned int max_cpus)
void __devinit
smp_prepare_boot_cpu(void)
{
/*
* Mark the boot cpu (current cpu) as online
*/
cpu_set(smp_processor_id(), cpu_online_map);
}

int __devinit
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/alpha/kernel/sys_titan.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ titan_update_irq_hw(unsigned long mask)
register int bcpu = boot_cpuid;

#ifdef CONFIG_SMP
cpumask_t cpm = cpu_present_mask;
cpumask_t cpm = cpu_present_map;
volatile unsigned long *dim0, *dim1, *dim2, *dim3;
unsigned long mask0, mask1, mask2, mask3, dummy;

Expand Down
24 changes: 9 additions & 15 deletions trunk/arch/mips/au1000/common/prom.c
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
/*
*
* BRIEF MODULE DESCRIPTION
* PROM library initialisation code, assuming a version of
* pmon is the boot code.
* PROM library initialisation code, assuming YAMON is the boot loader.
*
* Copyright 2000,2001 MontaVista Software Inc.
* Copyright 2000, 2001, 2006 MontaVista Software Inc.
* Author: MontaVista Software, Inc.
* ppopov@mvista.com or source@mvista.com
*
Expand Down Expand Up @@ -49,9 +48,9 @@ extern char **prom_argv, **prom_envp;

typedef struct
{
char *name;
/* char *val; */
}t_env_var;
char *name;
char *val;
} t_env_var;


char * prom_getcmdline(void)
Expand Down Expand Up @@ -85,21 +84,16 @@ char *prom_getenv(char *envname)
{
/*
* Return a pointer to the given environment variable.
* Environment variables are stored in the form of "memsize=64".
*/

t_env_var *env = (t_env_var *)prom_envp;
int i;

i = strlen(envname);

while(env->name) {
if(strncmp(envname, env->name, i) == 0) {
return(env->name + strlen(envname) + 1);
}
while (env->name) {
if (strcmp(envname, env->name) == 0)
return env->val;
env++;
}
return(NULL);
return NULL;
}

inline unsigned char str2hexnum(unsigned char c)
Expand Down
5 changes: 5 additions & 0 deletions trunk/arch/mips/au1000/common/sleeper.S
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,11 @@ sdsleep:
mtc0 k0, CP0_PAGEMASK
lw k0, 0x14(sp)
mtc0 k0, CP0_CONFIG

/* We need to catch the ealry Alchemy SOCs with
* the write-only Config[OD] bit and set it back to one...
*/
jal au1x00_fixup_config_od
lw $1, PT_R1(sp)
lw $2, PT_R2(sp)
lw $3, PT_R3(sp)
Expand Down
8 changes: 4 additions & 4 deletions trunk/arch/mips/kernel/cpu-bugs64.c
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ static inline void check_daddi(void)
"daddi %0, %1, %3\n\t"
".set pop"
: "=r" (v), "=&r" (tmp)
: "I" (0xffffffffffffdb9a), "I" (0x1234));
: "I" (0xffffffffffffdb9aUL), "I" (0x1234));
set_except_vector(12, handler);
local_irq_restore(flags);

Expand All @@ -224,7 +224,7 @@ static inline void check_daddi(void)
"dsrl %1, %1, 1\n\t"
"daddi %0, %1, %3"
: "=r" (v), "=&r" (tmp)
: "I" (0xffffffffffffdb9a), "I" (0x1234));
: "I" (0xffffffffffffdb9aUL), "I" (0x1234));
set_except_vector(12, handler);
local_irq_restore(flags);

Expand Down Expand Up @@ -280,7 +280,7 @@ static inline void check_daddiu(void)
"daddu %1, %2\n\t"
".set pop"
: "=&r" (v), "=&r" (w), "=&r" (tmp)
: "I" (0xffffffffffffdb9a), "I" (0x1234));
: "I" (0xffffffffffffdb9aUL), "I" (0x1234));

if (v == w) {
printk("no.\n");
Expand All @@ -296,7 +296,7 @@ static inline void check_daddiu(void)
"addiu %1, $0, %4\n\t"
"daddu %1, %2"
: "=&r" (v), "=&r" (w), "=&r" (tmp)
: "I" (0xffffffffffffdb9a), "I" (0x1234));
: "I" (0xffffffffffffdb9aUL), "I" (0x1234));

if (v == w) {
printk("yes.\n");
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/mips/kernel/cpu-probe.c
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,7 @@ static inline void cpu_probe_sibyte(struct cpuinfo_mips *c)
case PRID_IMP_SB1:
c->cputype = CPU_SB1;
/* FPU in pass1 is known to have issues. */
if ((c->processor_id & 0xff) < 0x20)
if ((c->processor_id & 0xff) < 0x02)
c->options &= ~(MIPS_CPU_FPU | MIPS_CPU_32FPR);
break;
case PRID_IMP_SB1A:
Expand Down
6 changes: 6 additions & 0 deletions trunk/arch/mips/kernel/module.c
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,9 @@ int apply_relocate(Elf_Shdr *sechdrs, const char *strtab,
sym = (Elf_Sym *)sechdrs[symindex].sh_addr
+ ELF_MIPS_R_SYM(rel[i]);
if (!sym->st_value) {
/* Ignore unresolved weak symbol */
if (ELF_ST_BIND(sym->st_info) == STB_WEAK)
continue;
printk(KERN_WARNING "%s: Unknown symbol %s\n",
me->name, strtab + sym->st_name);
return -ENOENT;
Expand Down Expand Up @@ -325,6 +328,9 @@ int apply_relocate_add(Elf_Shdr *sechdrs, const char *strtab,
sym = (Elf_Sym *)sechdrs[symindex].sh_addr
+ ELF_MIPS_R_SYM(rel[i]);
if (!sym->st_value) {
/* Ignore unresolved weak symbol */
if (ELF_ST_BIND(sym->st_info) == STB_WEAK)
continue;
printk(KERN_WARNING "%s: Unknown symbol %s\n",
me->name, strtab + sym->st_name);
return -ENOENT;
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/mips/kernel/scall64-o32.S
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ sys_call_table:
PTR sys_fork
PTR sys_read
PTR sys_write
PTR sys_open /* 4005 */
PTR compat_sys_open /* 4005 */
PTR sys_close
PTR sys_waitpid
PTR sys_creat
Expand Down
18 changes: 10 additions & 8 deletions trunk/arch/mips/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ static inline int parse_rd_cmdline(unsigned long* rd_start, unsigned long* rd_en
#ifdef CONFIG_64BIT
/* HACK: Guess if the sign extension was forgotten */
if (start > 0x0000000080000000 && start < 0x00000000ffffffff)
start |= 0xffffffff00000000;
start |= 0xffffffff00000000UL;
#endif

end = start + size;
Expand Down Expand Up @@ -355,8 +355,6 @@ static inline void bootmem_init(void)
}
#endif

memory_present(0, first_usable_pfn, max_low_pfn);

/* Initialize the boot-time allocator with low memory only. */
bootmap_size = init_bootmem(first_usable_pfn, max_low_pfn);

Expand Down Expand Up @@ -410,6 +408,7 @@ static inline void bootmem_init(void)

/* Register lowmem ranges */
free_bootmem(PFN_PHYS(curr_pfn), PFN_PHYS(size));
memory_present(0, curr_pfn, curr_pfn + size - 1);
}

/* Reserve the bootmap memory. */
Expand All @@ -419,17 +418,20 @@ static inline void bootmem_init(void)
#ifdef CONFIG_BLK_DEV_INITRD
initrd_below_start_ok = 1;
if (initrd_start) {
unsigned long initrd_size = ((unsigned char *)initrd_end) - ((unsigned char *)initrd_start);
unsigned long initrd_size = ((unsigned char *)initrd_end) -
((unsigned char *)initrd_start);
const int width = sizeof(long) * 2;

printk("Initial ramdisk at: 0x%p (%lu bytes)\n",
(void *)initrd_start, initrd_size);

if (CPHYSADDR(initrd_end) > PFN_PHYS(max_low_pfn)) {
printk("initrd extends beyond end of memory "
"(0x%0*Lx > 0x%0*Lx)\ndisabling initrd\n",
sizeof(long) * 2,
(unsigned long long)CPHYSADDR(initrd_end),
sizeof(long) * 2,
(unsigned long long)PFN_PHYS(max_low_pfn));
width,
(unsigned long long) CPHYSADDR(initrd_end),
width,
(unsigned long long) PFN_PHYS(max_low_pfn));
initrd_start = initrd_end = 0;
initrd_reserve_bootmem = 0;
}
Expand Down
5 changes: 4 additions & 1 deletion trunk/arch/mips/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,9 @@ void __init smp_prepare_cpus(unsigned int max_cpus)
current_thread_info()->cpu = 0;
smp_tune_scheduling();
plat_prepare_cpus(max_cpus);
#ifndef CONFIG_HOTPLUG_CPU
cpu_present_map = cpu_possible_map;
#endif
}

/* preload SMP state for boot cpu */
Expand Down Expand Up @@ -442,7 +445,7 @@ static int __init topology_init(void)
int cpu;
int ret;

for_each_cpu(cpu) {
for_each_present_cpu(cpu) {
ret = register_cpu(&per_cpu(cpu_devices, cpu), cpu, NULL);
if (ret)
printk(KERN_WARNING "topology_init: register_cpu %d "
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/mips/kernel/syscall.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,7 @@ void sys_set_thread_area(unsigned long addr)

asmlinkage int _sys_sysmips(int cmd, long arg1, int arg2, int arg3)
{
int tmp, len;
char __user *name;
int tmp;

switch(cmd) {
case MIPS_ATOMIC_SET:
Expand Down
19 changes: 17 additions & 2 deletions trunk/arch/mips/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -819,15 +819,30 @@ asmlinkage void do_watch(struct pt_regs *regs)

asmlinkage void do_mcheck(struct pt_regs *regs)
{
const int field = 2 * sizeof(unsigned long);
int multi_match = regs->cp0_status & ST0_TS;

show_regs(regs);
dump_tlb_all();

if (multi_match) {
printk("Index : %0x\n", read_c0_index());
printk("Pagemask: %0x\n", read_c0_pagemask());
printk("EntryHi : %0*lx\n", field, read_c0_entryhi());
printk("EntryLo0: %0*lx\n", field, read_c0_entrylo0());
printk("EntryLo1: %0*lx\n", field, read_c0_entrylo1());
printk("\n");
dump_tlb_all();
}

show_code((unsigned int *) regs->cp0_epc);

/*
* Some chips may have other causes of machine check (e.g. SB1
* graduation timer)
*/
panic("Caught Machine Check exception - %scaused by multiple "
"matching entries in the TLB.",
(regs->cp0_status & ST0_TS) ? "" : "not ");
(multi_match) ? "" : "not ");
}

asmlinkage void do_mt(struct pt_regs *regs)
Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/mips/math-emu/dp_fint.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@

ieee754dp ieee754dp_fint(int x)
{
COMPXDP;
u64 xm;
int xe;
int xs;

CLEARCX;

Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/mips/math-emu/dp_flong.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@

ieee754dp ieee754dp_flong(s64 x)
{
COMPXDP;
u64 xm;
int xe;
int xs;

CLEARCX;

Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/mips/math-emu/sp_fint.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@

ieee754sp ieee754sp_fint(int x)
{
COMPXSP;
unsigned xm;
int xe;
int xs;

CLEARCX;

Expand Down
Loading

0 comments on commit 47c073e

Please sign in to comment.