All of lore.kernel.org
 help / color / mirror / Atom feed
* [RESEND PATCH] cpufreq: unnecesary double free in pcc_cpufreq_do_osc
@ 2010-09-30 19:43 ` Davidlohr Bueso
  0 siblings, 0 replies; 11+ messages in thread
From: Davidlohr Bueso @ 2010-09-30 19:43 UTC (permalink / raw)
  To: davej, cpufreq; +Cc: LKML

x86, cpufreq: avoid an unnecessary double free when finished in pcc_cpufreq_do_osc()

There is no need to fall through the out_free label thus saving a kfree call.

Signed-off-by: Davidlohr Bueso <dave@gnu.org>
---
 arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c b/arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c
index 994230d..db7dc35 100644
--- a/arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c
+++ b/arch/x86/kernel/cpu/cpufreq/pcc-cpufreq.c
@@ -379,6 +379,8 @@ static int __init pcc_cpufreq_do_osc(acpi_handle *handle)
 	if (!(supported & 0x1))
 		return -ENODEV;
 
+	return ret;
+
 out_free:
 	kfree(output.pointer);
 	return ret;
-- 
1.7.0.4




^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2010-10-01  5:25 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-30 19:43 [RESEND PATCH] cpufreq: unnecesary double free in pcc_cpufreq_do_osc Davidlohr Bueso
2010-09-30 19:43 ` Davidlohr Bueso
2010-09-30 19:59 ` Pekka Enberg
2010-09-30 20:06   ` Dave Jones
2010-10-01  4:47     ` Pekka Enberg
2010-10-01  5:25       ` Dave Jones
2010-09-30 20:06   ` David Rientjes
2010-09-30 20:02 ` David Rientjes
2010-09-30 20:08   ` Dave Jones
2010-09-30 20:17     ` Davidlohr Bueso
2010-09-30 20:15   ` Davidlohr Bueso

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.