Commit c796b205 authored by Aravind Gopalakrishnan's avatar Aravind Gopalakrishnan Committed by Ingo Molnar

perf/x86/amd/ibs: Convert force_ibs_eilvt_setup() to void

The caller of force_ibs_eilvt_setup() is ibs_eilvt_setup()
which does not care about the return values.

So mark it void and clean up the return statements.
Signed-off-by: default avatarAravind Gopalakrishnan <aravind.gopalakrishnan@amd.com>
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Cc: <hpa@zytor.com>
Cc: <paulus@samba.org>
Cc: <tglx@linutronix.de>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/1422037175-20957-1-git-send-email-aravind.gopalakrishnan@amd.comSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
parent 6a694a60
...@@ -796,7 +796,7 @@ static int setup_ibs_ctl(int ibs_eilvt_off) ...@@ -796,7 +796,7 @@ static int setup_ibs_ctl(int ibs_eilvt_off)
* the IBS interrupt vector is handled by perf_ibs_cpu_notifier that * the IBS interrupt vector is handled by perf_ibs_cpu_notifier that
* is using the new offset. * is using the new offset.
*/ */
static int force_ibs_eilvt_setup(void) static void force_ibs_eilvt_setup(void)
{ {
int offset; int offset;
int ret; int ret;
...@@ -811,26 +811,24 @@ static int force_ibs_eilvt_setup(void) ...@@ -811,26 +811,24 @@ static int force_ibs_eilvt_setup(void)
if (offset == APIC_EILVT_NR_MAX) { if (offset == APIC_EILVT_NR_MAX) {
printk(KERN_DEBUG "No EILVT entry available\n"); printk(KERN_DEBUG "No EILVT entry available\n");
return -EBUSY; return;
} }
ret = setup_ibs_ctl(offset); ret = setup_ibs_ctl(offset);
if (ret) if (ret)
goto out; goto out;
if (!ibs_eilvt_valid()) { if (!ibs_eilvt_valid())
ret = -EFAULT;
goto out; goto out;
}
pr_info("IBS: LVT offset %d assigned\n", offset); pr_info("IBS: LVT offset %d assigned\n", offset);
return 0; return;
out: out:
preempt_disable(); preempt_disable();
put_eilvt(offset); put_eilvt(offset);
preempt_enable(); preempt_enable();
return ret; return;
} }
static void ibs_eilvt_setup(void) static void ibs_eilvt_setup(void)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment