media: ttusb-dec: cleanup an error handling logic
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 10 Jun 2021 14:00:53 +0000 (16:00 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 17 Jun 2021 07:27:34 +0000 (09:27 +0200)
commitdba328bab4c6fa4ec1ed3be616f7196865f2ce41
tree4f65040c829410088c4cf7aa1755acb77876c4df
parent5368b1ee2939961a16e74972b69088433fc52195
media: ttusb-dec: cleanup an error handling logic

Simplify the logic at ttusb_dec_send_command().

Besides avoiding some code duplication, as a side effect,
this could remove this false positive return with spatch:

drivers/media/usb/ttusb-dec/ttusb_dec.c:380 ttusb_dec_send_command() warn: inconsistent returns '&dec->usb_mutex'.
  Locked on  : 330
  Unlocked on: 354,365,380

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/usb/ttusb-dec/ttusb_dec.c