Web Analytics

如何加入Linux内核开发社区(1)

本文翻译自The Linux Foundation的《How to Participate in the Linux Community》(基于2012-03-21最新版本),原作者为Jonathan Corbet(corbet@lwn.net)。下面是该文章第一章节的中译文。 ...

March 27, 2012 · 10 min · Tony Bai

也谈Linux Kernel Hacking – Kconfig与Kbuild

挖掘简单现象背后的复杂本质。– Tony Bai^_^ 上文讲到Linux Kernel的配置和编译十分简单,甚至简单到可以与一个用户层应用相媲美。这一切都是因为Linux Kernel实现了一套易于使用、变更和后期维护的配置和编译体系。要知道最新Linux Kernel版本的代码量可是千万级别的,并且模块众多,其背后的配置和编译体系一定不那么简单,这次我们就来尝试Hack一下这套体系。 ...

March 18, 2012 · 14 min · Tony Bai

也谈Linux Kernel Hacking – 内核配置、编译与安装

Linux Kernel之于C程序员,就好比世界之巅珠穆朗玛之于专业登山客。 — Tony Bai^_^ 作为到目前为止最为成功的开源项目,Linux Kernel总是散发着无穷的魅力,就好比那珠穆朗玛,让人魂牵梦绕,心潮澎湃并总是想尝试征服。 ...

March 15, 2012 · 11 min · Tony Bai

回顾TCP协议那些事儿

我不是计算机科班出身。记得大学的时候旁听计算机系的网络课,当时计算机系使用教材是"计算机网络–自顶向下方法与Internet特色“的影印版,这本教材与众不同的一个地方就是作者JAMES F.KUROSE和KEITH W.ROSS采用了’自顶向下’的编排思路,先从应用层开始,最后讲到物理层。而且这本书在语言上形象生动,通俗易懂。只怪我当初没有一心一意听讲,到现在存在我的脑子中的基本概念居多,深刻理解甚少。以致于工作后遇到此类的问题,只能恶补。这不,在12月1日凌晨全国统一短信类服务接入代码的调整工作中,我就遇到了此类问题,不得不再次抱起W.Richard Stevens的’TCP详解卷一‘啃了啃,回顾一下TCP协议那些事儿。 ...

December 6, 2007 · 6 min · Tony Bai

Kernel 'head.S'

After being decompressed, the kernel image starts with another ‘startup_32′ function included in $(linux-2.6.15.3_dir/arch/i386/kernel/head.S’. This ‘head.S’ is the second one in linux source package, which is also called ‘kernel head’. And it is exactly what we want to describe in this artical. ...

March 2, 2006 · 3 min · Tony Bai

Compressed 'head.S'

_Why do we do this? Don’t ask me.. Incomprehensible are the ways of bootloaders. _ — comments in arch/i386/boot/compressed/misc.c There are two ‘head.S’ in linux source package. One is in $(Linux-2.6.15.3_dir/arch/i386/boot/compressed and the other one is in $(Linux-2.6.15.3_dir/arch/i386/kernel. The first one will be analyzed in this artical. Before we go ahead, let’s show a news of linux, that is ‘Army leans toward Linux for FCS(Future Combat System)’. ...

February 25, 2006 · 3 min · Tony Bai

Transfer to '32-bit'

The phase we talked about before is in ‘Real-address Mode’, which runs 16-bit program modules. At the tail of “Begin ‘setup.S’”, we had moved to ‘Protected Mode’, which usu runs 32-bit program modules. So there are two big problems which are ‘How to transfer control between 16-bit code and 32-bit code’ and how to transfer control from ‘real-mode’ to protected mode’. They are also what we wanna talk about in this artical. ...

February 17, 2006 · 5 min · Tony Bai

Outline 'memory layout'

So far we have arrived at the gate leading to the real kernel. And we’d better stop for a short break in order that we would have more energy to go ahead. Now let’s examine what we do to memory these days. Virtually what we want to do is drawing some pictures to describe the layout of the memory in various phases. For the layout is related to the bootloader, we’d better make our work based on the following assumption: The machine has two systems installed (Windows XP and Linux) and uses LILO as the bootloader. Let us look at the LILO configuration: ...

February 15, 2006 · 3 min · Tony Bai

Begin 'setup.S'

It is time for ‘setup.S’ to show its power. The ‘setup.S’ is loaded by the bootloader and virtually it belongs to neither the ‘bootstrap’ routine nor the kernel program, although it is a portion of the kernel image. The source of the ‘setup.S’ is kinda ‘big’ and what it does can be summarized into one word: “the ‘setup.S’ is responsible to establish the environment for the execution of the kernel program”. ...

February 13, 2006 · 5 min · Tony Bai

Goto 'Bootstrap'

The term ‘Bootstrap’, which originally refers to a person who tries to stand up by pulling his own boots, refers to a subroutine used to establish the full routine(its own left part, i think) or another routine in computer science. Today modern computers act as a vital role in our daily life and many of you may wonder what happens to the computer when you have it powered on. The ‘Bootstrap’, which is also called ‘boot’ for short, is the first step to be done by the computer. The process of ‘Bootstrap’, which starts on when the computer is powered on and usu ends off when the kernel of the operating system begins to run, is just what we are gonna describe. ...

February 11, 2006 · 4 min · Tony Bai