Commit 046e9c3b authored by Linus Torvalds's avatar Linus Torvalds

Merge master.kernel.org:/home/davem/BK/sparc-2.5

into home.transmeta.com:/home/torvalds/v2.5/linux
parents 8f009a86 12f10fbf
......@@ -208,6 +208,8 @@ if [ "$CONFIG_NET" = "y" ]; then
endmenu
fi
source net/ax25/Config.in
# This one must be before the filesystem configs. -DaveM
mainmenu_option next_comment
comment 'Unix98 PTY support'
......
......@@ -46,6 +46,9 @@
#include <asm/sbus.h>
#include <asm/dma.h>
#endif
#ifdef CONFIG_PCI
#include <asm/ebus.h>
#endif
#include <asm/a.out.h>
#include <asm/io-unit.h>
......@@ -183,10 +186,7 @@ EXPORT_SYMBOL(sbus_iounmap);
EXPORT_SYMBOL(sbus_ioremap);
#endif
#if CONFIG_PCI
/* Actually, ioremap/iounmap are not PCI specific. But it is ok for drivers. */
EXPORT_SYMBOL(ioremap);
EXPORT_SYMBOL(iounmap);
EXPORT_SYMBOL(ebus_chain);
EXPORT_SYMBOL(insl);
EXPORT_SYMBOL(outsl);
EXPORT_SYMBOL(pci_alloc_consistent);
......@@ -194,6 +194,9 @@ EXPORT_SYMBOL(pci_free_consistent);
EXPORT_SYMBOL(pci_map_single);
EXPORT_SYMBOL(pci_unmap_single);
EXPORT_SYMBOL(pci_dma_sync_single);
/* Actually, ioremap/iounmap are not PCI specific. But it is ok for drivers. */
EXPORT_SYMBOL(ioremap);
EXPORT_SYMBOL(iounmap);
#endif
/* Solaris/SunOS binary compatibility */
......
......@@ -8,6 +8,8 @@
# Copyright (C) 1998 Jakub Jelinek (jj@ultra.linux.cz)
#
AFLAGS_vmlinux.lds.o += -Usparc
# If the solaris /bin/sh wasn't so broken, I wouldn't need the following
# line...
SHELL =/bin/bash
......
......@@ -221,6 +221,8 @@ if [ "$CONFIG_NET" = "y" ]; then
endmenu
fi
source net/ax25/Config.in
# This one must be before the filesystem configs. -DaveM
mainmenu_option next_comment
comment 'Unix 98 PTY support'
......
......@@ -19,7 +19,7 @@ CONFIG_SYSCTL=y
# Loadable module support
#
CONFIG_MODULES=y
# CONFIG_MODVERSIONS is not set
CONFIG_MODVERSIONS=y
CONFIG_KMOD=y
#
......@@ -485,7 +485,6 @@ CONFIG_E100=m
# CONFIG_LNE390 is not set
CONFIG_FEALNX=m
CONFIG_NATSEMI=m
# CONFIG_NATSEMI_CABLE_MAGIC is not set
CONFIG_NE2K_PCI=m
# CONFIG_NE3210 is not set
# CONFIG_ES3210 is not set
......@@ -566,6 +565,34 @@ CONFIG_DE4X5=m
CONFIG_WINBOND_840=m
# CONFIG_DM9102 is not set
#
# Amateur Radio support
#
CONFIG_HAMRADIO=y
#
# Packet Radio protocols
#
CONFIG_AX25=m
CONFIG_AX25_DAMA_SLAVE=y
CONFIG_NETROM=m
CONFIG_ROSE=m
#
# AX.25 network device drivers
#
# CONFIG_MKISS is not set
# CONFIG_6PACK is not set
# CONFIG_BPQETHER is not set
# CONFIG_SCC_DELAY is not set
# CONFIG_SCC_TRXECHO is not set
# CONFIG_BAYCOM_SER_FDX is not set
# CONFIG_BAYCOM_SER_HDX is not set
# CONFIG_BAYCOM_PAR is not set
# CONFIG_BAYCOM_EPP is not set
# CONFIG_SOUNDMODEM is not set
# CONFIG_YAM is not set
#
# Unix 98 PTY support
#
......
......@@ -1566,17 +1566,14 @@ void user_instruction_dump (unsigned int *pc)
printk("\n");
}
void show_trace_task(struct task_struct *tsk)
void show_trace_raw(struct thread_info *tp, unsigned long ksp)
{
unsigned long pc, fp;
unsigned long thread_base = (unsigned long) tsk->thread_info;
unsigned long pc, fp, thread_base;
struct reg_window *rw;
int count = 0;
if (!tsk)
return;
fp = tsk->thread_info->ksp + STACK_BIAS;
fp = ksp + STACK_BIAS;
thread_base = (unsigned long) tp;
do {
/* Bogus frame pointer? */
if (fp < (thread_base + sizeof(struct thread_info)) ||
......@@ -1590,6 +1587,13 @@ void show_trace_task(struct task_struct *tsk)
printk("\n");
}
void show_trace_task(struct task_struct *tsk)
{
if (tsk)
show_trace_raw(tsk->thread_info,
tsk->thread_info->ksp);
}
void die_if_kernel(char *str, struct pt_regs *regs)
{
extern void __show_regs(struct pt_regs * regs);
......
......@@ -130,8 +130,8 @@ unsigned long __init prom_probe_memory (void)
return tally;
}
void unhandled_fault(unsigned long address, struct task_struct *tsk,
struct pt_regs *regs)
static void unhandled_fault(unsigned long address, struct task_struct *tsk,
struct pt_regs *regs)
{
if ((unsigned long) address < PAGE_SIZE) {
printk(KERN_ALERT "Unable to handle kernel NULL "
......@@ -148,6 +148,19 @@ void unhandled_fault(unsigned long address, struct task_struct *tsk,
die_if_kernel("Oops", regs);
}
extern void show_trace_raw(struct thread_info *, unsigned long);
static void bad_kernel_pc(struct pt_regs *regs)
{
unsigned long ksp;
printk(KERN_CRIT "OOPS: Bogus kernel PC [%016lx] in fault handler\n",
regs->tpc);
__asm__("mov %%sp, %0" : "=r" (ksp));
show_trace_raw(current_thread_info(), ksp);
unhandled_fault(regs->tpc, current, regs);
}
/*
* We now make sure that mmap_sem is held in all paths that call
* this. Additionally, to prevent kswapd from ripping ptes from
......@@ -215,7 +228,7 @@ static inline unsigned int get_fault_insn(struct pt_regs *regs, unsigned int ins
if (!regs->tpc || (regs->tpc & 0x3))
return 0;
if (regs->tstate & TSTATE_PRIV) {
insn = *(unsigned int *)regs->tpc;
insn = *(unsigned int *) regs->tpc;
} else {
insn = get_user_insn(regs->tpc);
}
......@@ -306,6 +319,20 @@ asmlinkage void do_sparc64_fault(struct pt_regs *regs)
(fault_code & FAULT_CODE_DTLB))
BUG();
if (regs->tstate & TSTATE_PRIV) {
unsigned long tpc = regs->tpc;
extern unsigned int _etext;
/* Sanity check the PC. */
if ((tpc >= KERNBASE && tpc < (unsigned long) &_etext) ||
(tpc >= MODULES_VADDR && tpc < MODULES_END)) {
/* Valid, no problems... */
} else {
bad_kernel_pc(regs);
return;
}
}
/*
* If we're in an interrupt or have no user
* context, we must not take the fault..
......@@ -314,7 +341,8 @@ asmlinkage void do_sparc64_fault(struct pt_regs *regs)
goto intr_or_no_mm;
if (test_thread_flag(TIF_32BIT)) {
regs->tpc &= 0xffffffff;
if (!(regs->tstate & TSTATE_PRIV))
regs->tpc &= 0xffffffff;
address &= 0xffffffff;
}
......
......@@ -76,6 +76,7 @@
#include <asm/system.h>
#ifdef __sparc__
#include <linux/pci.h>
#include <asm/ebus.h>
#ifdef __sparc_v9__
#include <asm/isa.h>
......
......@@ -18,7 +18,7 @@ if [ "$CONFIG_EXPERIMENTAL" = "y" ]; then
# XXX Why don't we do "source drivers/char/Config.in" somewhere?
if [ "$CONFIG_PCI" = "y" ]; then
define_bool CONFIG_APM_RTC_IS_GMT y # no shit
bool 'PC-style RTC' CONFIG_RTC
tristate 'PC-style Real Time Clock Support' CONFIG_RTC
fi
fi
fi
......
......@@ -152,24 +152,6 @@ do { spin_unlock_irq(&(prev)->switch_lock); \
#define task_running(rq, p) \
((rq)->curr == (p) || spin_is_locked(&(p)->switch_lock))
#ifndef CONFIG_DEBUG_SPINLOCK
#define CHECK_LOCKS(PREV) do { } while(0)
#else /* CONFIG_DEBUG_SPINLOCK */
#define CHECK_LOCKS(PREV) \
if ((PREV)->thread.smp_lock_count) { \
unsigned long rpc; \
__asm__ __volatile__("mov %%i7, %0" : "=r" (rpc)); \
printk(KERN_CRIT "(%s)[%d]: Sleeping with %d locks held!\n", \
(PREV)->comm, (PREV)->pid, \
(PREV)->thread.smp_lock_count); \
printk(KERN_CRIT "(%s)[%d]: Last lock at %08x\n", \
(PREV)->comm, (PREV)->pid, \
(PREV)->thread.smp_lock_pc); \
printk(KERN_CRIT "(%s)[%d]: Sched caller %016lx\n", \
(PREV)->comm, (PREV)->pid, rpc); \
}
#endif /* !(CONFIG_DEBUG_SPINLOCK) */
/* See what happens when you design the chip correctly?
*
* We tell gcc we clobber all non-fixed-usage registers except
......@@ -180,8 +162,7 @@ if ((PREV)->thread.smp_lock_count) { \
* and 2 stores in this critical code path. -DaveM
*/
#define switch_to(prev, next, last) \
do { CHECK_LOCKS(prev); \
if (test_thread_flag(TIF_PERFCTR)) { \
do { if (test_thread_flag(TIF_PERFCTR)) { \
unsigned long __tmp; \
read_pcr(__tmp); \
current_thread_info()->pcr_reg = __tmp; \
......
......@@ -70,6 +70,14 @@ int max_queued_signals = 1024;
| SIGWINCH | load-balance | ignore |
| SIGPWR | load-balance | kill-all |
| SIGRTMIN-SIGRTMAX | load-balance | kill-all |
----------------------------------------------------------
non-POSIX signal thread group behavior:
----------------------------------------------------------
| | userspace | kernel |
----------------------------------------------------------
| SIGEMT | specific | kill-all+core |
----------------------------------------------------------
*/
......@@ -82,12 +90,19 @@ int max_queued_signals = 1024;
#define M_SIGSTKFLT 0
#endif
#ifdef SIGEMT
#define M_SIGEMT M(SIGEMT)
#else
#define M_SIGEMT 0
#endif
#define M(sig) (1UL << (sig))
#define SIG_USER_SPECIFIC_MASK (\
M(SIGILL) | M(SIGTRAP) | M(SIGABRT) | M(SIGBUS) | \
M(SIGFPE) | M(SIGSEGV) | M(SIGPIPE) | M(SIGXFSZ) | \
M(SIGPROF) | M(SIGSYS) | M_SIGSTKFLT | M(SIGCONT) )
M(SIGPROF) | M(SIGSYS) | M_SIGSTKFLT | M(SIGCONT) | \
M_SIGEMT )
#define SIG_USER_LOAD_BALANCE_MASK (\
M(SIGHUP) | M(SIGINT) | M(SIGQUIT) | M(SIGUSR1) | \
......@@ -105,7 +120,8 @@ int max_queued_signals = 1024;
M(SIGPIPE) | M(SIGALRM) | M(SIGTERM) | M(SIGXCPU) | \
M(SIGXFSZ) | M(SIGVTALRM) | M(SIGPROF) | M(SIGPOLL) | \
M(SIGSYS) | M_SIGSTKFLT | M(SIGPWR) | M(SIGCONT) | \
M(SIGSTOP) | M(SIGTSTP) | M(SIGTTIN) | M(SIGTTOU) )
M(SIGSTOP) | M(SIGTSTP) | M(SIGTTIN) | M(SIGTTOU) | \
M_SIGEMT )
#define SIG_KERNEL_ONLY_MASK (\
M(SIGKILL) | M(SIGSTOP) )
......@@ -113,7 +129,7 @@ int max_queued_signals = 1024;
#define SIG_KERNEL_COREDUMP_MASK (\
M(SIGQUIT) | M(SIGILL) | M(SIGTRAP) | M(SIGABRT) | \
M(SIGFPE) | M(SIGSEGV) | M(SIGBUS) | M(SIGSYS) | \
M(SIGXCPU) | M(SIGXFSZ) )
M(SIGXCPU) | M(SIGXFSZ) | M_SIGEMT )
#define T(sig, mask) \
((1UL << (sig)) & mask)
......
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