aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/gpio.txt10
-rw-r--r--Documentation/zh_CN/gpio.txt8
2 files changed, 9 insertions, 9 deletions
diff --git a/Documentation/gpio.txt b/Documentation/gpio.txt
index 77a1d11af723..6f83fa965b4b 100644
--- a/Documentation/gpio.txt
+++ b/Documentation/gpio.txt
@@ -72,11 +72,11 @@ in this document, but drivers acting as clients to the GPIO interface must
72not care how it's implemented.) 72not care how it's implemented.)
73 73
74That said, if the convention is supported on their platform, drivers should 74That said, if the convention is supported on their platform, drivers should
75use it when possible. Platforms must declare GENERIC_GPIO support in their 75use it when possible. Platforms must select ARCH_REQUIRE_GPIOLIB or
76Kconfig (boolean true), and provide an <asm/gpio.h> file. Drivers that can't 76ARCH_WANT_OPTIONAL_GPIOLIB in their Kconfig. Drivers that can't work without
77work without standard GPIO calls should have Kconfig entries which depend 77standard GPIO calls should have Kconfig entries which depend on GPIOLIB. The
78on GENERIC_GPIO. The GPIO calls are available, either as "real code" or as 78GPIO calls are available, either as "real code" or as optimized-away stubs,
79optimized-away stubs, when drivers use the include file: 79when drivers use the include file:
80 80
81 #include <linux/gpio.h> 81 #include <linux/gpio.h>
82 82
diff --git a/Documentation/zh_CN/gpio.txt b/Documentation/zh_CN/gpio.txt
index 4fa7b4e6f856..d5b8f01833f4 100644
--- a/Documentation/zh_CN/gpio.txt
+++ b/Documentation/zh_CN/gpio.txt
@@ -84,10 +84,10 @@ GPIO 公约
84控制器的抽象函数来实现它。(有一些可选的代码能支持这种策略的实现,本文档 84控制器的抽象函数来实现它。(有一些可选的代码能支持这种策略的实现,本文档
85后面会介绍,但作为 GPIO 接口的客户端驱动程序必须与它的实现无关。) 85后面会介绍,但作为 GPIO 接口的客户端驱动程序必须与它的实现无关。)
86 86
87也就是说,如果在他们的平台上支持这个公约,驱动应尽可能的使用它。平台 87也就是说,如果在他们的平台上支持这个公约,驱动应尽可能的使用它。时,
88必须在 Kconfig 中 GENERIC_GPIO的支持 (布尔型 true),并 88必须在 Kconfig 中 ARCH_REQUIRE_GPIOLIB 者 ARCH_WANT_OPTIONAL_GPIOLIB
89个 <asm/gpio.h> 文件。那些调用标准 GPIO 函数的驱动应该在 Kconfig 89。那些调用标准 GPIO 函数的驱动应该在 Kconfig 入口中声明依赖GENERIC_GPIO。
90口中声明依赖GENERIC_GPIO。驱动包含文件: 90当驱动包含文件:
91 91
92 #include <linux/gpio.h> 92 #include <linux/gpio.h>
93 93