Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 179311
b: refs/heads/master
c: 926311f
h: refs/heads/master
i:
  179309: efe23b9
  179307: 74228f8
  179303: c489d16
  179295: 5280c12
v: v3
  • Loading branch information
Roel Kluin authored and Borislav Petkov committed Jan 15, 2010
1 parent c5f9a66 commit e0e4dc1
Show file tree
Hide file tree
Showing 117 changed files with 581 additions and 968 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: 3b3ef30833cc85982b0b7e950998d86f5e2d28cf
refs/heads/master: 926311fd7dabcd284a1e8a87a3e2bb5f929c0c60
3 changes: 2 additions & 1 deletion trunk/MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -410,8 +410,9 @@ F: drivers/i2c/busses/i2c-ali1563.c

ALPHA PORT
M: Richard Henderson <rth@twiddle.net>
S: Odd Fixes for 2.4; Maintained for 2.6.
M: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
M: Matt Turner <mattst88@gmail.com>
S: Maintained for 2.4; PCI support for 2.6.
L: linux-alpha@vger.kernel.org
F: arch/alpha/

Expand Down
3 changes: 2 additions & 1 deletion trunk/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ MAKEFLAGS += -rR --no-print-directory

# Avoid funny character set dependencies
unexport LC_ALL
LC_CTYPE=C
LC_COLLATE=C
LC_NUMERIC=C
export LC_COLLATE LC_NUMERIC
export LC_CTYPE LC_COLLATE LC_NUMERIC

# We are using a recursive build, so we need to do a little thinking
# to get the ordering right.
Expand Down
3 changes: 0 additions & 3 deletions trunk/arch/alpha/include/asm/topology.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ static const struct cpumask *cpumask_of_node(int node)
{
int cpu;

if (node == -1)
return cpu_all_mask;

cpumask_clear(&node_to_cpumask_map[node]);

for_each_online_cpu(cpu) {
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/arm/mach-davinci/include/mach/keyscan.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ enum davinci_matrix_types {
};

struct davinci_ks_platform_data {
int (*device_enable)(struct device *dev);
unsigned short *keymap;
u32 keymapsize;
u8 rep:1;
Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/powerpc/boot/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
all: $(obj)/zImage

BOOTCFLAGS := -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \
-fno-strict-aliasing -Os -msoft-float -pipe \
-fno-strict-aliasing -Os -msoft-float -pipe -D__KERNEL__\
-fomit-frame-pointer -fno-builtin -fPIC -nostdinc \
-isystem $(shell $(CROSS32CC) -print-file-name=include)
BOOTAFLAGS := -D__ASSEMBLY__ $(BOOTCFLAGS) -traditional -nostdinc
Expand All @@ -34,6 +34,8 @@ BOOTCFLAGS += -fno-stack-protector
endif

BOOTCFLAGS += -I$(obj) -I$(srctree)/$(obj)
BOOTCFLAGS += -include include/linux/autoconf.h -Iarch/powerpc/include
BOOTCFLAGS += -Iinclude

DTS_FLAGS ?= -p 1024

Expand Down
4 changes: 0 additions & 4 deletions trunk/arch/s390/include/asm/bug.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,6 @@
unreachable(); \
} while (0)

#define __WARN() do { \
__EMIT_BUG(BUGFLAG_WARNING); \
} while (0)

#define WARN_ON(x) ({ \
int __ret_warn_on = !!(x); \
if (__builtin_constant_p(__ret_warn_on)) { \
Expand Down
20 changes: 6 additions & 14 deletions trunk/arch/s390/include/asm/sigp.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,11 @@
#ifndef __SIGP__
#define __SIGP__

#include <asm/system.h>
#include <asm/ptrace.h>
#include <asm/atomic.h>

/* get real cpu address from logical cpu number */
extern int __cpu_logical_map[];

static inline int cpu_logical_map(int cpu)
{
#ifdef CONFIG_SMP
return __cpu_logical_map[cpu];
#else
return stap();
#endif
}
extern volatile int __cpu_logical_map[];

typedef enum
{
Expand Down Expand Up @@ -87,7 +79,7 @@ signal_processor(__u16 cpu_addr, sigp_order_code order_code)
" ipm %0\n"
" srl %0,28\n"
: "=d" (ccode)
: "d" (reg1), "d" (cpu_logical_map(cpu_addr)),
: "d" (reg1), "d" (__cpu_logical_map[cpu_addr]),
"a" (order_code) : "cc" , "memory");
return ccode;
}
Expand All @@ -106,7 +98,7 @@ signal_processor_p(__u32 parameter, __u16 cpu_addr, sigp_order_code order_code)
" ipm %0\n"
" srl %0,28\n"
: "=d" (ccode)
: "d" (reg1), "d" (cpu_logical_map(cpu_addr)),
: "d" (reg1), "d" (__cpu_logical_map[cpu_addr]),
"a" (order_code) : "cc" , "memory");
return ccode;
}
Expand All @@ -126,7 +118,7 @@ signal_processor_ps(__u32 *statusptr, __u32 parameter, __u16 cpu_addr,
" ipm %0\n"
" srl %0,28\n"
: "=d" (ccode), "+d" (reg1)
: "d" (cpu_logical_map(cpu_addr)), "a" (order_code)
: "d" (__cpu_logical_map[cpu_addr]), "a" (order_code)
: "cc" , "memory");
*statusptr = reg1;
return ccode;
Expand Down
12 changes: 7 additions & 5 deletions trunk/arch/s390/include/asm/thread_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,13 @@ static inline struct thread_info *current_thread_info(void)
#define TIF_SYSCALL_AUDIT 9 /* syscall auditing active */
#define TIF_SECCOMP 10 /* secure computing */
#define TIF_SYSCALL_TRACEPOINT 11 /* syscall tracepoint instrumentation */
#define TIF_POLLING_NRFLAG 16 /* true if poll_idle() is polling
#define TIF_USEDFPU 16 /* FPU was used by this task this quantum (SMP) */
#define TIF_POLLING_NRFLAG 17 /* true if poll_idle() is polling
TIF_NEED_RESCHED */
#define TIF_31BIT 17 /* 32bit process */
#define TIF_MEMDIE 18
#define TIF_RESTORE_SIGMASK 19 /* restore signal mask in do_signal() */
#define TIF_FREEZE 20 /* thread is freezing for suspend */
#define TIF_31BIT 18 /* 32bit process */
#define TIF_MEMDIE 19
#define TIF_RESTORE_SIGMASK 20 /* restore signal mask in do_signal() */
#define TIF_FREEZE 21 /* thread is freezing for suspend */

