File: 0003-Don-t-reference-non-standard-realtime-group.patch

package info (click to toggle)
rt-tests 2.6-1.1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 904 kB
  • sloc: ansic: 12,999; python: 493; makefile: 225; sh: 154
file content (32 lines) | stat: -rw-r--r-- 1,186 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= <u.kleine-koenig@pengutronix.de>
Date: Thu, 9 Sep 2021 13:59:59 +0900
Subject: Don't reference non-standard realtime group
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit

There is no dedicated realtime group in most distributions. So make the
error message a bit more understandable for people not running Redhat
MRG.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Forwarded: id:1310590111-11484-1-git-send-email-u.kleine-koenig@pengutronix.de
Closes: http://bugs.debian.org/619938
---
 src/lib/rt-utils.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/lib/rt-utils.c b/src/lib/rt-utils.c
index 6bbd25a..e293119 100644
--- a/src/lib/rt-utils.c
+++ b/src/lib/rt-utils.c
@@ -286,7 +286,8 @@ int check_privs(void)
 	param.sched_priority = 1;
 	if (sched_setscheduler(0, SCHED_FIFO, &param)) {
 		fprintf(stderr, "Unable to change scheduling policy!\n");
-		fprintf(stderr, "either run as root or join realtime group\n");
+		fprintf(stderr, "Probably missing capabilities, either run as "
+				"root or increase RLIMIT_RTPRIO limits.\n");
 		return 1;
 	}