Commit 4ff13d00 authored by Peter Zijlstra's avatar Peter Zijlstra Committed by Mark Brown

spi: Reduce kthread priority

The SPI thingies request FIFO-99 by default, reduce this to FIFO-50.

FIFO-99 is the very highest priority available to SCHED_FIFO and
it not a suitable default; it would indicate the SPI work is the
most important work on the machine.

Cc: Benson Leung <bleung@chromium.org>
Cc: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Cc: Guenter Roeck <groeck@chromium.org>
Cc: Mark Brown <broonie@kernel.org>
Cc: linux-spi@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20190801111541.917256884@infradead.orgSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent cc8b4659
...@@ -706,7 +706,7 @@ static int cros_ec_spi_devm_high_pri_alloc(struct device *dev, ...@@ -706,7 +706,7 @@ static int cros_ec_spi_devm_high_pri_alloc(struct device *dev,
struct cros_ec_spi *ec_spi) struct cros_ec_spi *ec_spi)
{ {
struct sched_param sched_priority = { struct sched_param sched_priority = {
.sched_priority = MAX_RT_PRIO - 1, .sched_priority = MAX_RT_PRIO / 2,
}; };
int err; int err;
......
...@@ -1434,7 +1434,7 @@ static void spi_pump_messages(struct kthread_work *work) ...@@ -1434,7 +1434,7 @@ static void spi_pump_messages(struct kthread_work *work)
*/ */
static void spi_set_thread_rt(struct spi_controller *ctlr) static void spi_set_thread_rt(struct spi_controller *ctlr)
{ {
struct sched_param param = { .sched_priority = MAX_RT_PRIO - 1 }; struct sched_param param = { .sched_priority = MAX_RT_PRIO / 2 };
dev_info(&ctlr->dev, dev_info(&ctlr->dev,
"will run message pump with realtime priority\n"); "will run message pump with realtime priority\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment