Skip to content

Commit

Permalink
uwb: fix uwb_dev_unlock() missed at an error path in uwb_rc_cmd_async()
Browse files Browse the repository at this point in the history
There is the only path in uwb_rc_cmd_async() where rc->uwb_dev is left unlocked.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Alexey Khoroshilov authored and Greg Kroah-Hartman committed Nov 26, 2012
1 parent d7e14b3 commit ffa5c41
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/uwb/reset.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ int uwb_rc_cmd_async(struct uwb_rc *rc, const char *cmd_name,
neh = uwb_rc_neh_add(rc, cmd, expected_type, expected_event, cb, arg);
if (IS_ERR(neh)) {
result = PTR_ERR(neh);
uwb_dev_unlock(&rc->uwb_dev);
goto out;
}

Expand Down

0 comments on commit ffa5c41

Please sign in to comment.