diff options
author | Josh Triplett <josh@freedesktop.org> | 2007-01-25 04:32:34 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-02-16 18:32:17 -0500 |
commit | c5999f0da73b7f46435a67671c8861ed14a94c4e (patch) | |
tree | 467381c8c4e94ec2c5f73b0378cc8ce07943b92c /drivers/usb | |
parent | df23fa01acc77444453633e1dec59cd7a4ea8ec3 (diff) |
USB: In init_endpoint_class, use PTR_ERR to obtain an errno value, not IS_ERR
init_endpoint_class calls class_create, and checks the result for an error
with IS_ERR; however, if true, it then returns the result of IS_ERR (a
boolean) rather than PTR_ERR (the actual errno).
Signed-off-by: Josh Triplett <josh@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/core/endpoint.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/core/endpoint.c b/drivers/usb/core/endpoint.c index 5e628ae3aec7..e0ec7045e865 100644 --- a/drivers/usb/core/endpoint.c +++ b/drivers/usb/core/endpoint.c | |||
@@ -229,7 +229,7 @@ static int init_endpoint_class(void) | |||
229 | kref_init(&ep_class->kref); | 229 | kref_init(&ep_class->kref); |
230 | ep_class->class = class_create(THIS_MODULE, "usb_endpoint"); | 230 | ep_class->class = class_create(THIS_MODULE, "usb_endpoint"); |
231 | if (IS_ERR(ep_class->class)) { | 231 | if (IS_ERR(ep_class->class)) { |
232 | result = IS_ERR(ep_class->class); | 232 | result = PTR_ERR(ep_class->class); |
233 | goto class_create_error; | 233 | goto class_create_error; |
234 | } | 234 | } |
235 | 235 | ||