荔园在线

荔园之美,在春之萌芽,在夏之绽放,在秋之收获,在冬之沉淀

[回到开始] [上一篇][下一篇]


发信人: georgehill (清风浮云 人生), 信区: Linux
标  题: FreeBSD kld简介 (1)(转寄)
发信站: BBS 荔园晨风站 (Wed Oct 25 17:36:37 2000), 站内信件

【 以下文字转载自 georgehill 的信箱 】
【 原文由 georgehill.bbs@smth.org 所发表 】
发信人: hhuu (不知道爱我的是爱我的人), 信区: FreeBSD
标  题: FreeBSD kld简介 (1)(转寄)
发信站: BBS 水木清华站 (Wed Oct 25 00:55:53 2000)

就象Linux下的lkm一样,FreeBSD中有相应的东东.
如果我没有搞错的话,2.x系列中是叫lkm的.现在
还有系统的同志可以在/usr/share/example/lkm
中看到这些前辈的影子.

但是时代变迁,到了3.x系列之后,新的东西出现
了,就是所谓的kld.

这里摘录的是关于FreeBSD的lkm和kld的比较:
1. LKM system used a userland linker to
   push prerelocated binary data into
   the kernel.
2. KLD system does the relocation itself
   in the kernel. LKMs had special data
   structures that the lkm driver knew about
   and used those to wire it into the kernel
3. LKMs were single purpose and were quite
   difficult to change from LKM to actual
   kernel code.
4. With KLDs, thins were made to be more
   generic. A file could contain 0 or more
   modules.
5. Each module is self-contianed and self-
   initializing and registering.
6. KLDs and kernel code are compiled the
   same.
7. It's possible to take a piece of the
   kernel and easily make it a KLD without
   much difficulty.
8. The dependncies and versioning are now
   at the module level.

   ---------待续

--
  行列中        作不朽文章
  谈笑间        论古今英雄
  痴狂里        诉红尘情爱
  来去时        不枉一生风流
                        ---------  bbs.ntu.edu.tw


※ 来源:·BBS 水木清华站 smth.org·[FROM: 166.111.161.18]
--
※ 转载:·BBS 荔园晨风站 bbs.szu.edu.cn·[FROM: 192.168.1.116]


[回到开始] [上一篇][下一篇]

荔园在线首页 友情链接:深圳大学 深大招生 荔园晨风BBS S-Term软件 网络书店