Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
9b0e6db0
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
160
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看板
提交
9b0e6db0
编写于
6月 23, 2009
作者:
S
Sascha Hauer
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
mx1: Codingstyle: Let the compiler count arrays
Signed-off-by:
N
Sascha Hauer
<
s.hauer@pengutronix.de
>
上级
3f4f54b4
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
39 addition
and
62 deletion
+39
-62
arch/arm/mach-mx1/devices.c
arch/arm/mach-mx1/devices.c
+33
-54
arch/arm/mach-mx1/scb9328.c
arch/arm/mach-mx1/scb9328.c
+6
-8
未找到文件。
arch/arm/mach-mx1/devices.c
浏览文件 @
9b0e6db0
...
@@ -29,12 +29,11 @@
...
@@ -29,12 +29,11 @@
#include "devices.h"
#include "devices.h"
static
struct
resource
imx_csi_resources
[]
=
{
static
struct
resource
imx_csi_resources
[]
=
{
[
0
]
=
{
{
.
start
=
0x00224000
,
.
start
=
0x00224000
,
.
end
=
0x00224010
,
.
end
=
0x00224010
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
CSI_INT
,
.
start
=
CSI_INT
,
.
end
=
CSI_INT
,
.
end
=
CSI_INT
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -55,12 +54,11 @@ struct platform_device imx_csi_device = {
...
@@ -55,12 +54,11 @@ struct platform_device imx_csi_device = {
};
};
static
struct
resource
imx_i2c_resources
[]
=
{
static
struct
resource
imx_i2c_resources
[]
=
{
[
0
]
=
{
{
.
start
=
0x00217000
,
.
start
=
0x00217000
,
.
end
=
0x00217010
,
.
end
=
0x00217010
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
I2C_INT
,
.
start
=
I2C_INT
,
.
end
=
I2C_INT
,
.
end
=
I2C_INT
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -75,22 +73,19 @@ struct platform_device imx_i2c_device = {
...
@@ -75,22 +73,19 @@ struct platform_device imx_i2c_device = {
};
};
static
struct
resource
imx_uart1_resources
[]
=
{
static
struct
resource
imx_uart1_resources
[]
=
{
[
0
]
=
{
{
.
start
=
UART1_BASE_ADDR
,
.
start
=
UART1_BASE_ADDR
,
.
end
=
UART1_BASE_ADDR
+
0xD0
,
.
end
=
UART1_BASE_ADDR
+
0xD0
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
UART1_MINT_RX
,
.
start
=
UART1_MINT_RX
,
.
end
=
UART1_MINT_RX
,
.
end
=
UART1_MINT_RX
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
2
]
=
{
.
start
=
UART1_MINT_TX
,
.
start
=
UART1_MINT_TX
,
.
end
=
UART1_MINT_TX
,
.
end
=
UART1_MINT_TX
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
3
]
=
{
.
start
=
UART1_MINT_RTS
,
.
start
=
UART1_MINT_RTS
,
.
end
=
UART1_MINT_RTS
,
.
end
=
UART1_MINT_RTS
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -105,22 +100,19 @@ struct platform_device imx_uart1_device = {
...
@@ -105,22 +100,19 @@ struct platform_device imx_uart1_device = {
};
};
static
struct
resource
imx_uart2_resources
[]
=
{
static
struct
resource
imx_uart2_resources
[]
=
{
[
0
]
=
{
{
.
start
=
UART2_BASE_ADDR
,
.
start
=
UART2_BASE_ADDR
,
.
end
=
UART2_BASE_ADDR
+
0xD0
,
.
end
=
UART2_BASE_ADDR
+
0xD0
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
UART2_MINT_RX
,
.
start
=
UART2_MINT_RX
,
.
end
=
UART2_MINT_RX
,
.
end
=
UART2_MINT_RX
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
2
]
=
{
.
start
=
UART2_MINT_TX
,
.
start
=
UART2_MINT_TX
,
.
end
=
UART2_MINT_TX
,
.
end
=
UART2_MINT_TX
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
3
]
=
{
.
start
=
UART2_MINT_RTS
,
.
start
=
UART2_MINT_RTS
,
.
end
=
UART2_MINT_RTS
,
.
end
=
UART2_MINT_RTS
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -135,17 +127,15 @@ struct platform_device imx_uart2_device = {
...
@@ -135,17 +127,15 @@ struct platform_device imx_uart2_device = {
};
};
static
struct
resource
imx_rtc_resources
[]
=
{
static
struct
resource
imx_rtc_resources
[]
=
{
[
0
]
=
{
{
.
start
=
0x00204000
,
.
start
=
0x00204000
,
.
end
=
0x00204024
,
.
end
=
0x00204024
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
RTC_INT
,
.
start
=
RTC_INT
,
.
end
=
RTC_INT
,
.
end
=
RTC_INT
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
2
]
=
{
.
start
=
RTC_SAMINT
,
.
start
=
RTC_SAMINT
,
.
end
=
RTC_SAMINT
,
.
end
=
RTC_SAMINT
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -160,12 +150,11 @@ struct platform_device imx_rtc_device = {
...
@@ -160,12 +150,11 @@ struct platform_device imx_rtc_device = {
};
};
static
struct
resource
imx_wdt_resources
[]
=
{
static
struct
resource
imx_wdt_resources
[]
=
{
[
0
]
=
{
{
.
start
=
0x00201000
,
.
start
=
0x00201000
,
.
end
=
0x00201008
,
.
end
=
0x00201008
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
WDT_INT
,
.
start
=
WDT_INT
,
.
end
=
WDT_INT
,
.
end
=
WDT_INT
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -180,42 +169,35 @@ struct platform_device imx_wdt_device = {
...
@@ -180,42 +169,35 @@ struct platform_device imx_wdt_device = {
};
};
static
struct
resource
imx_usb_resources
[]
=
{
static
struct
resource
imx_usb_resources
[]
=
{
[
0
]
=
{
{
.
start
=
0x00212000
,
.
start
=
0x00212000
,
.
end
=
0x00212148
,
.
end
=
0x00212148
,
.
flags
=
IORESOURCE_MEM
,
.
flags
=
IORESOURCE_MEM
,
},
},
{
[
1
]
=
{
.
start
=
USBD_INT0
,
.
start
=
USBD_INT0
,
.
end
=
USBD_INT0
,
.
end
=
USBD_INT0
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
2
]
=
{
.
start
=
USBD_INT1
,
.
start
=
USBD_INT1
,
.
end
=
USBD_INT1
,
.
end
=
USBD_INT1
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
3
]
=
{
.
start
=
USBD_INT2
,
.
start
=
USBD_INT2
,
.
end
=
USBD_INT2
,
.
end
=
USBD_INT2
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
4
]
=
{
.
start
=
USBD_INT3
,
.
start
=
USBD_INT3
,
.
end
=
USBD_INT3
,
.
end
=
USBD_INT3
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
5
]
=
{
.
start
=
USBD_INT4
,
.
start
=
USBD_INT4
,
.
end
=
USBD_INT4
,
.
end
=
USBD_INT4
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
6
]
=
{
.
start
=
USBD_INT5
,
.
start
=
USBD_INT5
,
.
end
=
USBD_INT5
,
.
end
=
USBD_INT5
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
},
},
{
[
7
]
=
{
.
start
=
USBD_INT6
,
.
start
=
USBD_INT6
,
.
end
=
USBD_INT6
,
.
end
=
USBD_INT6
,
.
flags
=
IORESOURCE_IRQ
,
.
flags
=
IORESOURCE_IRQ
,
...
@@ -231,29 +213,26 @@ struct platform_device imx_usb_device = {
...
@@ -231,29 +213,26 @@ struct platform_device imx_usb_device = {
/* GPIO port description */
/* GPIO port description */
static
struct
mxc_gpio_port
imx_gpio_ports
[]
=
{
static
struct
mxc_gpio_port
imx_gpio_ports
[]
=
{
[
0
]
=
{
{
.
chip
.
label
=
"gpio-0"
,
.
chip
.
label
=
"gpio-0"
,
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
),
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
),
.
irq
=
GPIO_INT_PORTA
,
.
irq
=
GPIO_INT_PORTA
,
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
,
},
},
{
[
1
]
=
{
.
chip
.
label
=
"gpio-1"
,
.
chip
.
label
=
"gpio-1"
,
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
+
0x100
),
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
+
0x100
),
.
irq
=
GPIO_INT_PORTB
,
.
irq
=
GPIO_INT_PORTB
,
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
+
32
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
+
32
,
},
},
{
[
2
]
=
{
.
chip
.
label
=
"gpio-2"
,
.
chip
.
label
=
"gpio-2"
,
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
+
0x200
),
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
+
0x200
),
.
irq
=
GPIO_INT_PORTC
,
.
irq
=
GPIO_INT_PORTC
,
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
+
64
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
+
64
,
},
},
{
[
3
]
=
{
.
chip
.
label
=
"gpio-3"
,
.
chip
.
label
=
"gpio-3"
,
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
+
0x300
),
.
base
=
(
void
__iomem
*
)
IO_ADDRESS
(
GPIO_BASE_ADDR
+
0x300
),
.
irq
=
GPIO_INT_PORTD
,
.
irq
=
GPIO_INT_PORTD
,
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
+
96
.
virtual_irq_start
=
MXC_GPIO_IRQ_START
+
96
,
}
}
};
};
...
...
arch/arm/mach-mx1/scb9328.c
浏览文件 @
9b0e6db0
...
@@ -68,22 +68,20 @@ static struct dm9000_plat_data dm9000_platdata = {
...
@@ -68,22 +68,20 @@ static struct dm9000_plat_data dm9000_platdata = {
* to gain access to address latch registers and the data path.
* to gain access to address latch registers and the data path.
*/
*/
static
struct
resource
dm9000x_resources
[]
=
{
static
struct
resource
dm9000x_resources
[]
=
{
[
0
]
=
{
{
.
name
=
"address area"
,
.
name
=
"address area"
,
.
start
=
IMX_CS5_PHYS
,
.
start
=
IMX_CS5_PHYS
,
.
end
=
IMX_CS5_PHYS
+
1
,
.
end
=
IMX_CS5_PHYS
+
1
,
.
flags
=
IORESOURCE_MEM
/* address access */
.
flags
=
IORESOURCE_MEM
,
/* address access */
},
},
{
[
1
]
=
{
.
name
=
"data area"
,
.
name
=
"data area"
,
.
start
=
IMX_CS5_PHYS
+
4
,
.
start
=
IMX_CS5_PHYS
+
4
,
.
end
=
IMX_CS5_PHYS
+
5
,
.
end
=
IMX_CS5_PHYS
+
5
,
.
flags
=
IORESOURCE_MEM
/* data access */
.
flags
=
IORESOURCE_MEM
,
/* data access */
},
},
{
[
2
]
=
{
.
start
=
IRQ_GPIOC
(
3
),
.
start
=
IRQ_GPIOC
(
3
),
.
end
=
IRQ_GPIOC
(
3
),
.
end
=
IRQ_GPIOC
(
3
),
.
flags
=
IORESOURCE_IRQ
|
IORESOURCE_IRQ_LOWLEVEL
.
flags
=
IORESOURCE_IRQ
|
IORESOURCE_IRQ_LOWLEVEL
,
},
},
};
};
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录