From owner-freebsd-bluetooth@freebsd.org Mon Sep 21 01:45:02 2015 Return-Path: Delivered-To: freebsd-bluetooth@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A0F19A0611C for ; Mon, 21 Sep 2015 01:45:02 +0000 (UTC) (envelope-from erdgeist@erdgeist.org) Received: from elektropost.org (elektropost.org [217.115.13.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0D1DF1647 for ; Mon, 21 Sep 2015 01:45:01 +0000 (UTC) (envelope-from erdgeist@erdgeist.org) Received: (qmail 8685 invoked from network); 21 Sep 2015 01:44:58 -0000 Received: from elektropost.org (HELO elektropost.org) (erdgeist@erdgeist.org) by elektropost.org with ESMTPS (DHE-RSA-AES128-SHA encrypted); 21 Sep 2015 01:44:58 -0000 Subject: Re: service bluetooth start ubt0 fails every other time To: Maksim Yevmenkin References: <55FF418D.10806@erdgeist.org> <55FF51F7.8030404@erdgeist.org> Cc: "freebsd-bluetooth@freebsd.org" From: Dirk Engling X-Enigmail-Draft-Status: N1110 Message-ID: <55FF6119.8050902@erdgeist.org> Date: Mon, 21 Sep 2015 03:44:57 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-bluetooth@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Using Bluetooth in FreeBSD environments List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Sep 2015 01:45:02 -0000 On 21.09.15 02:57, Maksim Yevmenkin wrote: > /etc/rc.d/bluetooth start/stop is executed from devd (on device > arrival / departure). there is no real need to execute bluetooth > start/stop by hand. i would implement this as part of > /etc/rc.d/bluetooth status command (just like other rc.d services), I see. I was following up on several howtos I found about getting bluetooth devices running, so I found this "And although bluetooth dongles will run the fore-mentioned command automatically when inserted into a USB slot, your built-in bluetooth controller is never inserted into anything so I’m not entirely sure how the service is started if it is not started manually." at http://modal.us/blog/2013/09/16/bluetooth-freebsd-9-1-macbook/. I wondered if it was smarter to just play along, since the howto is out there and others will also stumble here. Also the "service bluetooth start" command does not really adhere to the rc-systems standards (it works without rcvar, and as I noticed, start does as stop, when the stack is already up.) Also nowhere is communicated that this script is supposed to be internal to devd. Is the blog's author correct that builtin controllers are not reliably started when the system boots? When my system starts up with the builtin host controllers, I at least get a Warning: attempt to domain_add(graph) after domainfinalize() but ngctl status ubt0hci: reports that it actually was started. Thanks, erdgeist