summaryrefslogtreecommitdiffstats
path: root/pcitool
diff options
context:
space:
mode:
Diffstat (limited to 'pcitool')
-rw-r--r--pcitool/cli.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/pcitool/cli.c b/pcitool/cli.c
index 0696ef4..90f11d4 100644
--- a/pcitool/cli.c
+++ b/pcitool/cli.c
@@ -3715,6 +3715,10 @@ int main(int argc, char **argv) {
if (amode != ACCESS_DMA)
break;
case MODE_BENCHMARK:
+ sched_param.sched_priority = sched_get_priority_max(SCHED_FIFO);
+ err = sched_setscheduler(0, SCHED_FIFO, &sched_param);
+ if (err) pcilib_info("Failed to acquire real-time priority (errno: %i)", errno);
+ break;
case MODE_GRAB:
sched_param.sched_priority = sched_get_priority_min(SCHED_FIFO);
err = sched_setscheduler(0, SCHED_FIFO, &sched_param);