projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
78c7341
)
USB: Fix debugfs_create_file's error checking method for usb/gadget/s3c2410_udc
author
Zhaolei
<
[email protected]
>
Mon, 20 Oct 2008 10:53:04 +0000
(18:53 +0800)
committer
Greg Kroah-Hartman
<
[email protected]
>
Wed, 22 Oct 2008 17:05:27 +0000
(10:05 -0700)
debugfs_create_file() returns NULL if an error occurs, returns -ENODEV
when debugfs is not enabled in the kernel.
Signed-off-by: Zhao Lei <
[email protected]
>
Signed-off-by: Greg Kroah-Hartman <
[email protected]
>
drivers/usb/gadget/s3c2410_udc.c
patch
|
blob
|
history
diff --git
a/drivers/usb/gadget/s3c2410_udc.c
b/drivers/usb/gadget/s3c2410_udc.c
index 48f51b12d2e21010140448a23b554cc5ee31a145..00ba06b4475204012498cfdd5028ce03556be948 100644
(file)
--- a/
drivers/usb/gadget/s3c2410_udc.c
+++ b/
drivers/usb/gadget/s3c2410_udc.c
@@
-1894,11
+1894,8
@@
static int s3c2410_udc_probe(struct platform_device *pdev)
udc->regs_info = debugfs_create_file("registers", S_IRUGO,
s3c2410_udc_debugfs_root,
udc, &s3c2410_udc_debugfs_fops);
- if (IS_ERR(udc->regs_info)) {
- dev_warn(dev, "debugfs file creation failed %ld\n",
- PTR_ERR(udc->regs_info));
- udc->regs_info = NULL;
- }
+ if (!udc->regs_info)
+ dev_warn(dev, "debugfs file creation failed\n");
}
dev_dbg(dev, "probe ok\n");