3 # bluetooth Bluetooth subsystem starting and stopping. Turn HID adapters into Bluetooth ones.
7 # description: Bluetooth subsystem
12 # Source function library
13 . /etc/rc.d/init.d/functions
15 [ -f /etc/sysconfig/bluetooth ] && . /etc/sysconfig/bluetooth
18 # Check if the service is already running?
19 if [ ! -f /var/lock/subsys/bluetooth ]; then
20 if [ -x /sbin/udevadm ]; then
21 msg_starting "Bluetooth devices"
22 daemon /sbin/udevadm trigger --subsystem-match=bluetooth --action=add
24 touch /var/lock/subsys/bluetooth
27 msg_already_running bluetooth
32 if [ -f /var/lock/subsys/bluetooth ]; then
33 # nothing needed to stop it
34 rm -f /var/lock/subsys/bluetooth
36 msg_not_running bluetooth
41 if [ -f /var/lock/subsys/bluetooth ]; then
45 msg_not_running bluetooth
51 # See how we were called.
59 restart|reload|force-reload)
67 if [ -f /var/lock/subsys/bluetooth ]; then
74 msg_usage "$0 {start|stop|restart|try-restart|reload|force-reload|status}"