Revert "s390/cpum_sf: Remove WARN_ON_ONCE statements"
This reverts commit 9c06859c81
.
This commit is contained in:
parent
923ea36cad
commit
ec15971004
1 changed files with 8 additions and 4 deletions
|
@ -1432,7 +1432,7 @@ static int aux_output_begin(struct perf_output_handle *handle,
|
|||
unsigned long head, base, offset;
|
||||
struct hws_trailer_entry *te;
|
||||
|
||||
if (handle->head & ~PAGE_MASK)
|
||||
if (WARN_ON_ONCE(handle->head & ~PAGE_MASK))
|
||||
return -EINVAL;
|
||||
|
||||
aux->head = handle->head >> PAGE_SHIFT;
|
||||
|
@ -1613,7 +1613,7 @@ static void hw_collect_aux(struct cpu_hw_sf *cpuhw)
|
|||
unsigned long num_sdb;
|
||||
|
||||
aux = perf_get_aux(handle);
|
||||
if (!aux)
|
||||
if (WARN_ON_ONCE(!aux))
|
||||
return;
|
||||
|
||||
/* Inform user space new data arrived */
|
||||
|
@ -1635,7 +1635,7 @@ static void hw_collect_aux(struct cpu_hw_sf *cpuhw)
|
|||
__func__);
|
||||
break;
|
||||
}
|
||||
if (!aux)
|
||||
if (WARN_ON_ONCE(!aux))
|
||||
return;
|
||||
|
||||
/* Update head and alert_mark to new position */
|
||||
|
@ -1870,8 +1870,12 @@ static void cpumsf_pmu_start(struct perf_event *event, int flags)
|
|||
{
|
||||
struct cpu_hw_sf *cpuhw = this_cpu_ptr(&cpu_hw_sf);
|
||||
|
||||
if (!(event->hw.state & PERF_HES_STOPPED))
|
||||
if (WARN_ON_ONCE(!(event->hw.state & PERF_HES_STOPPED)))
|
||||
return;
|
||||
|
||||
if (flags & PERF_EF_RELOAD)
|
||||
WARN_ON_ONCE(!(event->hw.state & PERF_HES_UPTODATE));
|
||||
|
||||
perf_pmu_disable(event->pmu);
|
||||
event->hw.state = 0;
|
||||
cpuhw->lsctl.cs = 1;
|
||||
|
|
Loading…
Reference in a new issue