]> git.karo-electronics.de Git - karo-tx-linux.git/commit
target: Clean up returning errors in PR handling code
authorRoland Dreier <roland@purestorage.com>
Mon, 16 Jul 2012 22:17:10 +0000 (15:17 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 29 Jul 2012 15:04:18 +0000 (08:04 -0700)
commit815faab2c4b7deb2cc6495186307ceb0983214a9
tree0321d6a2654e7621f59a1cf4016e612905519599
parentc82cd13737cfab6cb9d1b31e624896e627f9c9e4
target: Clean up returning errors in PR handling code

commit d35212f3ca3bf4fb49d15e37f530c9931e2d2183 upstream.

 - instead of (PTR_ERR(file) < 0) just use IS_ERR(file)
 - return -EINVAL instead of EINVAL
 - all other error returns in target_scsi3_emulate_pr_out() use
   "goto out" -- get rid of the one remaining straight "return."

Signed-off-by: Roland Dreier <roland@purestorage.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/target/target_core_pr.c