Received: by 2002:a05:6a10:8395:0:0:0:0 with SMTP id n21csp608078pxh; Tue, 9 Nov 2021 16:06:38 -0800 (PST) X-Google-Smtp-Source: ABdhPJzyBq+JYPKdIPXsB7lcCGFdOzlO7DNdgjYb1FIFe44VJX5HMLRLO1JebtlVhYGTZomeKfPn X-Received: by 2002:a17:906:b2d0:: with SMTP id cf16mr14878904ejb.52.1636502798697; Tue, 09 Nov 2021 16:06:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1636502798; cv=none; d=google.com; s=arc-20160816; b=ObzteQ9HzHcmcPALCux8giKoJlg1A1CsA2oi6F5snDpohXX4poLx3qyq5VCDa/U5tk gcTewprj8GmP6ZuOt5y9VaXGhRSj66MXPSlScFMIu+s20BoVH/EyFYYXeM2ke2Sneadm MOpXuJuWnkUIl7z55foSozZt8snqWRki6+FwcLGplUJZ9nfTFFUinGfXbJEFZPpekTFS uXMitTdzdLtoojDo70C5BZE8S3Y92D9W73U06jJLZ7b7tPLEp7VHq97d08lQCK9/3X2K VDj/ZAcVNMKeu+hIzE5mGddBFFgLQUmRGd0fgoQJ3eAzMJPSBL+6Ipyq/BSlAhMXrA9P ehqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=r+PBFOa68zz/WZyxgEbpEZiQ9ozgU21z6q9dCnIR5GA=; b=ytUKVGkKOh92u2cQ8yorDQzvqsE+S4UZFLvb3npUHDE6mIxd9v3ylHFNNm9l/OVdwS QYs/c8jm69MUpD8WEa/YAVxNRKj3HawO53w5oJgo+sMhi2qrmmPFIJwD641ijkwdH694 j1G9NE521eZNSBKc452pfMXNJHpiXx1oMOh8cgLVbDDdUbzCStfYlEwEC2mZKgafKX5U J1iK1CFEz/7ZzqM71kE7gKJ1M5y637U7Pv7chN6cOIFHtOD2a4f3MmZ7jwdUIoP/GyZq uATFukF//7UOZDN2BI08RlbWxL/NdJOTLNCugn3exfimPPo5x/vWSmBaeVcfB9surCK4 nNfw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=PZkQflSJ; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id nd27si51326987ejc.554.2021.11.09.16.06.13; Tue, 09 Nov 2021 16:06:38 -0800 (PST) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=PZkQflSJ; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238541AbhKIQoY (ORCPT + 99 others); Tue, 9 Nov 2021 11:44:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59132 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238261AbhKIQoX (ORCPT ); Tue, 9 Nov 2021 11:44:23 -0500 Received: from sipsolutions.net (unknown [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A9633C061767 for ; Tue, 9 Nov 2021 08:41:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sipsolutions.net; s=mail; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Content-Type:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-To: Resent-Cc:Resent-Message-ID; bh=r+PBFOa68zz/WZyxgEbpEZiQ9ozgU21z6q9dCnIR5GA=; t=1636476097; x=1637685697; b=PZkQflSJYQlZe4BGNZ1zoGi91mzfvvZROFnAhmT9Q4/kjWd VIamlgndTo22C2vG6pbDOEOJET/hvJANf8wMNdn3Wknpa5nDAeLHGrrW0CtjbQE+VuRpzPJQq1trr dMuggc7MLtEiS7Wn/jGE7A2bKO0jPw/nnnnr5obFP5BwbR5vrMnqSu5wk4aW1ZPQU4IiLrz93mis+ CGgB6fY+y3Tyg7/zIFMjcW5lJ5rgc/JP5Is3FG8eVbZ7bfhS7/GTvJWe1kq9sqT3rFql+p47WW+KE zK3dGp7d2x2c1Ga61Q7q8gmIjIgeOq+msU0dcbREV8c3Wb1Jt3+xWyR6qpoc13HA==; Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.95) (envelope-from ) id 1mkUBh-00D1dY-RV; Tue, 09 Nov 2021 17:41:34 +0100 From: Benjamin Berg To: linux-bluetooth@vger.kernel.org Cc: Benjamin Berg Subject: [PATCH 3/4] Bluetooth: hci_core: Signal TX failure if sending a frame failed Date: Tue, 9 Nov 2021 17:41:12 +0100 Message-Id: <20211109164113.65981-4-benjamin@sipsolutions.net> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211109164113.65981-1-benjamin@sipsolutions.net> References: <20211109164113.65981-1-benjamin@sipsolutions.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org From: Benjamin Berg Call the hci_tx_error handler in case a frame cannot be send. Signed-off-by: Benjamin Berg --- net/bluetooth/hci_core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c index bbb35188e41f..8664c2fbacdb 100644 --- a/net/bluetooth/hci_core.c +++ b/net/bluetooth/hci_core.c @@ -4200,6 +4200,8 @@ static void hci_send_frame(struct hci_dev *hdev, struct sk_buff *skb) if (err < 0) { bt_dev_err(hdev, "sending frame failed (%d)", err); kfree_skb(skb); + + hci_tx_error(hdev, -err); } } -- 2.31.1