Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
3b24f30c
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看板
提交
3b24f30c
编写于
12月 10, 2008
作者:
E
Eric Miao
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[ARM] pxa/littleton: add preliminary I2C board info (da9034 + max7320)
Signed-off-by:
N
Eric Miao
<
eric.miao@marvell.com
>
上级
111059e7
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
81 addition
and
3 deletion
+81
-3
arch/arm/mach-pxa/include/mach/littleton.h
arch/arm/mach-pxa/include/mach/littleton.h
+8
-3
arch/arm/mach-pxa/littleton.c
arch/arm/mach-pxa/littleton.c
+73
-0
未找到文件。
arch/arm/mach-pxa/include/mach/littleton.h
浏览文件 @
3b24f30c
#ifndef __ASM_ARCH_ZYLONITE_H
#define __ASM_ARCH_ZYLONITE_H
#ifndef __ASM_ARCH_LITTLETON_H
#define __ASM_ARCH_LITTLETON_H
#include <mach/gpio.h>
#define LITTLETON_ETH_PHYS 0x30000000
#define LITTLETON_GPIO_LCD_CS (17)
#endif
/* __ASM_ARCH_ZYLONITE_H */
#define EXT0_GPIO_BASE (NR_BUILTIN_GPIO)
#define EXT0_GPIO(x) (EXT0_GPIO_BASE + (x))
#endif
/* __ASM_ARCH_LITTLETON_H */
arch/arm/mach-pxa/littleton.c
浏览文件 @
3b24f30c
...
...
@@ -23,6 +23,10 @@
#include <linux/gpio.h>
#include <linux/spi/spi.h>
#include <linux/smc91x.h>
#include <linux/i2c.h>
#include <linux/leds.h>
#include <linux/mfd/da903x.h>
#include <linux/i2c/max732x.h>
#include <asm/types.h>
#include <asm/setup.h>
...
...
@@ -40,6 +44,7 @@
#include <mach/pxafb.h>
#include <mach/ssp.h>
#include <mach/pxa2xx_spi.h>
#include <mach/i2c.h>
#include <mach/pxa27x_keypad.h>
#include <mach/pxa3xx_nand.h>
#include <mach/littleton.h>
...
...
@@ -314,6 +319,73 @@ static void __init littleton_init_nand(void)
static
inline
void
littleton_init_nand
(
void
)
{}
#endif
/* CONFIG_MTD_NAND_PXA3xx || CONFIG_MTD_NAND_PXA3xx_MODULE */
#if defined(CONFIG_I2C_PXA) || defined(CONFIG_I2C_PXA_MODULE)
static
struct
led_info
littleton_da9034_leds
[]
=
{
[
0
]
=
{
.
name
=
"littleton:keypad1"
,
.
flags
=
DA9034_LED_RAMP
,
},
[
1
]
=
{
.
name
=
"littleton:keypad2"
,
.
flags
=
DA9034_LED_RAMP
,
},
[
2
]
=
{
.
name
=
"littleton:vibra"
,
.
flags
=
0
,
},
};
static
struct
da903x_subdev_info
littleton_da9034_subdevs
[]
=
{
{
.
name
=
"da903x-led"
,
.
id
=
DA9034_ID_LED_1
,
.
platform_data
=
&
littleton_da9034_leds
[
0
],
},
{
.
name
=
"da903x-led"
,
.
id
=
DA9034_ID_LED_2
,
.
platform_data
=
&
littleton_da9034_leds
[
1
],
},
{
.
name
=
"da903x-led"
,
.
id
=
DA9034_ID_VIBRA
,
.
platform_data
=
&
littleton_da9034_leds
[
2
],
},
{
.
name
=
"da903x-backlight"
,
.
id
=
DA9034_ID_WLED
,
},
};
static
struct
da903x_platform_data
littleton_da9034_info
=
{
.
num_subdevs
=
ARRAY_SIZE
(
littleton_da9034_subdevs
),
.
subdevs
=
littleton_da9034_subdevs
,
};
static
struct
max732x_platform_data
littleton_max7320_info
=
{
.
gpio_base
=
EXT0_GPIO_BASE
,
};
static
struct
i2c_board_info
littleton_i2c_info
[]
=
{
[
0
]
=
{
.
type
=
"da9034"
,
.
addr
=
0x34
,
.
platform_data
=
&
littleton_da9034_info
,
.
irq
=
gpio_to_irq
(
mfp_to_gpio
(
MFP_PIN_GPIO18
)),
},
[
1
]
=
{
.
type
=
"max7320"
,
.
addr
=
0x50
,
.
platform_data
=
&
littleton_max7320_info
,
},
};
static
void
__init
littleton_init_i2c
(
void
)
{
pxa_set_i2c_info
(
NULL
);
i2c_register_board_info
(
0
,
ARRAY_AND_SIZE
(
littleton_i2c_info
));
}
#else
static
inline
void
littleton_init_i2c
(
void
)
{}
#endif
/* CONFIG_I2C_PXA || CONFIG_I2C_PXA_MODULE */
static
void
__init
littleton_init
(
void
)
{
/* initialize MFP configurations */
...
...
@@ -326,6 +398,7 @@ static void __init littleton_init(void)
platform_device_register
(
&
smc91x_device
);
littleton_init_spi
();
littleton_init_i2c
();
littleton_init_lcd
();
littleton_init_keypad
();
littleton_init_nand
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录