tags:

views:

552

answers:

10

So i want to try a new concept that involves deep modifications of the Linux kernel, and i wanted to know if is it worth to try or if it is too complicated ?

+1  A: 

Yes, it's complicated, but if you've got a new concept and you think that building it on top of the kernel is a good idea then it may well be worth the time.

If you're still put off by the Linux kernel then there's always the Minix kernel...

Sean
A: 

most of what you can accomplish should be doable with a kernel module. If you really have something big planned, then you can try and fork it. Hey, its open source, no one will tell you no :) Just make sure you back up often.

yx
+7  A: 

In the absence of further information, it sounds like what you are suggesting is better described as modifying the kernel, not forking.

What aspect of your ambition calls for forking? Forking is a thing whose essence is mostly defined in political terms - i.e. renaming the project, setting a different strategic direction, and so on.

Alex Balashov
+4  A: 

Like any piece of truly open software, forking the kernel is as simple as branching from the version control repository and beginning work on your own version. Also like any piece of truly open software, if you're going to fork it, it's best to have a solid reason for forking in place. And if you're eventually planning to merge back, then you're really not forking, but instead, you're branching and then asking for it to be merged. Just remember to replace regularly in that instance.

For the main point, though, it's going to be difficult... the Linux kernel is a very large and complex piece of software. You will be stuck with GPLv2 unless you remove all GPLv2 code that you cannot get permission to update to GPLv3, as well, so licensing would have to remain the same. But if you want to make substantial modifications to the Linux kernel because you think you can do it better, there is absolutely nobody stopping you. Add new drivers, modify the way graphics works, remove old APIs, do whatever you want. Once you've something to prove, people will start to pay attention, especially if you do it better than it's currently done. And you might wind up with the ultimate good result: Your work gets merged back into the mainline eventually.

Michael Trausch
+2  A: 

Forking open source software should be regarded as a last resort. What you should try doing first is making a branch of the kernel and submitting it for merge. That will make life much easier for everyone.

Jason Baker
+1  A: 

IIRC the proper way to maintain modified Linux kernel is a patch set like in Andrew Morton's mm.

Nikolai N Fetissov
+4  A: 

I want to stick to the question which is about difficulty. If you just want to add a system call to provide limited additional capability like tweak file descriptors then this is something any trained programmer can do. If you want to play with real-time, performance, process handling then beware that these can be very difficult because of how deep you go into the kernel.

Many undergraduate OS courses require adding a system call or adding some trivial fields/parameters to a construct. About 20 hours for something trivial, 60 for something easy but useful.

Ted Johnson
+2  A: 

"Deep modifications" are going to present you with a dilemma: do you track new Linux kernels and merge in your changes, or do you stick with the kernel you originally targeted and back patch critical fixes?

Unless your changes can be incorporated into the mainline kernel then you will be faced with the above. Can you sustain that effort, and is it worth it?

dwc
+3  A: 

Go to LKLM and check the archives if someone else is already working on something similar. If not, announce there what you plan to do and ask about the easiest way to accomplish it (kernel module, etc.). Create your own git repository to make the changes and allow others who are interested to pull from your repo. If your work turns out to be successfull, ask a maintainer to pull your changes and add them to the mainline.

It's certainly not unreasonable to do, but only you will know if it's worth your time working on those deep modifications.

lothar
A: 

You should consider whether your idea really needs to be done in kernel space, or whether it can effectively be done in userspace. This would be a reasonable question to ask by itself (with details of the idea, of course).

I have frequently seen people post kernel-related ideas to LKML that actually can be done entirely in userspace, sometimes more easily and more efficiently.

chuck