]> git.baikalelectronics.ru Git - kernel.git/commit
perf: Disallow sparse AUX allocations for non-SG PMUs in overwrite mode
authorAlexander Shishkin <alexander.shishkin@linux.intel.com>
Fri, 22 May 2015 15:30:20 +0000 (18:30 +0300)
committerIngo Molnar <mingo@kernel.org>
Wed, 27 May 2015 07:16:20 +0000 (09:16 +0200)
commit6ec6f0cfa453b956752a77d1ba224bbbb4bc1e1b
tree758ff1f596b92f1d424939fc09c72ae4f1a6ed5f
parent094072d8b8e05002ffe5382f2b9635c7904cb391
perf: Disallow sparse AUX allocations for non-SG PMUs in overwrite mode

PMUs that don't support hardware scatter tables require big contiguous
chunks of memory and a PMI to switch between them. However, in overwrite
using a PMI for this purpose adds extra overhead that the users would
like to avoid. Thus, in overwrite mode for such PMUs we can only allow
one contiguous chunk for the entire requested buffer.

This patch changes the behavior accordingly, so that if the buddy allocator
fails to come up with a single high-order chunk for the entire requested
buffer, the allocation will fail.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: acme@infradead.org
Cc: adrian.hunter@intel.com
Cc: hpa@zytor.com
Link: http://lkml.kernel.org/r/1432308626-18845-2-git-send-email-alexander.shishkin@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
kernel/events/ring_buffer.c