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 for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 23 Dec 2010 12:39:26 +0100
From:	torbenh <torbenh@....de>
To:	linux-kernel@...r.kernel.org
Subject: Sending some form of notifaction when sched_fifo throttling kicks
 in...


hi...

when the rt_runtime budget is exceeded, the kernel silently stops
scheduling RT tasks. there is no way to distinguish this from 
a task taking very long to complete.

it would be very nice, if the kernel would send some form of notifaction
when it starts throttling things.

recording the timestamp of the last occurence of throttling
in a /proc file would be sufficient, if there were no cgroups.

would it be possible to add a readonly property to the cpu subsystem ?
there is already a printk_once, but thats pretty useless :)


from -rt kernel kernel/sched_rt.c:

----------------------------------------------------------------------------------
static int sched_rt_runtime_exceeded(struct rt_rq *rt_rq)
{
	u64 runtime = sched_rt_runtime(rt_rq);

	if (rt_rq->rt_throttled)
		return rt_rq_throttled(rt_rq);

	if (sched_rt_runtime(rt_rq) >= sched_rt_period(rt_rq))
		return 0;

	balance_runtime(rt_rq);
	runtime = sched_rt_runtime(rt_rq);
	if (runtime == RUNTIME_INF)
		return 0;

	if (rt_rq->rt_time > runtime) {
		rt_rq->rt_throttled = 1;
		printk_once(KERN_WARNING "sched: RT throttling activated\n");
+ // send some form of notification. 
		if (rt_rq_throttled(rt_rq)) {
			sched_rt_rq_dequeue(rt_rq);
			return 1;
		}
	}

	return 0;
}
-----------------------------------------------------------------------------------
-- 
torben Hohn
--
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