Skip to content

Commit

Permalink
s390/cpum_sf: Assign error value to err variable
Browse files Browse the repository at this point in the history
When starting the CPU Measurement sampling facility using
qsi() function, this function may return an error value.
This error value is referenced in the else part of the
if statement to dump its value in a debug statement.
Right now this value is always zero because it has not been
assigned a value.

Signed-off-by: Thomas Richter <tmricht@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
  • Loading branch information
Thomas Richter authored and Vasily Gorbik committed Nov 12, 2019
1 parent c183883 commit 72fbcd0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/s390/kernel/perf_cpum_sf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1007,7 +1007,8 @@ static void cpumsf_pmu_disable(struct pmu *pmu)
}

/* Save state of TEAR and DEAR register contents */
if (!qsi(&si)) {
err = qsi(&si);
if (!err) {
/* TEAR/DEAR values are valid only if the sampling facility is
* enabled. Note that cpumsf_pmu_disable() might be called even
* for a disabled sampling facility because cpumsf_pmu_enable()
Expand Down

0 comments on commit 72fbcd0

Please sign in to comment.