Hi All,
The following patches change existing Chinese kernel docs to rst format
and reorg them to make them alive in 'make htmldocs'.
you can view the generated htmldocs from:
http://176.122.172.82/translations/zh_CN/index.html
Or make and review docs on your self box:
make htmldocs SPHINXDIRS=translations/zh_CN
lynx Documentation/output/translations/zh_CN/index.html
Any comments are appreciated!
V5 changes:
1, update howto.rst patch after Federico Vaga's changes on it.
V4 changes:
1, Add Harry's signed-off as his ack.
V3 changes:
1, fix a zh_CN/index.rst display issue
2, update .mailmap for zh_CN transolators'r email address
V2 changes:
1, change the disclaimer file to Chinese version,
2, replace the obsolete translator's email address in related files.
3, fix couple of format issues in couple files
Cheers!
Alex
---
Alex Shi (31):
docs/zh_CN: add disclaimer file
docs/zh_CN: move process related docs into process dir
docs/zh_CN: change Chinese index to know process dir
docs/zh_CN: add index file into process dir
docs/zh_CN: rename HOWTO into process directory
docs/zh_CN: howto format changes
docs/zh_CN: rename SubmittingPatches for html links
docs/zh_CN: format the submitting-patches doc to rst
docs/zh_CN: rename stable_kernel_rules doc
docs/zh_CN: rst format change for stable-kernel-rules
docs/zh_CN: rename email-clients.txt as email-clients.rst
docs/zh_CN: do rst format for email-clients.rst
docs/zh_CN: rename volatile-consider-harmful doc
docs/zh_CN: volatile doc format changes
docs/zh_CN: rename SubmittingDrivers
docs/zh_CN: format submitting drivers as rst
docs/zh_CN: rename magic-numbers as rst doc
docs/zh_CN: format the magic-number doc as rst
docs/zh_CN: rename stable_api_nonsense.txt as stable-api-nonsense.rst
docs/zh_CN: format stable-api-nonsense
docs/zh_CN: update Li Yang's email address
mailmap: update Li Yang's email address
docs/zh_CN: update Zhang Wei's email address
mailmap: update email address for Triplex
docs/zh_CN: update TripleX chung's email address
docs/zh_CN: fix indent issue in stable-api-nonsense file
docs/zh_CN: fix indent issue in submitting-drivers
docs/zh_CN: remove zh-kernel.org in MAINTAINERS
mailmap: update my obsolete email address
docs/zh_CN: fix rst format issue in submitting-patch
docs/zh_CN: fix rst format errors in howto.rst
.mailmap | 6 +
.../translations/zh_CN/disclaimer-zh_CN.rst | 9 ++
Documentation/translations/zh_CN/index.rst | 17 +-
.../translations/zh_CN/magic-number.txt | 153 ------------------
.../translations/zh_CN/oops-tracing.txt | 2 +-
.../zh_CN/{ => process}/coding-style.rst | 0
.../email-clients.rst} | 53 +++---
.../zh_CN/{HOWTO => process/howto.rst} | 69 +++++---
.../translations/zh_CN/process/index.rst | 53 ++++++
.../zh_CN/process/magic-number.rst | 151 +++++++++++++++++
.../stable-api-nonsense.rst} | 67 ++++----
.../stable-kernel-rules.rst} | 32 ++--
.../submitting-drivers.rst} | 34 ++--
.../submitting-patches.rst} | 58 +++----
.../volatile-considered-harmful.rst} | 35 ++--
Documentation/translations/zh_CN/sparse.txt | 6 +-
MAINTAINERS | 1 -
17 files changed, 407 insertions(+), 339 deletions(-)
create mode 100644 Documentation/translations/zh_CN/disclaimer-zh_CN.rst
delete mode 100644 Documentation/translations/zh_CN/magic-number.txt
rename Documentation/translations/zh_CN/{ => process}/coding-style.rst (100%)
rename Documentation/translations/zh_CN/{email-clients.txt => process/email-clients.rst} (82%)
rename Documentation/translations/zh_CN/{HOWTO => process/howto.rst} (95%)
create mode 100644 Documentation/translations/zh_CN/process/index.rst
create mode 100644 Documentation/translations/zh_CN/process/magic-number.rst
rename Documentation/translations/zh_CN/{stable_api_nonsense.txt => process/stable-api-nonsense.rst} (80%)
rename Documentation/translations/zh_CN/{stable_kernel_rules.txt => process/stable-kernel-rules.rst} (76%)
rename Documentation/translations/zh_CN/{SubmittingDrivers => process/submitting-drivers.rst} (86%)
rename Documentation/translations/zh_CN/{SubmittingPatches => process/submitting-patches.rst} (92%)
rename Documentation/translations/zh_CN/{volatile-considered-harmful.txt => process/volatile-considered-harmful.rst} (81%)
--
2.19.1.856.g8858448bb
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../translations/zh_CN/process/index.rst | 53 +++++++++++++++++++
1 file changed, 53 insertions(+)
create mode 100644 Documentation/translations/zh_CN/process/index.rst
diff --git a/Documentation/translations/zh_CN/process/index.rst b/Documentation/translations/zh_CN/process/index.rst
new file mode 100644
index 000000000000..03939e1a7b92
--- /dev/null
+++ b/Documentation/translations/zh_CN/process/index.rst
@@ -0,0 +1,53 @@
+.. raw:: latex
+
+ \renewcommand\thesection*
+ \renewcommand\thesubsection*
+
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: :ref:`Documentation/process/index.rst <process_index>`
+:Translator: Alex Shi <[email protected]>
+
+.. _cn_process_index:
+
+与Linux 内核社区一起工作
+========================
+
+那么你想成为Linux内核开发人员? 欢迎! 不但从技术意义上讲有很多关于内核的知识
+需要学,而且了解我们社区的工作方式也很重要。 阅读这些文章可以让您以更轻松地,
+麻烦最少的方式将更改合并到内核。
+
+以下是每位开发人员应阅读的基本指南。
+
+.. toctree::
+ :maxdepth: 1
+
+ howto
+ submitting-patches
+ coding-style
+ email-clients
+
+其它大多数开发人员感兴趣的社区指南:
+
+
+.. toctree::
+ :maxdepth: 1
+
+ submitting-drivers
+ stable-api-nonsense
+ stable-kernel-rules
+
+这些是一些总体技术指南,由于缺乏更好的地方,现在已经放在这里
+
+.. toctree::
+ :maxdepth: 1
+
+ magic-number
+ volatile-considered-harmful
+
+.. only:: subproject and html
+
+ 目录
+ ====
+
+ * :ref:`genindex`
--
2.19.1.856.g8858448bb
Make it available in htmldocs
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
Documentation/translations/zh_CN/process/{HOWTO => howto.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{HOWTO => howto.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/HOWTO b/Documentation/translations/zh_CN/process/howto.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/HOWTO
rename to Documentation/translations/zh_CN/process/howto.rst
--
2.19.1.856.g8858448bb
to Make it readble for html etc docs making.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/submitting-drivers.rst | 30 +++++++------------
1 file changed, 11 insertions(+), 19 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/submitting-drivers.rst b/Documentation/translations/zh_CN/process/submitting-drivers.rst
index 15e73562f710..c90ab5ae233d 100644
--- a/Documentation/translations/zh_CN/process/submitting-drivers.rst
+++ b/Documentation/translations/zh_CN/process/submitting-drivers.rst
@@ -1,30 +1,22 @@
-Chinese translated version of Documentation/process/submitting-drivers.rst
+.. _cn_submittingdrivers:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have a problem
-communicating in English you can also ask the Chinese maintainer for
-help. Contact the Chinese maintainer if this translation is outdated
-or if there is a problem with the translation.
+.. include:: ../disclaimer-zh_CN.rst
-Chinese maintainer: Li Yang <[email protected]>
----------------------------------------------------------------------
-Documentation/process/submitting-drivers.rst 的中文翻译
+:Original: :ref:`Documentation/process/submitting-drivers.rst
+ <submittingdrivers>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
-中文版维护者: 李阳 Li Yang <[email protected]>
-中文版翻译者: 李阳 Li Yang <[email protected]>
-中文版校译者: 陈琦 Maggie Chen <[email protected]>
- 王聪 Wang Cong <[email protected]>
- 张巍 Zhang Wei <[email protected]>
-
-以下为正文
----------------------------------------------------------------------
+ 中文版维护者: 李阳 Li Yang <[email protected]>
+ 中文版翻译者: 李阳 Li Yang <[email protected]>
+ 中文版校译者: 陈琦 Maggie Chen <[email protected]>
+ 王聪 Wang Cong <[email protected]>
+ 张巍 Zhang Wei <[email protected]>
如何向 Linux 内核提交驱动程序
------------------------------
+=============================
这篇文档将会解释如何向不同的内核源码树提交设备驱动程序。请注意,如果你感
兴趣的是显卡驱动程序,你也许应该访问 XFree86 项目(http://www.xfree86.org/)
--
2.19.1.856.g8858448bb
[email protected] and [email protected] is absolete email address
for TripleX Chung <[email protected]>
Signed-off-by: Alex Shi <[email protected]>
Cc: Andrew Morton <[email protected]>
Cc: TripleX Chung <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.mailmap | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.mailmap b/.mailmap
index 705c4f11f1a3..e5979518c396 100644
--- a/.mailmap
+++ b/.mailmap
@@ -207,6 +207,8 @@ Tejun Heo <[email protected]>
Thomas Graf <[email protected]>
Thomas Pedersen <[email protected]>
Tony Luck <[email protected]>
+TripleX Chung <[email protected]> <[email protected]>
+TripleX Chung <[email protected]> <[email protected]>
Tsuneo Yoshioka <[email protected]>
Uwe Kleine-König <[email protected]>
Uwe Kleine-König <[email protected]>
--
2.19.1.856.g8858448bb
Make it available for html etc docs.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/{email-clients.txt => email-clients.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{email-clients.txt => email-clients.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/email-clients.txt b/Documentation/translations/zh_CN/process/email-clients.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/email-clients.txt
rename to Documentation/translations/zh_CN/process/email-clients.rst
--
2.19.1.856.g8858448bb
to replace the obsolete email address with new one.
Signed-off-by: Alex Shi <[email protected]>
Cc: Zhang Wei <[email protected]>
Cc: Li Yang <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
Documentation/translations/zh_CN/process/submitting-drivers.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/translations/zh_CN/process/submitting-drivers.rst b/Documentation/translations/zh_CN/process/submitting-drivers.rst
index fade72515b04..43c0e4530362 100644
--- a/Documentation/translations/zh_CN/process/submitting-drivers.rst
+++ b/Documentation/translations/zh_CN/process/submitting-drivers.rst
@@ -13,7 +13,7 @@
中文版翻译者: 李阳 Li Yang <[email protected]>
中文版校译者: 陈琦 Maggie Chen <[email protected]>
王聪 Wang Cong <[email protected]>
- 张巍 Zhang Wei <[email protected]>
+ 张巍 Zhang Wei <[email protected]>
如何向 Linux 内核提交驱动程序
=============================
--
2.19.1.856.g8858448bb
Tame the 'make htmldocs' to avoid 'ERROR: Unexpected indentation'
etc errors.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: TripleX Chung <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/stable-api-nonsense.rst | 33 +++++++++++--------
1 file changed, 19 insertions(+), 14 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
index 42d974e6dc35..beb94200b35e 100644
--- a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
+++ b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
@@ -54,18 +54,22 @@ Linux能成为强壮,稳定,成熟的操作系统,这也是你最开始选
--------------
假如我们有一个稳定的内核源代码接口,那么自然而然的,我们就拥有了稳定的
二进制接口,是这样的吗?错。让我们看看关于Linux内核的几点事实:
+
- 取决于所用的C编译器的版本,不同的内核数据结构里的结构体的对齐方
-式会有差别,代码中不同函数的表现形式也不一样(函数是不是被inline编译取
-决于编译器行为)。不同的函数的表现形式并不重要,但是数据结构内部的对齐
-方式很关键。
+ 式会有差别,代码中不同函数的表现形式也不一样(函数是不是被inline
+ 编译取决于编译器行为)。不同的函数的表现形式并不重要,但是数据
+ 结构内部的对齐方式很关键。
+
- 取决于内核的配置选项,不同的选项会让内核的很多东西发生改变:
+
- 同一个结构体可能包含不同的成员变量
- 有的函数可能根本不会被实现(比如编译的时候没有选择SMP支持
-,一些锁函数就会被定义成空函数)。
+ 一些锁函数就会被定义成空函数)。
- 内核使用的内存会以不同的方式对齐,这取决于不同的内核配置选
-项。
+ 项。
+
- Linux可以在很多的不同体系结构的处理器上运行。在某个体系结构上编
-译好的二进制驱动程序,不可能在另外一个体系结构上正确的运行。
+ 译好的二进制驱动程序,不可能在另外一个体系结构上正确的运行。
对于一个特定的内核,满足这些条件并不难,使用同一个C编译器和同样的内核配
置选项来编译驱动程序模块就可以了。这对于给一个特定Linux发布的特定版本提
@@ -85,7 +89,7 @@ Linux能成为强壮,稳定,成熟的操作系统,这也是你最开始选
如果有人不将他的内核驱动程序,放入公版内核的源代码树,而又想让驱动程序
一直保持在最新的内核中可用,那么这个话题将会变得没完没了。
- 内核开发是持续而且快节奏的,从来都不会慢下来。内核开发人员在当前接口中
+内核开发是持续而且快节奏的,从来都不会慢下来。内核开发人员在当前接口中
找到bug,或者找到更好的实现方式。一旦发现这些,他们就很快会去修改当前的
接口。修改接口意味着,函数名可能会改变,结构体可能被扩充或者删减,函数
的参数也可能发生改变。一旦接口被修改,内核中使用这些接口的地方需要同时
@@ -93,21 +97,22 @@ Linux能成为强壮,稳定,成熟的操作系统,这也是你最开始选
举一个例子,内核的USB驱动程序接口在USB子系统的整个生命周期中,至少经历
了三次重写。这些重写解决以下问题:
+
- 把数据流从同步模式改成非同步模式,这个改动减少了一些驱动程序的
-复杂度,提高了所有USB驱动程序的吞吐率,这样几乎所有的USB设备都能以最大
-速率工作了。
+ 复杂度,提高了所有USB驱动程序的吞吐率,这样几乎所有的USB设备都
+ 能以最大速率工作了。
- 修改了USB核心代码中为USB驱动分配数据包内存的方式,所有的驱动都
-需要提供更多的参数给USB核心,以修正了很多已经被记录在案的死锁。
+ 需要提供更多的参数给USB核心,以修正了很多已经被记录在案的死锁。
这和一些封闭源代码的操作系统形成鲜明的对比,在那些操作系统上,不得不额
外的维护旧的USB接口。这导致了一个可能性,新的开发者依然会不小心使用旧的
接口,以不恰当的方式编写代码,进而影响到操作系统的稳定性。
- 在上面的例子中,所有的开发者都同意这些重要的改动,在这样的情况下修改代
+在上面的例子中,所有的开发者都同意这些重要的改动,在这样的情况下修改代
价很低。如果Linux保持一个稳定的内核源代码接口,那么就得创建一个新的接口
;旧的,有问题的接口必须一直维护,给Linux USB开发者带来额外的工作。既然
所有的Linux USB驱动的作者都是利用自己的时间工作,那么要求他们去做毫无意
义的免费额外工作,是不可能的。
- 安全问题对Linux来说十分重要。一个安全问题被发现,就会在短时间内得到修
+安全问题对Linux来说十分重要。一个安全问题被发现,就会在短时间内得到修
正。在很多情况下,这将导致Linux内核中的一些接口被重写,以从根本上避免安
全问题。一旦接口被重写,所有使用这些接口的驱动程序,必须同时得到修正,
以确定安全问题已经得到修复并且不可能在未来还有同样的安全问题。如果内核
@@ -132,14 +137,14 @@ Linux能成为强壮,稳定,成熟的操作系统,这也是你最开始选
做什么事情。
把驱动放到内核源代码树里会有很多的好处:
+
- 驱动的质量会提升,而维护成本(对原始作者来说)会下降。
- 其他人会给驱动添加新特性。
- 其他人会找到驱动中的bug并修复。
- 其他人会在驱动中找到性能优化的机会。
- 当外部的接口的改变需要修改驱动程序的时候,其他人会修改驱动程序
-。
- 不需要联系任何发行商,这个驱动会自动的随着所有的Linux发布一起发
-布。
+ 布。
和别的操作系统相比,Linux为更多不同的设备提供现成的驱动,而且能在更多不
同体系结构的处理器上支持这些设备。这个经过考验的开发模式,必然是错不了
--
2.19.1.856.g8858448bb
to Make it readble in html etc doc making. And fix the wrong
translation for 'number' in form.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Jia Wei Wei <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/magic-number.rst | 210 +++++++++---------
1 file changed, 104 insertions(+), 106 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/magic-number.rst b/Documentation/translations/zh_CN/process/magic-number.rst
index 7159cec04090..15c592518194 100644
--- a/Documentation/translations/zh_CN/process/magic-number.rst
+++ b/Documentation/translations/zh_CN/process/magic-number.rst
@@ -1,33 +1,29 @@
-Chinese translated version of Documentation/process/magic-number.rst
+.. _cn_magicnumbers:
-If you have any comment or update to the content, please post to LKML directly.
-However, if you have problem communicating in English you can also ask the
-Chinese maintainer for help. Contact the Chinese maintainer, if this
-translation is outdated or there is problem with translation.
+.. include:: ../disclaimer-zh_CN.rst
-Chinese maintainer: Jia Wei Wei <[email protected]>
----------------------------------------------------------------------
-Documentation/process/magic-number.rst的中文翻译
+:Original: :ref:`Documentation/process/magic-number.rst <magicnumbers>`
如果想评论或更新本文的内容,请直接发信到LKML。如果你使用英文交流有困难的话,也可
-以向中文版维护者求助。如果本翻译更新不及时或者翻译存在问题,请联系中文版维护者。
+以向中文版维护者求助。如果本翻译更新不及时或者翻译存在问题,请联系中文版维护者::
-中文版维护者: 贾威威 Jia Wei Wei <[email protected]>
-中文版翻译者: 贾威威 Jia Wei Wei <[email protected]>
-中文版校译者: 贾威威 Jia Wei Wei <[email protected]>
+ 中文版维护者: 贾威威 Jia Wei Wei <[email protected]>
+ 中文版翻译者: 贾威威 Jia Wei Wei <[email protected]>
+ 中文版校译者: 贾威威 Jia Wei Wei <[email protected]>
+
+Linux 魔术数
+============
-以下为正文
----------------------------------------------------------------------
这个文件是有关当前使用的魔术值注册表。当你给一个结构添加了一个魔术值,你也应该把这个魔术值添加到这个文件,因为我们最好把用于各种结构的魔术值统一起来。
使用魔术值来保护内核数据结构是一个非常好的主意。这就允许你在运行期检查(a)一个结构是否已经被攻击,或者(b)你已经给一个例行程序通过了一个错误的结构。后一种情况特别地有用---特别是当你通过一个空指针指向结构体的时候。tty源码,例如,经常通过特定驱动使用这种方法并且反复地排列特定方面的结构。
-使用魔术值的方法是在结构的开始处声明的,如下:
+使用魔术值的方法是在结构的开始处声明的,如下::
-struct tty_ldisc {
- int magic;
- ...
-};
+ struct tty_ldisc {
+ int magic;
+ ...
+ };
当你以后给内核添加增强功能的时候,请遵守这条规则!这样就会节省数不清的调试时间,特别是一些古怪的情况,例如,数组超出范围并且重新写了超出部分。遵守这个规则,这些情况可以被快速地,安全地避免。
@@ -58,93 +54,95 @@ struct tty_ldisc {
<[email protected]>
09 Jul 2003
-魔术名 地址 结构 所在文件
-===========================================================================
-PG_MAGIC 'P' pg_{read,write}_hdr include/linux/pg.h
-CMAGIC 0x0111 user include/linux/a.out.h
-MKISS_DRIVER_MAGIC 0x04bf mkiss_channel drivers/net/mkiss.h
-HDLC_MAGIC 0x239e n_hdlc drivers/char/n_hdlc.c
-APM_BIOS_MAGIC 0x4101 apm_user arch/x86/kernel/apm_32.c
-CYCLADES_MAGIC 0x4359 cyclades_port include/linux/cyclades.h
-DB_MAGIC 0x4442 fc_info drivers/net/iph5526_novram.c
-DL_MAGIC 0x444d fc_info drivers/net/iph5526_novram.c
-FASYNC_MAGIC 0x4601 fasync_struct include/linux/fs.h
-FF_MAGIC 0x4646 fc_info drivers/net/iph5526_novram.c
-ISICOM_MAGIC 0x4d54 isi_port include/linux/isicom.h
-PTY_MAGIC 0x5001 drivers/char/pty.c
-PPP_MAGIC 0x5002 ppp include/linux/if_pppvar.h
-SERIAL_MAGIC 0x5301 async_struct include/linux/serial.h
-SSTATE_MAGIC 0x5302 serial_state include/linux/serial.h
-SLIP_MAGIC 0x5302 slip drivers/net/slip.h
-STRIP_MAGIC 0x5303 strip drivers/net/strip.c
-X25_ASY_MAGIC 0x5303 x25_asy drivers/net/x25_asy.h
-SIXPACK_MAGIC 0x5304 sixpack drivers/net/hamradio/6pack.h
-AX25_MAGIC 0x5316 ax_disp drivers/net/mkiss.h
-TTY_MAGIC 0x5401 tty_struct include/linux/tty.h
-MGSL_MAGIC 0x5401 mgsl_info drivers/char/synclink.c
-TTY_DRIVER_MAGIC 0x5402 tty_driver include/linux/tty_driver.h
-MGSLPC_MAGIC 0x5402 mgslpc_info drivers/char/pcmcia/synclink_cs.c
-TTY_LDISC_MAGIC 0x5403 tty_ldisc include/linux/tty_ldisc.h
-USB_SERIAL_MAGIC 0x6702 usb_serial drivers/usb/serial/usb-serial.h
-FULL_DUPLEX_MAGIC 0x6969 drivers/net/ethernet/dec/tulip/de2104x.c
-USB_BLUETOOTH_MAGIC 0x6d02 usb_bluetooth drivers/usb/class/bluetty.c
-RFCOMM_TTY_MAGIC 0x6d02 net/bluetooth/rfcomm/tty.c
-USB_SERIAL_PORT_MAGIC 0x7301 usb_serial_port drivers/usb/serial/usb-serial.h
-CG_MAGIC 0x00090255 ufs_cylinder_group include/linux/ufs_fs.h
-RPORT_MAGIC 0x00525001 r_port drivers/char/rocket_int.h
-LSEMAGIC 0x05091998 lse drivers/fc4/fc.c
-GDTIOCTL_MAGIC 0x06030f07 gdth_iowr_str drivers/scsi/gdth_ioctl.h
-RIEBL_MAGIC 0x09051990 drivers/net/atarilance.c
-NBD_REQUEST_MAGIC 0x12560953 nbd_request include/linux/nbd.h
-RED_MAGIC2 0x170fc2a5 (any) mm/slab.c
-BAYCOM_MAGIC 0x19730510 baycom_state drivers/net/baycom_epp.c
-ISDN_X25IFACE_MAGIC 0x1e75a2b9 isdn_x25iface_proto_data
- drivers/isdn/isdn_x25iface.h
-ECP_MAGIC 0x21504345 cdkecpsig include/linux/cdk.h
-LSOMAGIC 0x27091997 lso drivers/fc4/fc.c
-LSMAGIC 0x2a3b4d2a ls drivers/fc4/fc.c
-WANPIPE_MAGIC 0x414C4453 sdla_{dump,exec} include/linux/wanpipe.h
-CS_CARD_MAGIC 0x43525553 cs_card sound/oss/cs46xx.c
-LABELCL_MAGIC 0x4857434c labelcl_info_s include/asm/ia64/sn/labelcl.h
-ISDN_ASYNC_MAGIC 0x49344C01 modem_info include/linux/isdn.h
-CTC_ASYNC_MAGIC 0x49344C01 ctc_tty_info drivers/s390/net/ctctty.c
-ISDN_NET_MAGIC 0x49344C02 isdn_net_local_s drivers/isdn/i4l/isdn_net_lib.h
-SAVEKMSG_MAGIC2 0x4B4D5347 savekmsg arch/*/amiga/config.c
-CS_STATE_MAGIC 0x4c4f4749 cs_state sound/oss/cs46xx.c
-SLAB_C_MAGIC 0x4f17a36d kmem_cache mm/slab.c
-COW_MAGIC 0x4f4f4f4d cow_header_v1 arch/um/drivers/ubd_user.c
-I810_CARD_MAGIC 0x5072696E i810_card sound/oss/i810_audio.c
-TRIDENT_CARD_MAGIC 0x5072696E trident_card sound/oss/trident.c
-ROUTER_MAGIC 0x524d4157 wan_device [in wanrouter.h pre 3.9]
-SAVEKMSG_MAGIC1 0x53415645 savekmsg arch/*/amiga/config.c
-GDA_MAGIC 0x58464552 gda arch/mips/include/asm/sn/gda.h
-RED_MAGIC1 0x5a2cf071 (any) mm/slab.c
-EEPROM_MAGIC_VALUE 0x5ab478d2 lanai_dev drivers/atm/lanai.c
-HDLCDRV_MAGIC 0x5ac6e778 hdlcdrv_state include/linux/hdlcdrv.h
-PCXX_MAGIC 0x5c6df104 channel drivers/char/pcxx.h
-KV_MAGIC 0x5f4b565f kernel_vars_s arch/mips/include/asm/sn/klkernvars.h
-I810_STATE_MAGIC 0x63657373 i810_state sound/oss/i810_audio.c
-TRIDENT_STATE_MAGIC 0x63657373 trient_state sound/oss/trident.c
-M3_CARD_MAGIC 0x646e6f50 m3_card sound/oss/maestro3.c
-FW_HEADER_MAGIC 0x65726F66 fw_header drivers/atm/fore200e.h
-SLOT_MAGIC 0x67267321 slot drivers/hotplug/cpqphp.h
-SLOT_MAGIC 0x67267322 slot drivers/hotplug/acpiphp.h
-LO_MAGIC 0x68797548 nbd_device include/linux/nbd.h
-OPROFILE_MAGIC 0x6f70726f super_block drivers/oprofile/oprofilefs.h
-M3_STATE_MAGIC 0x734d724d m3_state sound/oss/maestro3.c
-VMALLOC_MAGIC 0x87654320 snd_alloc_track sound/core/memory.c
-KMALLOC_MAGIC 0x87654321 snd_alloc_track sound/core/memory.c
-PWC_MAGIC 0x89DC10AB pwc_device drivers/usb/media/pwc.h
-NBD_REPLY_MAGIC 0x96744668 nbd_reply include/linux/nbd.h
-ENI155_MAGIC 0xa54b872d midway_eprom drivers/atm/eni.h
-CODA_MAGIC 0xC0DAC0DA coda_file_info include/linux/coda_fs_i.h
-DPMEM_MAGIC 0xc0ffee11 gdt_pci_sram drivers/scsi/gdth.h
-YAM_MAGIC 0xF10A7654 yam_port drivers/net/hamradio/yam.c
-CCB_MAGIC 0xf2691ad2 ccb drivers/scsi/ncr53c8xx.c
-QUEUE_MAGIC_FREE 0xf7e1c9a3 queue_entry drivers/scsi/arm/queue.c
-QUEUE_MAGIC_USED 0xf7e1cc33 queue_entry drivers/scsi/arm/queue.c
-HTB_CMAGIC 0xFEFAFEF1 htb_class net/sched/sch_htb.c
-NMI_MAGIC 0x48414d4d455201 nmi_s arch/mips/include/asm/sn/nmi.h
+===================== ================ ======================== ==========================================
+魔术数名 数字 结构 文件
+===================== ================ ======================== ==========================================
+PG_MAGIC 'P' pg_{read,write}_hdr ``include/linux/pg.h``
+CMAGIC 0x0111 user ``include/linux/a.out.h``
+MKISS_DRIVER_MAGIC 0x04bf mkiss_channel ``drivers/net/mkiss.h``
+HDLC_MAGIC 0x239e n_hdlc ``drivers/char/n_hdlc.c``
+APM_BIOS_MAGIC 0x4101 apm_user ``arch/x86/kernel/apm_32.c``
+CYCLADES_MAGIC 0x4359 cyclades_port ``include/linux/cyclades.h``
+DB_MAGIC 0x4442 fc_info ``drivers/net/iph5526_novram.c``
+DL_MAGIC 0x444d fc_info ``drivers/net/iph5526_novram.c``
+FASYNC_MAGIC 0x4601 fasync_struct ``include/linux/fs.h``
+FF_MAGIC 0x4646 fc_info ``drivers/net/iph5526_novram.c``
+ISICOM_MAGIC 0x4d54 isi_port ``include/linux/isicom.h``
+PTY_MAGIC 0x5001 ``drivers/char/pty.c``
+PPP_MAGIC 0x5002 ppp ``include/linux/if_pppvar.h``
+SERIAL_MAGIC 0x5301 async_struct ``include/linux/serial.h``
+SSTATE_MAGIC 0x5302 serial_state ``include/linux/serial.h``
+SLIP_MAGIC 0x5302 slip ``drivers/net/slip.h``
+STRIP_MAGIC 0x5303 strip ``drivers/net/strip.c``
+X25_ASY_MAGIC 0x5303 x25_asy ``drivers/net/x25_asy.h``
+SIXPACK_MAGIC 0x5304 sixpack ``drivers/net/hamradio/6pack.h``
+AX25_MAGIC 0x5316 ax_disp ``drivers/net/mkiss.h``
+TTY_MAGIC 0x5401 tty_struct ``include/linux/tty.h``
+MGSL_MAGIC 0x5401 mgsl_info ``drivers/char/synclink.c``
+TTY_DRIVER_MAGIC 0x5402 tty_driver ``include/linux/tty_driver.h``
+MGSLPC_MAGIC 0x5402 mgslpc_info ``drivers/char/pcmcia/synclink_cs.c``
+TTY_LDISC_MAGIC 0x5403 tty_ldisc ``include/linux/tty_ldisc.h``
+USB_SERIAL_MAGIC 0x6702 usb_serial ``drivers/usb/serial/usb-serial.h``
+FULL_DUPLEX_MAGIC 0x6969 ``drivers/net/ethernet/dec/tulip/de2104x.c``
+USB_BLUETOOTH_MAGIC 0x6d02 usb_bluetooth ``drivers/usb/class/bluetty.c``
+RFCOMM_TTY_MAGIC 0x6d02 ``net/bluetooth/rfcomm/tty.c``
+USB_SERIAL_PORT_MAGIC 0x7301 usb_serial_port ``drivers/usb/serial/usb-serial.h``
+CG_MAGIC 0x00090255 ufs_cylinder_group ``include/linux/ufs_fs.h``
+RPORT_MAGIC 0x00525001 r_port ``drivers/char/rocket_int.h``
+LSEMAGIC 0x05091998 lse ``drivers/fc4/fc.c``
+GDTIOCTL_MAGIC 0x06030f07 gdth_iowr_str ``drivers/scsi/gdth_ioctl.h``
+RIEBL_MAGIC 0x09051990 ``drivers/net/atarilance.c``
+NBD_REQUEST_MAGIC 0x12560953 nbd_request ``include/linux/nbd.h``
+RED_MAGIC2 0x170fc2a5 (any) ``mm/slab.c``
+BAYCOM_MAGIC 0x19730510 baycom_state ``drivers/net/baycom_epp.c``
+ISDN_X25IFACE_MAGIC 0x1e75a2b9 isdn_x25iface_proto_data ``drivers/isdn/isdn_x25iface.h``
+ECP_MAGIC 0x21504345 cdkecpsig ``include/linux/cdk.h``
+LSOMAGIC 0x27091997 lso ``drivers/fc4/fc.c``
+LSMAGIC 0x2a3b4d2a ls ``drivers/fc4/fc.c``
+WANPIPE_MAGIC 0x414C4453 sdla_{dump,exec} ``include/linux/wanpipe.h``
+CS_CARD_MAGIC 0x43525553 cs_card ``sound/oss/cs46xx.c``
+LABELCL_MAGIC 0x4857434c labelcl_info_s ``include/asm/ia64/sn/labelcl.h``
+ISDN_ASYNC_MAGIC 0x49344C01 modem_info ``include/linux/isdn.h``
+CTC_ASYNC_MAGIC 0x49344C01 ctc_tty_info ``drivers/s390/net/ctctty.c``
+ISDN_NET_MAGIC 0x49344C02 isdn_net_local_s ``drivers/isdn/i4l/isdn_net_lib.h``
+SAVEKMSG_MAGIC2 0x4B4D5347 savekmsg ``arch/*/amiga/config.c``
+CS_STATE_MAGIC 0x4c4f4749 cs_state ``sound/oss/cs46xx.c``
+SLAB_C_MAGIC 0x4f17a36d kmem_cache ``mm/slab.c``
+COW_MAGIC 0x4f4f4f4d cow_header_v1 ``arch/um/drivers/ubd_user.c``
+I810_CARD_MAGIC 0x5072696E i810_card ``sound/oss/i810_audio.c``
+TRIDENT_CARD_MAGIC 0x5072696E trident_card ``sound/oss/trident.c``
+ROUTER_MAGIC 0x524d4157 wan_device [in ``wanrouter.h`` pre 3.9]
+SAVEKMSG_MAGIC1 0x53415645 savekmsg ``arch/*/amiga/config.c``
+GDA_MAGIC 0x58464552 gda ``arch/mips/include/asm/sn/gda.h``
+RED_MAGIC1 0x5a2cf071 (any) ``mm/slab.c``
+EEPROM_MAGIC_VALUE 0x5ab478d2 lanai_dev ``drivers/atm/lanai.c``
+HDLCDRV_MAGIC 0x5ac6e778 hdlcdrv_state ``include/linux/hdlcdrv.h``
+PCXX_MAGIC 0x5c6df104 channel ``drivers/char/pcxx.h``
+KV_MAGIC 0x5f4b565f kernel_vars_s ``arch/mips/include/asm/sn/klkernvars.h``
+I810_STATE_MAGIC 0x63657373 i810_state ``sound/oss/i810_audio.c``
+TRIDENT_STATE_MAGIC 0x63657373 trient_state ``sound/oss/trident.c``
+M3_CARD_MAGIC 0x646e6f50 m3_card ``sound/oss/maestro3.c``
+FW_HEADER_MAGIC 0x65726F66 fw_header ``drivers/atm/fore200e.h``
+SLOT_MAGIC 0x67267321 slot ``drivers/hotplug/cpqphp.h``
+SLOT_MAGIC 0x67267322 slot ``drivers/hotplug/acpiphp.h``
+LO_MAGIC 0x68797548 nbd_device ``include/linux/nbd.h``
+OPROFILE_MAGIC 0x6f70726f super_block ``drivers/oprofile/oprofilefs.h``
+M3_STATE_MAGIC 0x734d724d m3_state ``sound/oss/maestro3.c``
+VMALLOC_MAGIC 0x87654320 snd_alloc_track ``sound/core/memory.c``
+KMALLOC_MAGIC 0x87654321 snd_alloc_track ``sound/core/memory.c``
+PWC_MAGIC 0x89DC10AB pwc_device ``drivers/usb/media/pwc.h``
+NBD_REPLY_MAGIC 0x96744668 nbd_reply ``include/linux/nbd.h``
+ENI155_MAGIC 0xa54b872d midway_eprom ``drivers/atm/eni.h``
+CODA_MAGIC 0xC0DAC0DA coda_file_info ``fs/coda/coda_fs_i.h``
+DPMEM_MAGIC 0xc0ffee11 gdt_pci_sram ``drivers/scsi/gdth.h``
+YAM_MAGIC 0xF10A7654 yam_port ``drivers/net/hamradio/yam.c``
+CCB_MAGIC 0xf2691ad2 ccb ``drivers/scsi/ncr53c8xx.c``
+QUEUE_MAGIC_FREE 0xf7e1c9a3 queue_entry ``drivers/scsi/arm/queue.c``
+QUEUE_MAGIC_USED 0xf7e1cc33 queue_entry ``drivers/scsi/arm/queue.c``
+HTB_CMAGIC 0xFEFAFEF1 htb_class ``net/sched/sch_htb.c``
+NMI_MAGIC 0x48414d4d455201 nmi_s ``arch/mips/include/asm/sn/nmi.h``
+===================== ================ ======================== ==========================================
+
请注意,在声音记忆管理中仍然有一些特殊的为每个驱动定义的魔术值。查看include/sound/sndmagic.h来获取他们完整的列表信息。很多OSS声音驱动拥有自己从声卡PCI ID构建的魔术值-他们也没有被列在这里。
--
2.19.1.856.g8858448bb
Tame howto.rst file to avoid "ERROR: Unexpected indentation." etc
compiler errors.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: TripleX Chung <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../translations/zh_CN/process/howto.rst | 32 +++++++++++++++++--
1 file changed, 30 insertions(+), 2 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/howto.rst b/Documentation/translations/zh_CN/process/howto.rst
index 4c46eb90f43f..6ab167812325 100644
--- a/Documentation/translations/zh_CN/process/howto.rst
+++ b/Documentation/translations/zh_CN/process/howto.rst
@@ -38,6 +38,7 @@ Linux内核大部分是由C语言写成的,一些体系结构相关的代码
参与内核开发,你必须精通C语言。除非你想为某个架构开发底层代码,否则你并
不需要了解(任何体系结构的)汇编语言。下面列举的书籍虽然不能替代扎实的C
语言教育和多年的开发经验,但如果需要的话,做为参考还是不错的:
+
- "The C Programming Language" by Kernighan and Ritchie [Prentice Hall]
《C程序设计语言(第2版·新版)》(徐宝文 李志 译)[机械工业出版社]
- "Practical C Programming" by Steve Oualline [O'Reilly]
@@ -94,16 +95,20 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
Documentation/process/submitting-patches.rst
Documentation/process/submitting-drivers.rst
+
这两份文档明确描述如何创建和发送补丁,其中包括(但不仅限于):
- 邮件内容
- 邮件格式
- 选择收件人
+
遵守这些规定并不能保证提交成功(因为所有补丁需要通过严格的内容和风格
审查),但是忽视他们几乎就意味着失败。
其他关于如何正确地生成补丁的优秀文档包括:
"The Perfect Patch"
+
http://www.ozlabs.org/~akpm/stuff/tpp.txt
+
"Linux kernel patch submission format"
http://linux.yyz.us/patch-format.html
@@ -111,9 +116,11 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
Documentation/process/stable-api-nonsense.rst
论证内核为什么特意不包括稳定的内核内部API,也就是说不包括像这样的特
性:
+
- 子系统中间层(为了兼容性?)
- 在不同操作系统间易于移植的驱动程序
- 减缓(甚至阻止)内核代码的快速变化
+
这篇文档对于理解Linux的开发哲学至关重要。对于将开发平台从其他操作系
统转移到Linux的人来说也很重要。
@@ -140,6 +147,7 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
妥善处理加锁的规则。生成的文档会放在 Documentation/DocBook/目录下。在内
核源码的主目录中使用以下不同命令将会分别生成PDF、Postscript、HTML和手册
页等不同格式的文档:
+
make pdfdocs
make htmldocs
@@ -147,7 +155,9 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
如何成为内核开发者
------------------
如果你对Linux内核开发一无所知,你应该访问“Linux内核新手”计划:
+
http://kernelnewbies.org
+
它拥有一个可以问各种最基本的内核开发问题的邮件列表(在提问之前一定要记得
查找已往的邮件,确认是否有人已经回答过相同的问题)。它还拥有一个可以获得
实时反馈的IRC聊天频道,以及大量对于学习Linux内核开发相当有帮助的文档。
@@ -158,7 +168,9 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
如果你想加入内核开发社区并协助完成一些任务,却找不到从哪里开始,可以访问
“Linux内核房管员”计划:
+
http://kernelnewbies.org/KernelJanitors
+
这是极佳的起点。它提供一个相对简单的任务列表,列出内核代码中需要被重新
整理或者改正的地方。通过和负责这个计划的开发者们一同工作,你会学到将补丁
集成进内核的基本原理。如果还没有决定下一步要做什么的话,你还可能会得到方
@@ -167,6 +179,7 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
如果你已经有一些现成的代码想要放到内核中,但是需要一些帮助来使它们拥有正
确的格式。请访问“内核导师”计划。这个计划就是用来帮助你完成这个目标的。它
是一个邮件列表,地址如下:
+
http://selenic.com/mailman/listinfo/kernel-mentors
在真正动手修改内核代码之前,理解要修改的代码如何运作是必需的。要达到这个
@@ -174,6 +187,7 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
一些特制的工具还可以提供帮助。例如,“Linux代码交叉引用”项目就是一个值得
特别推荐的帮助工具,它将源代码显示在有编目和索引的网页上。其中一个更新及
时的内核源码库,可以通过以下地址访问:
+
http://sosdg.org/~coywolf/lxr/
@@ -182,6 +196,7 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
目前Linux内核开发流程包括几个“主内核分支”和很多子系统相关的内核分支。这
些分支包括:
+
- 2.6.x主内核源码树
- 2.6.x.y -stable内核源码树
- 2.6.x -mm内核补丁集
@@ -193,6 +208,7 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
2.6.x内核是由Linus Torvalds(Linux的创造者)亲自维护的。你可以在
kernel.org网站的pub/linux/kernel/v2.6/目录下找到它。它的开发遵循以下步
骤:
+
- 每当一个新版本的内核被发布,为期两周的集成窗口将被打开。在这段时间里
维护者可以向Linus提交大段的修改,通常这些修改已经被放到-mm内核中几个
星期了。提交大量修改的首选方式是使用git工具(内核的代码版本管理工具
@@ -308,6 +324,7 @@ linux-kernel邮件列表中提供反馈,告诉大家你遇到了问题还是
bugzilla.kernel.org是Linux内核开发者们用来跟踪内核Bug的网站。我们鼓励用
户在这个工具中报告找到的所有bug。如何使用内核bugzilla的细节请访问:
+
http://test.kernel.org/bugzilla/faq.html
内核源码主目录中的admin-guide/reporting-bugs.rst文件里有一个很好的模板。它指导用户如何报
@@ -335,10 +352,14 @@ bugzilla.kernel.org是Linux内核开发者们用来跟踪内核Bug的网站。
正如上面的文档所描述,大多数的骨干内核开发者都加入了Linux Kernel邮件列
表。如何订阅和退订列表的细节可以在这里找到:
+
http://vger.kernel.org/vger-lists.html#linux-kernel
+
网上很多地方都有这个邮件列表的存档(archive)。可以使用搜索引擎来找到这些
存档。比如:
+
http://dir.gmane.org/gmane.linux.kernel
+
在发信之前,我们强烈建议你先在存档中搜索你想要讨论的问题。很多已经被详细
讨论过的问题只在邮件列表的存档中可以找到。
@@ -346,10 +367,12 @@ bugzilla.kernel.org是Linux内核开发者们用来跟踪内核Bug的网站。
MAINTAINERS文件中可以找到不同话题对应的邮件列表。
很多邮件列表架设在kernel.org服务器上。这些列表的信息可以在这里找到:
+
http://vger.kernel.org/vger-lists.html
在使用这些邮件列表时,请记住保持良好的行为习惯。下面的链接提供了与这些列
表(或任何其它邮件列表)交流的一些简单规则,虽然内容有点滥竽充数。
+
http://www.albion.com/netiquette/
当有很多人回复你的邮件时,邮件的抄送列表会变得很长。请不要将任何人从抄送
@@ -375,6 +398,7 @@ Documentation/process/submitting-patches.rst文档中所述)。内核开发者
内核社区的目标就是提供尽善尽美的内核。所以当你提交补丁期望被接受进内核的
时候,它的技术价值以及其他方面都将被评审。那么你可能会得到什么呢?
+
- 批评
- 评论
- 要求修改
@@ -387,6 +411,7 @@ Documentation/process/submitting-patches.rst文档中所述)。内核开发者
没在茫茫信海中。
你不应该做的事情:
+
- 期望自己的补丁不受任何质疑就直接被接受
- 翻脸
- 忽略别人的评论
@@ -406,7 +431,8 @@ Documentation/process/submitting-patches.rst文档中所述)。内核开发者
内核社区的工作模式同大多数传统公司开发队伍的工作模式并不相同。下面这些例
子,可以帮助你避免某些可能发生问题:
- 用这些话介绍你的修改提案会有好处:
+用这些话介绍你的修改提案会有好处:
+
- 它同时解决了多个问题
- 它删除了2000行代码
- 这是补丁,它已经解释了我想要说明的
@@ -414,7 +440,8 @@ Documentation/process/submitting-patches.rst文档中所述)。内核开发者
- 这是一系列小补丁用来……
- 这个修改提高了普通机器的性能……
- 应该避免如下的说法:
+应该避免如下的说法:
+
- 我们在AIX/ptx/Solaris就是这么做的,所以这么做肯定是好的……
- 我做这行已经20年了,所以……
- 为了我们公司赚钱考虑必须这么做
@@ -487,6 +514,7 @@ Linux内核社区并不喜欢一下接收大段的代码。修改需要被恰当
当你发送补丁的时候,需要特别留意邮件正文的内容。因为这里的信息将会做为补
丁的修改记录(ChangeLog),会被一直保留以备大家查阅。它需要完全地描述补丁,
包括:
+
- 为什么需要这个修改
- 补丁的总体设计
- 实现细节
--
2.19.1.856.g8858448bb
I am not working for Intel or Linaro, so udpate the email address.
Signed-off-by: Alex Shi <[email protected]>
Cc: Andrew Morton <[email protected]>
Cc: Li Yang <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.mailmap | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.mailmap b/.mailmap
index e5979518c396..7dc884c03d13 100644
--- a/.mailmap
+++ b/.mailmap
@@ -16,6 +16,8 @@ Alan Cox <[email protected]>
Alan Cox <[email protected]>
Aleksey Gorelov <[email protected]>
Aleksandar Markovic <[email protected]> <[email protected]>
+Alex Shi <[email protected]> <[email protected]>
+Alex Shi <[email protected]> <[email protected]>
Al Viro <[email protected]>
Al Viro <[email protected]>
Andi Shyti <[email protected]> <[email protected]>
--
2.19.1.856.g8858448bb
Change [email protected] and [email protected] to active address:
[email protected]
Signed-off-by: Alex Shi <[email protected]>
Cc: Li Yang <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
Documentation/translations/zh_CN/oops-tracing.txt | 2 +-
Documentation/translations/zh_CN/process/howto.rst | 4 ++--
.../translations/zh_CN/process/stable-api-nonsense.rst | 2 +-
.../translations/zh_CN/process/stable-kernel-rules.rst | 2 +-
.../translations/zh_CN/process/submitting-drivers.rst | 4 ++--
.../translations/zh_CN/process/submitting-patches.rst | 2 +-
Documentation/translations/zh_CN/sparse.txt | 6 +++---
7 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/Documentation/translations/zh_CN/oops-tracing.txt b/Documentation/translations/zh_CN/oops-tracing.txt
index a893f04dfd5d..93fa061cf9e4 100644
--- a/Documentation/translations/zh_CN/oops-tracing.txt
+++ b/Documentation/translations/zh_CN/oops-tracing.txt
@@ -16,7 +16,7 @@ Documentation/admin-guide/bug-hunting.rst 的中文翻译
中文版维护者: 杨瑞 Dave Young <[email protected]>
中文版翻译者: 杨瑞 Dave Young <[email protected]>
-中文版校译者: 李阳 Li Yang <[email protected]>
+中文版校译者: 李阳 Li Yang <[email protected]>
王聪 Wang Cong <[email protected]>
以下为正文
diff --git a/Documentation/translations/zh_CN/process/howto.rst b/Documentation/translations/zh_CN/process/howto.rst
index f25a74fb90da..4c46eb90f43f 100644
--- a/Documentation/translations/zh_CN/process/howto.rst
+++ b/Documentation/translations/zh_CN/process/howto.rst
@@ -9,8 +9,8 @@
译存在问题,请联系中文版维护者::
英文版维护者: Greg Kroah-Hartman <[email protected]>
- 中文版维护者: 李阳 Li Yang <[email protected]>
- 中文版翻译者: 李阳 Li Yang <[email protected]>
+ 中文版维护者: 李阳 Li Yang <[email protected]>
+ 中文版翻译者: 李阳 Li Yang <[email protected]>
中文版校译者:
钟宇 TripleX Chung <[email protected]>
陈琦 Maggie Chen <[email protected]>
diff --git a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
index e97bcf5c44ce..f11829429000 100644
--- a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
+++ b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
@@ -12,7 +12,7 @@
英文版维护者: Greg Kroah-Hartman <[email protected]>
中文版维护者: 钟宇 TripleX Chung <[email protected]>
中文版翻译者: 钟宇 TripleX Chung <[email protected]>
- 中文版校译者: 李阳 Li Yang <[email protected]>
+ 中文版校译者: 李阳 Li Yang <[email protected]>
Linux 内核驱动接口
==================
diff --git a/Documentation/translations/zh_CN/process/stable-kernel-rules.rst b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
index 425d06f99ac2..3d5a10dfc1ae 100644
--- a/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
+++ b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
@@ -11,7 +11,7 @@
中文版维护者: 钟宇 TripleX Chung <[email protected]>
中文版翻译者: 钟宇 TripleX Chung <[email protected]>
中文版校译者:
- - 李阳 Li Yang <[email protected]>
+ - 李阳 Li Yang <[email protected]>
- Kangkai Yin <[email protected]>
所有你想知道的事情 - 关于linux稳定版发布
diff --git a/Documentation/translations/zh_CN/process/submitting-drivers.rst b/Documentation/translations/zh_CN/process/submitting-drivers.rst
index c90ab5ae233d..fade72515b04 100644
--- a/Documentation/translations/zh_CN/process/submitting-drivers.rst
+++ b/Documentation/translations/zh_CN/process/submitting-drivers.rst
@@ -9,8 +9,8 @@
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
译存在问题,请联系中文版维护者::
- 中文版维护者: 李阳 Li Yang <[email protected]>
- 中文版翻译者: 李阳 Li Yang <[email protected]>
+ 中文版维护者: 李阳 Li Yang <[email protected]>
+ 中文版翻译者: 李阳 Li Yang <[email protected]>
中文版校译者: 陈琦 Maggie Chen <[email protected]>
王聪 Wang Cong <[email protected]>
张巍 Zhang Wei <[email protected]>
diff --git a/Documentation/translations/zh_CN/process/submitting-patches.rst b/Documentation/translations/zh_CN/process/submitting-patches.rst
index 2a2989733c8d..54d2d45e27df 100644
--- a/Documentation/translations/zh_CN/process/submitting-patches.rst
+++ b/Documentation/translations/zh_CN/process/submitting-patches.rst
@@ -10,7 +10,7 @@
中文版维护者: 钟宇 TripleX Chung <[email protected]>
中文版翻译者: 钟宇 TripleX Chung <[email protected]>
- 中文版校译者: 李阳 Li Yang <[email protected]>
+ 中文版校译者: 李阳 Li Yang <[email protected]>
王聪 Wang Cong <[email protected]>
diff --git a/Documentation/translations/zh_CN/sparse.txt b/Documentation/translations/zh_CN/sparse.txt
index 2f728962a8e2..47fc4a06ebe8 100644
--- a/Documentation/translations/zh_CN/sparse.txt
+++ b/Documentation/translations/zh_CN/sparse.txt
@@ -6,7 +6,7 @@ communicating in English you can also ask the Chinese maintainer for
help. Contact the Chinese maintainer if this translation is outdated
or if there is a problem with the translation.
-Chinese maintainer: Li Yang <[email protected]>
+Chinese maintainer: Li Yang <[email protected]>
---------------------------------------------------------------------
Documentation/dev-tools/sparse.rst 的中文翻译
@@ -14,8 +14,8 @@ Documentation/dev-tools/sparse.rst 的中文翻译
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
译存在问题,请联系中文版维护者。
-中文版维护者: 李阳 Li Yang <[email protected]>
-中文版翻译者: 李阳 Li Yang <[email protected]>
+中文版维护者: 李阳 Li Yang <[email protected]>
+中文版翻译者: 李阳 Li Yang <[email protected]>
以下为正文
--
2.19.1.856.g8858448bb
renamed: Documentation/translations/zh_CN/process/SubmittingPatches
-> Documentation/translations/zh_CN/process/submitting-patches.rst
For htmldoc links. And will change the doc format to rst.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/{SubmittingPatches => submitting-patches.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{SubmittingPatches => submitting-patches.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/SubmittingPatches b/Documentation/translations/zh_CN/process/submitting-patches.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/SubmittingPatches
rename to Documentation/translations/zh_CN/process/submitting-patches.rst
--
2.19.1.856.g8858448bb
make it readble as rst format for html etc doc making.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Bryan Wu <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../process/volatile-considered-harmful.rst | 35 ++++++++-----------
1 file changed, 14 insertions(+), 21 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/volatile-considered-harmful.rst b/Documentation/translations/zh_CN/process/volatile-considered-harmful.rst
index 475125967197..48b32ce58ef1 100644
--- a/Documentation/translations/zh_CN/process/volatile-considered-harmful.rst
+++ b/Documentation/translations/zh_CN/process/volatile-considered-harmful.rst
@@ -1,30 +1,23 @@
-Chinese translated version of Documentation/process/volatile-considered-harmful.rst
+.. _cn_volatile_considered_harmful:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have a problem
-communicating in English you can also ask the Chinese maintainer for
-help. Contact the Chinese maintainer if this translation is outdated
-or if there is a problem with the translation.
+.. include:: ../disclaimer-zh_CN.rst
-Maintainer: Jonathan Corbet <[email protected]>
-Chinese maintainer: Bryan Wu <[email protected]>
----------------------------------------------------------------------
-Documentation/process/volatile-considered-harmful.rst 的中文翻译
+:Original: :ref:`Documentation/process/volatile-considered-harmful.rst
+ <volatile_considered_harmful>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
-英文版维护者: Jonathan Corbet <[email protected]>
-中文版维护者: 伍鹏 Bryan Wu <[email protected]>
-中文版翻译者: 伍鹏 Bryan Wu <[email protected]>
-中文版校译者: 张汉辉 Eugene Teo <[email protected]>
- 杨瑞 Dave Young <[email protected]>
-以下为正文
----------------------------------------------------------------------
+ 英文版维护者: Jonathan Corbet <[email protected]>
+ 中文版维护者: 伍鹏 Bryan Wu <[email protected]>
+ 中文版翻译者: 伍鹏 Bryan Wu <[email protected]>
+ 中文版校译者: 张汉辉 Eugene Teo <[email protected]>
+ 杨瑞 Dave Young <[email protected]>
+ 时奎亮 Alex Shi <[email protected]>
为什么不应该使用“volatile”类型
-------------------------------
+==============================
C程序员通常认为volatile表示某个变量可以在当前执行的线程之外被改变;因此,在内核
中用到共享数据结构时,常常会有C程序员喜欢使用volatile这类变量。换句话说,他们经
@@ -41,7 +34,7 @@ C程序员通常认为volatile表示某个变量可以在当前执行的线程
必要再使用volatile。如果仍然必须使用volatile,那么几乎可以肯定在代码的某处有一
个bug。在正确设计的内核代码中,volatile能带来的仅仅是使事情变慢。
-思考一下这段典型的内核代码:
+思考一下这段典型的内核代码::
spin_lock(&the_lock);
do_something_on(&shared_data);
@@ -66,7 +59,7 @@ volatile的存储类型最初是为那些内存映射的I/O寄存器而定义。
是必需的。
另一种引起用户可能使用volatile的情况是当处理器正忙着等待一个变量的值。正确执行一
-个忙等待的方法是:
+个忙等待的方法是::
while (my_variable != what_i_want)
cpu_relax();
--
2.19.1.856.g8858448bb
Update the obslete email address to active one in Chineses docs.
Signed-off-by: Alex Shi <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Yang <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../translations/zh_CN/process/stable-api-nonsense.rst | 4 ++--
.../translations/zh_CN/process/stable-kernel-rules.rst | 4 ++--
.../translations/zh_CN/process/submitting-patches.rst | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
index f11829429000..42d974e6dc35 100644
--- a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
+++ b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
@@ -10,8 +10,8 @@
译存在问题,请联系中文版维护者::
英文版维护者: Greg Kroah-Hartman <[email protected]>
- 中文版维护者: 钟宇 TripleX Chung <[email protected]>
- 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
+ 中文版维护者: 钟宇 TripleX Chung <[email protected]>
+ 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
中文版校译者: 李阳 Li Yang <[email protected]>
Linux 内核驱动接口
diff --git a/Documentation/translations/zh_CN/process/stable-kernel-rules.rst b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
index 3d5a10dfc1ae..fb048c42ae48 100644
--- a/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
+++ b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
@@ -8,8 +8,8 @@
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
译存在问题,请联系中文版维护者::
- 中文版维护者: 钟宇 TripleX Chung <[email protected]>
- 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
+ 中文版维护者: 钟宇 TripleX Chung <[email protected]>
+ 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
中文版校译者:
- 李阳 Li Yang <[email protected]>
- Kangkai Yin <[email protected]>
diff --git a/Documentation/translations/zh_CN/process/submitting-patches.rst b/Documentation/translations/zh_CN/process/submitting-patches.rst
index 54d2d45e27df..47cdca62cfa2 100644
--- a/Documentation/translations/zh_CN/process/submitting-patches.rst
+++ b/Documentation/translations/zh_CN/process/submitting-patches.rst
@@ -8,8 +8,8 @@
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
译存在问题,请联系中文版维护者::
- 中文版维护者: 钟宇 TripleX Chung <[email protected]>
- 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
+ 中文版维护者: 钟宇 TripleX Chung <[email protected]>
+ 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
中文版校译者: 李阳 Li Yang <[email protected]>
王聪 Wang Cong <[email protected]>
--
2.19.1.856.g8858448bb
This web site is on sale, and Li Yang said it won't be in service again.
Signed-off-by: Alex Shi <[email protected]>
Cc: Greg Kroah-Hartman <[email protected]>
Cc: Li Yang <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
MAINTAINERS | 1 -
1 file changed, 1 deletion(-)
diff --git a/MAINTAINERS b/MAINTAINERS
index 4f004dc0a0f2..4d9132d19567 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3727,7 +3727,6 @@ F: scripts/checkpatch.pl
CHINESE DOCUMENTATION
M: Harry Wei <[email protected]>
L: [email protected] (subscribers-only)
-L: [email protected] (moderated for non-subscribers)
S: Maintained
F: Documentation/translations/zh_CN/
--
2.19.1.856.g8858448bb
Update the obsolete email address [email protected] and
[email protected] with [email protected].
Signed-off-by: Alex Shi <[email protected]>
Cc: Andrew Morton <[email protected]>
Cc: Li Yang <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.mailmap | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.mailmap b/.mailmap
index 37e1847c7988..705c4f11f1a3 100644
--- a/.mailmap
+++ b/.mailmap
@@ -117,6 +117,8 @@ Leonid I Ananiev <[email protected]>
Linas Vepstas <[email protected]>
Linus Lüssing <[email protected]> <[email protected]>
Linus Lüssing <[email protected]> <[email protected]>
+Li Yang <[email protected]> <[email protected]>
+Li Yang <[email protected]> <[email protected]>
Maciej W. Rozycki <[email protected]> <[email protected]>
Marcin Nowakowski <[email protected]> <[email protected]>
Mark Brown <[email protected]>
--
2.19.1.856.g8858448bb
Much process documents spread here isn't neat. It's good to put them together
in their directory: process
So create 'process' directory and move docs:
email-clients stable_kernel_rules stable_api_nosense
submittingpatches submittingdrivers HOWTO
volatile-considered-harmful
there.
Signed-off-by: Alex Shi <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
Documentation/translations/zh_CN/{ => process}/HOWTO | 0
Documentation/translations/zh_CN/{ => process}/SubmittingDrivers | 0
Documentation/translations/zh_CN/{ => process}/SubmittingPatches | 0
Documentation/translations/zh_CN/{ => process}/coding-style.rst | 0
Documentation/translations/zh_CN/{ => process}/email-clients.txt | 0
Documentation/translations/zh_CN/{ => process}/magic-number.txt | 0
.../translations/zh_CN/{ => process}/stable_api_nonsense.txt | 0
.../translations/zh_CN/{ => process}/stable_kernel_rules.txt | 0
.../zh_CN/{ => process}/volatile-considered-harmful.txt | 0
9 files changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/{ => process}/HOWTO (100%)
rename Documentation/translations/zh_CN/{ => process}/SubmittingDrivers (100%)
rename Documentation/translations/zh_CN/{ => process}/SubmittingPatches (100%)
rename Documentation/translations/zh_CN/{ => process}/coding-style.rst (100%)
rename Documentation/translations/zh_CN/{ => process}/email-clients.txt (100%)
rename Documentation/translations/zh_CN/{ => process}/magic-number.txt (100%)
rename Documentation/translations/zh_CN/{ => process}/stable_api_nonsense.txt (100%)
rename Documentation/translations/zh_CN/{ => process}/stable_kernel_rules.txt (100%)
rename Documentation/translations/zh_CN/{ => process}/volatile-considered-harmful.txt (100%)
diff --git a/Documentation/translations/zh_CN/HOWTO b/Documentation/translations/zh_CN/process/HOWTO
similarity index 100%
rename from Documentation/translations/zh_CN/HOWTO
rename to Documentation/translations/zh_CN/process/HOWTO
diff --git a/Documentation/translations/zh_CN/SubmittingDrivers b/Documentation/translations/zh_CN/process/SubmittingDrivers
similarity index 100%
rename from Documentation/translations/zh_CN/SubmittingDrivers
rename to Documentation/translations/zh_CN/process/SubmittingDrivers
diff --git a/Documentation/translations/zh_CN/SubmittingPatches b/Documentation/translations/zh_CN/process/SubmittingPatches
similarity index 100%
rename from Documentation/translations/zh_CN/SubmittingPatches
rename to Documentation/translations/zh_CN/process/SubmittingPatches
diff --git a/Documentation/translations/zh_CN/coding-style.rst b/Documentation/translations/zh_CN/process/coding-style.rst
similarity index 100%
rename from Documentation/translations/zh_CN/coding-style.rst
rename to Documentation/translations/zh_CN/process/coding-style.rst
diff --git a/Documentation/translations/zh_CN/email-clients.txt b/Documentation/translations/zh_CN/process/email-clients.txt
similarity index 100%
rename from Documentation/translations/zh_CN/email-clients.txt
rename to Documentation/translations/zh_CN/process/email-clients.txt
diff --git a/Documentation/translations/zh_CN/magic-number.txt b/Documentation/translations/zh_CN/process/magic-number.txt
similarity index 100%
rename from Documentation/translations/zh_CN/magic-number.txt
rename to Documentation/translations/zh_CN/process/magic-number.txt
diff --git a/Documentation/translations/zh_CN/stable_api_nonsense.txt b/Documentation/translations/zh_CN/process/stable_api_nonsense.txt
similarity index 100%
rename from Documentation/translations/zh_CN/stable_api_nonsense.txt
rename to Documentation/translations/zh_CN/process/stable_api_nonsense.txt
diff --git a/Documentation/translations/zh_CN/stable_kernel_rules.txt b/Documentation/translations/zh_CN/process/stable_kernel_rules.txt
similarity index 100%
rename from Documentation/translations/zh_CN/stable_kernel_rules.txt
rename to Documentation/translations/zh_CN/process/stable_kernel_rules.txt
diff --git a/Documentation/translations/zh_CN/volatile-considered-harmful.txt b/Documentation/translations/zh_CN/process/volatile-considered-harmful.txt
similarity index 100%
rename from Documentation/translations/zh_CN/volatile-considered-harmful.txt
rename to Documentation/translations/zh_CN/process/volatile-considered-harmful.txt
--
2.19.1.856.g8858448bb
to make it follow rst format and readble in html etc doc making.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/stable-api-nonsense.rst | 34 ++++++++-----------
1 file changed, 15 insertions(+), 19 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
index a2b27fab382c..e97bcf5c44ce 100644
--- a/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
+++ b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
@@ -1,26 +1,21 @@
-Chinese translated version of Documentation/process/stable-api-nonsense.rst
+.. _cn_stable_api_nonsense:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have problem
-communicating in English you can also ask the Chinese maintainer for help.
-Contact the Chinese maintainer, if this translation is outdated or there
-is problem with translation.
+.. include:: ../disclaimer-zh_CN.rst
-Maintainer: Greg Kroah-Hartman <[email protected]>
-Chinese maintainer: TripleX Chung <[email protected]>
----------------------------------------------------------------------
-Documentation/process/stable-api-nonsense.rst 的中文翻译
+:Original: :ref:`Documentation/process/stable-api-nonsense.rst
+ <stable_api_nonsense>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
-英文版维护者: Greg Kroah-Hartman <[email protected]>
-中文版维护者: 钟宇 TripleX Chung <[email protected]>
-中文版翻译者: 钟宇 TripleX Chung <[email protected]>
-中文版校译者: 李阳 Li Yang <[email protected]>
-以下为正文
----------------------------------------------------------------------
+ 英文版维护者: Greg Kroah-Hartman <[email protected]>
+ 中文版维护者: 钟宇 TripleX Chung <[email protected]>
+ 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
+ 中文版校译者: 李阳 Li Yang <[email protected]>
+
+Linux 内核驱动接口
+==================
写作本文档的目的,是为了解释为什么Linux既没有二进制内核接口,也没有稳定
的内核接口。这里所说的内核接口,是指内核里的接口,而不是内核和用户空间
@@ -124,7 +119,7 @@ Linux能成为强壮,稳定,成熟的操作系统,这也是你最开始选
要做什么
--------
+--------
如果你写了一个Linux内核驱动,但是它还不在Linux源代码树里,作为一个开发
者,你应该怎么做?为每个发布的每个版本提供一个二进制驱动,那简直是一个
@@ -150,7 +145,8 @@ Linux能成为强壮,稳定,成熟的操作系统,这也是你最开始选
同体系结构的处理器上支持这些设备。这个经过考验的开发模式,必然是错不了
的 :)
--------------
+感谢
+----
感谢 Randy Dunlap, Andrew Morton, David Brownell, Hanna Linder,
Robert Love, and Nishanth Aravamudan 对于本文档早期版本的评审和建议。
--
2.19.1.856.g8858448bb
Tame 'make htmldocs' w/o indent complains.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: TripleX Chung <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../translations/zh_CN/process/submitting-drivers.rst | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/Documentation/translations/zh_CN/process/submitting-drivers.rst b/Documentation/translations/zh_CN/process/submitting-drivers.rst
index 43c0e4530362..3be51d998c80 100644
--- a/Documentation/translations/zh_CN/process/submitting-drivers.rst
+++ b/Documentation/translations/zh_CN/process/submitting-drivers.rst
@@ -137,9 +137,13 @@ Linux 设备驱动程序,第三版(探讨 2.6.10 版内核):
LWN.net:
每周内核开发活动摘要 - http://lwn.net/
+
2.6 版中 API 的变更:
+
http://lwn.net/Articles/2.6-kernel-api/
+
将旧版内核的驱动程序移植到 2.6 版:
+
http://lwn.net/Articles/driver-porting/
内核新手(KernelNewbies):
--
2.19.1.856.g8858448bb
Rename the file to make it available in html etc docs making.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/{SubmittingDrivers => submitting-drivers.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{SubmittingDrivers => submitting-drivers.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/SubmittingDrivers b/Documentation/translations/zh_CN/process/submitting-drivers.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/SubmittingDrivers
rename to Documentation/translations/zh_CN/process/submitting-drivers.rst
--
2.19.1.856.g8858448bb
Make it available for html etc docs making.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Bryan Wu <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
...ile-considered-harmful.txt => volatile-considered-harmful.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{volatile-considered-harmful.txt => volatile-considered-harmful.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/volatile-considered-harmful.txt b/Documentation/translations/zh_CN/process/volatile-considered-harmful.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/volatile-considered-harmful.txt
rename to Documentation/translations/zh_CN/process/volatile-considered-harmful.rst
--
2.19.1.856.g8858448bb
make it available in html etc doc making
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../process/{stable_api_nonsense.txt => stable-api-nonsense.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{stable_api_nonsense.txt => stable-api-nonsense.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/stable_api_nonsense.txt b/Documentation/translations/zh_CN/process/stable-api-nonsense.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/stable_api_nonsense.txt
rename to Documentation/translations/zh_CN/process/stable-api-nonsense.rst
--
2.19.1.856.g8858448bb
to Make it readble with rst format.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/stable-kernel-rules.rst | 32 +++++++++----------
1 file changed, 15 insertions(+), 17 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/stable-kernel-rules.rst b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
index db4ba5a0c39a..425d06f99ac2 100644
--- a/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
+++ b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
@@ -1,31 +1,26 @@
-Chinese translated version of Documentation/process/stable-kernel-rules.rst
+.. _cn_stable_kernel_rules:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have a problem
-communicating in English you can also ask the Chinese maintainer for
-help. Contact the Chinese maintainer if this translation is outdated
-or if there is a problem with the translation.
+.. include:: ../disclaimer-zh_CN.rst
-Chinese maintainer: TripleX Chung <[email protected]>
----------------------------------------------------------------------
-Documentation/process/stable-kernel-rules.rst 的中文翻译
+:Original: :ref:`Documentation/process/stable-kernel-rules.rst <stable_kernel_rules>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
+ 中文版维护者: 钟宇 TripleX Chung <[email protected]>
+ 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
+ 中文版校译者:
+ - 李阳 Li Yang <[email protected]>
+ - Kangkai Yin <[email protected]>
-中文版维护者: 钟宇 TripleX Chung <[email protected]>
-中文版翻译者: 钟宇 TripleX Chung <[email protected]>
-中文版校译者: 李阳 Li Yang <[email protected]>
- Kangkai Yin <[email protected]>
-
-以下为正文
----------------------------------------------------------------------
+所有你想知道的事情 - 关于linux稳定版发布
+========================================
关于Linux 2.6稳定版发布,所有你想知道的事情。
关于哪些类型的补丁可以被接收进入稳定版代码树,哪些不可以的规则:
+----------------------------------------------------------------
- 必须是显而易见的正确,并且经过测试的。
- 连同上下文,不能大于100行。
@@ -41,6 +36,7 @@ Documentation/process/stable-kernel-rules.rst 的中文翻译
- 必须遵循Documentation/process/submitting-patches.rst里的规则。
向稳定版代码树提交补丁的过程:
+------------------------------
- 在确认了补丁符合以上的规则后,将补丁发送到[email protected]。
- 如果补丁被接受到队列里,发送者会收到一个ACK回复,如果没有被接受,收
@@ -49,6 +45,7 @@ Documentation/process/stable-kernel-rules.rst 的中文翻译
- 安全方面的补丁不要发到这个列表,应该发送到[email protected]。
审查周期:
+----------
- 当稳定版的维护者决定开始一个审查周期,补丁将被发送到审查委员会,以
及被补丁影响的领域的维护者(除非提交者就是该领域的维护者)并且抄送
@@ -63,4 +60,5 @@ Documentation/process/stable-kernel-rules.rst 的中文翻译
通常的审查周期。请联系内核安全小组以获得关于这个过程的更多细节。
审查委员会:
+------------
- 由一些自愿承担这项任务的内核开发者,和几个非志愿的组成。
--
2.19.1.856.g8858448bb
also with few contents changes
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../translations/zh_CN/process/howto.rst | 37 ++++++++-----------
1 file changed, 15 insertions(+), 22 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/howto.rst b/Documentation/translations/zh_CN/process/howto.rst
index 7a00a8a4eb15..f25a74fb90da 100644
--- a/Documentation/translations/zh_CN/process/howto.rst
+++ b/Documentation/translations/zh_CN/process/howto.rst
@@ -1,32 +1,23 @@
-Chinese translated version of Documentation/process/howto.rst
+.. _cn_process_howto:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have a problem
-communicating in English you can also ask the Chinese maintainer for
-help. Contact the Chinese maintainer if this translation is outdated
-or if there is a problem with the translation.
+.. include:: ../disclaimer-zh_CN.rst
-Maintainer: Greg Kroah-Hartman <[email protected]>
-Chinese maintainer: Li Yang <[email protected]>
----------------------------------------------------------------------
-Documentation/process/howto.rst 的中文翻译
+:Original: :ref:`Documentation/process/howto.rst <process_howto>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
-英文版维护者: Greg Kroah-Hartman <[email protected]>
-中文版维护者: 李阳 Li Yang <[email protected]>
-中文版翻译者: 李阳 Li Yang <[email protected]>
-中文版校译者: 钟宇 TripleX Chung <[email protected]>
- 陈琦 Maggie Chen <[email protected]>
- 王聪 Wang Cong <[email protected]>
-
-以下为正文
----------------------------------------------------------------------
+ 英文版维护者: Greg Kroah-Hartman <[email protected]>
+ 中文版维护者: 李阳 Li Yang <[email protected]>
+ 中文版翻译者: 李阳 Li Yang <[email protected]>
+ 中文版校译者:
+ 钟宇 TripleX Chung <[email protected]>
+ 陈琦 Maggie Chen <[email protected]>
+ 王聪 Wang Cong <[email protected]>
如何参与Linux内核开发
----------------------
+=====================
这是一篇将如何参与Linux内核开发的相关问题一网打尽的终极秘笈。它将指导你
成为一名Linux内核开发者,并且学会如何同Linux内核开发社区合作。它尽可能不
@@ -114,6 +105,7 @@ Linux内核代码中包含有大量的文档。这些文档对于学习如何与
"The Perfect Patch"
http://www.ozlabs.org/~akpm/stuff/tpp.txt
"Linux kernel patch submission format"
+
http://linux.yyz.us/patch-format.html
Documentation/process/stable-api-nonsense.rst
@@ -510,7 +502,8 @@ Linux内核社区并不喜欢一下接收大段的代码。修改需要被恰当
很多人已经做到了,而他们都曾经和现在的你站在同样的起点上。
----------------
+感谢
+----
感谢Paolo Ciarrocchi允许“开发流程”部分基于他所写的文章
(http://www.kerneltravel.net/newbie/2.6-development_process),感谢Randy
Dunlap和Gerrit Huizenga完善了应该说和不该说的列表。感谢Pat Mochel, Hanna
--
2.19.1.856.g8858448bb
Make it readble as rst format.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/email-clients.rst | 53 ++++++++-----------
1 file changed, 22 insertions(+), 31 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/email-clients.rst b/Documentation/translations/zh_CN/process/email-clients.rst
index ec31d97e8d0e..e8641a5899e4 100644
--- a/Documentation/translations/zh_CN/process/email-clients.rst
+++ b/Documentation/translations/zh_CN/process/email-clients.rst
@@ -1,33 +1,24 @@
-Chinese translated version of Documentation/process/email-clients.rst
+.. _cn_email_clients:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have a problem
-communicating in English you can also ask the Chinese maintainer for
-help. Contact the Chinese maintainer if this translation is outdated
-or if there is a problem with the translation.
+.. include:: ../disclaimer-zh_CN.rst
-Chinese maintainer: Harry Wei <[email protected]>
----------------------------------------------------------------------
-Documentation/process/email-clients.rst 的中文翻译
+:Original: :ref:`Documentation/process/email-clients.rst <email_clients>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
-中文版维护者: 贾威威 Harry Wei <[email protected]>
-中文版翻译者: 贾威威 Harry Wei <[email protected]>
-中文版校译者: Yinglin Luan <[email protected]>
- Xiaochen Wang <[email protected]>
- yaxinsn <[email protected]>
-
-以下为正文
----------------------------------------------------------------------
+ 中文版维护者: 贾威威 Harry Wei <[email protected]>
+ 中文版翻译者: 贾威威 Harry Wei <[email protected]>
+ 中文版校译者: Yinglin Luan <[email protected]>
+ Xiaochen Wang <[email protected]>
+ yaxinsn <[email protected]>
Linux邮件客户端配置信息
-======================================================================
+=======================
普通配置
-----------------------------------------------------------------------
+--------
Linux内核补丁是通过邮件被提交的,最好把补丁作为邮件体的内嵌文本。有些维护者
接收附件,但是附件的内容格式应该是"text/plain"。然而,附件一般是不赞成的,
因为这会使补丁的引用部分在评论过程中变的很困难。
@@ -56,7 +47,7 @@ Linux内核补丁是通过邮件被提交的,最好把补丁作为邮件体的
一些邮件客户端提示
-----------------------------------------------------------------------
+------------------
这里给出一些详细的MUA配置提示,可以用于给Linux内核发送补丁。这些并不意味是
所有的软件包配置总结。
@@ -64,8 +55,8 @@ Linux内核补丁是通过邮件被提交的,最好把补丁作为邮件体的
TUI = 以文本为基础的用户接口
GUI = 图形界面用户接口
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Alpine (TUI)
+~~~~~~~~~~~~
配置选项:
在"Sending Preferences"部分:
@@ -76,8 +67,8 @@ Alpine (TUI)
当写邮件时,光标应该放在补丁会出现的地方,然后按下CTRL-R组合键,使指定的
补丁文件嵌入到邮件中。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Evolution (GUI)
+~~~~~~~~~~~~~~~
一些开发者成功的使用它发送补丁
@@ -89,8 +80,8 @@ Evolution (GUI)
你还可以"diff -Nru old.c new.c | xclip",选择Preformat,然后使用中间键进行粘帖。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Kmail (GUI)
+~~~~~~~~~~~
一些开发者成功的使用它发送补丁。
@@ -118,13 +109,13 @@ display",这样内嵌附件更容易让读者看到。
并且希望这将会被处理。邮件是以只针对某个用户可读写的权限被保存的,所以如果你想把邮件复制到其他地方,
你不得不把他们的权限改为组或者整体可读。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lotus Notes (GUI)
+~~~~~~~~~~~~~~~~~
不要使用它。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Mutt (TUI)
+~~~~~~~~~~
很多Linux开发人员使用mutt客户端,所以证明它肯定工作的非常漂亮。
@@ -146,8 +137,8 @@ Mutt不自带编辑器,所以不管你使用什么编辑器都不应该带有
它应该以默认设置的形式工作。
然而,把"send_charset"设置为"us-ascii::utf-8"也是一个不错的主意。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Pine (TUI)
+~~~~~~~~~~
Pine过去有一些空格删减问题,但是这些现在应该都被修复了。
@@ -158,8 +149,8 @@ Pine过去有一些空格删减问题,但是这些现在应该都被修复了
- "no-strip-whitespace-before-send"选项也是需要的。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Sylpheed (GUI)
+~~~~~~~~~~~~~~
- 内嵌文本可以很好的工作(或者使用附件)。
- 允许使用外部的编辑器。
@@ -168,8 +159,8 @@ Sylpheed (GUI)
- 在组成窗口中有一个很有用的ruler bar。
- 给地址本中添加地址就不会正确的了解显示名。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Thunderbird (GUI)
+~~~~~~~~~~~~~~~~~
默认情况下,thunderbird很容易损坏文本,但是还有一些方法可以强制它变得更好。
@@ -191,13 +182,13 @@ Thunderbird (GUI)
$EDITOR来读取或者合并补丁到文本中。要实现它,可以下载并且安装这个扩展,然后添加一个使用它的
按键View->Toolbars->Customize...最后当你书写信息的时候仅仅点击它就可以了。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
TkRat (GUI)
+~~~~~~~~~~~
可以使用它。使用"Insert file..."或者外部的编辑器。
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Gmail (Web GUI)
+~~~~~~~~~~~~~~~
不要使用它发送补丁。
--
2.19.1.856.g8858448bb
This patch renamed stable_kernel_rules.txt to stable-kernel-rules.rst
Make it available in htmldocs making.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../process/{stable_kernel_rules.txt => stable-kernel-rules.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{stable_kernel_rules.txt => stable-kernel-rules.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/stable_kernel_rules.txt b/Documentation/translations/zh_CN/process/stable-kernel-rules.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/stable_kernel_rules.txt
rename to Documentation/translations/zh_CN/process/stable-kernel-rules.rst
--
2.19.1.856.g8858448bb
And remove Enghlish explainations in the docs, which it isn't
necessary in Chinese doc.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: TripleX Chung <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/submitting-patches.rst | 36 +++++++------------
1 file changed, 13 insertions(+), 23 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/submitting-patches.rst b/Documentation/translations/zh_CN/process/submitting-patches.rst
index e9098da8f1a4..2a2989733c8d 100644
--- a/Documentation/translations/zh_CN/process/submitting-patches.rst
+++ b/Documentation/translations/zh_CN/process/submitting-patches.rst
@@ -1,31 +1,21 @@
-Chinese translated version of Documentation/process/submitting-patches.rst
+.. _cn_process_submittingpatches:
-If you have any comment or update to the content, please contact the
-original document maintainer directly. However, if you have a problem
-communicating in English you can also ask the Chinese maintainer for
-help. Contact the Chinese maintainer if this translation is outdated
-or if there is a problem with the translation.
+.. include:: ../disclaimer-zh_CN.rst
-Chinese maintainer: TripleX Chung <[email protected]>
----------------------------------------------------------------------
-Documentation/process/submitting-patches.rst 的中文翻译
+:Original: :ref:`Documentation/process/submitting-patches.rst <submittingpatches>`
如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文
交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻
-译存在问题,请联系中文版维护者。
+译存在问题,请联系中文版维护者::
-中文版维护者: 钟宇 TripleX Chung <[email protected]>
-中文版翻译者: 钟宇 TripleX Chung <[email protected]>
-中文版校译者: 李阳 Li Yang <[email protected]>
- 王聪 Wang Cong <[email protected]>
+ 中文版维护者: 钟宇 TripleX Chung <[email protected]>
+ 中文版翻译者: 钟宇 TripleX Chung <[email protected]>
+ 中文版校译者: 李阳 Li Yang <[email protected]>
+ 王聪 Wang Cong <[email protected]>
-以下为正文
----------------------------------------------------------------------
- 如何让你的改动进入内核
- 或者
- 获得亲爱的 Linus Torvalds 的关注和处理
-----------------------------------
+如何让你的改动进入内核
+======================
对于想要将改动提交到 Linux 内核的个人或者公司来说,如果不熟悉“规矩”,
提交的流程会让人畏惧。本文档收集了一系列建议,这些建议可以大大的提高你
@@ -35,12 +25,12 @@ Documentation/process/submitting-patches.rst 的中文翻译
Documentation/process/submitting-drivers.rst 。
---------------------------
+---------------------------
第一节 - 创建并发送你的改动
---------------------------
+---------------------------
1) "diff -up"
------------
+-------------
使用 "diff -up" 或者 "diff -uprN" 来创建补丁。
--
2.19.1.856.g8858448bb
This a disclaimer file which will be included in Chinese files
as header. To reduce the same common contents copy.
Part of contents quoted from Federico Vaga's file:
Documentation/translations/it_IT/disclaimer-ita.rst.
Thanks a lot!
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Cc: Federico Vaga <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
Documentation/translations/zh_CN/disclaimer-zh_CN.rst | 9 +++++++++
1 file changed, 9 insertions(+)
create mode 100644 Documentation/translations/zh_CN/disclaimer-zh_CN.rst
diff --git a/Documentation/translations/zh_CN/disclaimer-zh_CN.rst b/Documentation/translations/zh_CN/disclaimer-zh_CN.rst
new file mode 100644
index 000000000000..5934369b2606
--- /dev/null
+++ b/Documentation/translations/zh_CN/disclaimer-zh_CN.rst
@@ -0,0 +1,9 @@
+:orphan:
+
+.. warning::
+ 此文件的目的是为让中文读者更容易阅读和理解,而不是作为一个分支。 因此,如果
+ 您对此文件有任何意见或更新,请先尝试更新原始英文文件。
+
+.. note::
+ 如果您发现本文档与原始文件有任何不同或者有翻译问题,请联系该文件的维护者,
+ 或者请求时奎亮的帮助:<[email protected]>。
--
2.19.1.856.g8858448bb
Tame 'make htmldocs' to avoid indent and code section
error complains.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Yang <[email protected]>
Cc: TripleX Chung <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/submitting-patches.rst | 22 +++++++++++--------
1 file changed, 13 insertions(+), 9 deletions(-)
diff --git a/Documentation/translations/zh_CN/process/submitting-patches.rst b/Documentation/translations/zh_CN/process/submitting-patches.rst
index 47cdca62cfa2..66c64acf86c1 100644
--- a/Documentation/translations/zh_CN/process/submitting-patches.rst
+++ b/Documentation/translations/zh_CN/process/submitting-patches.rst
@@ -39,7 +39,7 @@ Documentation/process/submitting-drivers.rst 。
参数生成。而且,请使用 '-p' 参数,那样会显示每个改动所在的C函数,使得
产生的补丁容易读得多。补丁应该基于内核源代码树的根目录,而不是里边的任
何子目录。
-为一个单独的文件创建补丁,一般来说这样做就够了:
+为一个单独的文件创建补丁,一般来说这样做就够了::
SRCTREE= linux-2.6
MYFILE= drivers/net/mydriver.c
@@ -51,7 +51,7 @@ Documentation/process/submitting-drivers.rst 。
diff -up $SRCTREE/$MYFILE{.orig,} > /tmp/patch
为多个文件创建补丁,你可以解开一个没有修改过的内核源代码树,然后和你自
-己的代码树之间做 diff 。例如:
+己的代码树之间做 diff 。例如::
MYSRC= /devel/linux-2.6
@@ -141,6 +141,7 @@ MAINTAINERS 文件里的)发送一个手册页(man-pages)补丁,或者
对于小的补丁,你也许会CC到 Adrian Bunk 管理的搜集琐碎补丁的邮件列表
(Trivial Patch Monkey)[email protected],那里专门收集琐碎的补丁。下面这样
的补丁会被看作“琐碎的”补丁:
+
文档的拼写修正。
修正会影响到 grep(1) 的拼写。
警告信息修正(频繁的打印无用的警告是不好的。)
@@ -241,8 +242,10 @@ Linus 和 linux-kernel 邮件列表的 e-mail 流量都很高,一个通常的
"sign-off" 是在补丁的注释的最后的简单的一行文字,认证你编写了它或者其他
人有权力将它作为开放源代码的补丁传递。规则很简单:如果你能认证如下信息
:
- 开发者来源证书 1.1
- 对于本项目的贡献,我认证如下信息:
+开发者来源证书 1.1
+^^^^^^^^^^^^^^^^^^
+对于本项目的贡献,我认证如下信息:
+
(a)这些贡献是完全或者部分的由我创建,我有权利以文件中指出
的开放源代码许可证提交它;或者
(b)这些贡献基于以前的工作,据我所知,这些以前的工作受恰当的开放
@@ -295,7 +298,7 @@ e-mail 标题中的“一句话概述”扼要的描述 e-mail 中的补丁。
丁。用户将希望通过 google 来搜索"一句话概述"来找到那些讨论这个补丁的文
章。
-一些标题的例子:
+一些标题的例子::
Subject: [patch 2/5] ext2: improve scalability of bitmap searching
Subject: [PATCHv2 001/207] x86: fix eflags tracking
@@ -338,7 +341,7 @@ Nuff 说过,如果你的代码和这个偏离太多,那么它有可能会被
在头文件里,有条件地定义 "static inline" 函数,或者宏,在代码里用这些东
西。让编译器把那些"空操作"优化掉。
-一个简单的例子,不好的代码:
+一个简单的例子,不好的代码::
dev = alloc_etherdev (sizeof(struct funky_private));
if (!dev)
@@ -349,12 +352,14 @@ Nuff 说过,如果你的代码和这个偏离太多,那么它有可能会被
清理后的例子:
-(头文件里)
+(头文件里)::
+
#ifndef CONFIG_NET_FUNKINESS
static inline void init_funky_net (struct net_device *d) {}
#endif
-(代码文件里)
+(代码文件里)::
+
dev = alloc_etherdev (sizeof(struct funky_private));
if (!dev)
return -ENODEV;
@@ -399,4 +404,3 @@ Kernel Documentation/process/coding-style.rst:
Linus Torvalds's mail on the canonical patch format:
<http://lkml.org/lkml/2005/4/7/183>
---
--
2.19.1.856.g8858448bb
And add some description translation in index file.
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
Documentation/translations/zh_CN/index.rst | 17 +++++++++++++----
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/Documentation/translations/zh_CN/index.rst b/Documentation/translations/zh_CN/index.rst
index 75956d669962..d3165535ec9e 100644
--- a/Documentation/translations/zh_CN/index.rst
+++ b/Documentation/translations/zh_CN/index.rst
@@ -3,10 +3,19 @@
\renewcommand\thesection*
\renewcommand\thesubsection*
-Chinese translations
-====================
+中文翻译
+========
+
+这些手册包含有关如何开发内核的整体信息。内核社区非常庞大,一年下来有数千名开发
+人员做出贡献。 与任何大型社区一样,知道如何完成任务将使得更改合并的过程变得更
+加容易。
.. toctree::
- :maxdepth: 1
+ :maxdepth: 2
+
+ process/index
+
+目录和表格
+----------
- coding-style
+* :ref:`genindex`
--
2.19.1.856.g8858448bb
to Make it available in html etc doc making
Signed-off-by: Alex Shi <[email protected]>
Cc: Harry Wei <[email protected]>
Cc: Jonathan Corbet <[email protected]>
Cc: Jia Wei Wei <[email protected]>
Cc: Li Zefan <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: Fengguang Wu <[email protected]>
Cc: Coly Li <[email protected]>
Signed-off-by: Weiwei Jia <[email protected]>
---
.../zh_CN/process/{magic-number.txt => magic-number.rst} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename Documentation/translations/zh_CN/process/{magic-number.txt => magic-number.rst} (100%)
diff --git a/Documentation/translations/zh_CN/process/magic-number.txt b/Documentation/translations/zh_CN/process/magic-number.rst
similarity index 100%
rename from Documentation/translations/zh_CN/process/magic-number.txt
rename to Documentation/translations/zh_CN/process/magic-number.rst
--
2.19.1.856.g8858448bb
On Wed, 13 Mar 2019 21:49:30 +0800
Alex Shi <[email protected]> wrote:
> The following patches change existing Chinese kernel docs to rst format
> and reorg them to make them alive in 'make htmldocs'.
I have applied this set, thanks.
jon