mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
Merge branch 'linus' into perf/core, to pick up fixes
Signed-off-by: Ingo Molnar <[email protected]>
This commit is contained in:
commit
9ed8f1a6e7
756 changed files with 7346 additions and 3904 deletions
|
|
@ -4968,6 +4968,11 @@ static void __perf_event_period(struct perf_event *event,
|
|||
}
|
||||
}
|
||||
|
||||
static int perf_event_check_period(struct perf_event *event, u64 value)
|
||||
{
|
||||
return event->pmu->check_period(event, value);
|
||||
}
|
||||
|
||||
static int perf_event_period(struct perf_event *event, u64 __user *arg)
|
||||
{
|
||||
u64 value;
|
||||
|
|
@ -4984,6 +4989,9 @@ static int perf_event_period(struct perf_event *event, u64 __user *arg)
|
|||
if (event->attr.freq && value > sysctl_perf_event_sample_rate)
|
||||
return -EINVAL;
|
||||
|
||||
if (perf_event_check_period(event, value))
|
||||
return -EINVAL;
|
||||
|
||||
event_function_call(event, __perf_event_period, &value);
|
||||
|
||||
return 0;
|
||||
|
|
@ -9600,6 +9608,11 @@ static int perf_pmu_nop_int(struct pmu *pmu)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int perf_event_nop_int(struct perf_event *event, u64 value)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static DEFINE_PER_CPU(unsigned int, nop_txn_flags);
|
||||
|
||||
static void perf_pmu_start_txn(struct pmu *pmu, unsigned int flags)
|
||||
|
|
@ -9900,6 +9913,9 @@ got_cpu_context:
|
|||
pmu->pmu_disable = perf_pmu_nop_void;
|
||||
}
|
||||
|
||||
if (!pmu->check_period)
|
||||
pmu->check_period = perf_event_nop_int;
|
||||
|
||||
if (!pmu->event_idx)
|
||||
pmu->event_idx = perf_event_idx_default;
|
||||
|
||||
|
|
|
|||
|
|
@ -733,7 +733,7 @@ struct ring_buffer *rb_alloc(int nr_pages, long watermark, int cpu, int flags)
|
|||
size = sizeof(struct ring_buffer);
|
||||
size += nr_pages * sizeof(void *);
|
||||
|
||||
if (order_base_2(size) >= MAX_ORDER)
|
||||
if (order_base_2(size) >= PAGE_SHIFT+MAX_ORDER)
|
||||
goto fail;
|
||||
|
||||
rb = kzalloc(size, GFP_KERNEL);
|
||||
|
|
|
|||
Loading…
Reference in a new issue