From: Lai Jiangshan Date: Mon, 8 Mar 2010 06:50:43 +0000 (+0800) Subject: ring-buffer: Move disabled check into preempt disable section X-Git-Tag: v2.6.34-rc2~52^2~4 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=52fbe9cde7fdb5c6fac196d7ebd2d92d05ef3cd4;p=pandora-kernel.git ring-buffer: Move disabled check into preempt disable section The ring buffer resizing and resetting relies on a schedule RCU action. The buffers are disabled, a synchronize_sched() is called and then the resize or reset takes place. But this only works if the disabling of the buffers are within the preempt disabled section, otherwise a window exists that the buffers can be written to while a reset or resize takes place. Cc: stable@kernel.org Reported-by: Li Zefan Signed-off-by: Lai Jiangshan LKML-Reference: <4B949E43.2010906@cn.fujitsu.com> Signed-off-by: Steven Rostedt --- Reading git-diff-tree failed