浏览代码

Bluetooth: ath3k: Silence uninitialized variable warning

We could print an uninitialized value in the error message.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Dan Carpenter 9 年之前
父节点
当前提交
e9fc71649b
共有 1 个文件被更改,包括 4 次插入2 次删除
  1. 4 2
      drivers/bluetooth/ath3k.c

+ 4 - 2
drivers/bluetooth/ath3k.c

@@ -206,7 +206,8 @@ static int ath3k_load_firmware(struct usb_device *udev,
 				const struct firmware *firmware)
 				const struct firmware *firmware)
 {
 {
 	u8 *send_buf;
 	u8 *send_buf;
-	int err, pipe, len, size, sent = 0;
+	int len = 0;
+	int err, pipe, size, sent = 0;
 	int count = firmware->size;
 	int count = firmware->size;
 
 
 	BT_DBG("udev %p", udev);
 	BT_DBG("udev %p", udev);
@@ -302,7 +303,8 @@ static int ath3k_load_fwfile(struct usb_device *udev,
 		const struct firmware *firmware)
 		const struct firmware *firmware)
 {
 {
 	u8 *send_buf;
 	u8 *send_buf;
-	int err, pipe, len, size, count, sent = 0;
+	int len = 0;
+	int err, pipe, size, count, sent = 0;
 	int ret;
 	int ret;
 
 
 	count = firmware->size;
 	count = firmware->size;