您的位置:首页 > 其它

Documentation-power-drivers-testing.txt

2013-10-24 10:56 211 查看
Chinese translated version of Documentation/power/drivers-testing.txt

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.

Maintainer: Eric W. Biederman <ebiederman@xmission.com>

Chinese maintainer: Shao Qi <shaoqitony@gmail.com>

---------------------------------------------------------------------

Documentation/power/drivers-testing.txt 的中文翻译

如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文

交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻

译存在问题,请联系中文版维护者。

英文版维护者: Eric W. Biederman <ebiederman@xmission.com>

中文版维护者: 邵奇 Shao Qi <shaoqitony@gmail.com>

中文版翻译者: 邵奇 Shao Qi <shaoqitony@gmail.com>

中文版校译者: 邵奇 Shao Qi <shaoqitony@gmail.com>

以下为正文

---------------------------------------------------------------------

Testing suspend and resume support in device drivers

测试设备驱动程序的暂停和恢复支持

(C) 2007 Rafael J. Wysocki <rjw@sisk.pl>, GPL

1. Preparing the test system

1. 准备测试系统

Unfortunately, to effectively test the support for the system-wide suspend and

resume transitions in a driver, it is necessary to suspend and resume a fully

functional system with this driver loaded. Moreover, that should be done

several times, preferably several times in a row, and separately for hibernation

(aka suspend to disk or STD) and suspend to RAM (STR), because each of these

cases involves slightly different operations and different interactions with

the machine's BIOS.

不幸的是,有效地测试全系统驱动程序暂停和恢复转换支持,必须暂停和恢复此驱动程序

加载的全功能系统。此外,需要做数次,最好是分别连续几次的休眠(又叫做挂起磁盘或STD)

和挂起内存(STR),因为这些情况包括稍有不同的操作和与机器BIOS不同的交互。

Of course, for this purpose the test system has to be known to suspend and

resume without the driver being tested. Thus, if possible, you should first

resolve all suspend/resume-related problems in the test system before you start

testing the new driver. Please see Documentation/power/basic-pm-debugging.txt

for more information about the debugging of suspend/resume functionality.

当然,以此为目的,测试系统要暂停或恢复,必须没有测试过驱动程序。因此,如果可能的话,

在你开始测试新的驱动程序之前,你应该先解决测试系统中所有与暂停/恢复有关的问题。

请查看Documentation/power/basic-pm-debugging.txt,以了解更多关于调试暂停/恢复功能

的信息。

2. Testing the driver

2. 测试驱动程序

Once you have resolved the suspend/resume-related problems with your test system

without the new driver, you are ready to test it:

一旦你不同新的驱动程序,解决了测试系统中与暂停/恢复有关的问题,你就可以测试它了:

a) Build the driver as a module, load it and try the test modes of hibernation

(see: Documentation/power/basic-pm-debugging.txt, 1).

a) 构建驱动程序作为一个模块,加载它,并尝试测试休眠模式

(见:Documentation/power/basic-pm-debugging.txt, 1)。

b) Load the driver and attempt to hibernate in the "reboot", "shutdown" and

"platform" modes (see: Documentation/power/basic-pm-debugging.txt, 1).

b) 加载驱动程序并尝试在"重启","关机"和"平台"模式中休眠

(见:Documentation/power/basic-pm-debugging.txt, 1)。

c) Compile the driver directly into the kernel and try the test modes of

hibernation.

c) 直接编译驱动程序到内核中,并尝试测试休眠模式

d) Attempt to hibernate with the driver compiled directly into the kernel

in the "reboot", "shutdown" and "platform" modes.

d) 尝试在"重启","关机"和"平台"模式中,用已经直接编译到内核中的驱动程序进行

休眠。

e) Try the test modes of suspend (see: Documentation/power/basic-pm-debugging.txt,

2). [As far as the STR tests are concerned, it should not matter whether or

not the driver is built as a module.]

e) 测试暂停模式(见:Documentation/power/basic-pm-debugging.txt,2)[就目前的STR测试

而言,驱动程序是否被构建成一个模块并不重要。]

f) Attempt to suspend to RAM using the s2ram tool with the driver loaded

(see: Documentation/power/basic-pm-debugging.txt, 2).

f) 尝试用s2ram工具通过已经加载的驱动程序,挂起内存。

(见:Documentation/power/basic-pm-debugging.txt, 2)。

Each of the above tests should be repeated several times and the STD tests

should be mixed with the STR tests. If any of them fails, the driver cannot be

regarded as suspend/resume-safe.

上述所有测试都应该被重复多次,并且STD测试应该和STR测试混合。如果其中有任何一个失败

了,驱动程序在暂停/恢复方面就不能视为是安全的。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: