[Pkg-bluetooth-discuss] [PATCH] Add support for launching via udev

Mario Limonciello mario_limonciello at dell.com
Fri Jul 17 15:37:36 UTC 2009


Hi Filippo:

Filippo Giunchedi wrote:
> Hi Mario,
>
> On Tue, Jul 14, 2009 at 01:42:12PM -0500, Mario Limonciello wrote:
>
> Apart from the pkill -TERM where IMO bluetoothd should write its pid somewhere,
>   
Well bluetoothd is a process that doesn't really scale into running more
than one at a time.  For this reason, I don't see much other purpose to
having the PID written out anywhere.  If not for the fact that dbus
isn't started early enough, we could even get away entirely without an
init script.
> how to handle the case where the user doesn't want bluetoothd started at all?
> having the init script as a K init link will probably be enough for the boot,
> though when udev triggers bluetoothd after init it will start.
>
>   
I think this starts to fall into a historical/philosophical belief of
how services should operate.  It's a different operating model than
Linux has had in the past.  Previously if you had bluez installed and
didn't change the defaults, bluetoothd started up regardless if you had
the hardware.  Generally the reason you would turn it off is you didn't
have the hardware and didn't want to waste memory with such a daemon
running, but also didn't want to have to install it later if you did get
hardware.

Now it's only running if you have the hardware.  It brings up a point of
why would you have it installed and have hardware if you didn't want it
running?  There are other services that operate in this same fashion
these days too.  Look at any of the dbus activated services in
/usr/share/dbus-1/system-services.  They won't necessarily start at
boot, but are activated when something requests them.  In this case that
"something" requesting them is generally a frontend trying to access them.

I'm attaching one more update to that init diff.  This time it adds a
guard to the pkill so that the init script doesn't fallover if
bluetoothd isn't running.
> filippo
>   

-- 
Mario Limonciello
*Dell | Linux Engineering*
mario_limonciello at dell.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: debian.diff
Type: text/x-patch
Size: 10455 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-bluetooth-discuss/attachments/20090717/3b7f62a0/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-bluetooth-discuss/attachments/20090717/3b7f62a0/attachment.pgp>


More information about the Pkg-bluetooth-discuss mailing list