Skip to contentSkip to conversation

docs/zh_CN: add parisc Chinese documents

PATCH Superseded Yanteng Si 4 participants 16 messages Apr 29, 2021 – May 7, 2021 1 message not in the archive

Subsystems (2)

v1 of 4 Superseded Latest is v4 →

lore
Share & tools
lore

Yanteng Si

author
#0 lore raw

cover docs/zh_CN: add parisc Chinese documents

This set translates Documentation/parisc/* into Chinese.

Yanteng Si (3):
docs/zh_CN: add parisc index translation docs/zh_CN: add parisc debugging.rst translation docs/zh_CN: add parisc registers.rst translation

 Documentation/translations/zh_CN/index.rst    |   1 +
 .../translations/zh_CN/parisc/debugging.rst   |  41 +++++
 .../translations/zh_CN/parisc/index.rst       |  28 ++++
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 4 files changed, 223 insertions(+)
 create mode 100644 Documentation/translations/zh_CN/parisc/debugging.rst
 create mode 100644 Documentation/translations/zh_CN/parisc/index.rst
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Signature · 1 line
2.27.0
author
#1 lore raw

PATCH 1/3 docs/zh_CN: add parisc index translation

This path translates Documentation/parisc/index.rst into Chinese.

---
 Documentation/translations/zh_CN/index.rst    |  1 +
 .../translations/zh_CN/parisc/index.rst       | 24 +++++++++++++++++++
 2 files changed, 25 insertions(+)
 create mode 100644 Documentation/translations/zh_CN/parisc/index.rst
Documentation/translations/zh_CN/index.rst +1 -0
index ee6b20ca9080..160a55f819bf 100644
@@ -30,6 +30,7 @@
    riscv/index
    core-api/index
    openrisc/index
+   parisc/index
 
 目录和表格
 ----------
Documentation/translations/zh_CN/parisc/index.rst new file +24 -0
new file mode 100644
index 000000000000..ef232d46b1ba
@@ -0,0 +1,24 @@
+.. SPDX-License-Identifier: GPL-2.0
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/index.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_index:
+
+====================
+PA-RISC体系架构
+====================
+
+Todolist:
+
+   debugging
+   registers
+   features
+
+.. only::  subproject and html
+
+   Indices
+   =======
+
+   * :ref:`genindex`
Signature · 1 line
2.27.0
Reviewed-by on v1 1/3
#2 lore raw

Re: [PATCH 1/3] docs/zh_CN: add parisc index translation

Quoted 3 lines · Yanteng Si

This path translates Documentation/parisc/index.rst into Chinese.

PA-RISC docs are silent, lastest practical activity on 2013-07-09.

Quoted 50 lines
---
 Documentation/translations/zh_CN/index.rst    |  1 +
 .../translations/zh_CN/parisc/index.rst       | 24 +++++++++++++++++++
 2 files changed, 25 insertions(+)
 create mode 100644 Documentation/translations/zh_CN/parisc/index.rst
Documentation/translations/zh_CN/index.rst +1 -0
index ee6b20ca9080..160a55f819bf 100644
@@ -30,6 +30,7 @@
    riscv/index
    core-api/index
    openrisc/index
+   parisc/index
 
 目录和表格
 ----------
Documentation/translations/zh_CN/parisc/index.rst new file +24 -0
new file mode 100644
index 000000000000..ef232d46b1ba
@@ -0,0 +1,24 @@
+.. SPDX-License-Identifier: GPL-2.0
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/index.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_index:
+
+====================
+PA-RISC体系架构
+====================
+
+Todolist:
+
+   debugging
+   registers
+   features
+
+.. only::  subproject and html
+
+   Indices
+   =======
+
+   * :ref:`genindex`
Signature · 1 line
2.27.0
maintainer
#3 lore raw

Re: [PATCH 1/3] docs/zh_CN: add parisc index translation

Quoted 8 lines · Wu X.C.
Quoted 3 lines · Yanteng Si

This path translates Documentation/parisc/index.rst into Chinese.

PA-RISC docs are silent, lastest practical activity on 2013-07-09.

Indeed...PA-RISC in general is not a hotbed of activity these days. Is there some need in particular that is driving this translation? The work is there and I'll apply it, but I do wonder why...

Thanks,

jon

A message that is not in the archive (sent off-list or not yet received): CAEensMxWmRppXmxuYEsq-jS-psQ8N1Zim-d+CCOckig__RfN5w@mail.gmail.com

#5 lore raw

Re: [PATCH 1/3] docs/zh_CN: add parisc index translation

Quoted 14 lines · yanteng si <[email protected]> 于2021年4月30日周五 下午2:26写道:
Quoted 10 lines · Jonathan Corbet <[email protected]> 于2021年4月30日周五 上午12:16写道:
Quoted 7 lines · Wu X.C.
Quoted 3 lines · Yanteng Si

This path translates Documentation/parisc/index.rst into Chinese.

Quoted 8 lines
Quoted 6 lines
Quoted 1 line

PA-RISC docs are silent, lastest practical activity on 2013-07-09.

Indeed...PA-RISC in general is not a hotbed of activity these days. Is there some need in particular that is driving this translation? The work is there and I'll apply it, but I do wonder why...

Just for fun, I just translated it after reading the English document. ~>_<~

My web version of Gmail occasionally switched to HTML mode and emails were dropped by the doc-list. T_T

author
#6 lore raw

PATCH 2/3 docs/zh_CN: add parisc debugging.rst translation

In reply to Yanteng Si

This translates Documentation/parisc/debugging.rst into Chinese.

---
 .../translations/zh_CN/parisc/debugging.rst   | 41 +++++++++++++++++++
 .../translations/zh_CN/parisc/index.rst       |  6 ++-
 2 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/debugging.rst
Documentation/translations/zh_CN/parisc/debugging.rst new file +41 -0
new file mode 100644
index 000000000000..99af303fd3d8
@@ -0,0 +1,41 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/debugging.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_debugging:
+
+=================
+调试PA-RISC
+=================
+
+好吧,这里有一些关于调试linux/parisc的低级(偏硬件)部分的提示。
+
+
+1. 绝对地址
+=====================
+
+很多汇编代码目前是以实模式运行的,这意味着绝对地址被使用,而不是像内核其他
+部分那样使用虚拟地址。要将绝对地址转换为虚拟地址,你可以在System.map中查
+找,添加__PAGE_OFFSET(目前是0x10000000)。
+
+
+2. HPMCs
+========
+
+当实模式的代码试图访问不存在的内存时,你会得到一个HPMC,而不是一个内核opps。
+为了调试HPMC,尝试找到系统响应者/请求者地址。系统请求者地址应该与处理器的
+HPA(I/O范围内的高地址)相匹配;系统响应者地址是实模式代码试图访问的地址。
+
+系统响应者地址的典型值是大于__PAGE_OFFSET (0x10000000)的地址,这意味着
+在实际模式代码试图访问它之前,一个虚拟地址没有被翻译成一个物理地址。
+
+
+3. 有趣的Q位
+============
+
+某些非常关键的代码必须清除PSW中的Q位。当Q位被清除时,CPU不会更新中断处理
+程序所读取的寄存器,以找出机器被中断的位置——所以如果你在清除Q位的指令和再
+次设置Q位的RFI之间遇到中断,你不知道它到底发生在哪里。如果你幸运的话,IAOQ
+会指向清除Q位的指令,如果你不幸运的话,它会指向任何地方。通常Q位的问题会
+表现在无法解释的系统挂起或运行到物理内存的末端。
Documentation/translations/zh_CN/parisc/index.rst +5 -1
index ef232d46b1ba..b913d664e735 100644
@@ -10,9 +10,13 @@
 PA-RISC体系架构
 ====================
 
-Todolist:
+.. toctree::
+   :maxdepth: 2
 
    debugging
+
+Todolist:
+
    registers
    features
 
Signature · 1 line
2.27.0
#7 lore raw

Re: [PATCH 2/3] docs/zh_CN: add parisc debugging.rst translation

Quoted 17 lines · Yanteng Si

This translates Documentation/parisc/debugging.rst into Chinese.

---
 .../translations/zh_CN/parisc/debugging.rst   | 41 +++++++++++++++++++
 .../translations/zh_CN/parisc/index.rst       |  6 ++-
 2 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/debugging.rst
Documentation/translations/zh_CN/parisc/debugging.rst new file +2 -0
new file mode 100644
index 000000000000..99af303fd3d8
@@ -0,0 +1,41 @@
+.. include:: ../disclaimer-zh_CN.rst
+

Documentation/translations/zh_CN/parisc/debugging.rst line 12

Quoted 10 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +10 -0
+:Original: Documentation/parisc/debugging.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_debugging:
+
+=================
+调试PA-RISC
+=================
+
+好吧,这里有一些关于调试linux/parisc的低级(偏硬件)部分的提示。

maybe
较底层部分的信息。
depend on your choice

Documentation/translations/zh_CN/parisc/debugging.rst line 18

Quoted 6 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +6 -0
+
+
+1. 绝对地址
+=====================
+
+很多汇编代码目前是以实模式运行的,这意味着绝对地址被使用,而不是像内核其他

很多汇编代码目前运行在实模式下,这意味着会使用绝对地址,而不是像内核其他

Documentation/translations/zh_CN/parisc/debugging.rst line 25

Quoted 7 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +7 -0
+部分那样使用虚拟地址。要将绝对地址转换为虚拟地址,你可以在System.map中查
+找,添加__PAGE_OFFSET(目前是0x10000000)。
+
+
+2. HPMCs
+========
+

high priority machine check

Documentation/translations/zh_CN/parisc/debugging.rst line 26

Quoted 1 line
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+当实模式的代码试图访问不存在的内存时,你会得到一个HPMC,而不是一个内核opps。

会出现HPMC而不是内核oops。

Documentation/translations/zh_CN/parisc/debugging.rst line 27

Quoted 1 line
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+为了调试HPMC,尝试找到系统响应者/请求者地址。系统请求者地址应该与处理器的

要调试HPMC,请尝试……

(某)处理器

s/响应者/响应程序/g
s/请求者/请求程序/g
replace all

Documentation/translations/zh_CN/parisc/debugging.rst line 31

Quoted 4 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+HPA(I/O范围内的高地址)相匹配;系统响应者地址是实模式代码试图访问的地址。
+
+系统响应者地址的典型值是大于__PAGE_OFFSET (0x10000000)的地址,这意味着
+在实际模式代码试图访问它之前,一个虚拟地址没有被翻译成一个物理地址。

在实模式试图访问它之前,虚拟地址没有被翻译成物理地址。

Documentation/translations/zh_CN/parisc/debugging.rst line 41

Quoted 10 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +10 -0
+
+
+3. 有趣的Q位
+============
+
+某些非常关键的代码必须清除PSW中的Q位。当Q位被清除时,CPU不会更新中断处理
+程序所读取的寄存器,以找出机器被中断的位置——所以如果你在清除Q位的指令和再
+次设置Q位的RFI之间遇到中断,你不知道它到底发生在哪里。如果你幸运的话,IAOQ
+会指向清除Q位的指令,如果你不幸运的话,它会指向任何地方。通常Q位的问题会
+表现在无法解释的系统挂起或运行到物理内存的末端。

How about 表现为无法解释的系统挂起或物理内存越界。

Quoted 21 lines
Documentation/translations/zh_CN/parisc/index.rst +5 -1
index ef232d46b1ba..b913d664e735 100644
@@ -10,9 +10,13 @@
 PA-RISC体系架构
 ====================
 
-Todolist:
+.. toctree::
+   :maxdepth: 2
 
    debugging
+
+Todolist:
+
    registers
    features
 
Signature · 1 line
2.27.0

Thanks

Wu X.C.

#8 lore raw

Re: [PATCH 2/3] docs/zh_CN: add parisc debugging.rst translation

Quoted 25 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:13写道:
Quoted 23 lines · Yanteng Si

This translates Documentation/parisc/debugging.rst into Chinese.

---
 .../translations/zh_CN/parisc/debugging.rst   | 41 +++++++++++++++++++
 .../translations/zh_CN/parisc/index.rst       |  6 ++-
 2 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/debugging.rst
Documentation/translations/zh_CN/parisc/debugging.rst new file +8 -0
new file mode 100644
index 000000000000..99af303fd3d8
@@ -0,0 +1,41 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/debugging.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_debugging:
+
+=================
Quoted 8 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 12

Quoted 4 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+调试PA-RISC
+=================
+
+好吧,这里有一些关于调试linux/parisc的低级(偏硬件)部分的提示。

maybe
较底层部分的信息。
depend on your choice

OK! use 较底层部分的信息。

Quoted 9 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 18

Quoted 7 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +6 -0
+
+
+1. 绝对地址
+=====================
+
+很多汇编代码目前是以实模式运行的,这意味着绝对地址被使用,而不是像内核其他

很多汇编代码目前运行在实模式下,这意味着会使用绝对地址,而不是像内核其他

ok!

Quoted 10 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 25

Quoted 8 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +7 -0
+部分那样使用虚拟地址。要将绝对地址转换为虚拟地址,你可以在System.map中查
+找,添加__PAGE_OFFSET(目前是0x10000000)。
+
+
+2. HPMCs
+========
+

high priority machine check

OK!

Quoted 4 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 26

Quoted 2 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+当实模式的代码试图访问不存在的内存时,你会得到一个HPMC,而不是一个内核opps。

会出现HPMC而不是内核oops。

How about 会打印HPMC而不是内核oops?

Quoted 4 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 27

Quoted 2 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+为了调试HPMC,尝试找到系统响应者/请求者地址。系统请求者地址应该与处理器的

要调试HPMC,请尝试……

maybe 若要调试HPMC,请尝试……?

Quoted 2 lines

(某)处理器

use 该处理器 ?

Quoted 4 lines

s/响应者/响应程序/g
s/请求者/请求程序/g
replace all

OK!

Quoted 7 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 31

Quoted 5 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+HPA(I/O范围内的高地址)相匹配;系统响应者地址是实模式代码试图访问的地址。
+
+系统响应者地址的典型值是大于__PAGE_OFFSET (0x10000000)的地址,这意味着
+在实际模式代码试图访问它之前,一个虚拟地址没有被翻译成一个物理地址。

在实模式试图访问它之前,虚拟地址没有被翻译成物理地址。

OK!

Quoted 13 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 41

Quoted 11 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +10 -0
+
+
+3. 有趣的Q位
+============
+
+某些非常关键的代码必须清除PSW中的Q位。当Q位被清除时,CPU不会更新中断处理
+程序所读取的寄存器,以找出机器被中断的位置——所以如果你在清除Q位的指令和再
+次设置Q位的RFI之间遇到中断,你不知道它到底发生在哪里。如果你幸运的话,IAOQ
+会指向清除Q位的指令,如果你不幸运的话,它会指向任何地方。通常Q位的问题会
+表现在无法解释的系统挂起或运行到物理内存的末端。

How about 表现为无法解释的系统挂起或物理内存越界。

And how about 出现在无法解释的系统挂起或物理内存越界。?
出现 ----> 问题 :-)

Quoted 20 lines
Quoted 20 lines
Documentation/translations/zh_CN/parisc/index.rst +5 -1
index ef232d46b1ba..b913d664e735 100644
@@ -10,9 +10,13 @@
 PA-RISC体系架构
 ====================
 
-Todolist:
+.. toctree::
+   :maxdepth: 2
 
    debugging
+
+Todolist:
+
    registers
    features
 
Quoted 7 lines
Quoted 2 lines

--
2.27.0

Thanks

Wu X.C.

Thanks you review!

Thanks,

Yanteng

#9 lore raw

Re: [PATCH 2/3] docs/zh_CN: add parisc debugging.rst translation

Quoted 55 lines · yanteng si
Quoted 25 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:13写道:
Quoted 23 lines · Yanteng Si

This translates Documentation/parisc/debugging.rst into Chinese.

---
 .../translations/zh_CN/parisc/debugging.rst   | 41 +++++++++++++++++++
 .../translations/zh_CN/parisc/index.rst       |  6 ++-
 2 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/debugging.rst
Documentation/translations/zh_CN/parisc/debugging.rst new file +8 -0
new file mode 100644
index 000000000000..99af303fd3d8
@@ -0,0 +1,41 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/debugging.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_debugging:
+
+=================
Quoted 8 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 12

Quoted 4 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+调试PA-RISC
+=================
+
+好吧,这里有一些关于调试linux/parisc的低级(偏硬件)部分的提示。

maybe
较底层部分的信息。
depend on your choice

OK! use 较底层部分的信息。

Quoted 9 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 18

Quoted 7 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +6 -0
+
+
+1. 绝对地址
+=====================
+
+很多汇编代码目前是以实模式运行的,这意味着绝对地址被使用,而不是像内核其他

很多汇编代码目前运行在实模式下,这意味着会使用绝对地址,而不是像内核其他

ok!

Quoted 10 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 25

Quoted 8 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +7 -0
+部分那样使用虚拟地址。要将绝对地址转换为虚拟地址,你可以在System.map中查
+找,添加__PAGE_OFFSET(目前是0x10000000)。
+
+
+2. HPMCs
+========
+

high priority machine check

Quoted 1 line

OK!

这个作一个译注 或者 在下一句的HPMC后面括注

Quoted 5 lines
Quoted 4 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 26

Quoted 2 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+当实模式的代码试图访问不存在的内存时,你会得到一个HPMC,而不是一个内核opps。

会出现HPMC而不是内核oops。

How about 会打印HPMC而不是内核oops?

Will it just be 'print' ? I'm not sure.

Quoted 5 lines
Quoted 4 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 27

Quoted 2 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+为了调试HPMC,尝试找到系统响应者/请求者地址。系统请求者地址应该与处理器的

要调试HPMC,请尝试……

maybe 若要调试HPMC,请尝试……?

OK.

Quoted 3 lines
Quoted 2 lines

(某)处理器

use 该处理器 ?

(one of the)
or use
处理器(之一)

Quoted 26 lines
Quoted 4 lines

s/响应者/响应程序/g
s/请求者/请求程序/g
replace all

OK!

Quoted 7 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 31

Quoted 5 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+HPA(I/O范围内的高地址)相匹配;系统响应者地址是实模式代码试图访问的地址。
+
+系统响应者地址的典型值是大于__PAGE_OFFSET (0x10000000)的地址,这意味着
+在实际模式代码试图访问它之前,一个虚拟地址没有被翻译成一个物理地址。

在实模式试图访问它之前,虚拟地址没有被翻译成物理地址。

OK!

Quoted 13 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 41

Quoted 11 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +10 -0
+
+
+3. 有趣的Q位
+============
+
+某些非常关键的代码必须清除PSW中的Q位。当Q位被清除时,CPU不会更新中断处理
+程序所读取的寄存器,以找出机器被中断的位置——所以如果你在清除Q位的指令和再
+次设置Q位的RFI之间遇到中断,你不知道它到底发生在哪里。如果你幸运的话,IAOQ
+会指向清除Q位的指令,如果你不幸运的话,它会指向任何地方。通常Q位的问题会
+表现在无法解释的系统挂起或运行到物理内存的末端。

How about 表现为无法解释的系统挂起或物理内存越界。

Quoted 2 lines

And how about 出现在无法解释的系统挂起或物理内存越界。?
出现 ----> 问题 :-)

表现为 + 某情景、状态

出现在 + 某处、部分、方位、某时

Thanks

Wu X.C.

Quoted 32 lines
Quoted 20 lines
Quoted 20 lines
Documentation/translations/zh_CN/parisc/index.rst +5 -1
index ef232d46b1ba..b913d664e735 100644
@@ -10,9 +10,13 @@
 PA-RISC体系架构
 ====================
 
-Todolist:
+.. toctree::
+   :maxdepth: 2
 
    debugging
+
+Todolist:
+
    registers
    features
 
Quoted 7 lines
Quoted 2 lines

--
2.27.0

Thanks

Wu X.C.

Thanks you review!

Thanks,

Yanteng

#10 lore raw

Re: [PATCH 2/3] docs/zh_CN: add parisc debugging.rst translation

Quoted 57 lines · Wu X.C. <[email protected]> 于2021年5月4日周二 下午4:25写道:
Quoted 55 lines · yanteng si
Quoted 25 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:13写道:
Quoted 23 lines · Yanteng Si

This translates Documentation/parisc/debugging.rst into Chinese.

---
 .../translations/zh_CN/parisc/debugging.rst   | 41 +++++++++++++++++++
 .../translations/zh_CN/parisc/index.rst       |  6 ++-
 2 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/debugging.rst
Documentation/translations/zh_CN/parisc/debugging.rst new file +8 -0
new file mode 100644
index 000000000000..99af303fd3d8
@@ -0,0 +1,41 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/debugging.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_debugging:
+
+=================
Quoted 8 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 12

Quoted 4 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+调试PA-RISC
+=================
+
+好吧,这里有一些关于调试linux/parisc的低级(偏硬件)部分的提示。

maybe
较底层部分的信息。
depend on your choice

OK! use 较底层部分的信息。

Quoted 9 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 18

Quoted 7 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +6 -0
+
+
+1. 绝对地址
+=====================
+
+很多汇编代码目前是以实模式运行的,这意味着绝对地址被使用,而不是像内核其他

很多汇编代码目前运行在实模式下,这意味着会使用绝对地址,而不是像内核其他

ok!

Quoted 10 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 25

Quoted 8 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +7 -0
+部分那样使用虚拟地址。要将绝对地址转换为虚拟地址,你可以在System.map中查
+找,添加__PAGE_OFFSET(目前是0x10000000)。
+
+
+2. HPMCs
+========
+

high priority machine check

Quoted 4 lines
Quoted 1 line

OK!

这个作一个译注 或者 在下一句的HPMC后面括注

OK!use 你会得到一个 HPMC(high priority machine check)

Quoted 7 lines
Quoted 5 lines
Quoted 4 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 26

Quoted 2 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+当实模式的代码试图访问不存在的内存时,你会得到一个HPMC,而不是一个内核opps。

会出现HPMC而不是内核oops。

How about 会打印HPMC而不是内核oops?

Will it just be 'print' ? I'm not sure.

OK!use 会出现HPMC而不是内核oops。

Quoted 10 lines
Quoted 6 lines
Quoted 5 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 27

Quoted 3 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +1 -0
+为了调试HPMC,尝试找到系统响应者/请求者地址。系统请求者地址应该与处理器的

要调试HPMC,请尝试……

maybe 若要调试HPMC,请尝试……?

OK.

Quoted 1 line
Quoted 1 line
Quoted 6 lines
Quoted 2 lines
Quoted 1 line

(某)处理器

use 该处理器 ?

(one of the)
or use
处理器(之一)

OK!use (某)处理器

Quoted 26 lines
Quoted 26 lines
Quoted 4 lines

s/响应者/响应程序/g
s/请求者/请求程序/g
replace all

OK!

Quoted 7 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 31

Quoted 5 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +4 -0
+HPA(I/O范围内的高地址)相匹配;系统响应者地址是实模式代码试图访问的地址。
+
+系统响应者地址的典型值是大于__PAGE_OFFSET (0x10000000)的地址,这意味着
+在实际模式代码试图访问它之前,一个虚拟地址没有被翻译成一个物理地址。

在实模式试图访问它之前,虚拟地址没有被翻译成物理地址。

OK!

Quoted 13 lines

Documentation/translations/zh_CN/parisc/debugging.rst line 41

Quoted 11 lines
Documentation/translations/zh_CN/parisc/debugging.rst new file +10 -0
+
+
+3. 有趣的Q位
+============
+
+某些非常关键的代码必须清除PSW中的Q位。当Q位被清除时,CPU不会更新中断处理
+程序所读取的寄存器,以找出机器被中断的位置——所以如果你在清除Q位的指令和再
+次设置Q位的RFI之间遇到中断,你不知道它到底发生在哪里。如果你幸运的话,IAOQ
+会指向清除Q位的指令,如果你不幸运的话,它会指向任何地方。通常Q位的问题会
+表现在无法解释的系统挂起或运行到物理内存的末端。

How about 表现为无法解释的系统挂起或物理内存越界。

Quoted 6 lines
Quoted 2 lines

And how about 出现在无法解释的系统挂起或物理内存越界。?
出现 ----> 问题 :-)

表现为 + 某情景、状态

出现在 + 某处、部分、方位、某时

OK!use 表现为无法解释的系统挂起或物理内存越界。

Quoted 4 lines

Thanks

Wu X.C

Thanks,

Yanteng

Quoted 34 lines
Quoted 33 lines
Quoted 21 lines
Quoted 21 lines
Documentation/translations/zh_CN/parisc/index.rst +5 -1
index ef232d46b1ba..b913d664e735 100644
@@ -10,9 +10,13 @@
 PA-RISC体系架构
 ====================
 
-Todolist:
+.. toctree::
+   :maxdepth: 2
 
    debugging
+
+Todolist:
+
    registers
    features
 
Quoted 7 lines
Quoted 2 lines

--
2.27.0

Thanks

Wu X.C.

Thanks you review!

Thanks,

Yanteng

author
#11 lore raw

PATCH 3/3 docs/zh_CN: add parisc registers.rst translation

In reply to Yanteng Si

This patch translates Documentation/parisc/registers.rst into Chinese.

---
 .../translations/zh_CN/parisc/index.rst       |   2 +-
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 2 files changed, 154 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Documentation/translations/zh_CN/parisc/index.rst +1 -1
index b913d664e735..a47454ebe32e 100644
@@ -14,10 +14,10 @@ PA-RISC体系架构
    :maxdepth: 2
 
    debugging
+   registers
 
 Todolist:
 
-   registers
    features
 
 .. only::  subproject and html
Documentation/translations/zh_CN/parisc/registers.rst new file +153 -0

153 lines not on this page · raw message

Signature · 1 line
2.27.0
#12 lore raw

Re: [PATCH 3/3] docs/zh_CN: add parisc registers.rst translation

Quoted 44 lines · Yanteng Si

This patch translates Documentation/parisc/registers.rst into Chinese.

---
 .../translations/zh_CN/parisc/index.rst       |   2 +-
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 2 files changed, 154 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Documentation/translations/zh_CN/parisc/index.rst +1 -1
index b913d664e735..a47454ebe32e 100644
@@ -14,10 +14,10 @@ PA-RISC体系架构
    :maxdepth: 2
 
    debugging
+   registers
 
 Todolist:
 
-   registers
    features
 
 .. only::  subproject and html
Documentation/translations/zh_CN/parisc/registers.rst new file +13 -0
new file mode 100644
index 000000000000..7a2193674cb0
@@ -0,0 +1,153 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/registers.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_registers:
+
+=========================
+Linux/PA-RISC的寄存器用法
+=========================
+
+[ 用星号表示目前尚未实现的计划用途。 ]
+

Documentation/translations/zh_CN/parisc/registers.rst line 23

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+ABI约定的通用寄存器
+===================
+
+控制寄存器
+----------
+
+============================    =================================
+CR 0 (恢复计数器)               用于ptrace
+CR 1-CR 7(无定义)               未使用
+CR 8 (Protection ID)            每进程 value*

保护ID ?
逐进程值

Documentation/translations/zh_CN/parisc/registers.rst line 24

Quoted 1 line
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR 9, 12, 13 (PIDS)             未使用的

remove 的

Documentation/translations/zh_CN/parisc/registers.rst line 25

Quoted 1 line
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR10 (CCR)                      懒惰FPU saving*

FPU延迟保存
FYI <https://access.redhat.com/solutions/3485131>

Documentation/translations/zh_CN/parisc/registers.rst line 28

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR11                            按照ABI的规定(SAR)。
+CR14 (中断向量)                 初始化为 fault_vector
+CR15 (EIEM)                     初始化为所有的 ones*

What is "ones" ?

Documentation/translations/zh_CN/parisc/registers.rst line 29

Quoted 1 line
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR16 (间隔计时器)               读取周期数/写入开始时间间隔 Tmr

T(i)m(e)r

Documentation/translations/zh_CN/parisc/registers.rst line 42

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +13 -0
+CR17-CR22                       中断参数
+CR19                            中断指令寄存器
+CR20                            中断空间寄存器
+CR21                            中断偏移量寄存器
+CR22                            中断 PSW
+CR23 (EIRR)                     读取未决中断/写入清除位
+CR24 (TR 0)                     内核空间页目录指针
+CR25 (TR 1)                     用户空间页目录指针
+CR26 (TR 2)                     不使用
+CR27 (TR 3)                     线程描述符指针
+CR28 (TR 4)                     不使用
+CR29 (TR 5)                     不使用
+CR30 (TR 6)                     当 / 0

当 ?

Documentation/translations/zh_CN/parisc/registers.rst line 54

Quoted 12 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+CR31 (TR 7)                     临时寄存器,在不同地方使用
+============================    =================================
+
+空间寄存器(内核模式)
+----------------------
+
+========                        ==============================
+SR0                             临时空间寄存器
+SR4-SR7                         设置为0
+SR1                             临时空间寄存器
+SR2                             内核不应该破坏它
+SR3                             用于用户空间访问(当前进程)。

remove 。

Documentation/translations/zh_CN/parisc/registers.rst line 63

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +9 -0
+========                        ==============================
+
+空间寄存器(用户模式)
+----------------------
+
+========                        ============================
+SR0                             临时空间寄存器
+SR1                             临时空间寄存器
+SR2                             保存Linux网关页的空间

网关? I am not sure if it's correct.

Quoted 11 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +11 -0
+SR3                             在内核中保存用户地址空间的值
+SR4-SR7                         定义了用户/内核的短地址空间
+========                        ============================
+
+
+处理器状态字
+------------
+
+======================          ================================================
+W (64位地址)                  0
+E (小尾端)                    0

Documentation/translations/zh_CN/parisc/registers.rst line 84

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+S (安全间隔计时器)            0
+T (产生分支陷阱)              0
+H (高特权级陷阱)              0
+L (低特权级陷阱)              0
+N (撤销下一条指令)            被C代码使用
+X (数据存储中断禁用)          0
+B (产生分支)                  被C代码使用
+C (代码地址转译)              1, 在执行实模式代码时为0
+V (除法步长校正)              被C代码使用
+M (HPMC 掩码)                 0, 在执行HPMC handler* 时为1

handler

Documentation/translations/zh_CN/parisc/registers.rst line 91

Quoted 7 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+C/B (进/借 位)                被C代码使用
+O (有序引用)                  1*
+F (性能监视器)                0
+R (回收计数器陷阱)            0
+Q (收集中断状态)              1 (在rfi之前的代码中为0)
+P (保护标识符)                1*
+D (数据地址转译)              1, 在执行实模external interrupt mask式代码时为0

------------------------------------------------^^^^^^^^^^^^^^^^^^^^^^^

Documentation/translations/zh_CN/parisc/registers.rst line 95

Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +4 -0
+I (外部中断掩码)              由cli()/sti()宏使用。
+======================          ================================================
+
+“隐形” 寄存器(影子寄存器)

---------^
extra space

Documentation/translations/zh_CN/parisc/registers.rst line 107

Quoted 12 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+---------------------------
+
+=============                   ===================
+PSW W 默认值                    0
+PSW E 默认值                    0
+影子寄存器                      被中断处理代码使用
+TOC启用位                       1
+=============                   ===================
+
+----------------------------------------------------------
+
+PA-RISC架构定义了7个寄存器作为 "影子寄存器"。这些寄存器在

"" -> “”

Documentation/translations/zh_CN/parisc/registers.rst line 115

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+RETURN FROM INTERRUPTION AND RESTORE指令中使用,通过消
+除中断处理程序中对一般寄存器(GR)的保存和恢复的需要来减
+少状态保存和恢复时间。影子寄存器是GRs 1, 8, 9, 16, 17,
+24和25。
+
+-------------------------------------------------------------------------
+
+寄存器使用说明,最初由约翰-马文提供,并由Randolph Chung提供一些补充说明。

s/-/·/
or don't translate name

Documentation/translations/zh_CN/parisc/registers.rst line 123

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+对于通用寄存器:
+
+r1,r2,r19-r26,r28,r29 & r31可以在不保存它们的情况下被使用。当然,如果你
+关心它们,在调用另一个程序之前,你也需要保存它们。上面的一些寄存器确实
+有特殊的含义,你应该注意一下:
+
+    r1:

Next paragraph's indentation should be a 8-width TAB. So as followed.

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+    addil指令是硬性规定将其结果放在r1中,所以如果你使用这条指令要
+    注意这点。
+
+    r2:
+    这就是返回指针。一般来说,你不想使用它,因为你需要这个指针来返
+    回给你的调用者。然而,它与这组寄存器组合在一起,因为调用者不能
+    依赖你返回时的值是相同的,也就是说,你可以将r2复制到另一个寄存
+    器,并在作废r2后通过该寄存器返回,这应该不会给调用程序带来问题。
+
+    r19-r22:

Documentation/translations/zh_CN/parisc/registers.rst line 143

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+    这些通常被认为是临时寄存器。
+    请注意,在64位中它们是arg7-arg4。
+
+    r23-r26:
+    这些是arg3-arg0,也就是说,如果你不再关心传入的值,你可以使用
+    它们。
+
+    r28,r29:
+    是ret0和ret1。它们是你传递返回值的东西。r28是主要的返回。当返
+    回小结构时,r29也可以用来将数据传回给调用者。

这俩是ret0和ret1。它们是你传入返回值的地方。r28是主返回值。当返回
小结构体时,r29也可以用来将数据传回给调用者。

Documentation/translations/zh_CN/parisc/registers.rst line 151

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+    r30:
+    栈指针
+
+    r31:
+    ble指令将返回指针放在这里。
+
+

Next paragraph's indentation is correct.

Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +2 -0
+    r3-r18,r27,r30需要被保存和恢复。r3-r18只是一般用途的寄存器。
+    r27是数据指针,用来使对全局变量的引用更容易。r30是栈指针。
Signature · 1 line
2.27.0

Thanks

Wu X.C.

#13 lore raw

Re: [PATCH 3/3] docs/zh_CN: add parisc registers.rst translation

Quoted 50 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:15写道:
Quoted 48 lines · Yanteng Si

This patch translates Documentation/parisc/registers.rst into Chinese.

---
 .../translations/zh_CN/parisc/index.rst       |   2 +-
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 2 files changed, 154 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Documentation/translations/zh_CN/parisc/index.rst +1 -1
index b913d664e735..a47454ebe32e 100644
@@ -14,10 +14,10 @@ PA-RISC体系架构
    :maxdepth: 2
 
    debugging
+   registers
 
 Todolist:
 
-   registers
    features
 
 .. only::  subproject and html
Documentation/translations/zh_CN/parisc/registers.rst new file +17 -0
new file mode 100644
index 000000000000..7a2193674cb0
@@ -0,0 +1,153 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/registers.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_registers:
+
+=========================
+Linux/PA-RISC的寄存器用法
+=========================
+
+[ 用星号表示目前尚未实现的计划用途。 ]
+
+ABI约定的通用寄存器
+===================
+
+控制寄存器
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 23

Quoted 6 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +6 -0
+----------
+
+============================    =================================
+CR 0 (恢复计数器)               用于ptrace
+CR 1-CR 7(无定义)               未使用
+CR 8 (Protection ID)            每进程 value*

保护ID ?

I think the words translated here may make it difficult to understand。

Quoted 1 line

逐进程值

逐 = 每

Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 24

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR 9, 12, 13 (PIDS)             未使用的

remove 的

OK!

Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 25

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR10 (CCR)                      懒惰FPU saving*

FPU延迟保存

OK!

Quoted 7 lines

FYI <https://access.redhat.com/solutions/3485131>

Documentation/translations/zh_CN/parisc/registers.rst line 28

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR11                            按照ABI的规定(SAR)。
+CR14 (中断向量)                 初始化为 fault_vector
+CR15 (EIEM)                     初始化为所有的 ones*

What is "ones" ?

I Think "ones" is a point.
Need to see the code to know, I need some time.

Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 29

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR16 (间隔计时器)               读取周期数/写入开始时间间隔 Tmr

T(i)m(e)r

Origin Doc is Tmr. :)

Quoted 16 lines
Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR17-CR22                       中断参数
+CR19                            中断指令寄存器
+CR20                            中断空间寄存器

Documentation/translations/zh_CN/parisc/registers.rst line 42

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+CR21                            中断偏移量寄存器
+CR22                            中断 PSW
+CR23 (EIRR)                     读取未决中断/写入清除位
+CR24 (TR 0)                     内核空间页目录指针
+CR25 (TR 1)                     用户空间页目录指针
+CR26 (TR 2)                     不使用
+CR27 (TR 3)                     线程描述符指针
+CR28 (TR 4)                     不使用
+CR29 (TR 5)                     不使用
+CR30 (TR 6)                     当 / 0

当 ?

当前

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 54

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+CR31 (TR 7)                     临时寄存器,在不同地方使用
+============================    =================================
+
+空间寄存器(内核模式)
+----------------------
+
+========                        ==============================
+SR0                             临时空间寄存器
+SR4-SR7                         设置为0
+SR1                             临时空间寄存器
+SR2                             内核不应该破坏它
+SR3                             用于用户空间访问(当前进程)。

remove 。

OK!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 63

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +9 -0
+========                        ==============================
+
+空间寄存器(用户模式)
+----------------------
+
+========                        ============================
+SR0                             临时空间寄存器
+SR1                             临时空间寄存器
+SR2                             保存Linux网关页的空间

网关? I am not sure if it's correct.

Emmmmm,Please give me some time

Quoted 16 lines
Quoted 16 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
+SR3                             在内核中保存用户地址空间的值
+SR4-SR7                         定义了用户/内核的短地址空间
+========                        ============================
+
+
+处理器状态字
+------------
+
+======================          ================================================
+W (64位地址)                  0
+E (小尾端)                    0
+S (安全间隔计时器)            0
+T (产生分支陷阱)              0
+H (高特权级陷阱)              0
+L (低特权级陷阱)              0
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 84

Quoted 6 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +6 -0
+N (撤销下一条指令)            被C代码使用
+X (数据存储中断禁用)          0
+B (产生分支)                  被C代码使用
+C (代码地址转译)              1, 在执行实模式代码时为0
+V (除法步长校正)              被C代码使用
+M (HPMC 掩码)                 0, 在执行HPMC handler* 时为1

handler

I think "handler" is a point.

Quoted 9 lines

Documentation/translations/zh_CN/parisc/registers.rst line 91

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+C/B (进/借 位)                被C代码使用
+O (有序引用)                  1*
+F (性能监视器)                0
+R (回收计数器陷阱)            0
+Q (收集中断状态)              1 (在rfi之前的代码中为0)
+P (保护标识符)                1*
+D (数据地址转译)              1, 在执行实模external interrupt mask式代码时为0

------------------------------------------------^^^^^^^^^^^^^^^^^^^^^^^

在执行实模式代码时为0

Quoted 7 lines

Documentation/translations/zh_CN/parisc/registers.rst line 95

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +4 -0
+I (外部中断掩码)              由cli()/sti()宏使用。
+======================          ================================================
+
+“隐形” 寄存器(影子寄存器)

---------^
extra space

OK! DEL

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 107

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+---------------------------
+
+=============                   ===================
+PSW W 默认值                    0
+PSW E 默认值                    0
+影子寄存器                      被中断处理代码使用
+TOC启用位                       1
+=============                   ===================
+
+----------------------------------------------------------
+
+PA-RISC架构定义了7个寄存器作为 "影子寄存器"。这些寄存器在

"" -> “”

ok!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 115

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+RETURN FROM INTERRUPTION AND RESTORE指令中使用,通过消
+除中断处理程序中对一般寄存器(GR)的保存和恢复的需要来减
+少状态保存和恢复时间。影子寄存器是GRs 1, 8, 9, 16, 17,
+24和25。
+
+-------------------------------------------------------------------------
+
+寄存器使用说明,最初由约翰-马文提供,并由Randolph Chung提供一些补充说明。

s/-/·/
or don't translate name

OK!
John Marvin

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 123

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+对于通用寄存器:
+
+r1,r2,r19-r26,r28,r29 & r31可以在不保存它们的情况下被使用。当然,如果你
+关心它们,在调用另一个程序之前,你也需要保存它们。上面的一些寄存器确实
+有特殊的含义,你应该注意一下:
+
+    r1:

Next paragraph's indentation should be a 8-width TAB. So as followed.

OK!

Quoted 16 lines
Quoted 16 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
+    addil指令是硬性规定将其结果放在r1中,所以如果你使用这条指令要
+    注意这点。
+
+    r2:
+    这就是返回指针。一般来说,你不想使用它,因为你需要这个指针来返
+    回给你的调用者。然而,它与这组寄存器组合在一起,因为调用者不能
+    依赖你返回时的值是相同的,也就是说,你可以将r2复制到另一个寄存
+    器,并在作废r2后通过该寄存器返回,这应该不会给调用程序带来问题。
+
+    r19-r22:
+    这些通常被认为是临时寄存器。
+    请注意,在64位中它们是arg7-arg4。
+
+    r23-r26:
+    这些是arg3-arg0,也就是说,如果你不再关心传入的值,你可以使用
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 143

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +5 -0
+    它们。
+
+    r28,r29:
+    是ret0和ret1。它们是你传递返回值的东西。r28是主要的返回。当返
+    回小结构时,r29也可以用来将数据传回给调用者。

这俩是ret0和ret1。它们是你传入返回值的地方。r28是主返回值。当返回
小结构体时,r29也可以用来将数据传回给调用者。

OK!
调用者 -> 调用程序?:)

Quoted 10 lines

Documentation/translations/zh_CN/parisc/registers.rst line 151

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+    r30:
+    栈指针
+
+    r31:
+    ble指令将返回指针放在这里。
+
+

Next paragraph's indentation is correct.

Quoted 9 lines
Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +2 -1
+    r3-r18,r27,r30需要被保存和恢复。r3-r18只是一般用途的寄存器。
+    r27是数据指针,用来使对全局变量的引用更容易。r30是栈指针。
--

2.27.0

Thanks

Wu X.C.

Thanks your review!

Thanks,

Yanteng

#14 lore raw

Re: [PATCH 3/3] docs/zh_CN: add parisc registers.rst translation

Hi Xiangcheng:

an asterisk(*) is used for planned usage which is currently unimplemented. so, I add "*" to corresponding place.

Quoted 50 lines · yanteng si <[email protected]> 于2021年5月4日周二 下午3:26写道:
Quoted 48 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:15写道:
Quoted 46 lines · Yanteng Si

This patch translates Documentation/parisc/registers.rst into Chinese.

---
 .../translations/zh_CN/parisc/index.rst       |   2 +-
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 2 files changed, 154 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Documentation/translations/zh_CN/parisc/index.rst +1 -1
index b913d664e735..a47454ebe32e 100644
@@ -14,10 +14,10 @@ PA-RISC体系架构
    :maxdepth: 2
 
    debugging
+   registers
 
 Todolist:
 
-   registers
    features
 
 .. only::  subproject and html
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
new file mode 100644
index 000000000000..7a2193674cb0
@@ -0,0 +1,153 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/registers.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_registers:
+
+=========================
+Linux/PA-RISC的寄存器用法
+=========================
+
+[ 用星号表示目前尚未实现的计划用途。 ]
+
+ABI约定的通用寄存器
+===================
Quoted 8 lines
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 23

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+控制寄存器
+----------
+
+============================    =================================
+CR 0 (恢复计数器)               用于ptrace
+CR 1-CR 7(无定义)               未使用
+CR 8 (Protection ID)            每进程 value*

每进程值*

Quoted 10 lines
Quoted 2 lines

保护ID ?

I think the words translated here may make it difficult to understand。

Quoted 1 line

逐进程值

逐 = 每

Quoted 3 lines
Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR 9, 12, 13 (PIDS)             未使用的
Quoted 7 lines
Quoted 1 line

remove 的

OK!

Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 25

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR10 (CCR)                      懒惰FPU saving*

FPU延迟保存

OK!

FPU延迟保存*

Quoted 9 lines
Quoted 7 lines

FYI <https://access.redhat.com/solutions/3485131>

Documentation/translations/zh_CN/parisc/registers.rst line 28

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR11                            按照ABI的规定(SAR)。
+CR14 (中断向量)                 初始化为 fault_vector
+CR15 (EIEM)                     初始化为所有的 ones*

What is "ones" ?

I Think "ones" is a point.
Need to see the code to know, I need some time.

所有位初始化为1

Quoted 51 lines
Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 29

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR16 (间隔计时器)               读取周期数/写入开始时间间隔 Tmr

T(i)m(e)r

Origin Doc is Tmr. :)

Quoted 16 lines
Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR17-CR22                       中断参数
+CR19                            中断指令寄存器
+CR20                            中断空间寄存器

Documentation/translations/zh_CN/parisc/registers.rst line 42

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+CR21                            中断偏移量寄存器
+CR22                            中断 PSW
+CR23 (EIRR)                     读取未决中断/写入清除位
+CR24 (TR 0)                     内核空间页目录指针
+CR25 (TR 1)                     用户空间页目录指针
+CR26 (TR 2)                     不使用
+CR27 (TR 3)                     线程描述符指针
+CR28 (TR 4)                     不使用
+CR29 (TR 5)                     不使用
+CR30 (TR 6)                     当 / 0

当 ?

当前

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 54

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+CR31 (TR 7)                     临时寄存器,在不同地方使用
+============================    =================================
+
+空间寄存器(内核模式)
+----------------------
+
+========                        ==============================
+SR0                             临时空间寄存器
+SR4-SR7                         设置为0
+SR1                             临时空间寄存器
+SR2                             内核不应该破坏它
+SR3                             用于用户空间访问(当前进程)。

remove 。

OK!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 63

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +9 -0
+========                        ==============================
+
+空间寄存器(用户模式)
+----------------------
+
+========                        ============================
+SR0                             临时空间寄存器
+SR1                             临时空间寄存器
+SR2                             保存Linux网关页的空间

网关? I am not sure if it's correct.

Quoted 1 line

Emmmmm,Please give me some time

The Linux gateway page on PA-RISC is "special".
It actually has PAGE_GATEWAY bits set (this is linux terminology; in parisc terminology it's Execute, promote to PL0) in the page map. So anything executing on this page executes with kernel level privilege (there's more to it than that: to have this happen, you also have to use a branch with a ,gate completer to activate the privilege promotion). The upshot is that everything that runs on the gateway page runs at kernel privilege but with the current user process address space (although you have access to kernel space via %sr2). For the 0x100 syscall entry, we redo the space registers to point to the kernel address space (preserving the user address space in %sr3), move to wide mode if required, save the user registers and branch into the kernel syscall entry point. For all the other functions, we execute at kernel privilege but don't flip address spaces. The basic upshot of this is that these code snippets are executed atomically (because the kernel can't be pre-empted) and they may perform architecturally forbidden (to PL3) operations (like setting control registers).

The "gateway page" is a trap, the page contains privileged code to help handle user
state exceptions. Since there is no "syscall" command in parisc, so "syscall" is a jump
into "gateway page", and I think it is better to keep it in English.

保存Linux gateway page的空间? :)

Quoted 24 lines
Quoted 16 lines
Quoted 16 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
+SR3                             在内核中保存用户地址空间的值
+SR4-SR7                         定义了用户/内核的短地址空间
+========                        ============================
+
+
+处理器状态字
+------------
+
+======================          ================================================
+W (64位地址)                  0
+E (小尾端)                    0
+S (安全间隔计时器)            0
+T (产生分支陷阱)              0
+H (高特权级陷阱)              0
+L (低特权级陷阱)              0
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 84

Quoted 6 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +6 -0
+N (撤销下一条指令)            被C代码使用
+X (数据存储中断禁用)          0
+B (产生分支)                  被C代码使用
+C (代码地址转译)              1, 在执行实模式代码时为0
+V (除法步长校正)              被C代码使用
+M (HPMC 掩码)                 0, 在执行HPMC handler* 时为1

handler

Quoted 1 line

I think "handler" is a point.

handler -> 操作

Quoted 104 lines
Quoted 9 lines

Documentation/translations/zh_CN/parisc/registers.rst line 91

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+C/B (进/借 位)                被C代码使用
+O (有序引用)                  1*
+F (性能监视器)                0
+R (回收计数器陷阱)            0
+Q (收集中断状态)              1 (在rfi之前的代码中为0)
+P (保护标识符)                1*
+D (数据地址转译)              1, 在执行实模external interrupt mask式代码时为0

------------------------------------------------^^^^^^^^^^^^^^^^^^^^^^^

在执行实模式代码时为0

Quoted 7 lines

Documentation/translations/zh_CN/parisc/registers.rst line 95

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +4 -0
+I (外部中断掩码)              由cli()/sti()宏使用。
+======================          ================================================
+
+“隐形” 寄存器(影子寄存器)

---------^
extra space

OK! DEL

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 107

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+---------------------------
+
+=============                   ===================
+PSW W 默认值                    0
+PSW E 默认值                    0
+影子寄存器                      被中断处理代码使用
+TOC启用位                       1
+=============                   ===================
+
+----------------------------------------------------------
+
+PA-RISC架构定义了7个寄存器作为 "影子寄存器"。这些寄存器在

"" -> “”

ok!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 115

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+RETURN FROM INTERRUPTION AND RESTORE指令中使用,通过消
+除中断处理程序中对一般寄存器(GR)的保存和恢复的需要来减
+少状态保存和恢复时间。影子寄存器是GRs 1, 8, 9, 16, 17,
+24和25。
+
+-------------------------------------------------------------------------
+
+寄存器使用说明,最初由约翰-马文提供,并由Randolph Chung提供一些补充说明。

s/-/·/
or don't translate name

OK!
John Marvin

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 123

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+对于通用寄存器:
+
+r1,r2,r19-r26,r28,r29 & r31可以在不保存它们的情况下被使用。当然,如果你
+关心它们,在调用另一个程序之前,你也需要保存它们。上面的一些寄存器确实
+有特殊的含义,你应该注意一下:
+
+    r1:

Next paragraph's indentation should be a 8-width TAB. So as followed.

OK!

Quoted 16 lines
Quoted 16 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
+    addil指令是硬性规定将其结果放在r1中,所以如果你使用这条指令要
+    注意这点。
+
+    r2:
+    这就是返回指针。一般来说,你不想使用它,因为你需要这个指针来返
+    回给你的调用者。然而,它与这组寄存器组合在一起,因为调用者不能
+    依赖你返回时的值是相同的,也就是说,你可以将r2复制到另一个寄存
+    器,并在作废r2后通过该寄存器返回,这应该不会给调用程序带来问题。
+
+    r19-r22:
+    这些通常被认为是临时寄存器。
+    请注意,在64位中它们是arg7-arg4。
+
+    r23-r26:
+    这些是arg3-arg0,也就是说,如果你不再关心传入的值,你可以使用
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 143

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +5 -0
+    它们。
+
+    r28,r29:
+    是ret0和ret1。它们是你传递返回值的东西。r28是主要的返回。当返
+    回小结构时,r29也可以用来将数据传回给调用者。

这俩是ret0和ret1。它们是你传入返回值的地方。r28是主返回值。当返回
小结构体时,r29也可以用来将数据传回给调用者。

OK!
调用者 -> 调用程序?:)

Quoted 17 lines

Documentation/translations/zh_CN/parisc/registers.rst line 151

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+    r30:
+    栈指针
+
+    r31:
+    ble指令将返回指针放在这里。
+
+

Next paragraph's indentation is correct.

Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +2 -1
+    r3-r18,r27,r30需要被保存和恢复。r3-r18只是一般用途的寄存器。
+    r27是数据指针,用来使对全局变量的引用更容易。r30是栈指针。
--

2.27.0

Thanks

Quoted 7 lines
Quoted 2 lines

Wu X.C.

Thanks your review!

Thanks,

Yanteng

Thanks,

Yanteng

#15 lore raw

Re: [PATCH 3/3] docs/zh_CN: add parisc registers.rst translation

Quoted 4 lines · yanteng si

Hi Xiangcheng:

an asterisk(*) is used for planned usage which is currently unimplemented. so, I add "*" to corresponding place.

ok

Quoted 53 lines
Quoted 51 lines · yanteng si <[email protected]> 于2021年5月4日周二 下午3:26写道:
Quoted 49 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:15写道:
Quoted 47 lines · Yanteng Si

This patch translates Documentation/parisc/registers.rst into Chinese.

---
 .../translations/zh_CN/parisc/index.rst       |   2 +-
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 2 files changed, 154 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Documentation/translations/zh_CN/parisc/index.rst +1 -1
index b913d664e735..a47454ebe32e 100644
@@ -14,10 +14,10 @@ PA-RISC体系架构
    :maxdepth: 2
 
    debugging
+   registers
 
 Todolist:
 
-   registers
    features
 
 .. only::  subproject and html
Documentation/translations/zh_CN/parisc/registers.rst new file +16 -0
new file mode 100644
index 000000000000..7a2193674cb0
@@ -0,0 +1,153 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/registers.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_registers:
+
+=========================
+Linux/PA-RISC的寄存器用法
+=========================
+
+[ 用星号表示目前尚未实现的计划用途。 ]
+
+ABI约定的通用寄存器
+===================
+
Quoted 11 lines
Quoted 7 lines
Quoted 7 lines

Documentation/translations/zh_CN/parisc/registers.rst line 23

Quoted 7 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+控制寄存器
+----------
+
+============================    =================================
+CR 0 (恢复计数器)               用于ptrace
+CR 1-CR 7(无定义)               未使用
+CR 8 (Protection ID)            每进程 value*

每进程值*

Quoted 3 lines
Quoted 2 lines

保护ID ?

I think the words translated here may make it difficult to understand。

ok

Quoted 3 lines
Quoted 3 lines
Quoted 2 lines

逐进程值

逐 = 每

Fine

Quoted 14 lines
Quoted 11 lines
Quoted 5 lines

Documentation/translations/zh_CN/parisc/registers.rst line 24

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR 9, 12, 13 (PIDS)             未使用的

remove 的

OK!

Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 25

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR10 (CCR)                      懒惰FPU saving*

FPU延迟保存

OK!

FPU延迟保存*

Quoted 2 lines
Quoted 2 lines

FYI <https://access.redhat.com/solutions/3485131>

Quoted 8 lines
Quoted 7 lines
Quoted 5 lines

Documentation/translations/zh_CN/parisc/registers.rst line 28

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR11                            按照ABI的规定(SAR)。
+CR14 (中断向量)                 初始化为 fault_vector
+CR15 (EIEM)                     初始化为所有的 ones*

What is "ones" ?

I Think "ones" is a point.
Need to see the code to know, I need some time.

所有位初始化为1

ok

Quoted 5 lines
Quoted 5 lines
Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 29

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR16 (间隔计时器)               读取周期数/写入开始时间间隔 Tmr

T(i)m(e)r

Origin Doc is Tmr. :)

I mean why not translate it to 计时器

Quoted 17 lines
Quoted 17 lines
Quoted 17 lines
Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR17-CR22                       中断参数
+CR19                            中断指令寄存器
+CR20                            中断空间寄存器

Documentation/translations/zh_CN/parisc/registers.rst line 42

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+CR21                            中断偏移量寄存器
+CR22                            中断 PSW
+CR23 (EIRR)                     读取未决中断/写入清除位
+CR24 (TR 0)                     内核空间页目录指针
+CR25 (TR 1)                     用户空间页目录指针
+CR26 (TR 2)                     不使用
+CR27 (TR 3)                     线程描述符指针
+CR28 (TR 4)                     不使用
+CR29 (TR 5)                     不使用
+CR30 (TR 6)                     当 / 0

当 ?

Quoted 1 line
Quoted 1 line

当前

ok

Quoted 47 lines
Quoted 28 lines
Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 54

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+CR31 (TR 7)                     临时寄存器,在不同地方使用
+============================    =================================
+
+空间寄存器(内核模式)
+----------------------
+
+========                        ==============================
+SR0                             临时空间寄存器
+SR4-SR7                         设置为0
+SR1                             临时空间寄存器
+SR2                             内核不应该破坏它
+SR3                             用于用户空间访问(当前进程)。

remove 。

OK!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 63

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +9 -0
+========                        ==============================
+
+空间寄存器(用户模式)
+----------------------
+
+========                        ============================
+SR0                             临时空间寄存器
+SR1                             临时空间寄存器
+SR2                             保存Linux网关页的空间

网关? I am not sure if it's correct.

Quoted 1 line

Emmmmm,Please give me some time

The Linux gateway page on PA-RISC is "special".
It actually has PAGE_GATEWAY bits set (this is linux terminology; in parisc terminology it's Execute, promote to PL0) in the page map. So anything executing on this page executes with kernel level privilege (there's more to it than that: to have this happen, you also have to use a branch with a ,gate completer to activate the privilege promotion). The upshot is that everything that runs on the gateway page runs at kernel privilege but with the current user process address space (although you have access to kernel space via %sr2). For the 0x100 syscall entry, we redo the space registers to point to the kernel address space (preserving the user address space in %sr3), move to wide mode if required, save the user registers and branch into the kernel syscall entry point. For all the other functions, we execute at kernel privilege but don't flip address spaces. The basic upshot of this is that these code snippets are executed atomically (because the kernel can't be pre-empted) and they may perform architecturally forbidden (to PL3) operations (like setting control registers).

Quoted 6 lines

The "gateway page" is a trap, the page contains privileged code to help handle user
state exceptions. Since there is no "syscall" command in parisc, so "syscall" is a jump
into "gateway page", and I think it is better to keep it in English.

Thanks for the long explanation.

Quoted 1 line

保存Linux gateway page的空间? :)

OK, it's reasonable to keep it here.

Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +11 -0
+SR3                             在内核中保存用户地址空间的值
+SR4-SR7                         定义了用户/内核的短地址空间
+========                        ============================
+
+
+处理器状态字
+------------
+
+======================          ================================================
+W (64位地址)                  0
+E (小尾端)                    0

Documentation/translations/zh_CN/parisc/registers.rst line 84

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+S (安全间隔计时器)            0
+T (产生分支陷阱)              0
+H (高特权级陷阱)              0
+L (低特权级陷阱)              0
+N (撤销下一条指令)            被C代码使用
+X (数据存储中断禁用)          0
+B (产生分支)                  被C代码使用
+C (代码地址转译)              1, 在执行实模式代码时为0
+V (除法步长校正)              被C代码使用
+M (HPMC 掩码)                 0, 在执行HPMC handler* 时为1

handler

Quoted 104 lines
Quoted 1 line

I think "handler" is a point.

handler -> 操作

Quoted 102 lines
Quoted 9 lines

Documentation/translations/zh_CN/parisc/registers.rst line 91

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+C/B (进/借 位)                被C代码使用
+O (有序引用)                  1*
+F (性能监视器)                0
+R (回收计数器陷阱)            0
+Q (收集中断状态)              1 (在rfi之前的代码中为0)
+P (保护标识符)                1*
+D (数据地址转译)              1, 在执行实模external interrupt mask式代码时为0

------------------------------------------------^^^^^^^^^^^^^^^^^^^^^^^

在执行实模式代码时为0

Quoted 7 lines

Documentation/translations/zh_CN/parisc/registers.rst line 95

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +4 -0
+I (外部中断掩码)              由cli()/sti()宏使用。
+======================          ================================================
+
+“隐形” 寄存器(影子寄存器)

---------^
extra space

OK! DEL

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 107

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+---------------------------
+
+=============                   ===================
+PSW W 默认值                    0
+PSW E 默认值                    0
+影子寄存器                      被中断处理代码使用
+TOC启用位                       1
+=============                   ===================
+
+----------------------------------------------------------
+
+PA-RISC架构定义了7个寄存器作为 "影子寄存器"。这些寄存器在

"" -> “”

ok!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 115

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+RETURN FROM INTERRUPTION AND RESTORE指令中使用,通过消
+除中断处理程序中对一般寄存器(GR)的保存和恢复的需要来减
+少状态保存和恢复时间。影子寄存器是GRs 1, 8, 9, 16, 17,
+24和25。
+
+-------------------------------------------------------------------------
+
+寄存器使用说明,最初由约翰-马文提供,并由Randolph Chung提供一些补充说明。

s/-/·/
or don't translate name

OK!
John Marvin

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 123

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+对于通用寄存器:
+
+r1,r2,r19-r26,r28,r29 & r31可以在不保存它们的情况下被使用。当然,如果你
+关心它们,在调用另一个程序之前,你也需要保存它们。上面的一些寄存器确实
+有特殊的含义,你应该注意一下:
+
+    r1:

Next paragraph's indentation should be a 8-width TAB. So as followed.

OK!

Quoted 16 lines
Quoted 16 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
+    addil指令是硬性规定将其结果放在r1中,所以如果你使用这条指令要
+    注意这点。
+
+    r2:
+    这就是返回指针。一般来说,你不想使用它,因为你需要这个指针来返
+    回给你的调用者。然而,它与这组寄存器组合在一起,因为调用者不能
+    依赖你返回时的值是相同的,也就是说,你可以将r2复制到另一个寄存
+    器,并在作废r2后通过该寄存器返回,这应该不会给调用程序带来问题。
+
+    r19-r22:
+    这些通常被认为是临时寄存器。
+    请注意,在64位中它们是arg7-arg4。
+
+    r23-r26:
+    这些是arg3-arg0,也就是说,如果你不再关心传入的值,你可以使用
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 143

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +5 -0
+    它们。
+
+    r28,r29:
+    是ret0和ret1。它们是你传递返回值的东西。r28是主要的返回。当返
+    回小结构时,r29也可以用来将数据传回给调用者。

这俩是ret0和ret1。它们是你传入返回值的地方。r28是主返回值。当返回
小结构体时,r29也可以用来将数据传回给调用者。

OK!
调用者 -> 调用程序?:)

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 151

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+    r30:
+    栈指针
+
+    r31:
+    ble指令将返回指针放在这里。
+
+

Next paragraph's indentation is correct.

Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +2 -1
+    r3-r18,r27,r30需要被保存和恢复。r3-r18只是一般用途的寄存器。
+    r27是数据指针,用来使对全局变量的引用更容易。r30是栈指针。
--

2.27.0

Thanks

	Wu X.C.
#16 lore raw

Re: [PATCH 3/3] docs/zh_CN: add parisc registers.rst translation

Quoted 108 lines · Wu X.C. <[email protected]> 于2021年5月7日周五 上午10:15写道:
Quoted 4 lines · yanteng si

Hi Xiangcheng:

an asterisk(*) is used for planned usage which is currently unimplemented. so, I add "*" to corresponding place.

ok

Quoted 53 lines
Quoted 51 lines · yanteng si <[email protected]> 于2021年5月4日周二 下午3:26写道:
Quoted 49 lines · Wu X.C. <[email protected]> 于2021年4月29日周四 下午11:15写道:
Quoted 47 lines · Yanteng Si

This patch translates Documentation/parisc/registers.rst into Chinese.

---
 .../translations/zh_CN/parisc/index.rst       |   2 +-
 .../translations/zh_CN/parisc/registers.rst   | 153 ++++++++++++++++++
 2 files changed, 154 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/translations/zh_CN/parisc/registers.rst
Documentation/translations/zh_CN/parisc/index.rst +1 -1
index b913d664e735..a47454ebe32e 100644
@@ -14,10 +14,10 @@ PA-RISC体系架构
    :maxdepth: 2
 
    debugging
+   registers
 
 Todolist:
 
-   registers
    features
 
 .. only::  subproject and html
Documentation/translations/zh_CN/parisc/registers.rst new file +16 -0
new file mode 100644
index 000000000000..7a2193674cb0
@@ -0,0 +1,153 @@
+.. include:: ../disclaimer-zh_CN.rst
+
+:Original: Documentation/parisc/registers.rst
+:Translator: Yanteng Si <[email protected]>
+
+.. _cn_parisc_registers:
+
+=========================
+Linux/PA-RISC的寄存器用法
+=========================
+
+[ 用星号表示目前尚未实现的计划用途。 ]
+
+ABI约定的通用寄存器
+===================
+
Quoted 11 lines
Quoted 7 lines
Quoted 7 lines

Documentation/translations/zh_CN/parisc/registers.rst line 23

Quoted 7 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+控制寄存器
+----------
+
+============================    =================================
+CR 0 (恢复计数器)               用于ptrace
+CR 1-CR 7(无定义)               未使用
+CR 8 (Protection ID)            每进程 value*

每进程值*

Quoted 3 lines
Quoted 2 lines

保护ID ?

I think the words translated here may make it difficult to understand。

ok

Quoted 3 lines
Quoted 3 lines
Quoted 2 lines

逐进程值

逐 = 每

Fine

Quoted 14 lines
Quoted 11 lines
Quoted 5 lines

Documentation/translations/zh_CN/parisc/registers.rst line 24

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR 9, 12, 13 (PIDS)             未使用的

remove 的

OK!

Quoted 4 lines

Documentation/translations/zh_CN/parisc/registers.rst line 25

Quoted 2 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR10 (CCR)                      懒惰FPU saving*

FPU延迟保存

OK!

FPU延迟保存*

Quoted 2 lines
Quoted 2 lines

FYI <https://access.redhat.com/solutions/3485131>

Quoted 8 lines
Quoted 7 lines
Quoted 5 lines

Documentation/translations/zh_CN/parisc/registers.rst line 28

Quoted 3 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR11                            按照ABI的规定(SAR)。
+CR14 (中断向量)                 初始化为 fault_vector
+CR15 (EIEM)                     初始化为所有的 ones*

What is "ones" ?

I Think "ones" is a point.
Need to see the code to know, I need some time.

所有位初始化为1

ok

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 6 lines
Quoted 4 lines
Quoted 4 lines
Quoted 3 lines

Documentation/translations/zh_CN/parisc/registers.rst line 29

Quoted 1 line
Documentation/translations/zh_CN/parisc/registers.rst new file +1 -0
+CR16 (间隔计时器)               读取周期数/写入开始时间间隔 Tmr

T(i)m(e)r

Origin Doc is Tmr. :)

I mean why not translate it to 计时器

OK!
Tmr -> 计时器

Quoted 210 lines
Quoted 18 lines
Quoted 18 lines
Quoted 18 lines
Quoted 6 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +3 -0
+CR17-CR22                       中断参数
+CR19                            中断指令寄存器
+CR20                            中断空间寄存器

Documentation/translations/zh_CN/parisc/registers.rst line 42

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+CR21                            中断偏移量寄存器
+CR22                            中断 PSW
+CR23 (EIRR)                     读取未决中断/写入清除位
+CR24 (TR 0)                     内核空间页目录指针
+CR25 (TR 1)                     用户空间页目录指针
+CR26 (TR 2)                     不使用
+CR27 (TR 3)                     线程描述符指针
+CR28 (TR 4)                     不使用
+CR29 (TR 5)                     不使用
+CR30 (TR 6)                     当 / 0

当 ?

Quoted 1 line
Quoted 1 line

当前

ok

Quoted 47 lines
Quoted 28 lines
Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 54

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+CR31 (TR 7)                     临时寄存器,在不同地方使用
+============================    =================================
+
+空间寄存器(内核模式)
+----------------------
+
+========                        ==============================
+SR0                             临时空间寄存器
+SR4-SR7                         设置为0
+SR1                             临时空间寄存器
+SR2                             内核不应该破坏它
+SR3                             用于用户空间访问(当前进程)。

remove 。

OK!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 63

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +9 -0
+========                        ==============================
+
+空间寄存器(用户模式)
+----------------------
+
+========                        ============================
+SR0                             临时空间寄存器
+SR1                             临时空间寄存器
+SR2                             保存Linux网关页的空间

网关? I am not sure if it's correct.

Quoted 1 line

Emmmmm,Please give me some time

The Linux gateway page on PA-RISC is "special".
It actually has PAGE_GATEWAY bits set (this is linux terminology; in parisc terminology it's Execute, promote to PL0) in the page map. So anything executing on this page executes with kernel level privilege (there's more to it than that: to have this happen, you also have to use a branch with a ,gate completer to activate the privilege promotion). The upshot is that everything that runs on the gateway page runs at kernel privilege but with the current user process address space (although you have access to kernel space via %sr2). For the 0x100 syscall entry, we redo the space registers to point to the kernel address space (preserving the user address space in %sr3), move to wide mode if required, save the user registers and branch into the kernel syscall entry point. For all the other functions, we execute at kernel privilege but don't flip address spaces. The basic upshot of this is that these code snippets are executed atomically (because the kernel can't be pre-empted) and they may perform architecturally forbidden (to PL3) operations (like setting control registers).

Quoted 6 lines

The "gateway page" is a trap, the page contains privileged code to help handle user
state exceptions. Since there is no "syscall" command in parisc, so "syscall" is a jump
into "gateway page", and I think it is better to keep it in English.

Thanks for the long explanation.

Quoted 1 line

保存Linux gateway page的空间? :)

OK, it's reasonable to keep it here.

Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +11 -0
+SR3                             在内核中保存用户地址空间的值
+SR4-SR7                         定义了用户/内核的短地址空间
+========                        ============================
+
+
+处理器状态字
+------------
+
+======================          ================================================
+W (64位地址)                  0
+E (小尾端)                    0

Documentation/translations/zh_CN/parisc/registers.rst line 84

Quoted 10 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +10 -0
+S (安全间隔计时器)            0
+T (产生分支陷阱)              0
+H (高特权级陷阱)              0
+L (低特权级陷阱)              0
+N (撤销下一条指令)            被C代码使用
+X (数据存储中断禁用)          0
+B (产生分支)                  被C代码使用
+C (代码地址转译)              1, 在执行实模式代码时为0
+V (除法步长校正)              被C代码使用
+M (HPMC 掩码)                 0, 在执行HPMC handler* 时为1

handler

Quoted 104 lines
Quoted 1 line

I think "handler" is a point.

handler -> 操作

Quoted 102 lines
Quoted 9 lines

Documentation/translations/zh_CN/parisc/registers.rst line 91

Quoted 8 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +7 -0
+C/B (进/借 位)                被C代码使用
+O (有序引用)                  1*
+F (性能监视器)                0
+R (回收计数器陷阱)            0
+Q (收集中断状态)              1 (在rfi之前的代码中为0)
+P (保护标识符)                1*
+D (数据地址转译)              1, 在执行实模external interrupt mask式代码时为0

------------------------------------------------^^^^^^^^^^^^^^^^^^^^^^^

在执行实模式代码时为0

Quoted 7 lines

Documentation/translations/zh_CN/parisc/registers.rst line 95

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +4 -0
+I (外部中断掩码)              由cli()/sti()宏使用。
+======================          ================================================
+
+“隐形” 寄存器(影子寄存器)

---------^
extra space

OK! DEL

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 107

Quoted 13 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +12 -0
+---------------------------
+
+=============                   ===================
+PSW W 默认值                    0
+PSW E 默认值                    0
+影子寄存器                      被中断处理代码使用
+TOC启用位                       1
+=============                   ===================
+
+----------------------------------------------------------
+
+PA-RISC架构定义了7个寄存器作为 "影子寄存器"。这些寄存器在

"" -> “”

ok!

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 115

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+RETURN FROM INTERRUPTION AND RESTORE指令中使用,通过消
+除中断处理程序中对一般寄存器(GR)的保存和恢复的需要来减
+少状态保存和恢复时间。影子寄存器是GRs 1, 8, 9, 16, 17,
+24和25。
+
+-------------------------------------------------------------------------
+
+寄存器使用说明,最初由约翰-马文提供,并由Randolph Chung提供一些补充说明。

s/-/·/
or don't translate name

OK!
John Marvin

Quoted 12 lines

Documentation/translations/zh_CN/parisc/registers.rst line 123

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+对于通用寄存器:
+
+r1,r2,r19-r26,r28,r29 & r31可以在不保存它们的情况下被使用。当然,如果你
+关心它们,在调用另一个程序之前,你也需要保存它们。上面的一些寄存器确实
+有特殊的含义,你应该注意一下:
+
+    r1:

Next paragraph's indentation should be a 8-width TAB. So as followed.

OK!

Quoted 16 lines
Quoted 16 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +15 -0
+    addil指令是硬性规定将其结果放在r1中,所以如果你使用这条指令要
+    注意这点。
+
+    r2:
+    这就是返回指针。一般来说,你不想使用它,因为你需要这个指针来返
+    回给你的调用者。然而,它与这组寄存器组合在一起,因为调用者不能
+    依赖你返回时的值是相同的,也就是说,你可以将r2复制到另一个寄存
+    器,并在作废r2后通过该寄存器返回,这应该不会给调用程序带来问题。
+
+    r19-r22:
+    这些通常被认为是临时寄存器。
+    请注意,在64位中它们是arg7-arg4。
+
+    r23-r26:
+    这些是arg3-arg0,也就是说,如果你不再关心传入的值,你可以使用
Quoted 8 lines

Documentation/translations/zh_CN/parisc/registers.rst line 143

Quoted 5 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +5 -0
+    它们。
+
+    r28,r29:
+    是ret0和ret1。它们是你传递返回值的东西。r28是主要的返回。当返
+    回小结构时,r29也可以用来将数据传回给调用者。

这俩是ret0和ret1。它们是你传入返回值的地方。r28是主返回值。当返回
小结构体时,r29也可以用来将数据传回给调用者。

OK!
调用者 -> 调用程序?:)

Quoted 15 lines

Documentation/translations/zh_CN/parisc/registers.rst line 151

Quoted 9 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +8 -0
+
+    r30:
+    栈指针
+
+    r31:
+    ble指令将返回指针放在这里。
+
+

Next paragraph's indentation is correct.

Quoted 4 lines
Documentation/translations/zh_CN/parisc/registers.rst new file +2 -1
+    r3-r18,r27,r30需要被保存和恢复。r3-r18只是一般用途的寄存器。
+    r27是数据指针,用来使对全局变量的引用更容易。r30是栈指针。
--

2.27.0

Quoted 3 lines

Thanks

        Wu X.C.

Thanks,

Yanteng