From: Robert Richter Date: Thu, 5 Apr 2012 16:24:42 +0000 (+0200) Subject: perf/x86: Fix cmpxchg() usage in amd_put_event_constraints() X-Git-Tag: v3.5-rc1~141^2~41 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5f09fc688936705b2020ca247df39ee27283668a;p=pandora-kernel.git perf/x86: Fix cmpxchg() usage in amd_put_event_constraints() Now the return value of cmpxchg() is used to match an event. The change removes the duplicate event comparison and traverses the list until an event was removed. This also fixes the following warning: arch/x86/kernel/cpu/perf_event_amd.c:170: warning: value computed is not used Signed-off-by: Robert Richter Signed-off-by: Peter Zijlstra Link: http://lkml.kernel.org/r/1333643084-26776-3-git-send-email-robert.richter@amd.com Signed-off-by: Ingo Molnar --- Reading git-diff-tree failed