Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
170c2d0a
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
161
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
170c2d0a
编写于
11月 14, 2012
作者:
M
Mark Brown
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'spi-mcspi' into spi-next
上级
8266bdd2
2cd45179
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
8 addition
and
8 deletion
+8
-8
Documentation/devicetree/bindings/spi/omap-spi.txt
Documentation/devicetree/bindings/spi/omap-spi.txt
+3
-3
drivers/spi/spi-omap2-mcspi.c
drivers/spi/spi-omap2-mcspi.c
+3
-3
include/linux/platform_data/spi-omap2-mcspi.h
include/linux/platform_data/spi-omap2-mcspi.h
+2
-2
未找到文件。
Documentation/devicetree/bindings/spi/omap-spi.txt
浏览文件 @
170c2d0a
...
...
@@ -6,9 +6,9 @@ Required properties:
- "ti,omap4-spi" for OMAP4+.
- ti,spi-num-cs : Number of chipselect supported by the instance.
- ti,hwmods: Name of the hwmod associated to the McSPI
- ti,pindir-d0-
in-d1-out: Select the D0 pin as in
put and D1 as
output. The default is D0 as out
put and
D1 as
in
put.
- ti,pindir-d0-
out-d1-in: Select the D0 pin as out
put and D1 as
input. The default is D0 as in
put and
D1 as
out
put.
Example:
...
...
drivers/spi/spi-omap2-mcspi.c
浏览文件 @
170c2d0a
...
...
@@ -765,7 +765,7 @@ static int omap2_mcspi_setup_transfer(struct spi_device *spi,
/* standard 4-wire master mode: SCK, MOSI/out, MISO/in, nCS
* REVISIT: this controller could support SPI_3WIRE mode.
*/
if
(
mcspi
->
pin_dir
==
MCSPI_PINDIR_D0_
OUT_D1_IN
)
{
if
(
mcspi
->
pin_dir
==
MCSPI_PINDIR_D0_
IN_D1_OUT
)
{
l
&=
~
OMAP2_MCSPI_CHCONF_IS
;
l
&=
~
OMAP2_MCSPI_CHCONF_DPE1
;
l
|=
OMAP2_MCSPI_CHCONF_DPE0
;
...
...
@@ -1187,8 +1187,8 @@ static int __devinit omap2_mcspi_probe(struct platform_device *pdev)
of_property_read_u32
(
node
,
"ti,spi-num-cs"
,
&
num_cs
);
master
->
num_chipselect
=
num_cs
;
master
->
bus_num
=
bus_num
++
;
if
(
of_get_property
(
node
,
"ti,pindir-d0-
in-d1-out
"
,
NULL
))
mcspi
->
pin_dir
=
MCSPI_PINDIR_D0_
IN_D1_OUT
;
if
(
of_get_property
(
node
,
"ti,pindir-d0-
out-d1-in
"
,
NULL
))
mcspi
->
pin_dir
=
MCSPI_PINDIR_D0_
OUT_D1_IN
;
}
else
{
pdata
=
pdev
->
dev
.
platform_data
;
master
->
num_chipselect
=
pdata
->
num_cs
;
...
...
include/linux/platform_data/spi-omap2-mcspi.h
浏览文件 @
170c2d0a
...
...
@@ -7,8 +7,8 @@
#define OMAP4_MCSPI_REG_OFFSET 0x100
#define MCSPI_PINDIR_D0_
OUT_D1_IN
0
#define MCSPI_PINDIR_D0_
IN_D1_OUT
1
#define MCSPI_PINDIR_D0_
IN_D1_OUT
0
#define MCSPI_PINDIR_D0_
OUT_D1_IN
1
struct
omap2_mcspi_platform_config
{
unsigned
short
num_cs
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录