Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
d10f2b6e
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
13
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
raspberrypi-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
d10f2b6e
编写于
2月 12, 2010
作者:
T
Tony Lindgren
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
omap2/3/4: Fix mbox init for multi-omap
Fix mbox init for multi-omap Signed-off-by:
N
Tony Lindgren
<
tony@atomide.com
>
上级
6fbd55d0
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
24 addition
and
6 deletion
+24
-6
arch/arm/mach-omap2/devices.c
arch/arm/mach-omap2/devices.c
+24
-6
未找到文件。
arch/arm/mach-omap2/devices.c
浏览文件 @
d10f2b6e
...
@@ -141,7 +141,7 @@ static inline void omap_init_camera(void)
...
@@ -141,7 +141,7 @@ static inline void omap_init_camera(void)
#define MBOX_REG_SIZE 0x120
#define MBOX_REG_SIZE 0x120
#ifdef CONFIG_ARCH_OMAP2
#ifdef CONFIG_ARCH_OMAP2
static
struct
resource
omap_mbox_resources
[]
=
{
static
struct
resource
omap
2
_mbox_resources
[]
=
{
{
{
.
start
=
OMAP24XX_MAILBOX_BASE
,
.
start
=
OMAP24XX_MAILBOX_BASE
,
.
end
=
OMAP24XX_MAILBOX_BASE
+
MBOX_REG_SIZE
-
1
,
.
end
=
OMAP24XX_MAILBOX_BASE
+
MBOX_REG_SIZE
-
1
,
...
@@ -156,10 +156,14 @@ static struct resource omap_mbox_resources[] = {
...
@@ -156,10 +156,14 @@ static struct resource omap_mbox_resources[] = {
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
};
};
static
int
omap2_mbox_resources_sz
=
ARRAY_SIZE
(
omap2_mbox_resources
);
#else
#define omap2_mbox_resources NULL
#define omap2_mbox_resources_sz 0
#endif
#endif
#ifdef CONFIG_ARCH_OMAP3
#ifdef CONFIG_ARCH_OMAP3
static
struct
resource
omap_mbox_resources
[]
=
{
static
struct
resource
omap
3
_mbox_resources
[]
=
{
{
{
.
start
=
OMAP34XX_MAILBOX_BASE
,
.
start
=
OMAP34XX_MAILBOX_BASE
,
.
end
=
OMAP34XX_MAILBOX_BASE
+
MBOX_REG_SIZE
-
1
,
.
end
=
OMAP34XX_MAILBOX_BASE
+
MBOX_REG_SIZE
-
1
,
...
@@ -170,12 +174,16 @@ static struct resource omap_mbox_resources[] = {
...
@@ -170,12 +174,16 @@ static struct resource omap_mbox_resources[] = {
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
};
};
static
int
omap3_mbox_resources_sz
=
ARRAY_SIZE
(
omap3_mbox_resources
);
#else
#define omap3_mbox_resources NULL
#define omap3_mbox_resources_sz 0
#endif
#endif
#ifdef CONFIG_ARCH_OMAP4
#ifdef CONFIG_ARCH_OMAP4
#define OMAP4_MBOX_REG_SIZE 0x130
#define OMAP4_MBOX_REG_SIZE 0x130
static
struct
resource
omap_mbox_resources
[]
=
{
static
struct
resource
omap
4
_mbox_resources
[]
=
{
{
{
.
start
=
OMAP44XX_MAILBOX_BASE
,
.
start
=
OMAP44XX_MAILBOX_BASE
,
.
end
=
OMAP44XX_MAILBOX_BASE
+
.
end
=
OMAP44XX_MAILBOX_BASE
+
...
@@ -187,6 +195,10 @@ static struct resource omap_mbox_resources[] = {
...
@@ -187,6 +195,10 @@ static struct resource omap_mbox_resources[] = {
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
};
};
static
int
omap4_mbox_resources_sz
=
ARRAY_SIZE
(
omap4_mbox_resources
);
#else
#define omap4_mbox_resources NULL
#define omap4_mbox_resources_sz 0
#endif
#endif
static
struct
platform_device
mbox_device
=
{
static
struct
platform_device
mbox_device
=
{
...
@@ -196,9 +208,15 @@ static struct platform_device mbox_device = {
...
@@ -196,9 +208,15 @@ static struct platform_device mbox_device = {
static
inline
void
omap_init_mbox
(
void
)
static
inline
void
omap_init_mbox
(
void
)
{
{
if
(
cpu_is_omap2420
()
||
cpu_is_omap3430
()
||
cpu_is_omap44xx
())
{
if
(
cpu_is_omap24xx
())
{
mbox_device
.
num_resources
=
ARRAY_SIZE
(
omap_mbox_resources
);
mbox_device
.
resource
=
omap2_mbox_resources
;
mbox_device
.
resource
=
omap_mbox_resources
;
mbox_device
.
num_resources
=
omap2_mbox_resources_sz
;
}
else
if
(
cpu_is_omap34xx
())
{
mbox_device
.
resource
=
omap3_mbox_resources
;
mbox_device
.
num_resources
=
omap3_mbox_resources_sz
;
}
else
if
(
cpu_is_omap44xx
())
{
mbox_device
.
resource
=
omap4_mbox_resources
;
mbox_device
.
num_resources
=
omap4_mbox_resources_sz
;
}
else
{
}
else
{
pr_err
(
"%s: platform not supported
\n
"
,
__func__
);
pr_err
(
"%s: platform not supported
\n
"
,
__func__
);
return
;
return
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录