Question

I am planning to code a new scheduler for Linux. I wish to know the current scheduler being used and its "C" code. Where I can find the file containing the code of the scheduler in linux file system.

any references or help regarding how scheduling algorithm can be modified will be great or any source where I can learn from?

Was it helpful?

Solution

Documentation/scheduler includes the documentations of current Linux scheduler, kernel/sched the implementation.

You can clone the Linux repository to your local machine by:

git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

OTHER TIPS

The scheduler code is in sched.c in the linux tree, you can open it up to see which is the default scheduler selected.

And too add/change a scheduler, see this post: How to create a new Linux kernel scheduler

You need to have the entire linux source to be able change/add a scheduler. As suggested by @leeduhem, clone the linux source to your machine.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top