Loading kernel/perf_event.c +13 −11 Original line number Diff line number Diff line Loading @@ -4917,12 +4917,15 @@ static enum hrtimer_restart perf_swevent_hrtimer(struct hrtimer *hrtimer) static void perf_swevent_start_hrtimer(struct perf_event *event) { struct hw_perf_event *hwc = &event->hw; s64 period; if (!is_sampling_event(event)) return; hrtimer_init(&hwc->hrtimer, CLOCK_MONOTONIC, HRTIMER_MODE_REL); hwc->hrtimer.function = perf_swevent_hrtimer; if (is_sampling_event(event)) { s64 period = local64_read(&hwc->period_left); period = local64_read(&hwc->period_left); if (period) { if (period < 0) period = 10000; Loading @@ -4935,7 +4938,6 @@ static void perf_swevent_start_hrtimer(struct perf_event *event) ns_to_ktime(period), 0, HRTIMER_MODE_REL_PINNED, 0); } } static void perf_swevent_cancel_hrtimer(struct perf_event *event) { Loading Loading
kernel/perf_event.c +13 −11 Original line number Diff line number Diff line Loading @@ -4917,12 +4917,15 @@ static enum hrtimer_restart perf_swevent_hrtimer(struct hrtimer *hrtimer) static void perf_swevent_start_hrtimer(struct perf_event *event) { struct hw_perf_event *hwc = &event->hw; s64 period; if (!is_sampling_event(event)) return; hrtimer_init(&hwc->hrtimer, CLOCK_MONOTONIC, HRTIMER_MODE_REL); hwc->hrtimer.function = perf_swevent_hrtimer; if (is_sampling_event(event)) { s64 period = local64_read(&hwc->period_left); period = local64_read(&hwc->period_left); if (period) { if (period < 0) period = 10000; Loading @@ -4935,7 +4938,6 @@ static void perf_swevent_start_hrtimer(struct perf_event *event) ns_to_ktime(period), 0, HRTIMER_MODE_REL_PINNED, 0); } } static void perf_swevent_cancel_hrtimer(struct perf_event *event) { Loading