Merge branch 'linus' into core/locking
Merge reason: Update to almost-final-.36 Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
+11
-2
@@ -931,6 +931,7 @@ static inline int
|
||||
remove_hrtimer(struct hrtimer *timer, struct hrtimer_clock_base *base)
|
||||
{
|
||||
if (hrtimer_is_queued(timer)) {
|
||||
unsigned long state;
|
||||
int reprogram;
|
||||
|
||||
/*
|
||||
@@ -944,8 +945,13 @@ remove_hrtimer(struct hrtimer *timer, struct hrtimer_clock_base *base)
|
||||
debug_deactivate(timer);
|
||||
timer_stats_hrtimer_clear_start_info(timer);
|
||||
reprogram = base->cpu_base == &__get_cpu_var(hrtimer_bases);
|
||||
__remove_hrtimer(timer, base, HRTIMER_STATE_INACTIVE,
|
||||
reprogram);
|
||||
/*
|
||||
* We must preserve the CALLBACK state flag here,
|
||||
* otherwise we could move the timer base in
|
||||
* switch_hrtimer_base.
|
||||
*/
|
||||
state = timer->state & HRTIMER_STATE_CALLBACK;
|
||||
__remove_hrtimer(timer, base, state, reprogram);
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
@@ -1231,6 +1237,9 @@ static void __run_hrtimer(struct hrtimer *timer, ktime_t *now)
|
||||
BUG_ON(timer->state != HRTIMER_STATE_CALLBACK);
|
||||
enqueue_hrtimer(timer, base);
|
||||
}
|
||||
|
||||
WARN_ON_ONCE(!(timer->state & HRTIMER_STATE_CALLBACK));
|
||||
|
||||
timer->state &= ~HRTIMER_STATE_CALLBACK;
|
||||
}
|
||||
|
||||
|
||||
@@ -1537,6 +1537,7 @@ static int __unlink_module(void *_mod)
|
||||
{
|
||||
struct module *mod = _mod;
|
||||
list_del(&mod->list);
|
||||
module_bug_cleanup(mod);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -2625,6 +2626,7 @@ static struct module *load_module(void __user *umod,
|
||||
if (err < 0)
|
||||
goto ddebug;
|
||||
|
||||
module_bug_finalize(info.hdr, info.sechdrs, mod);
|
||||
list_add_rcu(&mod->list, &modules);
|
||||
mutex_unlock(&module_mutex);
|
||||
|
||||
@@ -2650,6 +2652,8 @@ static struct module *load_module(void __user *umod,
|
||||
mutex_lock(&module_mutex);
|
||||
/* Unlink carefully: kallsyms could be walking list. */
|
||||
list_del_rcu(&mod->list);
|
||||
module_bug_cleanup(mod);
|
||||
|
||||
ddebug:
|
||||
if (!mod->taints)
|
||||
dynamic_debug_remove(info.debug);
|
||||
|
||||
+1
-3
@@ -2202,15 +2202,13 @@ static void perf_event_for_each(struct perf_event *event,
|
||||
static int perf_event_period(struct perf_event *event, u64 __user *arg)
|
||||
{
|
||||
struct perf_event_context *ctx = event->ctx;
|
||||
unsigned long size;
|
||||
int ret = 0;
|
||||
u64 value;
|
||||
|
||||
if (!event->attr.sample_period)
|
||||
return -EINVAL;
|
||||
|
||||
size = copy_from_user(&value, arg, sizeof(value));
|
||||
if (size != sizeof(value))
|
||||
if (copy_from_user(&value, arg, sizeof(value)))
|
||||
return -EFAULT;
|
||||
|
||||
if (!value)
|
||||
|
||||
@@ -2214,6 +2214,14 @@ int copy_siginfo_to_user(siginfo_t __user *to, siginfo_t *from)
|
||||
err |= __put_user(from->si_addr, &to->si_addr);
|
||||
#ifdef __ARCH_SI_TRAPNO
|
||||
err |= __put_user(from->si_trapno, &to->si_trapno);
|
||||
#endif
|
||||
#ifdef BUS_MCEERR_AO
|
||||
/*
|
||||
* Other callers might not initialize the si_lsb field,
|
||||
* so check explicitely for the right codes here.
|
||||
*/
|
||||
if (from->si_code == BUS_MCEERR_AR || from->si_code == BUS_MCEERR_AO)
|
||||
err |= __put_user(from->si_addr_lsb, &to->si_addr_lsb);
|
||||
#endif
|
||||
break;
|
||||
case __SI_CHLD:
|
||||
|
||||
+14
-3
@@ -365,9 +365,10 @@ call:
|
||||
EXPORT_SYMBOL_GPL(smp_call_function_any);
|
||||
|
||||
/**
|
||||
* __smp_call_function_single(): Run a function on another CPU
|
||||
* __smp_call_function_single(): Run a function on a specific CPU
|
||||
* @cpu: The CPU to run on.
|
||||
* @data: Pre-allocated and setup data structure
|
||||
* @wait: If true, wait until function has completed on specified CPU.
|
||||
*
|
||||
* Like smp_call_function_single(), but allow caller to pass in a
|
||||
* pre-allocated data structure. Useful for embedding @data inside
|
||||
@@ -376,8 +377,10 @@ EXPORT_SYMBOL_GPL(smp_call_function_any);
|
||||
void __smp_call_function_single(int cpu, struct call_single_data *data,
|
||||
int wait)
|
||||
{
|
||||
csd_lock(data);
|
||||
unsigned int this_cpu;
|
||||
unsigned long flags;
|
||||
|
||||
this_cpu = get_cpu();
|
||||
/*
|
||||
* Can deadlock when called with interrupts disabled.
|
||||
* We allow cpu's that are not yet online though, as no one else can
|
||||
@@ -387,7 +390,15 @@ void __smp_call_function_single(int cpu, struct call_single_data *data,
|
||||
WARN_ON_ONCE(cpu_online(smp_processor_id()) && wait && irqs_disabled()
|
||||
&& !oops_in_progress);
|
||||
|
||||
generic_exec_single(cpu, data, wait);
|
||||
if (cpu == this_cpu) {
|
||||
local_irq_save(flags);
|
||||
data->func(data->info);
|
||||
local_irq_restore(flags);
|
||||
} else {
|
||||
csd_lock(data);
|
||||
generic_exec_single(cpu, data, wait);
|
||||
}
|
||||
put_cpu();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+1
-1
@@ -2485,7 +2485,7 @@ static int __do_proc_doulongvec_minmax(void *data, struct ctl_table *table, int
|
||||
kbuf[left] = 0;
|
||||
}
|
||||
|
||||
for (; left && vleft--; i++, min++, max++, first=0) {
|
||||
for (; left && vleft--; i++, first = 0) {
|
||||
unsigned long val;
|
||||
|
||||
if (write) {
|
||||
|
||||
@@ -143,15 +143,6 @@ int sysctl_check_table(struct nsproxy *namespaces, struct ctl_table *table)
|
||||
if (!table->maxlen)
|
||||
set_fail(&fail, table, "No maxlen");
|
||||
}
|
||||
if ((table->proc_handler == proc_doulongvec_minmax) ||
|
||||
(table->proc_handler == proc_doulongvec_ms_jiffies_minmax)) {
|
||||
if (table->maxlen > sizeof (unsigned long)) {
|
||||
if (!table->extra1)
|
||||
set_fail(&fail, table, "No min");
|
||||
if (!table->extra2)
|
||||
set_fail(&fail, table, "No max");
|
||||
}
|
||||
}
|
||||
#ifdef CONFIG_PROC_SYSCTL
|
||||
if (table->procname && !table->proc_handler)
|
||||
set_fail(&fail, table, "No proc_handler");
|
||||
|
||||
@@ -405,7 +405,7 @@ static inline int test_time_stamp(u64 delta)
|
||||
#define BUF_MAX_DATA_SIZE (BUF_PAGE_SIZE - (sizeof(u32) * 2))
|
||||
|
||||
/* Max number of timestamps that can fit on a page */
|
||||
#define RB_TIMESTAMPS_PER_PAGE (BUF_PAGE_SIZE / RB_LEN_TIME_STAMP)
|
||||
#define RB_TIMESTAMPS_PER_PAGE (BUF_PAGE_SIZE / RB_LEN_TIME_EXTEND)
|
||||
|
||||
int ring_buffer_print_page_header(struct trace_seq *s)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user