#define _TIF_NOTIFY_RESUME (1<<TIF_NOTIFY_RESUME)
#define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK)
Expand All @@ -111,6 +112,7 @@ static inline struct thread_info *current_thread_info(void)
#define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT)
#define _TIF_SECCOMP (1<<TIF_SECCOMP)
#define _TIF_SYSCALL_TRACEPOINT (1<<TIF_SYSCALL_TRACEPOINT)
#define _TIF_USEDFPU (1<<TIF_USEDFPU)
#define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG)
#define _TIF_31BIT (1<<TIF_31BIT)
#define _TIF_FREEZE (1<<TIF_FREEZE)
Expand Down
6 changes: 2 additions & 4 deletions trunk/arch/s390/include/asm/unistd.h
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,8 @@
#define __NR_pwritev 329
#define __NR_rt_tgsigqueueinfo 330
#define __NR_perf_event_open 331
#define NR_syscalls 332
#define __NR_recvmmsg 332
#define NR_syscalls 333

/*
* There are some system calls that are not present on 64 bit, some
Expand Down Expand Up @@ -376,9 +377,6 @@
#define __IGNORE_migrate_pages
#define __IGNORE_move_pages

/* Ignore system calls that are also reachable via sys_socket */
#define __IGNORE_recvmmsg

