Skip to content

Commit

Permalink
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6
Browse files Browse the repository at this point in the history
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SPARC64]: Adjust kernel PC validation test in fault handler.
  [SPARC64]: Loosen checks in exception table handling.
  [SPARC64]: Fix section mismatch from kernel_map_range
  [SPARC64]: Fix section mismatchs from dr_cpu_data
  [SPARC]: Fix build in arch/sparc/kernel/led.c
  • Loading branch information
Linus Torvalds committed Feb 29, 2008
2 parents 5ad5872 + be71716 commit 547598d
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 20 deletions.
3 changes: 3 additions & 0 deletions arch/sparc/kernel/led.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
#include <linux/init.h>
#include <linux/proc_fs.h>
#include <linux/string.h>
#include <linux/jiffies.h>
#include <linux/timer.h>
#include <linux/uaccess.h>

#include <asm/auxio.h>

Expand Down
14 changes: 7 additions & 7 deletions arch/sparc64/kernel/ds.c
Original file line number Diff line number Diff line change
Expand Up @@ -525,10 +525,10 @@ static void dr_cpu_mark(struct ds_data *resp, int cpu, int ncpus,
}
}

static int dr_cpu_configure(struct ds_info *dp,
struct ds_cap_state *cp,
u64 req_num,
cpumask_t *mask)
static int __cpuinit dr_cpu_configure(struct ds_info *dp,
struct ds_cap_state *cp,
u64 req_num,
cpumask_t *mask)
{
struct ds_data *resp;
int resp_len, ncpus, cpu;
Expand Down Expand Up @@ -623,9 +623,9 @@ static int dr_cpu_unconfigure(struct ds_info *dp,
return 0;
}

static void dr_cpu_data(struct ds_info *dp,
struct ds_cap_state *cp,
void *buf, int len)
static void __cpuinit dr_cpu_data(struct ds_info *dp,
struct ds_cap_state *cp,
void *buf, int len)
{
struct ds_data *data = buf;
struct dr_cpu_tag *tag = (struct dr_cpu_tag *) (data + 1);
Expand Down
2 changes: 1 addition & 1 deletion arch/sparc64/kernel/mdesc.c
Original file line number Diff line number Diff line change
Expand Up @@ -758,7 +758,7 @@ static void __devinit get_mondo_data(struct mdesc_handle *hp, u64 mp,
get_one_mondo_bits(val, &tb->nonresum_qmask, 2);
}

void __devinit mdesc_fill_in_cpu_data(cpumask_t mask)
void __cpuinit mdesc_fill_in_cpu_data(cpumask_t mask)
{
struct mdesc_handle *hp = mdesc_grab();
u64 mp;
Expand Down
14 changes: 3 additions & 11 deletions arch/sparc64/mm/fault.c
Original file line number Diff line number Diff line change
Expand Up @@ -244,16 +244,8 @@ static void do_kernel_fault(struct pt_regs *regs, int si_code, int fault_code,
if (regs->tstate & TSTATE_PRIV) {
const struct exception_table_entry *entry;

if (asi == ASI_P && (insn & 0xc0800000) == 0xc0800000) {
if (insn & 0x2000)
asi = (regs->tstate >> 24);
else
asi = (insn >> 5);
}

/* Look in asi.h: All _S asis have LS bit set */
if ((asi & 0x1) &&
(entry = search_exception_tables(regs->tpc))) {
entry = search_exception_tables(regs->tpc);
if (entry) {
regs->tpc = entry->fixup;
regs->tnpc = regs->tpc + 4;
return;
Expand Down Expand Up @@ -294,7 +286,7 @@ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs)
unsigned long tpc = regs->tpc;

/* Sanity check the PC. */
if ((tpc >= KERNBASE && tpc < (unsigned long) _etext) ||
if ((tpc >= KERNBASE && tpc < (unsigned long) __init_end) ||
(tpc >= MODULES_VADDR && tpc < MODULES_END)) {
/* Valid, no problems... */
} else {
Expand Down
3 changes: 2 additions & 1 deletion arch/sparc64/mm/init.c
Original file line number Diff line number Diff line change
Expand Up @@ -1010,7 +1010,8 @@ static struct linux_prom64_registers pall[MAX_BANKS] __initdata;
static int pall_ents __initdata;

#ifdef CONFIG_DEBUG_PAGEALLOC
static unsigned long kernel_map_range(unsigned long pstart, unsigned long pend, pgprot_t prot)
static unsigned long __ref kernel_map_range(unsigned long pstart,
unsigned long pend, pgprot_t prot)
{
unsigned long vstart = PAGE_OFFSET + pstart;
unsigned long vend = PAGE_OFFSET + pend;
Expand Down

0 comments on commit 547598d

Please sign in to comment.