From 5459b384f2b8b39d5680bcdab7e99bc39afa194c Mon Sep 17 00:00:00 2001 From: Philip Cuadra Date: Mon, 12 Jun 2017 15:47:19 -0700 Subject: [PATCH] msm_serial_hs: make the Bluetooth tty thread RT For Bluetooth, the tty kthread should be RT in order to avoid scheduling delays. Bug: 36106419 Test: play bluetooth audio, verify tty kthread runs at RT via systrace Change-Id: I441dd10d22f8831d055166bcd1ff9f01e5ca13d4 Signed-off-by: Philip Cuadra --- drivers/tty/serial/msm_serial_hs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/tty/serial/msm_serial_hs.c b/drivers/tty/serial/msm_serial_hs.c index 844c7617b9e6..fd191761bfa1 100644 --- a/drivers/tty/serial/msm_serial_hs.c +++ b/drivers/tty/serial/msm_serial_hs.c @@ -62,6 +62,7 @@ #include #include #include +#include #include #include @@ -3394,6 +3395,7 @@ static void msm_serial_hs_rt_init(struct uart_port *uport) msm_uport->pm_state = MSM_HS_PM_SUSPENDED; mutex_unlock(&msm_uport->mtx); pm_runtime_enable(uport->dev); + tty_port_set_policy(&uport->state->port, SCHED_FIFO, 1); } static int msm_hs_runtime_suspend(struct device *dev)