diff --git a/[refs] b/[refs] index 6b4f956323c1..09f450db0de7 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a17e18790a8c47113a73139d54a375dc9ccd8f08 +refs/heads/master: 15cbf627abcd93c3c668d5a92d58d9fec8f953dd diff --git a/trunk/arch/parisc/Kconfig b/trunk/arch/parisc/Kconfig index 524d9352f17e..f388dc68f605 100644 --- a/trunk/arch/parisc/Kconfig +++ b/trunk/arch/parisc/Kconfig @@ -18,7 +18,6 @@ config PARISC select BUG select HAVE_PERF_EVENTS select GENERIC_ATOMIC64 if !64BIT - select HAVE_ARCH_TRACEHOOK help The PA-RISC microprocessor is designed by Hewlett-Packard and used in many of their workstations & servers (HP9000 700 and 800 series, diff --git a/trunk/arch/x86/include/asm/processor.h b/trunk/arch/x86/include/asm/processor.h index b753ea59703a..fc801bab1b3b 100644 --- a/trunk/arch/x86/include/asm/processor.h +++ b/trunk/arch/x86/include/asm/processor.h @@ -450,8 +450,6 @@ struct thread_struct { struct perf_event *ptrace_bps[HBP_NUM]; /* Debug status used for traps, single steps, etc... */ unsigned long debugreg6; - /* Keep track of the exact dr7 value set by the user */ - unsigned long ptrace_dr7; /* Fault info: */ unsigned long cr2; unsigned long trap_no; diff --git a/trunk/arch/x86/kernel/hw_breakpoint.c b/trunk/arch/x86/kernel/hw_breakpoint.c index bb6006e3e295..05d5fec64a94 100644 --- a/trunk/arch/x86/kernel/hw_breakpoint.c +++ b/trunk/arch/x86/kernel/hw_breakpoint.c @@ -212,6 +212,25 @@ static int arch_check_va_in_kernelspace(unsigned long va, u8 hbp_len) return (va >= TASK_SIZE) && ((va + len - 1) >= TASK_SIZE); } +/* + * Store a breakpoint's encoded address, length, and type. + */ +static int arch_store_info(struct perf_event *bp) +{ + struct arch_hw_breakpoint *info = counter_arch_bp(bp); + /* + * For kernel-addresses, either the address or symbol name can be + * specified. + */ + if (info->name) + info->address = (unsigned long) + kallsyms_lookup_name(info->name); + if (info->address) + return 0; + + return -EINVAL; +} + int arch_bp_generic_fields(int x86_len, int x86_type, int *gen_len, int *gen_type) { @@ -343,13 +362,10 @@ int arch_validate_hwbkpt_settings(struct perf_event *bp, return ret; } - /* - * For kernel-addresses, either the address or symbol name can be - * specified. - */ - if (info->name) - info->address = (unsigned long) - kallsyms_lookup_name(info->name); + ret = arch_store_info(bp); + + if (ret < 0) + return ret; /* * Check that the low-order bits of the address are appropriate * for the alignment implied by len. diff --git a/trunk/arch/x86/kernel/ptrace.c b/trunk/arch/x86/kernel/ptrace.c index 0c1033d61e59..017d937639fe 100644 --- a/trunk/arch/x86/kernel/ptrace.c +++ b/trunk/arch/x86/kernel/ptrace.c @@ -702,7 +702,7 @@ static unsigned long ptrace_get_debugreg(struct task_struct *tsk, int n) } else if (n == 6) { val = thread->debugreg6; } else if (n == 7) { - val = thread->ptrace_dr7; + val = ptrace_get_dr7(thread->ptrace_bps); } return val; } @@ -778,11 +778,8 @@ int ptrace_set_debugreg(struct task_struct *tsk, int n, unsigned long val) return rc; } /* All that's left is DR7 */ - if (n == 7) { + if (n == 7) rc = ptrace_write_dr7(tsk, val); - if (!rc) - thread->ptrace_dr7 = val; - } ret_path: return rc; diff --git a/trunk/drivers/clocksource/cs5535-clockevt.c b/trunk/drivers/clocksource/cs5535-clockevt.c index b314a999aabe..27d20fac19d1 100644 --- a/trunk/drivers/clocksource/cs5535-clockevt.c +++ b/trunk/drivers/clocksource/cs5535-clockevt.c @@ -21,7 +21,7 @@ #define DRV_NAME "cs5535-clockevt" -static int timer_irq; +static int timer_irq = CONFIG_CS5535_MFGPT_DEFAULT_IRQ; module_param_named(irq, timer_irq, int, 0644); MODULE_PARM_DESC(irq, "Which IRQ to use for the clock source MFGPT ticks."); diff --git a/trunk/drivers/video/efifb.c b/trunk/drivers/video/efifb.c index d25df51bb0d2..eb12182b2059 100644 --- a/trunk/drivers/video/efifb.c +++ b/trunk/drivers/video/efifb.c @@ -161,17 +161,8 @@ static int efifb_setcolreg(unsigned regno, unsigned red, unsigned green, return 0; } -static void efifb_destroy(struct fb_info *info) -{ - if (info->screen_base) - iounmap(info->screen_base); - release_mem_region(info->aperture_base, info->aperture_size); - framebuffer_release(info); -} - static struct fb_ops efifb_ops = { .owner = THIS_MODULE, - .fb_destroy = efifb_destroy, .fb_setcolreg = efifb_setcolreg, .fb_fillrect = cfb_fillrect, .fb_copyarea = cfb_copyarea, @@ -290,7 +281,7 @@ static int __init efifb_probe(struct platform_device *dev) info->par = NULL; info->aperture_base = efifb_fix.smem_start; - info->aperture_size = size_remap; + info->aperture_size = size_total; info->screen_base = ioremap(efifb_fix.smem_start, efifb_fix.smem_len); if (!info->screen_base) { diff --git a/trunk/fs/exec.c b/trunk/fs/exec.c index cce6bbdbdbb1..e95c692ef0e4 100644 --- a/trunk/fs/exec.c +++ b/trunk/fs/exec.c @@ -637,6 +637,7 @@ int setup_arg_pages(struct linux_binprm *bprm, * will align it up. */ rlim_stack = rlimit(RLIMIT_STACK) & PAGE_MASK; + rlim_stack = min(rlim_stack, stack_size); #ifdef CONFIG_STACK_GROWSUP if (stack_size + stack_expand > rlim_stack) stack_base = vma->vm_start + rlim_stack; diff --git a/trunk/kernel/perf_event.c b/trunk/kernel/perf_event.c index 2ae7409bf38f..2b19297742cb 100644 --- a/trunk/kernel/perf_event.c +++ b/trunk/kernel/perf_event.c @@ -3259,6 +3259,8 @@ static void perf_event_task_output(struct perf_event *event, task_event->event_id.tid = perf_event_tid(event, task); task_event->event_id.ptid = perf_event_tid(event, current); + task_event->event_id.time = perf_clock(); + perf_output_put(&handle, task_event->event_id); perf_output_end(&handle); @@ -3266,7 +3268,7 @@ static void perf_event_task_output(struct perf_event *event, static int perf_event_task_match(struct perf_event *event) { - if (event->state < PERF_EVENT_STATE_INACTIVE) + if (event->state != PERF_EVENT_STATE_ACTIVE) return 0; if (event->cpu != -1 && event->cpu != smp_processor_id()) @@ -3298,7 +3300,7 @@ static void perf_event_task_event(struct perf_task_event *task_event) cpuctx = &get_cpu_var(perf_cpu_context); perf_event_task_ctx(&cpuctx->ctx, task_event); if (!ctx) - ctx = rcu_dereference(current->perf_event_ctxp); + ctx = rcu_dereference(task_event->task->perf_event_ctxp); if (ctx) perf_event_task_ctx(ctx, task_event); put_cpu_var(perf_cpu_context); @@ -3329,7 +3331,6 @@ static void perf_event_task(struct task_struct *task, /* .ppid */ /* .tid */ /* .ptid */ - .time = perf_clock(), }, }; @@ -3379,7 +3380,7 @@ static void perf_event_comm_output(struct perf_event *event, static int perf_event_comm_match(struct perf_event *event) { - if (event->state < PERF_EVENT_STATE_INACTIVE) + if (event->state != PERF_EVENT_STATE_ACTIVE) return 0; if (event->cpu != -1 && event->cpu != smp_processor_id()) @@ -3499,7 +3500,7 @@ static void perf_event_mmap_output(struct perf_event *event, static int perf_event_mmap_match(struct perf_event *event, struct perf_mmap_event *mmap_event) { - if (event->state < PERF_EVENT_STATE_INACTIVE) + if (event->state != PERF_EVENT_STATE_ACTIVE) return 0; if (event->cpu != -1 && event->cpu != smp_processor_id()) diff --git a/trunk/kernel/sys.c b/trunk/kernel/sys.c index 18bde979f346..26a6b73a6b85 100644 --- a/trunk/kernel/sys.c +++ b/trunk/kernel/sys.c @@ -222,7 +222,6 @@ SYSCALL_DEFINE2(getpriority, int, which, int, who) if (which > PRIO_USER || which < PRIO_PROCESS) return -EINVAL; - rcu_read_lock(); read_lock(&tasklist_lock); switch (which) { case PRIO_PROCESS: @@ -268,7 +267,6 @@ SYSCALL_DEFINE2(getpriority, int, which, int, who) } out_unlock: read_unlock(&tasklist_lock); - rcu_read_unlock(); return retval; } diff --git a/trunk/lib/idr.c b/trunk/lib/idr.c index 0dc782216d4b..1cac726c44bc 100644 --- a/trunk/lib/idr.c +++ b/trunk/lib/idr.c @@ -156,12 +156,10 @@ static int sub_alloc(struct idr *idp, int *starting_id, struct idr_layer **pa) id = (id | ((1 << (IDR_BITS * l)) - 1)) + 1; /* if already at the top layer, we need to grow */ - if (id >= 1 << (idp->layers * IDR_BITS)) { + if (!(p = pa[l])) { *starting_id = id; return IDR_NEED_TO_GROW; } - p = pa[l]; - BUG_ON(!p); /* If we need to go up one layer, continue the * loop; otherwise, restart from the top. diff --git a/trunk/mm/oom_kill.c b/trunk/mm/oom_kill.c index 237050478f28..f52481b1c1e5 100644 --- a/trunk/mm/oom_kill.c +++ b/trunk/mm/oom_kill.c @@ -459,8 +459,6 @@ static int oom_kill_process(struct task_struct *p, gfp_t gfp_mask, int order, list_for_each_entry(c, &p->children, sibling) { if (c->mm == p->mm) continue; - if (mem && !task_in_mem_cgroup(c, mem)) - continue; if (!oom_kill_task(c)) return 0; } diff --git a/trunk/tools/perf/util/probe-event.c b/trunk/tools/perf/util/probe-event.c index fde17b090a47..29465d440043 100644 --- a/trunk/tools/perf/util/probe-event.c +++ b/trunk/tools/perf/util/probe-event.c @@ -272,7 +272,6 @@ int synthesize_perf_probe_point(struct probe_point *pp) int ret; pp->probes[0] = buf = zalloc(MAX_CMDLEN); - pp->found = 1; if (!buf) die("Failed to allocate memory by zalloc."); if (pp->offset) { @@ -295,7 +294,6 @@ int synthesize_perf_probe_point(struct probe_point *pp) error: free(pp->probes[0]); pp->probes[0] = NULL; - pp->found = 0; } return ret; } @@ -457,7 +455,6 @@ void show_perf_probe_events(void) struct strlist *rawlist; struct str_node *ent; - memset(&pp, 0, sizeof(pp)); fd = open_kprobe_events(O_RDONLY, 0); rawlist = get_trace_kprobe_event_rawlist(fd); close(fd);