Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
9ae0eb45
K
Kernel
项目概览
openeuler
/
Kernel
1 年多 前同步成功
通知
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看板
提交
9ae0eb45
编写于
8月 13, 2020
作者:
F
Felipe Balbi
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
usb: dwc3: debugfs: fix checkpatch warnings
no functional changes Signed-off-by:
N
Felipe Balbi
<
balbi@kernel.org
>
上级
993ffc5b
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
26 addition
and
30 deletion
+26
-30
drivers/usb/dwc3/debugfs.c
drivers/usb/dwc3/debugfs.c
+26
-30
未找到文件。
drivers/usb/dwc3/debugfs.c
浏览文件 @
9ae0eb45
...
...
@@ -397,13 +397,13 @@ static int dwc3_mode_show(struct seq_file *s, void *unused)
switch
(
DWC3_GCTL_PRTCAP
(
reg
))
{
case
DWC3_GCTL_PRTCAP_HOST
:
seq_p
rintf
(
s
,
"host
\n
"
);
seq_p
uts
(
s
,
"host
\n
"
);
break
;
case
DWC3_GCTL_PRTCAP_DEVICE
:
seq_p
rintf
(
s
,
"device
\n
"
);
seq_p
uts
(
s
,
"device
\n
"
);
break
;
case
DWC3_GCTL_PRTCAP_OTG
:
seq_p
rintf
(
s
,
"otg
\n
"
);
seq_p
uts
(
s
,
"otg
\n
"
);
break
;
default:
seq_printf
(
s
,
"UNKNOWN %08x
\n
"
,
DWC3_GCTL_PRTCAP
(
reg
));
...
...
@@ -464,22 +464,22 @@ static int dwc3_testmode_show(struct seq_file *s, void *unused)
switch
(
reg
)
{
case
0
:
seq_p
rintf
(
s
,
"no test
\n
"
);
seq_p
uts
(
s
,
"no test
\n
"
);
break
;
case
USB_TEST_J
:
seq_p
rintf
(
s
,
"test_j
\n
"
);
seq_p
uts
(
s
,
"test_j
\n
"
);
break
;
case
USB_TEST_K
:
seq_p
rintf
(
s
,
"test_k
\n
"
);
seq_p
uts
(
s
,
"test_k
\n
"
);
break
;
case
USB_TEST_SE0_NAK
:
seq_p
rintf
(
s
,
"test_se0_nak
\n
"
);
seq_p
uts
(
s
,
"test_se0_nak
\n
"
);
break
;
case
USB_TEST_PACKET
:
seq_p
rintf
(
s
,
"test_packet
\n
"
);
seq_p
uts
(
s
,
"test_packet
\n
"
);
break
;
case
USB_TEST_FORCE_ENABLE
:
seq_p
rintf
(
s
,
"test_force_enable
\n
"
);
seq_p
uts
(
s
,
"test_force_enable
\n
"
);
break
;
default:
seq_printf
(
s
,
"UNKNOWN %d
\n
"
,
reg
);
...
...
@@ -760,27 +760,26 @@ static int dwc3_transfer_type_show(struct seq_file *s, void *unused)
unsigned
long
flags
;
spin_lock_irqsave
(
&
dwc
->
lock
,
flags
);
if
(
!
(
dep
->
flags
&
DWC3_EP_ENABLED
)
||
!
dep
->
endpoint
.
desc
)
{
seq_printf
(
s
,
"--
\n
"
);
if
(
!
(
dep
->
flags
&
DWC3_EP_ENABLED
)
||
!
dep
->
endpoint
.
desc
)
{
seq_puts
(
s
,
"--
\n
"
);
goto
out
;
}
switch
(
usb_endpoint_type
(
dep
->
endpoint
.
desc
))
{
case
USB_ENDPOINT_XFER_CONTROL
:
seq_p
rintf
(
s
,
"control
\n
"
);
seq_p
uts
(
s
,
"control
\n
"
);
break
;
case
USB_ENDPOINT_XFER_ISOC
:
seq_p
rintf
(
s
,
"isochronous
\n
"
);
seq_p
uts
(
s
,
"isochronous
\n
"
);
break
;
case
USB_ENDPOINT_XFER_BULK
:
seq_p
rintf
(
s
,
"bulk
\n
"
);
seq_p
uts
(
s
,
"bulk
\n
"
);
break
;
case
USB_ENDPOINT_XFER_INT
:
seq_p
rintf
(
s
,
"interrupt
\n
"
);
seq_p
uts
(
s
,
"interrupt
\n
"
);
break
;
default:
seq_p
rintf
(
s
,
"--
\n
"
);
seq_p
uts
(
s
,
"--
\n
"
);
}
out:
...
...
@@ -798,11 +797,11 @@ static int dwc3_trb_ring_show(struct seq_file *s, void *unused)
spin_lock_irqsave
(
&
dwc
->
lock
,
flags
);
if
(
dep
->
number
<=
1
)
{
seq_p
rintf
(
s
,
"--
\n
"
);
seq_p
uts
(
s
,
"--
\n
"
);
goto
out
;
}
seq_p
rintf
(
s
,
"buffer_addr,size,type,ioc,isp_imi,csp,chn,lst,hwo
\n
"
);
seq_p
uts
(
s
,
"buffer_addr,size,type,ioc,isp_imi,csp,chn,lst,hwo
\n
"
);
for
(
i
=
0
;
i
<
DWC3_TRB_NUM
;
i
++
)
{
struct
dwc3_trb
*
trb
=
&
dep
->
trb_pool
[
i
];
...
...
@@ -884,7 +883,7 @@ static void dwc3_debugfs_create_endpoint_files(struct dwc3_ep *dep,
const
struct
file_operations
*
fops
=
dwc3_ep_file_map
[
i
].
fops
;
const
char
*
name
=
dwc3_ep_file_map
[
i
].
name
;
debugfs_create_file
(
name
,
S_IRUGO
,
parent
,
dep
,
fops
);
debugfs_create_file
(
name
,
0444
,
parent
,
dep
,
fops
);
}
}
...
...
@@ -929,21 +928,18 @@ void dwc3_debugfs_init(struct dwc3 *dwc)
root
=
debugfs_create_dir
(
dev_name
(
dwc
->
dev
),
usb_debug_root
);
dwc
->
root
=
root
;
debugfs_create_regset32
(
"regdump"
,
S_IRUGO
,
root
,
dwc
->
regset
);
debugfs_create_regset32
(
"regdump"
,
0444
,
root
,
dwc
->
regset
);
debugfs_create_file
(
"lsp_dump"
,
0644
,
root
,
dwc
,
&
dwc3_lsp_fops
);
debugfs_create_file
(
"lsp_dump"
,
S_IRUGO
|
S_IWUSR
,
root
,
dwc
,
&
dwc3_lsp_fops
);
if
(
IS_ENABLED
(
CONFIG_USB_DWC3_DUAL_ROLE
))
{
debugfs_create_file
(
"mode"
,
S_IRUGO
|
S_IWUSR
,
root
,
dwc
,
if
(
IS_ENABLED
(
CONFIG_USB_DWC3_DUAL_ROLE
))
debugfs_create_file
(
"mode"
,
0644
,
root
,
dwc
,
&
dwc3_mode_fops
);
}
if
(
IS_ENABLED
(
CONFIG_USB_DWC3_DUAL_ROLE
)
||
IS_ENABLED
(
CONFIG_USB_DWC3_GADGET
))
{
debugfs_create_file
(
"testmode"
,
S_IRUGO
|
S_IWUSR
,
root
,
dwc
,
&
dwc3_testmode_fops
);
debugfs_create_file
(
"link_state"
,
S_IRUGO
|
S_IWUSR
,
root
,
dwc
,
debugfs_create_file
(
"testmode"
,
0644
,
root
,
dwc
,
&
dwc3_testmode_fops
);
debugfs_create_file
(
"link_state"
,
0644
,
root
,
dwc
,
&
dwc3_link_state_fops
);
dwc3_debugfs_create_endpoint_dirs
(
dwc
,
root
);
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录