From: Randy Witt Date: Thu, 17 Oct 2013 20:56:47 +0000 (-0400) Subject: serial_core: Don't re-initialize a previously initialized spinlock. X-Git-Tag: v3.14-rc1~149^2~61 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=42b6a1baa3ec18de2eb15baa250da6203eeb2d39;p=pandora-kernel.git serial_core: Don't re-initialize a previously initialized spinlock. The uart_set_options() code unconditionally initalizes the spinlock on the port. This can cause a deadlock in some situations. One instance that exposed the problem, was when writing to /sys/module/kgdboc/parameters/kgdboc to use ttyS0 when the console is already running on ttyS0. If the spinlock is re-initialized while the lock is held due to output to the console, there is a deadlock. Assume the spinlock is initialized if the port is a console. Signed-off-by: Randy Witt Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed