]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
slow-work: use get_ref wrapper instead of directly calling get_ref
authorDave Airlie <airlied@redhat.com>
Mon, 29 Mar 2010 11:01:50 +0000 (12:01 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 10 Aug 2010 17:20:45 +0000 (10:20 -0700)
commit 88be12c440cfa2fa3f5be83507360aac9ea1c54e upstream.

Otherwise we can get an oops if the user has no get_ref/put_ref
requirement.

Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Kurt Garloff <garloff@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
kernel/slow-work.c

index 00889bd3c5903812ed89d722135b15330b513dbb..3514c4449604bda6333ff158d52652a6086c7025 100644 (file)
@@ -640,7 +640,7 @@ int delayed_slow_work_enqueue(struct delayed_slow_work *dwork,
                        goto cancelled;
 
                /* the timer holds a reference whilst it is pending */
-               ret = work->ops->get_ref(work);
+               ret = slow_work_get_ref(work);
                if (ret < 0)
                        goto cant_get_ref;