linux内核线程优先级配置
linux内核线程优先级配置
/* reference driver/spi/spi.c */
#include <linux/sched/rt.h>
#include <uapi/linux/sched/types.h>
static struct sched_param param = { .sched_priority = MAX_RT_PRIO - 1 };
sched_setscheduler(current, SCHED_FIFO, ¶m);