Re: [PATCH] schedutils: don't assume SCHED_BATCH and SCHED_IDLE exist

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Apr 20, 2009 at 01:34:18PM +0200, Karel Zak wrote:
> On Mon, Apr 20, 2009 at 01:13:28AM -0400, Mike Frysinger wrote:
> > On Sunday 19 April 2009 10:34:10 Aurelien Jarno wrote:
> > > SCHED_FIFO, SCHED_OTHER, SCHED_RR are part of POSIX 1003.1b Process
> > > Scheduling, so it is correct to assume they always exists.
> > >
> > > SCHED_BATCH and SCHED_IDLE are Linux specific, we should not assume
> > > they exists.
> > 
> > looks like you add a whole lot of ifdef's for no real gain.  on non-Linux 
> > systems, you end up with options that simply dont work.  not a big deal.  on 
> > the flip side, these ifdef's are pretty invasive and split up code in a pretty 
> > bad way.
> 
>  Exactly.
>  
>  It'd be better to add a NOTES section to the chrt.1 man page where
>  you can describe the difference between Linux and non-linux systems. 

This is done in the batch below.

>From cceaa1ebdea150959e9d8aff66d654063b1103ab Mon Sep 17 00:00:00 2001
From: Aurelien Jarno <aurelien@xxxxxxxxxxx>
Date: Wed, 22 Apr 2009 09:09:26 +0200
Subject: [PATCH] schedutils: add a comment about non POSIX 1003.1b attributes in chrt.1

Mention that only SCHED_FIFO, SCHED_OTHER and SCHED_RR are part of
POSIX 1003.1b Process Scheduling in chrt.1.

Signed-off-by: Aurelien Jarno <aurelien@xxxxxxxxxxx>
---
 schedutils/chrt.1 |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/schedutils/chrt.1 b/schedutils/chrt.1
index a78ad25..83b3dbb 100644
--- a/schedutils/chrt.1
+++ b/schedutils/chrt.1
@@ -104,6 +104,14 @@ A user must possess
 .BR CAP_SYS_NICE
 to change the scheduling attributes of a process.  Any user can retrieve the
 scheduling information.
+.SH NOTES
+Only
+.BR SCHED_FIFO ,
+.BR SCHED_OTHER
+and
+.BR SCHED_RR
+are part of POSIX 1003.1b Process Scheduling. The other scheduling attributes
+may be ignored on some systems.
 .SH AUTHOR
 Written by Robert M. Love.
 .SH COPYRIGHT
-- 
1.6.2.3


-- 
Aurelien Jarno	                        GPG: 1024D/F1BCDB73
aurelien@xxxxxxxxxxx                 http://www.aurel32.net
--
To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux