Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
ccfadbb7
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
14
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看板
提交
ccfadbb7
编写于
5月 02, 2018
作者:
S
Sekhar Nori
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'v4.18/nand-cs-simplification' into v4.18/soc
上级
8e730c7f
7c4db57c
变更
12
隐藏空白更改
内联
并排
Showing
12 changed file
with
26 addition
and
7 deletion
+26
-7
arch/arm/mach-davinci/aemif.c
arch/arm/mach-davinci/aemif.c
+4
-4
arch/arm/mach-davinci/board-da830-evm.c
arch/arm/mach-davinci/board-da830-evm.c
+1
-0
arch/arm/mach-davinci/board-da850-evm.c
arch/arm/mach-davinci/board-da850-evm.c
+1
-0
arch/arm/mach-davinci/board-dm355-evm.c
arch/arm/mach-davinci/board-dm355-evm.c
+1
-0
arch/arm/mach-davinci/board-dm355-leopard.c
arch/arm/mach-davinci/board-dm355-leopard.c
+1
-0
arch/arm/mach-davinci/board-dm365-evm.c
arch/arm/mach-davinci/board-dm365-evm.c
+1
-0
arch/arm/mach-davinci/board-dm644x-evm.c
arch/arm/mach-davinci/board-dm644x-evm.c
+1
-0
arch/arm/mach-davinci/board-dm646x-evm.c
arch/arm/mach-davinci/board-dm646x-evm.c
+1
-0
arch/arm/mach-davinci/board-mityomapl138.c
arch/arm/mach-davinci/board-mityomapl138.c
+1
-0
arch/arm/mach-davinci/board-neuros-osd2.c
arch/arm/mach-davinci/board-neuros-osd2.c
+1
-0
drivers/mtd/nand/raw/davinci_nand.c
drivers/mtd/nand/raw/davinci_nand.c
+3
-3
include/linux/platform_data/mtd-davinci.h
include/linux/platform_data/mtd-davinci.h
+10
-0
未找到文件。
arch/arm/mach-davinci/aemif.c
浏览文件 @
ccfadbb7
...
@@ -189,7 +189,7 @@ int davinci_aemif_setup(struct platform_device *pdev)
...
@@ -189,7 +189,7 @@ int davinci_aemif_setup(struct platform_device *pdev)
* Setup Async configuration register in case we did not boot
* Setup Async configuration register in case we did not boot
* from NAND and so bootloader did not bother to set it up.
* from NAND and so bootloader did not bother to set it up.
*/
*/
val
=
davinci_aemif_readl
(
base
,
A1CR_OFFSET
+
pd
ev
->
id
*
4
);
val
=
davinci_aemif_readl
(
base
,
A1CR_OFFSET
+
pd
ata
->
core_chipsel
*
4
);
/*
/*
* Extended Wait is not valid and Select Strobe mode is not
* Extended Wait is not valid and Select Strobe mode is not
* used
* used
...
@@ -198,13 +198,13 @@ int davinci_aemif_setup(struct platform_device *pdev)
...
@@ -198,13 +198,13 @@ int davinci_aemif_setup(struct platform_device *pdev)
if
(
pdata
->
options
&
NAND_BUSWIDTH_16
)
if
(
pdata
->
options
&
NAND_BUSWIDTH_16
)
val
|=
0x1
;
val
|=
0x1
;
davinci_aemif_writel
(
base
,
A1CR_OFFSET
+
pd
ev
->
id
*
4
,
val
);
davinci_aemif_writel
(
base
,
A1CR_OFFSET
+
pd
ata
->
core_chipsel
*
4
,
val
);
clkrate
=
clk_get_rate
(
clk
);
clkrate
=
clk_get_rate
(
clk
);
if
(
pdata
->
timing
)
if
(
pdata
->
timing
)
ret
=
davinci_aemif_setup_timing
(
pdata
->
timing
,
base
,
pdev
->
id
,
ret
=
davinci_aemif_setup_timing
(
pdata
->
timing
,
base
,
clkrate
);
pdata
->
core_chipsel
,
clkrate
);
if
(
ret
<
0
)
if
(
ret
<
0
)
dev_dbg
(
&
pdev
->
dev
,
"NAND timing values setup fail
\n
"
);
dev_dbg
(
&
pdev
->
dev
,
"NAND timing values setup fail
\n
"
);
...
...
arch/arm/mach-davinci/board-da830-evm.c
浏览文件 @
ccfadbb7
...
@@ -310,6 +310,7 @@ static struct davinci_aemif_timing da830_evm_nandflash_timing = {
...
@@ -310,6 +310,7 @@ static struct davinci_aemif_timing da830_evm_nandflash_timing = {
};
};
static
struct
davinci_nand_pdata
da830_evm_nand_pdata
=
{
static
struct
davinci_nand_pdata
da830_evm_nand_pdata
=
{
.
core_chipsel
=
1
,
.
parts
=
da830_evm_nand_partitions
,
.
parts
=
da830_evm_nand_partitions
,
.
nr_parts
=
ARRAY_SIZE
(
da830_evm_nand_partitions
),
.
nr_parts
=
ARRAY_SIZE
(
da830_evm_nand_partitions
),
.
ecc_mode
=
NAND_ECC_HW
,
.
ecc_mode
=
NAND_ECC_HW
,
...
...
arch/arm/mach-davinci/board-da850-evm.c
浏览文件 @
ccfadbb7
...
@@ -244,6 +244,7 @@ static struct davinci_aemif_timing da850_evm_nandflash_timing = {
...
@@ -244,6 +244,7 @@ static struct davinci_aemif_timing da850_evm_nandflash_timing = {
};
};
static
struct
davinci_nand_pdata
da850_evm_nandflash_data
=
{
static
struct
davinci_nand_pdata
da850_evm_nandflash_data
=
{
.
core_chipsel
=
1
,
.
parts
=
da850_evm_nandflash_partition
,
.
parts
=
da850_evm_nandflash_partition
,
.
nr_parts
=
ARRAY_SIZE
(
da850_evm_nandflash_partition
),
.
nr_parts
=
ARRAY_SIZE
(
da850_evm_nandflash_partition
),
.
ecc_mode
=
NAND_ECC_HW
,
.
ecc_mode
=
NAND_ECC_HW
,
...
...
arch/arm/mach-davinci/board-dm355-evm.c
浏览文件 @
ccfadbb7
...
@@ -77,6 +77,7 @@ static struct mtd_partition davinci_nand_partitions[] = {
...
@@ -77,6 +77,7 @@ static struct mtd_partition davinci_nand_partitions[] = {
};
};
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
.
core_chipsel
=
0
,
.
mask_chipsel
=
BIT
(
14
),
.
mask_chipsel
=
BIT
(
14
),
.
parts
=
davinci_nand_partitions
,
.
parts
=
davinci_nand_partitions
,
.
nr_parts
=
ARRAY_SIZE
(
davinci_nand_partitions
),
.
nr_parts
=
ARRAY_SIZE
(
davinci_nand_partitions
),
...
...
arch/arm/mach-davinci/board-dm355-leopard.c
浏览文件 @
ccfadbb7
...
@@ -72,6 +72,7 @@ static struct mtd_partition davinci_nand_partitions[] = {
...
@@ -72,6 +72,7 @@ static struct mtd_partition davinci_nand_partitions[] = {
};
};
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
.
core_chipsel
=
0
,
.
mask_chipsel
=
BIT
(
14
),
.
mask_chipsel
=
BIT
(
14
),
.
parts
=
davinci_nand_partitions
,
.
parts
=
davinci_nand_partitions
,
.
nr_parts
=
ARRAY_SIZE
(
davinci_nand_partitions
),
.
nr_parts
=
ARRAY_SIZE
(
davinci_nand_partitions
),
...
...
arch/arm/mach-davinci/board-dm365-evm.c
浏览文件 @
ccfadbb7
...
@@ -138,6 +138,7 @@ static struct mtd_partition davinci_nand_partitions[] = {
...
@@ -138,6 +138,7 @@ static struct mtd_partition davinci_nand_partitions[] = {
};
};
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
.
core_chipsel
=
0
,
.
mask_chipsel
=
BIT
(
14
),
.
mask_chipsel
=
BIT
(
14
),
.
parts
=
davinci_nand_partitions
,
.
parts
=
davinci_nand_partitions
,
.
nr_parts
=
ARRAY_SIZE
(
davinci_nand_partitions
),
.
nr_parts
=
ARRAY_SIZE
(
davinci_nand_partitions
),
...
...
arch/arm/mach-davinci/board-dm644x-evm.c
浏览文件 @
ccfadbb7
...
@@ -152,6 +152,7 @@ static struct davinci_aemif_timing davinci_evm_nandflash_timing = {
...
@@ -152,6 +152,7 @@ static struct davinci_aemif_timing davinci_evm_nandflash_timing = {
};
};
static
struct
davinci_nand_pdata
davinci_evm_nandflash_data
=
{
static
struct
davinci_nand_pdata
davinci_evm_nandflash_data
=
{
.
core_chipsel
=
0
,
.
parts
=
davinci_evm_nandflash_partition
,
.
parts
=
davinci_evm_nandflash_partition
,
.
nr_parts
=
ARRAY_SIZE
(
davinci_evm_nandflash_partition
),
.
nr_parts
=
ARRAY_SIZE
(
davinci_evm_nandflash_partition
),
.
ecc_mode
=
NAND_ECC_HW
,
.
ecc_mode
=
NAND_ECC_HW
,
...
...
arch/arm/mach-davinci/board-dm646x-evm.c
浏览文件 @
ccfadbb7
...
@@ -84,6 +84,7 @@ static struct davinci_aemif_timing dm6467tevm_nandflash_timing = {
...
@@ -84,6 +84,7 @@ static struct davinci_aemif_timing dm6467tevm_nandflash_timing = {
};
};
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
static
struct
davinci_nand_pdata
davinci_nand_data
=
{
.
core_chipsel
=
0
,
.
mask_cle
=
0x80000
,
.
mask_cle
=
0x80000
,
.
mask_ale
=
0x40000
,
.
mask_ale
=
0x40000
,
.
parts
=
davinci_nand_partitions
,
.
parts
=
davinci_nand_partitions
,
...
...
arch/arm/mach-davinci/board-mityomapl138.c
浏览文件 @
ccfadbb7
...
@@ -400,6 +400,7 @@ static struct mtd_partition mityomapl138_nandflash_partition[] = {
...
@@ -400,6 +400,7 @@ static struct mtd_partition mityomapl138_nandflash_partition[] = {
};
};
static
struct
davinci_nand_pdata
mityomapl138_nandflash_data
=
{
static
struct
davinci_nand_pdata
mityomapl138_nandflash_data
=
{
.
core_chipsel
=
1
,
.
parts
=
mityomapl138_nandflash_partition
,
.
parts
=
mityomapl138_nandflash_partition
,
.
nr_parts
=
ARRAY_SIZE
(
mityomapl138_nandflash_partition
),
.
nr_parts
=
ARRAY_SIZE
(
mityomapl138_nandflash_partition
),
.
ecc_mode
=
NAND_ECC_HW
,
.
ecc_mode
=
NAND_ECC_HW
,
...
...
arch/arm/mach-davinci/board-neuros-osd2.c
浏览文件 @
ccfadbb7
...
@@ -87,6 +87,7 @@ static struct mtd_partition davinci_ntosd2_nandflash_partition[] = {
...
@@ -87,6 +87,7 @@ static struct mtd_partition davinci_ntosd2_nandflash_partition[] = {
};
};
static
struct
davinci_nand_pdata
davinci_ntosd2_nandflash_data
=
{
static
struct
davinci_nand_pdata
davinci_ntosd2_nandflash_data
=
{
.
core_chipsel
=
0
,
.
parts
=
davinci_ntosd2_nandflash_partition
,
.
parts
=
davinci_ntosd2_nandflash_partition
,
.
nr_parts
=
ARRAY_SIZE
(
davinci_ntosd2_nandflash_partition
),
.
nr_parts
=
ARRAY_SIZE
(
davinci_ntosd2_nandflash_partition
),
.
ecc_mode
=
NAND_ECC_HW
,
.
ecc_mode
=
NAND_ECC_HW
,
...
...
drivers/mtd/nand/raw/davinci_nand.c
浏览文件 @
ccfadbb7
...
@@ -547,7 +547,7 @@ static struct davinci_nand_pdata
...
@@ -547,7 +547,7 @@ static struct davinci_nand_pdata
return
ERR_PTR
(
-
ENOMEM
);
return
ERR_PTR
(
-
ENOMEM
);
if
(
!
of_property_read_u32
(
pdev
->
dev
.
of_node
,
if
(
!
of_property_read_u32
(
pdev
->
dev
.
of_node
,
"ti,davinci-chipselect"
,
&
prop
))
"ti,davinci-chipselect"
,
&
prop
))
pd
ev
->
id
=
prop
;
pd
ata
->
core_chipsel
=
prop
;
else
else
return
ERR_PTR
(
-
EINVAL
);
return
ERR_PTR
(
-
EINVAL
);
...
@@ -629,7 +629,7 @@ static int nand_davinci_probe(struct platform_device *pdev)
...
@@ -629,7 +629,7 @@ static int nand_davinci_probe(struct platform_device *pdev)
return
-
ENODEV
;
return
-
ENODEV
;
/* which external chipselect will we be managing? */
/* which external chipselect will we be managing? */
if
(
pd
ev
->
id
<
0
||
pdev
->
id
>
3
)
if
(
pd
ata
->
core_chipsel
<
0
||
pdata
->
core_chipsel
>
3
)
return
-
ENODEV
;
return
-
ENODEV
;
info
=
devm_kzalloc
(
&
pdev
->
dev
,
sizeof
(
*
info
),
GFP_KERNEL
);
info
=
devm_kzalloc
(
&
pdev
->
dev
,
sizeof
(
*
info
),
GFP_KERNEL
);
...
@@ -685,7 +685,7 @@ static int nand_davinci_probe(struct platform_device *pdev)
...
@@ -685,7 +685,7 @@ static int nand_davinci_probe(struct platform_device *pdev)
info
->
ioaddr
=
(
uint32_t
__force
)
vaddr
;
info
->
ioaddr
=
(
uint32_t
__force
)
vaddr
;
info
->
current_cs
=
info
->
ioaddr
;
info
->
current_cs
=
info
->
ioaddr
;
info
->
core_chipsel
=
pd
ev
->
id
;
info
->
core_chipsel
=
pd
ata
->
core_chipsel
;
info
->
mask_chipsel
=
pdata
->
mask_chipsel
;
info
->
mask_chipsel
=
pdata
->
mask_chipsel
;
/* use nandboot-capable ALE/CLE masks by default */
/* use nandboot-capable ALE/CLE masks by default */
...
...
include/linux/platform_data/mtd-davinci.h
浏览文件 @
ccfadbb7
...
@@ -56,6 +56,16 @@ struct davinci_nand_pdata { /* platform_data */
...
@@ -56,6 +56,16 @@ struct davinci_nand_pdata { /* platform_data */
uint32_t
mask_ale
;
uint32_t
mask_ale
;
uint32_t
mask_cle
;
uint32_t
mask_cle
;
/*
* 0-indexed chip-select number of the asynchronous
* interface to which the NAND device has been connected.
*
* So, if you have NAND connected to CS3 of DA850, you
* will pass '1' here. Since the asynchronous interface
* on DA850 starts from CS2.
*/
uint32_t
core_chipsel
;
/* for packages using two chipselects */
/* for packages using two chipselects */
uint32_t
mask_chipsel
;
uint32_t
mask_chipsel
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录