[prog] Re: [Newchix] Newbie question about kernel hacking

Jimen Ching jching at flex.com
Wed Feb 5 20:08:58 EST 2003


>On Mon, Jan 13, 2003, Rachel McConnell wrote:
>> What are some reasons for hacking the kernel?
>>
>> that is, not why does anyone WANT to (i have that down already!),  but
>> what sorts of things need changing about it?

I'm not sure if Linux 'needs' changing.  But different people might 'want'
to change it for different reasons.  For instance, the current Linux
kernel doesn't have very good support for POSIX threads.  Someone who
wants to develop an application using POSIX threads might modify the
kernel to support it.  And there is always someone trying to improve the
VM (virtual memory subsystem) or the scheduler.  If someone doing research
discovers a better scheduler, I don't think Linus would oppose
incorporating it.

Of course, this assumes you only modify the kernel proper.  A very large
portion of the Linux kernel consists of the device drivers.  Adding new
device support is always a worth while effort.

>> what kinds of hacks do people make?

Changes to the kernel usually involve things that are very performance
sensitive.  Moving an operation into the kernel means you eliminate the
overhead of copying data between userspace and kernelspace.  The drawback
is that you also lose protection.  A single piece of bad code could bring
down the entire system.  But if you don't care about such things, feel
free to put X11 and Mozilla into the kernel to make it faster.  ;-)

--jc
-- 
Jimen Ching (WH6BRR)      jching at flex.com     wh6brr at uhm.ampr.org



More information about the Programming mailing list