#define __ARCH_WANT_IPC_PARSE_VERSION
#define __ARCH_WANT_OLD_READDIR
#define __ARCH_WANT_SYS_ALARM
Expand Down
41 changes: 25 additions & 16 deletions trunk/arch/s390/kernel/compat_linux.c
Original file line number Diff line number Diff line change
Expand Up @@ -616,35 +616,44 @@ asmlinkage long sys32_fstatat64(unsigned int dfd, char __user *filename,
*/

struct mmap_arg_struct_emu31 {
compat_ulong_t addr;
compat_ulong_t len;
compat_ulong_t prot;
compat_ulong_t flags;
compat_ulong_t fd;
compat_ulong_t offset;
u32 addr;
u32 len;
u32 prot;
u32 flags;
u32 fd;
u32 offset;
};

asmlinkage unsigned long old32_mmap(struct mmap_arg_struct_emu31 __user *arg)
asmlinkage unsigned long
old32_mmap(struct mmap_arg_struct_emu31 __user *arg)
{
struct mmap_arg_struct_emu31 a;
int error = -EFAULT;

if (copy_from_user(&a, arg, sizeof(a)))
return -EFAULT;
goto out;

error = -EINVAL;
if (a.offset & ~PAGE_MASK)
return -EINVAL;
a.addr = (unsigned long) compat_ptr(a.addr);
return sys_mmap_pgoff(a.addr, a.len, a.prot, a.flags, a.fd,
a.offset >> PAGE_SHIFT);
goto out;

error = sys_mmap_pgoff(a.addr, a.len, a.prot, a.flags, a.fd,
a.offset >> PAGE_SHIFT);
out:
return error;
}

asmlinkage long sys32_mmap2(struct mmap_arg_struct_emu31 __user *arg)
asmlinkage long
sys32_mmap2(struct mmap_arg_struct_emu31 __user *arg)
{
struct mmap_arg_struct_emu31 a;
int error = -EFAULT;

if (copy_from_user(&a, arg, sizeof(a)))
return -EFAULT;
a.addr = (unsigned long) compat_ptr(a.addr);
return sys_mmap_pgoff(a.addr, a.len, a.prot, a.flags, a.fd, a.offset);
goto out;
error = sys_mmap_pgoff(a.addr, a.len, a.prot, a.flags, a.fd, a.offset);
out:
return error;
}

asmlinkage long sys32_read(unsigned int fd, char __user * buf, size_t count)
Expand Down
9 changes: 9 additions & 0 deletions trunk/arch/s390/kernel/compat_wrapper.S
Original file line number Diff line number Diff line change
Expand Up @@ -1853,3 +1853,12 @@ sys32_execve_wrapper:
llgtr %r3,%r3 # compat_uptr_t *
llgtr %r4,%r4 # compat_uptr_t *
jg sys32_execve # branch to system call

.globl compat_sys_recvmmsg_wrapper
compat_sys_recvmmsg_wrapper:
lgfr %r2,%r2 # int
llgtr %r3,%r3 # struct compat_mmsghdr *
llgfr %r4,%r4 # unsigned int
llgfr %r5,%r5 # unsigned int
llgtr %r6,%r6 # struct compat_timespec *
jg compat_sys_recvmmsg
3 changes: 2 additions & 1 deletion trunk/arch/s390/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,8 @@ void exit_thread(void)

void flush_thread(void)
{
clear_used_math();
clear_tsk_thread_flag(current, TIF_USEDFPU);
}

void release_thread(struct task_struct *dead_task)
Expand Down Expand Up @@ -215,7 +217,6 @@ int copy_thread(unsigned long clone_flags, unsigned long new_stackp,
p->thread.mm_segment = get_fs();
/* Don't copy debug registers */
memset(&p->thread.per_info, 0, sizeof(p->thread.per_info));
clear_tsk_thread_flag(p, TIF_SINGLE_STEP);
/* Initialize per thread user and system timer values */
ti = task_thread_info(p);
ti->user_timer = 0;
Expand Down
8 changes: 0 additions & 8 deletions trunk/arch/s390/kernel/ptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ FixPerRegisters(struct task_struct *task)
{
struct pt_regs *regs;
per_struct *per_info;
per_cr_words cr_words;

regs = task_pt_regs(task);
per_info = (per_struct *) &task->thread.per_info;
Expand Down Expand Up @@ -99,13 +98,6 @@ FixPerRegisters(struct task_struct *task)
per_info->control_regs.bits.storage_alt_space_ctl = 1;
else
per_info->control_regs.bits.storage_alt_space_ctl = 0;

if (task == current) {
__ctl_store(cr_words, 9, 11);
if (memcmp(&cr_words, &per_info->control_regs.words,
sizeof(cr_words)) != 0)
__ctl_load(per_info->control_regs.words, 9, 11);
}
}

void user_enable_single_step(struct task_struct *task)
Expand Down
8 changes: 8 additions & 0 deletions trunk/arch/s390/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ unsigned long elf_hwcap = 0;
char elf_platform[ELF_PLATFORM_SIZE];

struct mem_chunk __initdata memory_chunk[MEMORY_CHUNKS];
volatile int __cpu_logical_map[NR_CPUS]; /* logical cpu to cpu address */

int __initdata memory_end_set;
unsigned long __initdata memory_end;
Expand Down Expand Up @@ -123,6 +124,12 @@ void __cpuinit cpu_init(void)
*/
get_cpu_id(&S390_lowcore.cpu_id);

/*
* Force FPU initialization:
*/
clear_thread_flag(TIF_USEDFPU);
clear_used_math();

atomic_inc(&init_mm.mm_count);
current->active_mm = &init_mm;
BUG_ON(current->mm);
Expand Down Expand Up @@ -848,6 +855,7 @@ setup_arch(char **cmdline_p)
setup_lowcore();

cpu_init();
__cpu_logical_map[0] = stap();
s390_init_cpu_topology();

/*
Expand Down
10 changes: 9 additions & 1 deletion trunk/arch/s390/kernel/signal.c
Original file line number Diff line number Diff line change
Expand Up @@ -499,11 +499,19 @@ void do_signal(struct pt_regs *regs)
if (test_thread_flag(TIF_RESTORE_SIGMASK))
clear_thread_flag(TIF_RESTORE_SIGMASK);

/*
* If we would have taken a single-step trap
* for a normal instruction, act like we took
* one for the handler setup.
*/
if (current->thread.per_info.single_step)
set_thread_flag(TIF_SINGLE_STEP);

/*
* Let tracing know that we've done the handler setup.
*/
tracehook_signal_handler(signr, &info, &ka, regs,
current->thread.per_info.single_step);
test_thread_flag(TIF_SINGLE_STEP));
}
return;
}
Expand Down
9 changes: 0 additions & 9 deletions trunk/arch/s390/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,6 @@
#include <asm/cpu.h>
#include "entry.h"

