Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp6388604ybe; Wed, 18 Sep 2019 02:38:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqxj5zccTAwAc92KisLHkjWomLNhwRnjJmTDHUNSierbNPPBzc6n4peQ6xQwu9BjLh7uHV2z X-Received: by 2002:a05:6402:32f:: with SMTP id q15mr6868136edw.143.1568799539328; Wed, 18 Sep 2019 02:38:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568799539; cv=none; d=google.com; s=arc-20160816; b=J4t1D4tbo5wvV9omZ8bebKoPZRmnYDV0bQXW1PJb4eWKtIPF9k30O+DfmVj8atV5uW cZX4YjzyeHHpm+okYCIYY7tmDR8+JPFGCN8OrLAdzANeAuS7qmXzEOHQbWbjeNK2mE/X cpmmRGljVWNRehnwTwc7et4+d8qh9vTH+PpTikd5Xf5nOk8xBg0XQwe/kERHwRPWHHo1 UNpVbxFmsLNPbNOZE90VoVhnFQvOtUgFX9eZbYyDPyg/qFUIX4ph+qxLN9cSSIyT4mBL a7efEx8tGXrQkxMdaJuf+8dPk9cI+Dw395wXOhoM4WG73C6DcdZuHEEUyIseriSEyT+/ M2vQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from:authenticated-by; bh=Ge9JeZzvWBLlVHw5kdd6AvZgvuW9J+CAqkpLaFUVpak=; b=Vl5zHHd/a5Hpv12z06VvbkpwYxI3+YIA565fg7HVkiA5goubPHDHAVruTQyxLmYtep FOF8fXpvkMwcr0v55Pgwk07suEZ52UVDofuxmNgDNtrtbVaCfhAqFZGbNYanZLIf4qu2 y6tLfGUaypYOAlxzlFo5M+0Xem6I5iu8unNk0IGgKF5ozrcNLVudehhS481xej0RwCsI SKHGVOG4St25yPD7q7b706GzRCpoOlbgZ011s9GY4zPbzXIBHWOVvHHlZzj45UFwix1m qO2OYiiHrdItPJJE8lRdu5MJNApleOoy/0P9MN7B1EJsGLReTRFV7R5cmDwGY/wLRbyQ 5hJg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n16si2507506ejh.165.2019.09.18.02.38.35; Wed, 18 Sep 2019 02:38:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726257AbfIRI47 (ORCPT + 99 others); Wed, 18 Sep 2019 04:56:59 -0400 Received: from rtits2.realtek.com ([211.75.126.72]:52084 "EHLO rtits2.realtek.com.tw" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725909AbfIRI47 (ORCPT ); Wed, 18 Sep 2019 04:56:59 -0400 Authenticated-By: X-SpamFilter-By: BOX Solutions SpamTrap 5.62 with qID x8I8ukxU018315, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (RTITCASV01.realtek.com.tw[172.21.6.18]) by rtits2.realtek.com.tw (8.15.2/2.57/5.78) with ESMTPS id x8I8ukxU018315 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 18 Sep 2019 16:56:47 +0800 Received: from localhost.localdomain (172.21.83.238) by RTITCASV01.realtek.com.tw (172.21.6.18) with Microsoft SMTP Server id 14.3.468.0; Wed, 18 Sep 2019 16:56:46 +0800 From: To: , , , CC: , Subject: [PATCH] Bluetooth: btrtl: Fix an issue for the incorrect error return code. Date: Wed, 18 Sep 2019 16:56:41 +0800 Message-ID: <20190918085641.5374-1-max.chou@realtek.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [172.21.83.238] Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org From: Max Chou It does not need the '-' for PTR_ERR(skb) because PTR_ERR(skb) will return the negative value during errors. Signed-off-by: Max Chou --- drivers/bluetooth/btrtl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/bluetooth/btrtl.c b/drivers/bluetooth/btrtl.c index bf3c02be6930..ae9a2047f242 100644 --- a/drivers/bluetooth/btrtl.c +++ b/drivers/bluetooth/btrtl.c @@ -418,7 +418,7 @@ static int rtl_download_firmware(struct hci_dev *hdev, if (IS_ERR(skb)) { rtl_dev_err(hdev, "download fw command failed (%ld)", PTR_ERR(skb)); - ret = -PTR_ERR(skb); + ret = PTR_ERR(skb); goto out; } -- 2.17.1