diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2013-08-15 03:55:10 -0400 |
---|---|---|
committer | MyungJoo Ham <myungjoo.ham@samsung.com> | 2013-10-28 07:18:30 -0400 |
commit | ea7f4548c93aacbac5fe3e1b4eb273d3df5f16e3 (patch) | |
tree | fcbcd88bf24dd310bf55543c3bd3814bf3867664 /drivers/devfreq/devfreq.c | |
parent | 9671dc7935722a911262cade5c594315540628f2 (diff) |
PM / devfreq: create_freezable_workqueue() doesn't return an ERR_PTR
The create_freezable_workqueue() function returns a NULL on error and
not an ERR_PTR.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Diffstat (limited to 'drivers/devfreq/devfreq.c')
-rw-r--r-- | drivers/devfreq/devfreq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c index c99c00d35d34..22e5d2ffebd8 100644 --- a/drivers/devfreq/devfreq.c +++ b/drivers/devfreq/devfreq.c | |||
@@ -993,10 +993,10 @@ static int __init devfreq_init(void) | |||
993 | } | 993 | } |
994 | 994 | ||
995 | devfreq_wq = create_freezable_workqueue("devfreq_wq"); | 995 | devfreq_wq = create_freezable_workqueue("devfreq_wq"); |
996 | if (IS_ERR(devfreq_wq)) { | 996 | if (!devfreq_wq) { |
997 | class_destroy(devfreq_class); | 997 | class_destroy(devfreq_class); |
998 | pr_err("%s: couldn't create workqueue\n", __FILE__); | 998 | pr_err("%s: couldn't create workqueue\n", __FILE__); |
999 | return PTR_ERR(devfreq_wq); | 999 | return -ENOMEM; |
1000 | } | 1000 | } |
1001 | devfreq_class->dev_groups = devfreq_groups; | 1001 | devfreq_class->dev_groups = devfreq_groups; |
1002 | 1002 | ||