Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

s390/cpum_cf: simplify pr_err() statement in cpumf_pmu_enable/disable

Simplify pr_err() statement into one line and omit return statement.

No functional change.

Signed-off-by: Thomas Richter <tmricht@linux.ibm.com>
Acked-by: Sumanth Korikkar <sumanthk@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>

authored by

Thomas Richter and committed by
Vasily Gorbik
c01f2a5f b3e0423c

+8 -14
+8 -14
arch/s390/kernel/perf_cpum_cf.c
··· 471 471 return; 472 472 473 473 err = lcctl(cpuhw->state | cpuhw->dev_state); 474 - if (err) { 475 - pr_err("Enabling the performance measuring unit " 476 - "failed with rc=%x\n", err); 477 - return; 478 - } 479 - 480 - cpuhw->flags |= PMU_F_ENABLED; 474 + if (err) 475 + pr_err("Enabling the performance measuring unit failed with rc=%x\n", err); 476 + else 477 + cpuhw->flags |= PMU_F_ENABLED; 481 478 } 482 479 483 480 /* ··· 494 497 inactive = cpuhw->state & ~((1 << CPUMF_LCCTL_ENABLE_SHIFT) - 1); 495 498 inactive |= cpuhw->dev_state; 496 499 err = lcctl(inactive); 497 - if (err) { 498 - pr_err("Disabling the performance measuring unit " 499 - "failed with rc=%x\n", err); 500 - return; 501 - } 502 - 503 - cpuhw->flags &= ~PMU_F_ENABLED; 500 + if (err) 501 + pr_err("Disabling the performance measuring unit failed with rc=%x\n", err); 502 + else 503 + cpuhw->flags &= ~PMU_F_ENABLED; 504 504 } 505 505 506 506 #define PMC_INIT 0UL