mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: <mark-yw.chen@mediatek.com>
To: <marcel@holtmann.org>, <johan.hedberg@gmail.com>
Cc: <sean.wang@mediatek.com>, <mark-yw.chen@mediatek.com>,
	<aaron.hou@mediatek.com>, <kaichuan.hsieh@canonical.com>,
	<pmenzel@molgen.mpg.de>, <linux-bluetooth@vger.kernel.org>,
	<linux-mediatek@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>
Subject: [PATCH v3 2/2] Bluetooth: btusb: Return error code when getting patch status failed
Date: Tue, 7 Dec 2021 01:33:43 +0800	[thread overview]
Message-ID: <20211206173343.31380-2-mark-yw.chen@mediatek.com> (raw)
In-Reply-To: <20211206173343.31380-1-mark-yw.chen@mediatek.com>

From: Mark Chen <mark-yw.chen@mediatek.com>

If there are failure cases in getting patch status, it should return the
error code (-EIO).

Fixes: fc342c4dc4087 ("Bluetooth: btusb: Add protocol support for MediaTek MT7921U USB devices")
Co-developed-by: Sean Wang <sean.wang@mediatek.com>
Signed-off-by: Sean Wang <sean.wang@mediatek.com>
Signed-off-by: Mark Chen <mark-yw.chen@mediatek.com>
---
 drivers/bluetooth/btmtk.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/bluetooth/btmtk.c b/drivers/bluetooth/btmtk.c
index c2ee5c4b975a..526dfdf1fe01 100644
--- a/drivers/bluetooth/btmtk.c
+++ b/drivers/bluetooth/btmtk.c
@@ -121,6 +121,7 @@ int btmtk_setup_firmware_79xx(struct hci_dev *hdev, const char *fwname,
 				} else {
 					bt_dev_err(hdev, "Failed wmt patch dwnld status (%d)",
 						   status);
+					err = -EIO;
 					goto err_release_fw;
 				}
 			}
-- 
2.18.0


  reply	other threads:[~2021-12-06 17:34 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-06 17:33 [PATCH v3 1/2] Bluetooth: btusb: Handle download_firmware failure cases mark-yw.chen
2021-12-06 17:33 ` mark-yw.chen [this message]
2021-12-06 19:40   ` [PATCH v3 2/2] Bluetooth: btusb: Return error code when getting patch status failed Marcel Holtmann
2021-12-06 19:40 ` [PATCH v3 1/2] Bluetooth: btusb: Handle download_firmware failure cases Marcel Holtmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211206173343.31380-2-mark-yw.chen@mediatek.com \
    --to=mark-yw.chen@mediatek.com \
    --cc=aaron.hou@mediatek.com \
    --cc=johan.hedberg@gmail.com \
    --cc=kaichuan.hsieh@canonical.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=marcel@holtmann.org \
    --cc=pmenzel@molgen.mpg.de \
    --cc=sean.wang@mediatek.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®