From: Wu Zhangjin on
Hi, All

Just made SCHED_DEADLINE run on my YeeLoong laptop ;)

SCHED_DEADLINE made by Dario Faggioli and Michael Trimarchi, is "a new
scheduling class called SCHED_DEADLINE for the Linux kernel. The
scheduling class implements the real-time scheduling algorithm called
Earliest Deadline First (EDF), one of the most common real-time
scheduling algorithms."

Its homepage:

http://www.evidence.eu.com/content/view/313/390/

and more information about it is available here:

http://gitorious.org/sched_deadline/pages/Home

Thanks very much to the authors, I just cloned it and did some necessary
modification for MIPS to make it work on my YeeLoong laptop with debian
6.0(squeeze), at last, I got a really "deterministic" laptop.

And the information about "SCHED_DEADLINE for MIPS" is listed as
follows:

1. sched_deadline for MIPS

I have put it here:

git://dev.lemote.com/rt4ls.git rt/2.6.31/sched-deadline

It is based on:

git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git
rt/2.6.31

and

git://gitorious.org/sched_deadline/linux-deadline.git rt-deadline

and the following commits are added(please get more info from the git
repo.):

SCHED_DEADLINE: added system calls for MIPS
SCHED_DEADLINE: Fixup of "BUG: scheduling while atomic"

NOTE: If you plan to run it on your board, please remember to add your
board specific RT-preempt support at first.

2. sched_tool for MIPS

git://dev.lemote.com/rt4ls.git rt/schedtool-deadline

The schedtool is based on:

git://gitorious.org/sched_deadline/schedtool-deadline.git

To make the schedtool work on MIPS machine with debian O32 ABI system, I
have fixed the timespec struct and of course, the related system calls'
numbers are added in.

3. Usage (only use YeeLoong as an example)

3.1 Get the latest kernel with RT-preempt and SCHED_DEADLINE support

git://dev.lemote.com/rt4ls.git rt/2.6.31/loongson

3.2 Compile the kernel

A minimal defconfig is provided:

arch/mips/configs/yeeloong_rt_defconfig

and please refer to:

http://www.gitorious.org/sched_deadline/pages/Compile
http://dev.lemote.com/code/rt4ls/wiki/linux-loongson-howto

3.3 Get the schedtool with SCHED_DEADLINE support and compile it

git://dev.lemote.com/rt4ls.git rt/schedtool-deadline

3.4 Run your application with the SCHED_DEADLINE

$ ./schedtool -E -d 100000 -b 10000 -e yes

-E using the SCHED_DEADLINE policy(the old name is SCHED_EDF)
-d deadline
-b budget(runtime)
-e start command with specified policy/priority

Did you want to do some benchmarking on the RT-preempt and
SCHED_DEADLINE for MIPS? please refer to the "Benchmarks and Test Cases
" part of http://rt.wiki.kernel.org and the "Usage, Evaluation,
Examples" parts of http://gitorious.org/sched_deadline/pages/Home

That's all, Enjoy it!

Best Regards,
Wu Zhangjin

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/