lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 15 Aug 2012 17:14:39 +0200
From:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
To:	Trevor Brandt <tjbrandt@...il.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
	Josh Triplett <josh@...htriplett.org>,
	Eric Paris <eparis@...hat.com>,
	Fabio Estevam <fabio.estevam@...escale.com>,
	Ingo Molnar <mingo@...e.hu>,
	Thomas Gleixner <tglx@...utronix.de>,
	Suresh Siddha <suresh.b.siddha@...el.com>,
	Glauber Costa <glommer@...allels.com>,
	Steven Rostedt <rostedt@...dmis.org>,
	Kamalesh Babulal <kamalesh@...ux.vnet.ibm.com>,
	Mike Galbraith <efault@....de>, linux-kernel@...r.kernel.org,
	team-fjord@...glegroups.com
Subject: Re: [PATCH] sched: Support compiling out real-time scheduling with
 REALTIME_SCHED.

On Tue, 2012-08-14 at 13:50 -0700, Trevor Brandt wrote:
> Adds support for compiling out the real-time scheduler (SCHED_FIFO
> and SCHED_RR) to save space. Changes sched_set_stop_task to use
> SCHED_NORMAL rather than SCHED_FIFO, since the kernel only uses this
> function as a fake scheduling priority for userspace to read to avoid
> exposing the stop class to userspace. Bloat-o-meter gives a space
> savings of 1877 bytes with REALTIME_SCHED turned off.
> 
> Userspace works fine with REALTIME_SCHED turned off. Processes
> attempting to set a real-time scheduling policy get EINVAL, exactly
> the response that the sched_setscheduler manpage documents you will
> get if the "scheduling policy is not one of the recognized policies."

Are you in the same group that wanted to make SCHED_FAIR optional as
well?

> Signed-off-by: Trevor Brandt <tjbrandt@...il.com>
> Reviewed-by: Josh Triplett <josh@...htriplett.org>

> diff --git a/kernel/sched/Makefile b/kernel/sched/Makefile
> index 9a7dd35..a9bee25 100644
> --- a/kernel/sched/Makefile
> +++ b/kernel/sched/Makefile
> @@ -11,7 +11,8 @@ ifneq ($(CONFIG_SCHED_OMIT_FRAME_POINTER),y)
>  CFLAGS_core.o := $(PROFILING) -fno-omit-frame-pointer
>  endif
>  
> -obj-y += core.o clock.o idle_task.o fair.o rt.o stop_task.o
> +obj-y += core.o clock.o idle_task.o fair.o stop_task.o
> +obj-$(CONFIG_REALTIME_SCHED) += rt.o
>  obj-$(CONFIG_SMP) += cpupri.o

This wants extra magic, cpupri is only used for rt, cutting that will of
course increase your savings.

>  obj-$(CONFIG_SCHED_AUTOGROUP) += auto_group.o
>  obj-$(CONFIG_SCHEDSTATS) += stats.o

Other than that I'm not entirely happy with the growing #ifdef maze.
Granted this new one isn't nearly as bad as some of the existing ones,
but I do wish someone would clean up some of that.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