summaryrefslogtreecommitdiffstats
path: root/drivers/tty
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty')
-rw-r--r--drivers/tty/serial/serial_core.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c
index d529b5ce66c7..a333c59cba2c 100644
--- a/drivers/tty/serial/serial_core.c
+++ b/drivers/tty/serial/serial_core.c
@@ -95,9 +95,7 @@ static inline void uart_port_deref(struct uart_port *uport)
static inline struct uart_port *uart_port_check(struct uart_state *state)
{
-#ifdef CONFIG_LOCKDEP
- WARN_ON(!lockdep_is_held(&state->port.mutex));
-#endif
+ lockdep_assert_held(&state->port.mutex);
return state->uart_port;
}