Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
c5fa44d1
K
Kernel
项目概览
openeuler
/
Kernel
接近 2 年 前同步成功
通知
8
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
c5fa44d1
编写于
6月 13, 2013
作者:
S
Samuel Ortiz
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'for-mfd-next' of
git://git.linaro.org/people/ljones/linux-3.0-ux500
上级
734f935a
aaaab422
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
77 addition
and
46 deletion
+77
-46
drivers/mfd/88pm860x-core.c
drivers/mfd/88pm860x-core.c
+1
-2
drivers/mfd/aat2870-core.c
drivers/mfd/aat2870-core.c
+3
-2
drivers/mfd/ab3100-core.c
drivers/mfd/ab3100-core.c
+10
-18
drivers/mfd/ab8500-core.c
drivers/mfd/ab8500-core.c
+58
-21
drivers/mfd/ab8500-debugfs.c
drivers/mfd/ab8500-debugfs.c
+1
-1
drivers/mfd/dbx500-prcmu-regs.h
drivers/mfd/dbx500-prcmu-regs.h
+2
-2
include/linux/mfd/abx500/ab8500.h
include/linux/mfd/abx500/ab8500.h
+2
-0
未找到文件。
drivers/mfd/88pm860x-core.c
浏览文件 @
c5fa44d1
...
@@ -1155,7 +1155,7 @@ static int pm860x_probe(struct i2c_client *client,
...
@@ -1155,7 +1155,7 @@ static int pm860x_probe(struct i2c_client *client,
return
-
ENOMEM
;
return
-
ENOMEM
;
chip
->
id
=
verify_addr
(
client
);
chip
->
id
=
verify_addr
(
client
);
chip
->
regmap
=
regmap_init_i2c
(
client
,
&
pm860x_regmap_config
);
chip
->
regmap
=
devm_
regmap_init_i2c
(
client
,
&
pm860x_regmap_config
);
if
(
IS_ERR
(
chip
->
regmap
))
{
if
(
IS_ERR
(
chip
->
regmap
))
{
ret
=
PTR_ERR
(
chip
->
regmap
);
ret
=
PTR_ERR
(
chip
->
regmap
);
dev_err
(
&
client
->
dev
,
"Failed to allocate register map: %d
\n
"
,
dev_err
(
&
client
->
dev
,
"Failed to allocate register map: %d
\n
"
,
...
@@ -1203,7 +1203,6 @@ static int pm860x_remove(struct i2c_client *client)
...
@@ -1203,7 +1203,6 @@ static int pm860x_remove(struct i2c_client *client)
regmap_exit
(
chip
->
regmap_companion
);
regmap_exit
(
chip
->
regmap_companion
);
i2c_unregister_device
(
chip
->
companion
);
i2c_unregister_device
(
chip
->
companion
);
}
}
regmap_exit
(
chip
->
regmap
);
kfree
(
chip
);
kfree
(
chip
);
return
0
;
return
0
;
}
}
...
...
drivers/mfd/aat2870-core.c
浏览文件 @
c5fa44d1
...
@@ -312,8 +312,9 @@ static ssize_t aat2870_reg_write_file(struct file *file,
...
@@ -312,8 +312,9 @@ static ssize_t aat2870_reg_write_file(struct file *file,
while
(
*
start
==
' '
)
while
(
*
start
==
' '
)
start
++
;
start
++
;
if
(
strict_strtoul
(
start
,
16
,
&
val
))
ret
=
kstrtoul
(
start
,
16
,
&
val
);
return
-
EINVAL
;
if
(
ret
)
return
ret
;
ret
=
aat2870
->
write
(
aat2870
,
(
u8
)
addr
,
(
u8
)
val
);
ret
=
aat2870
->
write
(
aat2870
,
(
u8
)
addr
,
(
u8
)
val
);
if
(
ret
)
if
(
ret
)
...
...
drivers/mfd/ab3100-core.c
浏览文件 @
c5fa44d1
...
@@ -491,7 +491,7 @@ static ssize_t ab3100_get_set_reg(struct file *file,
...
@@ -491,7 +491,7 @@ static ssize_t ab3100_get_set_reg(struct file *file,
char
buf
[
32
];
char
buf
[
32
];
ssize_t
buf_size
;
ssize_t
buf_size
;
int
regp
;
int
regp
;
u
nsigned
long
user_reg
;
u
8
user_reg
;
int
err
;
int
err
;
int
i
=
0
;
int
i
=
0
;
...
@@ -514,34 +514,29 @@ static ssize_t ab3100_get_set_reg(struct file *file,
...
@@ -514,34 +514,29 @@ static ssize_t ab3100_get_set_reg(struct file *file,
/*
/*
* Advance pointer to end of string then terminate
* Advance pointer to end of string then terminate
* the register string. This is needed to satisfy
* the register string. This is needed to satisfy
* the
strict_strtoul
() function.
* the
kstrtou8
() function.
*/
*/
while
((
i
<
buf_size
)
&&
(
buf
[
i
]
!=
' '
))
while
((
i
<
buf_size
)
&&
(
buf
[
i
]
!=
' '
))
i
++
;
i
++
;
buf
[
i
]
=
'\0'
;
buf
[
i
]
=
'\0'
;
err
=
strict_strtoul
(
&
buf
[
regp
],
16
,
&
user_reg
);
err
=
kstrtou8
(
&
buf
[
regp
],
16
,
&
user_reg
);
if
(
err
)
if
(
err
)
return
err
;
return
err
;
if
(
user_reg
>
0xff
)
return
-
EINVAL
;
/* Either we read or we write a register here */
/* Either we read or we write a register here */
if
(
!
priv
->
mode
)
{
if
(
!
priv
->
mode
)
{
/* Reading */
/* Reading */
u8
reg
=
(
u8
)
user_reg
;
u8
regvalue
;
u8
regvalue
;
ab3100_get_register_interruptible
(
ab3100
,
reg
,
&
regvalue
);
ab3100_get_register_interruptible
(
ab3100
,
user_
reg
,
&
regvalue
);
dev_info
(
ab3100
->
dev
,
dev_info
(
ab3100
->
dev
,
"debug read AB3100 reg[0x%02x]: 0x%02x
\n
"
,
"debug read AB3100 reg[0x%02x]: 0x%02x
\n
"
,
reg
,
regvalue
);
user_
reg
,
regvalue
);
}
else
{
}
else
{
int
valp
;
int
valp
;
unsigned
long
user_value
;
u8
user_value
;
u8
reg
=
(
u8
)
user_reg
;
u8
value
;
u8
regvalue
;
u8
regvalue
;
/*
/*
...
@@ -557,20 +552,17 @@ static ssize_t ab3100_get_set_reg(struct file *file,
...
@@ -557,20 +552,17 @@ static ssize_t ab3100_get_set_reg(struct file *file,
i
++
;
i
++
;
buf
[
i
]
=
'\0'
;
buf
[
i
]
=
'\0'
;
err
=
strict_strtoul
(
&
buf
[
valp
],
16
,
&
user_value
);
err
=
kstrtou8
(
&
buf
[
valp
],
16
,
&
user_value
);
if
(
err
)
if
(
err
)
return
err
;
return
err
;
if
(
user_reg
>
0xff
)
return
-
EINVAL
;
value
=
(
u8
)
user_value
;
ab3100_set_register_interruptible
(
ab3100
,
user_reg
,
user_value
);
ab3100_set_register_interruptible
(
ab3100
,
reg
,
value
);
ab3100_get_register_interruptible
(
ab3100
,
user_reg
,
&
regvalue
);
ab3100_get_register_interruptible
(
ab3100
,
reg
,
&
regvalue
);
dev_info
(
ab3100
->
dev
,
dev_info
(
ab3100
->
dev
,
"debug write reg[0x%02x] with 0x%02x, "
"debug write reg[0x%02x] with 0x%02x, "
"after readback: 0x%02x
\n
"
,
"after readback: 0x%02x
\n
"
,
reg
,
value
,
regvalue
);
user_reg
,
user_
value
,
regvalue
);
}
}
return
buf_size
;
return
buf_size
;
}
}
...
...
drivers/mfd/ab8500-core.c
浏览文件 @
c5fa44d1
...
@@ -650,6 +650,21 @@ static struct resource ab8500_rtc_resources[] = {
...
@@ -650,6 +650,21 @@ static struct resource ab8500_rtc_resources[] = {
},
},
};
};
static
struct
resource
ab8540_rtc_resources
[]
=
{
{
.
name
=
"1S"
,
.
start
=
AB8540_INT_RTC_1S
,
.
end
=
AB8540_INT_RTC_1S
,
.
flags
=
IORESOURCE_IRQ
,
},
{
.
name
=
"ALARM"
,
.
start
=
AB8500_INT_RTC_ALARM
,
.
end
=
AB8500_INT_RTC_ALARM
,
.
flags
=
IORESOURCE_IRQ
,
},
};
static
struct
resource
ab8500_poweronkey_db_resources
[]
=
{
static
struct
resource
ab8500_poweronkey_db_resources
[]
=
{
{
{
.
name
=
"ONKEY_DBF"
,
.
name
=
"ONKEY_DBF"
,
...
@@ -1050,6 +1065,10 @@ static struct mfd_cell ab8500_devs[] = {
...
@@ -1050,6 +1065,10 @@ static struct mfd_cell ab8500_devs[] = {
.
name
=
"ab8500-sysctrl"
,
.
name
=
"ab8500-sysctrl"
,
.
of_compatible
=
"stericsson,ab8500-sysctrl"
,
.
of_compatible
=
"stericsson,ab8500-sysctrl"
,
},
},
{
.
name
=
"ab8500-ext-regulator"
,
.
of_compatible
=
"stericsson,ab8500-ext-regulator"
,
},
{
{
.
name
=
"ab8500-regulator"
,
.
name
=
"ab8500-regulator"
,
.
of_compatible
=
"stericsson,ab8500-regulator"
,
.
of_compatible
=
"stericsson,ab8500-regulator"
,
...
@@ -1098,10 +1117,6 @@ static struct mfd_cell ab8500_devs[] = {
...
@@ -1098,10 +1117,6 @@ static struct mfd_cell ab8500_devs[] = {
.
of_compatible
=
"stericsson,ab8500-pwm"
,
.
of_compatible
=
"stericsson,ab8500-pwm"
,
.
id
=
3
,
.
id
=
3
,
},
},
{
.
name
=
"ab8500-leds"
,
.
of_compatible
=
"stericsson,ab8500-leds"
,
},
{
{
.
name
=
"ab8500-denc"
,
.
name
=
"ab8500-denc"
,
.
of_compatible
=
"stericsson,ab8500-denc"
,
.
of_compatible
=
"stericsson,ab8500-denc"
,
...
@@ -1124,6 +1139,7 @@ static struct mfd_cell ab8500_devs[] = {
...
@@ -1124,6 +1139,7 @@ static struct mfd_cell ab8500_devs[] = {
},
},
{
{
.
name
=
"ab8500-codec"
,
.
name
=
"ab8500-codec"
,
.
of_compatible
=
"stericsson,ab8500-codec"
,
},
},
};
};
...
@@ -1138,6 +1154,9 @@ static struct mfd_cell ab9540_devs[] = {
...
@@ -1138,6 +1154,9 @@ static struct mfd_cell ab9540_devs[] = {
{
{
.
name
=
"ab8500-sysctrl"
,
.
name
=
"ab8500-sysctrl"
,
},
},
{
.
name
=
"ab8500-ext-regulator"
,
},
{
{
.
name
=
"ab8500-regulator"
,
.
name
=
"ab8500-regulator"
,
},
},
...
@@ -1170,9 +1189,6 @@ static struct mfd_cell ab9540_devs[] = {
...
@@ -1170,9 +1189,6 @@ static struct mfd_cell ab9540_devs[] = {
.
name
=
"ab8500-pwm"
,
.
name
=
"ab8500-pwm"
,
.
id
=
1
,
.
id
=
1
,
},
},
{
.
name
=
"ab8500-leds"
,
},
{
{
.
name
=
"abx500-temp"
,
.
name
=
"abx500-temp"
,
.
num_resources
=
ARRAY_SIZE
(
ab8500_temp_resources
),
.
num_resources
=
ARRAY_SIZE
(
ab8500_temp_resources
),
...
@@ -1241,9 +1257,6 @@ static struct mfd_cell ab8505_devs[] = {
...
@@ -1241,9 +1257,6 @@ static struct mfd_cell ab8505_devs[] = {
.
name
=
"ab8500-pwm"
,
.
name
=
"ab8500-pwm"
,
.
id
=
1
,
.
id
=
1
,
},
},
{
.
name
=
"ab8500-leds"
,
},
{
{
.
name
=
"pinctrl-ab8505"
,
.
name
=
"pinctrl-ab8505"
,
},
},
...
@@ -1273,6 +1286,9 @@ static struct mfd_cell ab8540_devs[] = {
...
@@ -1273,6 +1286,9 @@ static struct mfd_cell ab8540_devs[] = {
{
{
.
name
=
"ab8500-sysctrl"
,
.
name
=
"ab8500-sysctrl"
,
},
},
{
.
name
=
"ab8500-ext-regulator"
,
},
{
{
.
name
=
"ab8500-regulator"
,
.
name
=
"ab8500-regulator"
,
},
},
...
@@ -1286,11 +1302,6 @@ static struct mfd_cell ab8540_devs[] = {
...
@@ -1286,11 +1302,6 @@ static struct mfd_cell ab8540_devs[] = {
.
num_resources
=
ARRAY_SIZE
(
ab8505_gpadc_resources
),
.
num_resources
=
ARRAY_SIZE
(
ab8505_gpadc_resources
),
.
resources
=
ab8505_gpadc_resources
,
.
resources
=
ab8505_gpadc_resources
,
},
},
{
.
name
=
"ab8500-rtc"
,
.
num_resources
=
ARRAY_SIZE
(
ab8500_rtc_resources
),
.
resources
=
ab8500_rtc_resources
,
},
{
{
.
name
=
"ab8500-acc-det"
,
.
name
=
"ab8500-acc-det"
,
.
num_resources
=
ARRAY_SIZE
(
ab8500_av_acc_detect_resources
),
.
num_resources
=
ARRAY_SIZE
(
ab8500_av_acc_detect_resources
),
...
@@ -1305,9 +1316,6 @@ static struct mfd_cell ab8540_devs[] = {
...
@@ -1305,9 +1316,6 @@ static struct mfd_cell ab8540_devs[] = {
.
name
=
"ab8500-pwm"
,
.
name
=
"ab8500-pwm"
,
.
id
=
1
,
.
id
=
1
,
},
},
{
.
name
=
"ab8500-leds"
,
},
{
{
.
name
=
"abx500-temp"
,
.
name
=
"abx500-temp"
,
.
num_resources
=
ARRAY_SIZE
(
ab8500_temp_resources
),
.
num_resources
=
ARRAY_SIZE
(
ab8500_temp_resources
),
...
@@ -1331,6 +1339,24 @@ static struct mfd_cell ab8540_devs[] = {
...
@@ -1331,6 +1339,24 @@ static struct mfd_cell ab8540_devs[] = {
},
},
};
};
static
struct
mfd_cell
ab8540_cut1_devs
[]
=
{
{
.
name
=
"ab8500-rtc"
,
.
of_compatible
=
"stericsson,ab8500-rtc"
,
.
num_resources
=
ARRAY_SIZE
(
ab8500_rtc_resources
),
.
resources
=
ab8500_rtc_resources
,
},
};
static
struct
mfd_cell
ab8540_cut2_devs
[]
=
{
{
.
name
=
"ab8540-rtc"
,
.
of_compatible
=
"stericsson,ab8540-rtc"
,
.
num_resources
=
ARRAY_SIZE
(
ab8540_rtc_resources
),
.
resources
=
ab8540_rtc_resources
,
},
};
static
ssize_t
show_chip_id
(
struct
device
*
dev
,
static
ssize_t
show_chip_id
(
struct
device
*
dev
,
struct
device_attribute
*
attr
,
char
*
buf
)
struct
device_attribute
*
attr
,
char
*
buf
)
{
{
...
@@ -1734,11 +1760,22 @@ static int ab8500_probe(struct platform_device *pdev)
...
@@ -1734,11 +1760,22 @@ static int ab8500_probe(struct platform_device *pdev)
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab9540_devs
,
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab9540_devs
,
ARRAY_SIZE
(
ab9540_devs
),
NULL
,
ARRAY_SIZE
(
ab9540_devs
),
NULL
,
ab8500
->
irq_base
,
ab8500
->
domain
);
ab8500
->
irq_base
,
ab8500
->
domain
);
else
if
(
is_ab8540
(
ab8500
))
else
if
(
is_ab8540
(
ab8500
))
{
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab8540_devs
,
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab8540_devs
,
ARRAY_SIZE
(
ab8540_devs
),
NULL
,
ARRAY_SIZE
(
ab8540_devs
),
NULL
,
ab8500
->
irq_base
,
ab8500
->
domain
);
ab8500
->
irq_base
,
NULL
);
else
if
(
is_ab8505
(
ab8500
))
if
(
ret
)
return
ret
;
if
(
is_ab8540_1p2_or_earlier
(
ab8500
))
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab8540_cut1_devs
,
ARRAY_SIZE
(
ab8540_cut1_devs
),
NULL
,
ab8500
->
irq_base
,
NULL
);
else
/* ab8540 >= cut2 */
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab8540_cut2_devs
,
ARRAY_SIZE
(
ab8540_cut2_devs
),
NULL
,
ab8500
->
irq_base
,
NULL
);
}
else
if
(
is_ab8505
(
ab8500
))
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab8505_devs
,
ret
=
mfd_add_devices
(
ab8500
->
dev
,
0
,
ab8505_devs
,
ARRAY_SIZE
(
ab8505_devs
),
NULL
,
ARRAY_SIZE
(
ab8505_devs
),
NULL
,
ab8500
->
irq_base
,
ab8500
->
domain
);
ab8500
->
irq_base
,
ab8500
->
domain
);
...
...
drivers/mfd/ab8500-debugfs.c
浏览文件 @
c5fa44d1
...
@@ -2757,7 +2757,7 @@ static ssize_t show_irq(struct device *dev,
...
@@ -2757,7 +2757,7 @@ static ssize_t show_irq(struct device *dev,
unsigned
int
irq_index
;
unsigned
int
irq_index
;
int
err
;
int
err
;
err
=
strict_
strtoul
(
attr
->
attr
.
name
,
0
,
&
name
);
err
=
k
strtoul
(
attr
->
attr
.
name
,
0
,
&
name
);
if
(
err
)
if
(
err
)
return
err
;
return
err
;
...
...
drivers/mfd/dbx500-prcmu-regs.h
浏览文件 @
c5fa44d1
...
@@ -16,8 +16,8 @@
...
@@ -16,8 +16,8 @@
#define BITS(_start, _end) ((BIT(_end) - BIT(_start)) + BIT(_end))
#define BITS(_start, _end) ((BIT(_end) - BIT(_start)) + BIT(_end))
#define PRCM_ACLK_MGT (0x004)
#define PRCM_ACLK_MGT (0x004)
#define PRCM_SVA
CLK_MGT
(0x008)
#define PRCM_SVA
MMCSPCLK_MGT
(0x008)
#define PRCM_SIA
CLK_MGT
(0x00C)
#define PRCM_SIA
MMDSPCLK_MGT
(0x00C)
#define PRCM_SGACLK_MGT (0x014)
#define PRCM_SGACLK_MGT (0x014)
#define PRCM_UARTCLK_MGT (0x018)
#define PRCM_UARTCLK_MGT (0x018)
#define PRCM_MSP02CLK_MGT (0x01C)
#define PRCM_MSP02CLK_MGT (0x01C)
...
...
include/linux/mfd/abx500/ab8500.h
浏览文件 @
c5fa44d1
...
@@ -291,6 +291,8 @@ enum ab8500_version {
...
@@ -291,6 +291,8 @@ enum ab8500_version {
#define AB8540_INT_FSYNC2R 213
#define AB8540_INT_FSYNC2R 213
#define AB8540_INT_BITCLK2F 214
#define AB8540_INT_BITCLK2F 214
#define AB8540_INT_BITCLK2R 215
#define AB8540_INT_BITCLK2R 215
/* ab8540_irq_regoffset[27] -> IT[Source|Latch|Mask]33 */
#define AB8540_INT_RTC_1S 216
/*
/*
* AB8500_AB9540_NR_IRQS is used when configuring the IRQ numbers for the
* AB8500_AB9540_NR_IRQS is used when configuring the IRQ numbers for the
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录