]> git.baikalelectronics.ru Git - kernel.git/commit
tracing: fix mmiotrace resizing crash
authorIngo Molnar <mingo@elte.hu>
Thu, 13 Nov 2008 13:58:31 +0000 (14:58 +0100)
committerIngo Molnar <mingo@elte.hu>
Thu, 13 Nov 2008 13:58:31 +0000 (14:58 +0100)
commit4b9f1f9fc162f6cadc7e8c1a33f369ba380d881e
treea93d6dfeec829b61d6a74b5a9c841bcfeaeeb31d
parentd676eed1933f9f10cf89dd88429753848ebbd3bf
tracing: fix mmiotrace resizing crash

Pekka reported a crash when resizing the mmiotrace tracer (if only
mmiotrace is enabled).

This happens because in that case we do not allocate the max buffer,
but we try to use it.

Make ring_buffer_resize() idempotent against NULL buffers.

Reported-by: Pekka Paalanen <pq@iki.fi>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/trace/ring_buffer.c