msm_serial_hs: make the Bluetooth tty thread RT

For Bluetooth, the tty kthread should be RT in order to avoid scheduling
delays.

Cherry picked from:
commit 4c7f1a012302 ("msm_serial_hs: make the Bluetooth tty thread RT")

Bug: 36106419
Test: Play Bluetooth audio, verify tty kthread runs at RT via systrace
Change-Id: Ic14cd4114084230fbbf8eb38dadca4bc248db952
Signed-off-by: Philip Cuadra <philipcuadra@google.com>
Signed-off-by: Petri Gynther <pgynther@google.com>
(cherry picked from commit c84fcb124cf5bad4cb2bb7f991218cbafc0d659e)
(cherry picked from commit 1c7f9800ea86452482cd8ba8ffc7f8bd1cd472dd)
(cherry picked from commit 7c0efe5a6a5238cccf3b1b024ba6f8d7b81c2146)
(cherry picked from commit ab0405166e1a6f9cc15563273689409183c1a940)
(cherry picked from commit 49927c880b7eec179d725588de8ce7df57af38a0)
(cherry picked from commit 28cb836c18654ea55deb69467cb511ac6ff7ac5d)
(cherry picked from commit fd95db1245adc6d93ad39695398ee4ab6ec8daf5)
(cherry picked from commit 8da753f0a6af9b5e326b0ae2633487b8c730fe46)
(cherry picked from commit cb4353176d581a8bfdb9a600b929c7f8a61d6193)
(cherry picked from commit a072b5abd1705bb16a7f8e1da3c36cbaccd80307)
(cherry picked from commit 9795d136b6b94cfb3ed78d9dcc1335e09dc37b6a)
This commit is contained in:
Philip Cuadra 2017-06-12 15:47:19 -07:00 committed by spakkkk
parent 81fc40bd90
commit 89e9ace199

View File

@ -50,6 +50,7 @@
#include <linux/ipc_logging.h> #include <linux/ipc_logging.h>
#include <asm/irq.h> #include <asm/irq.h>
#include <linux/kthread.h> #include <linux/kthread.h>
#include <uapi/linux/sched.h>
#include <linux/msm-sps.h> #include <linux/msm-sps.h>
#include <linux/platform_data/msm_serial_hs.h> #include <linux/platform_data/msm_serial_hs.h>
@ -3288,6 +3289,7 @@ static void msm_serial_hs_rt_init(struct uart_port *uport)
msm_uport->pm_state = MSM_HS_PM_SUSPENDED; msm_uport->pm_state = MSM_HS_PM_SUSPENDED;
mutex_unlock(&msm_uport->mtx); mutex_unlock(&msm_uport->mtx);
pm_runtime_enable(uport->dev); pm_runtime_enable(uport->dev);
tty_port_set_policy(&uport->state->port, SCHED_FIFO, 1);
} }
static int msm_hs_runtime_suspend(struct device *dev) static int msm_hs_runtime_suspend(struct device *dev)