Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp1133200rwb; Wed, 16 Nov 2022 12:35:00 -0800 (PST) X-Google-Smtp-Source: AA0mqf6qYJKb33PraC8MZvB5APF1uFiHEiIMW4RAm/PaON+6qrSWXPKTdIVbITIoYVSe7p/vxayR X-Received: by 2002:a17:907:a604:b0:799:9ace:e868 with SMTP id vt4-20020a170907a60400b007999acee868mr18363637ejc.451.1668630899541; Wed, 16 Nov 2022 12:34:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668630899; cv=none; d=google.com; s=arc-20160816; b=nFQJy0K7fF96myiu98DjerFnMNMjsfWZcHwqokePtoIrR5OSzf+FG8B9LqCBYs5u+o Byf1IIMmgT5InP4SWZHLacChy72c2y9vBr5EroAsJC0r7fUj/VhsP2WvjYuQ57xmVLI9 fVPjlttc94ZTHHPvmBc4RB7cLlO6DBeuQFNjoR5KIbnJCqyvI2urm2KYviYFAMPexGFr jkN9XH/hqvr35XW2M9oIgkffEKqloZaLTXCoI1c28K51uzr+koOTRjWgG6+Wwxfu+MIW ywoCFnrYnVfdx1zCDHvmR5g0RZauevmiCrzfFyV83wZmsBS40mykJT3dPGOf6R6YxluH L5xg== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=wIPDLnO3IoAeI00Smq/ujtO4jdLyKZdBbvJO81An0Us=; b=DVFjFYjyHy9xfNIP5V4XnDlPgo3jTe68WFnSmu9Lqj5ymqf0NN6/QeCA374nOz2Ljx eOpasIFPTMy8Qv1UGzzlKKZowo/hmJDrAyJf0NFXZRhMysXWANe+nMR+brD4lE5rQ1V+ mG90U4JzMJihcv7VR2rIMigTUnZyQN8hDeZ92DOGYIcXZg2irqTerbmiagV/v5pw0RkC ojYdIcYIoURtLdhFXiMZKSgRn1B1j8ywhUUPdvr79Fzyq60GHhSm9oeWQ2ppXjtJnXDf wuxWG6c3URqkecpSFlQKwmSafFNvL7CIJt0zejMLelU/yenSlQtbW6LjuBDDbmlED588 DuzQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@o2.pl header.s=1024a header.b=ahtEv54o; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=o2.pl Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gt38-20020a1709072da600b007add8160fd4si15202169ejc.766.2022.11.16.12.34.23; Wed, 16 Nov 2022 12:34:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@o2.pl header.s=1024a header.b=ahtEv54o; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=o2.pl Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233938AbiKPU3c (ORCPT + 99 others); Wed, 16 Nov 2022 15:29:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49954 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231221AbiKPU3b (ORCPT ); Wed, 16 Nov 2022 15:29:31 -0500 Received: from mx-out.tlen.pl (mx-out.tlen.pl [193.222.135.142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9D032A199 for ; Wed, 16 Nov 2022 12:29:28 -0800 (PST) Received: (wp-smtpd smtp.tlen.pl 10810 invoked from network); 16 Nov 2022 21:29:21 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=o2.pl; s=1024a; t=1668630561; bh=wIPDLnO3IoAeI00Smq/ujtO4jdLyKZdBbvJO81An0Us=; h=From:To:Cc:Subject; b=ahtEv54oe3So5cDD0xuRqhdgCPnPfel5z6Z6Z7TSlT3OpWgOs5pZnaP0cwmLk+IpW v8rF7ca+UmzuCnqMDd/b5sfRS1oZPN4igsdS2juPNG2O3dTRvt76AcqMAxtX+TaXj0 i0VZOc1q14HNBx4pVgvtqeAiiXUrZ/eJIEVwP2tk= Received: from aafn183.neoplus.adsl.tpnet.pl (HELO localhost.localdomain) (mat.jonczyk@o2.pl@[83.4.143.183]) (envelope-sender ) by smtp.tlen.pl (WP-SMTPD) with SMTP for ; 16 Nov 2022 21:29:21 +0100 From: =?UTF-8?q?Mateusz=20Jo=C5=84czyk?= To: linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: =?UTF-8?q?Mateusz=20Jo=C5=84czyk?= , Brian Gix , Luiz Augusto von Dentz , Marcel Holtmann , Johan Hedberg Subject: [PATCH] Bluetooth: silence a dmesg error message in hci_request.c Date: Wed, 16 Nov 2022 21:28:56 +0100 Message-Id: <20221116202856.55847-1-mat.jonczyk@o2.pl> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-WP-MailID: cf8b44b908658acece8b81a6ab35ced6 X-WP-AV: skaner antywirusowy Poczty o2 X-WP-SPAM: NO 000000B [0XNk] X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org On kernel 6.1-rcX, I have been getting the following dmesg error message on every boot, resume from suspend and rfkill unblock of the Bluetooth device: Bluetooth: hci0: HCI_REQ-0xfcf0 After some investigation, it turned out to be caused by commit dd50a864ffae ("Bluetooth: Delete unreferenced hci_request code") which modified hci_req_add() in net/bluetooth/hci_request.c to always print an error message when it is executed. In my case, the function was executed by msft_set_filter_enable() in net/bluetooth/msft.c, which provides support for Microsoft vendor opcodes. As explained by Brian Gix, "the error gets logged because it is using a deprecated (but still working) mechanism to issue HCI opcodes" [1]. So this is just a debugging tool to show that a deprecated function is executed. As such, it should not be included in the mainline kernel. See for example commit 771c035372a0 ("deprecate the '__deprecated' attribute warnings entirely and for good") Additionally, this error message is cryptic and the user is not able to do anything about it. [1] Link: https://lore.kernel.org/lkml/beb8dcdc3aee4c5c833aa382f35995f17e7961a1.camel@intel.com/ Fixes: dd50a864ffae ("Bluetooth: Delete unreferenced hci_request code") Signed-off-by: Mateusz Jończyk Cc: Brian Gix Cc: Luiz Augusto von Dentz Cc: Marcel Holtmann Cc: Johan Hedberg --- net/bluetooth/hci_request.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/bluetooth/hci_request.c b/net/bluetooth/hci_request.c index 5a0296a4352e..f7e006a36382 100644 --- a/net/bluetooth/hci_request.c +++ b/net/bluetooth/hci_request.c @@ -269,7 +269,7 @@ void hci_req_add_ev(struct hci_request *req, u16 opcode, u32 plen, void hci_req_add(struct hci_request *req, u16 opcode, u32 plen, const void *param) { - bt_dev_err(req->hdev, "HCI_REQ-0x%4.4x", opcode); + bt_dev_dbg(req->hdev, "HCI_REQ-0x%4.4x", opcode); hci_req_add_ev(req, opcode, plen, param, 0); } base-commit: 094226ad94f471a9f19e8f8e7140a09c2625abaa -- 2.25.1