/* logical cpu to cpu address */
int __cpu_logical_map[NR_CPUS];

static struct task_struct *current_set[NR_CPUS];

static u8 smp_cpu_type;
Expand Down Expand Up @@ -720,12 +717,6 @@ void __init smp_cpus_done(unsigned int max_cpus)
{
}

void __init smp_setup_processor_id(void)
{
S390_lowcore.cpu_nr = 0;
__cpu_logical_map[0] = stap();
}

/*
* the frequency of the profiling timer can be changed
* by writing a multiplier value into /proc/profile.
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/s390/kernel/syscalls.S
Original file line number Diff line number Diff line change
Expand Up @@ -340,3 +340,4 @@ SYSCALL(sys_preadv,sys_preadv,compat_sys_preadv_wrapper)
SYSCALL(sys_pwritev,sys_pwritev,compat_sys_pwritev_wrapper)
SYSCALL(sys_rt_tgsigqueueinfo,sys_rt_tgsigqueueinfo,compat_sys_rt_tgsigqueueinfo_wrapper) /* 330 */
SYSCALL(sys_perf_event_open,sys_perf_event_open,sys_perf_event_open_wrapper)
SYSCALL(sys_recvmmsg,sys_recvmmsg,compat_sys_recvmmsg_wrapper)
2 changes: 1 addition & 1 deletion trunk/arch/s390/kernel/topology.c
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ static void add_cpus_to_core(struct tl_cpu *tl_cpu, struct core_info *core)

rcpu = CPU_BITS - 1 - cpu + tl_cpu->origin;
for_each_present_cpu(lcpu) {
if (cpu_logical_map(lcpu) == rcpu) {
if (__cpu_logical_map[lcpu] == rcpu) {
cpu_set(lcpu, core->mask);
smp_cpu_polarization[lcpu] = tl_cpu->pp;
}
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/s390/lib/spinlock.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ static inline void _raw_yield_cpu(int cpu)
{
if (MACHINE_HAS_DIAG9C)
asm volatile("diag %0,0,0x9c"
: : "d" (cpu_logical_map(cpu)));
: : "d" (__cpu_logical_map[cpu]));
else
_raw_yield();
}
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/s390/mm/mmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@

static inline unsigned long mmap_base(void)
{
unsigned long gap = rlimit(RLIMIT_STACK);
unsigned long gap = current->signal->rlim[RLIMIT_STACK].rlim_cur;

if (gap < MIN_GAP)
gap = MIN_GAP;
Expand All @@ -61,7 +61,7 @@ static inline int mmap_is_legacy(void)
#endif
return sysctl_legacy_va_layout ||
(current->personality & ADDR_COMPAT_LAYOUT) ||
rlimit(RLIMIT_STACK) == RLIM_INFINITY;
current->signal->rlim[RLIMIT_STACK].rlim_cur == RLIM_INFINITY;
}

#ifndef CONFIG_64BIT
Expand Down
Loading

0 comments on commit e0e4dc1

Please sign in to comment.