From: Kulikov Vasiliy Date: Mon, 5 Jul 2010 08:01:22 +0000 (+0400) Subject: Bluetooth: Silence warning in btmrvl SDIO driver X-Git-Tag: v2.6.36-rc1~571^2~64^2~48^2~53 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=278be27fc401119c985235ee549dc229d85e6bf5;p=profile%2Fivi%2Fkernel-x86-ivi.git Bluetooth: Silence warning in btmrvl SDIO driver Clone checking of ret to simplify the code. This patch silences a compiler warning: drivers/bluetooth/btmrvl_sdio.c: In function ‘btmrvl_sdio_verify_fw_download’: drivers/bluetooth/btmrvl_sdio.c:80: warning: ‘fws1’ may be used uninitialized in this function drivers/bluetooth/btmrvl_sdio.c:80: note: ‘fws1’ was declared here Signed-off-by: Kulikov Vasiliy Reviewed-by: Dan Carpenter Signed-off-by: Marcel Holtmann --- diff --git a/drivers/bluetooth/btmrvl_sdio.c b/drivers/bluetooth/btmrvl_sdio.c index df0773e..47f0f91 100644 --- a/drivers/bluetooth/btmrvl_sdio.c +++ b/drivers/bluetooth/btmrvl_sdio.c @@ -83,10 +83,10 @@ static int btmrvl_sdio_read_fw_status(struct btmrvl_sdio_card *card, u16 *dat) *dat = 0; fws0 = sdio_readb(card->func, CARD_FW_STATUS0_REG, &ret); + if (ret) + return -EIO; - if (!ret) - fws1 = sdio_readb(card->func, CARD_FW_STATUS1_REG, &ret); - + fws1 = sdio_readb(card->func, CARD_FW_STATUS1_REG, &ret); if (ret) return -EIO;