Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
e56236b0
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看板
提交
e56236b0
编写于
1月 31, 2018
作者:
J
Jiri Kosina
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'for-4.16/i2c-hid' into for-linus
上级
740c84ee
847989e5
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
14 addition
and
6 deletion
+14
-6
Documentation/devicetree/bindings/input/hid-over-i2c.txt
Documentation/devicetree/bindings/input/hid-over-i2c.txt
+1
-1
drivers/hid/i2c-hid/i2c-hid.c
drivers/hid/i2c-hid/i2c-hid.c
+13
-5
未找到文件。
Documentation/devicetree/bindings/input/hid-over-i2c.txt
浏览文件 @
e56236b0
...
...
@@ -31,7 +31,7 @@ device-specific compatible properties, which should be used in addition to the
- vdd-supply: phandle of the regulator that provides the supply voltage.
- post-power-on-delay-ms: time required by the device after enabling its regulators
before it is ready for communication. Must be used with 'vdd-supply'
.
or powering it on, before it is ready for communication
.
Example:
...
...
drivers/hid/i2c-hid/i2c-hid.c
浏览文件 @
e56236b0
...
...
@@ -934,11 +934,6 @@ static int i2c_hid_of_probe(struct i2c_client *client,
}
pdata
->
hid_descriptor_address
=
val
;
ret
=
of_property_read_u32
(
dev
->
of_node
,
"post-power-on-delay-ms"
,
&
val
);
if
(
!
ret
)
pdata
->
post_power_delay_ms
=
val
;
return
0
;
}
...
...
@@ -955,6 +950,16 @@ static inline int i2c_hid_of_probe(struct i2c_client *client,
}
#endif
static
void
i2c_hid_fwnode_probe
(
struct
i2c_client
*
client
,
struct
i2c_hid_platform_data
*
pdata
)
{
u32
val
;
if
(
!
device_property_read_u32
(
&
client
->
dev
,
"post-power-on-delay-ms"
,
&
val
))
pdata
->
post_power_delay_ms
=
val
;
}
static
int
i2c_hid_probe
(
struct
i2c_client
*
client
,
const
struct
i2c_device_id
*
dev_id
)
{
...
...
@@ -998,6 +1003,9 @@ static int i2c_hid_probe(struct i2c_client *client,
ihid
->
pdata
=
*
platform_data
;
}
/* Parse platform agnostic common properties from ACPI / device tree */
i2c_hid_fwnode_probe
(
client
,
&
ihid
->
pdata
);
ihid
->
pdata
.
supply
=
devm_regulator_get
(
&
client
->
dev
,
"vdd"
);
if
(
IS_ERR
(
ihid
->
pdata
.
supply
))
{
ret
=
PTR_ERR
(
ihid
->
pdata
.
supply
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录