Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp9846411imu; Wed, 5 Dec 2018 11:14:49 -0800 (PST) X-Google-Smtp-Source: AFSGD/XPLJlniJlRw249cE/Lk/OvcycgdGczk4xB4bQbx0OYf2FV+3pDs+TDw6iF2CSc4FNd6d7s X-Received: by 2002:a62:220d:: with SMTP id i13mr25447513pfi.162.1544037289866; Wed, 05 Dec 2018 11:14:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544037289; cv=none; d=google.com; s=arc-20160816; b=Qhh7y9geovQ5Ryge4aN3xEf8/9DuMThh6qjbV4xeUTlnCyq5EAu97I6Hp7gK7w8sYx kdCX7G+qog5jRdHMofuh2PPZ9JWlz4Ofq6ps5ckRTJ4wfVL2lu7bstVJpTwGu6Zhb3wx RTcgGeVybVUhM+HhYzjEGaiU/GcCKNdHZ7LkXXXz+3xNtC4c7XQFgvkQXdHCU4lcl1tb OtSzggcL/2kRtutkVGdHz04s/+Phgg8Wouw6dfFvqZ/rqqclsDuniMn/YBPc321LQuyr fqeOjAuyaWTPIwY5vs0aYyZSZ0UlmR3OV0WZ/yAlZVxwKa3NELJUAFxRBN06Sk5c6xPM IQyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=FPLRD/ogjX5L+qr84Idgc08saOc/19egVb810UN1+8Q=; b=cDseZmZNGTdP1m87KPJbqrw1x6dmie0bL4Q/wpRxFgKbHi6t2/Fx4uH/ZO4d2lD7pb PBv2VodLtwLyDZ8SBlpuCOQYhrX+EXlHCANmrl4hgAlpRKtd7114ktyoX5cQSzTTrNbQ 9KvOUiuM3Vnj3YqgspQJghT6D1ArcnNkWpfSG+p5gr1MoQPJ+JB7R4gthQjiDqooszRO Qg31FSw7gEDPg9SDhD3EfXqLG9PcLHXeQZjeBCg6vU9Yi28ndbpN/XIUaVnFe6MleNyC HK0cO6tgF6NdxvXSg9DD00GCbZnIR9CzRktDjMxT2hnIGIP2mbDA+O2U0gsJtjPBxzCO iLdQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-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 a16si19919278plm.365.2018.12.05.11.14.34; Wed, 05 Dec 2018 11:14:49 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728083AbeLETN6 (ORCPT + 99 others); Wed, 5 Dec 2018 14:13:58 -0500 Received: from smtprelay0067.hostedemail.com ([216.40.44.67]:40210 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727606AbeLETN6 (ORCPT ); Wed, 5 Dec 2018 14:13:58 -0500 X-Greylist: delayed 529 seconds by postgrey-1.27 at vger.kernel.org; Wed, 05 Dec 2018 14:13:57 EST Received: from smtprelay.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by smtpgrave02.hostedemail.com (Postfix) with ESMTP id 3FB6A18020DB3; Wed, 5 Dec 2018 19:05:09 +0000 (UTC) Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay08.hostedemail.com (Postfix) with ESMTP id 26B75182CF66B; Wed, 5 Dec 2018 19:05:08 +0000 (UTC) X-Session-Marker: 6461674062616B6B652E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,dag@bakke.com,:::::::::::::::::,RULES_HIT:41:152:355:379:599:854:960:967:968:973:988:989:1260:1261:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1542:1593:1594:1711:1730:1747:1777:1792:2393:2525:2553:2559:2564:2682:2685:2859:2893:2933:2937:2939:2942:2945:2947:2951:2954:3022:3138:3139:3140:3141:3142:3354:3865:3866:3867:3868:3870:3871:3872:3874:3934:3936:3938:3941:3944:3947:3950:3953:3956:3959:4321:5007:6119:7576:7652:7903:9025:9036:10004:10394:10400:10848:11232:11473:11658:11914:12043:12050:12438:12555:12740:12895:13019:13161:13229:13845:13894:14096:14097:14181:14685:14721:21063:21067:21080:21324:21365:21451:21627:21789:30054:30090:30091,0,RBL:error,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:neutral,Custom_rules:0:0:0,LFtime:32,LUA_SUMMARY:none X-HE-Tag: coil62_663d10cb1d15b X-Filterd-Recvd-Size: 3591 Received: from [192.168.6.106] (219.92-221-209.customer.lyse.net [92.221.209.219]) (Authenticated sender: dag@bakke.com) by omf15.hostedemail.com (Postfix) with ESMTPA; Wed, 5 Dec 2018 19:05:01 +0000 (UTC) Subject: Re: [PATCH v2 BlueZ] hid2hci: Fix udev rules for linux-4.14+ To: =?UTF-8?B?VmlsbGUgU3lyasOkbMOk?= , Greg Kroah-Hartman Cc: linux-bluetooth@vger.kernel.org, Dmitry Torokhov , Marcel Holtmann , Kay Sievers , =?UTF-8?Q?Zbigniew_J=c4=99drzejewski-Szmek?= , systemd-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org References: <20180620164240.6535-1-ville.syrjala@linux.intel.com> <20181204204117.14964-1-ville.syrjala@linux.intel.com> <20181205070621.GE16346@kroah.com> <20181205154032.GT9144@intel.com> From: Dag B Message-ID: Date: Wed, 5 Dec 2018 20:09:35 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0 MIME-Version: 1.0 In-Reply-To: <20181205154032.GT9144@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05.12.2018 16:40, Ville Syrjälä wrote: > On Wed, Dec 05, 2018 at 08:06:21AM +0100, Greg Kroah-Hartman wrote: >> On Tue, Dec 04, 2018 at 10:41:17PM +0200, Ville Syrjala wrote: >>> From: Ville Syrjälä >>> >>> Since commit 1455cf8dbfd0 ("driver core: emit uevents when >>> device is bound to a driver") the kernel started emitting >>> "bind" and "unbind" uevents which confuse the hid2hci >>> udev rules. >>> >>> The symptoms on an affected machine (Dell E5400 in my case) >>> include bluetooth devices not appearing and udev hogging >>> the cpu as it's busy processing a constant stream of these >>> "bind"+"unbind" uevents. >> What is causing a "stream" of bind and unbind events? This only happens >> when a device is attached to a driver or removed from a driver, which is >> caused by something else happening. > Not sure if it's just due to this thing causing devices to > appear/disappear during bind/unbind events or what. > >> This should not be a normal >> occurance, unless something odd is happening to your hardware? > It's not specific to my hardware. Lot's of people are affected. > See eg. > https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1759836 > > Acutally looking through that bug it seems someone else noticed > hid2hci failing lot in the logs. So maybe it's just that we already > switched the mode during "add", and then we try to redo the same > thing during "bind" which fails, and that then causes and unbind? > Dunno, udev is beyond me. > > There is another bluetooth scenario where a cpu core peaks at 100%. This is when a bluetooth keyboard goes out to lunch/suspends/disappears. No idea if this is related to the original issue, asking forgiveness if it is not. I have found it challenging to attract any attention to the problem, despite it not being an entirely new or uncommon occurence. Google the following terms: bluetooth keyboard bluetoothd linux 100% cpu By chance, I discovered a supposed fix for this on github today. I have not had the chance to test it (or if it even applies) yet: https://github.com/peak3d/bluez/commit/9cc3c1afd793e40b1a0cdc4a13e08b5e2575759e Could someone please shine a light on the sanity of this patch? Dag B