From: Azael Avalos Date: Wed, 7 Sep 2016 15:28:15 +0000 (-0600) Subject: platform/x86: toshiba_bluetooth: Decouple an error checking status code X-Git-Tag: v4.14-rc1~2227^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=28e476d7438eedd3ecc7b5ebe6f2a3dfd21ca10e;p=platform%2Fkernel%2Flinux-rpi.git platform/x86: toshiba_bluetooth: Decouple an error checking status code This patch simply decouples the error checking of the ACPI status and the actual BT status, as those two were nested in an if/else check, but are completely unrelated. Signed-off-by: Azael Avalos Signed-off-by: Darren Hart --- diff --git a/drivers/platform/x86/toshiba_bluetooth.c b/drivers/platform/x86/toshiba_bluetooth.c index 5db495dd..be1d137 100644 --- a/drivers/platform/x86/toshiba_bluetooth.c +++ b/drivers/platform/x86/toshiba_bluetooth.c @@ -80,7 +80,9 @@ static int toshiba_bluetooth_present(acpi_handle handle) if (ACPI_FAILURE(result)) { pr_err("ACPI call to query Bluetooth presence failed\n"); return -ENXIO; - } else if (!bt_present) { + } + + if (!bt_present) { pr_info("Bluetooth device not present\n"); return -ENODEV; }