From e8ff1fd108ac4d6192d48446815b83cf41589af7 Mon Sep 17 00:00:00 2001 From: Max Krasnyansky Date: Sat, 24 Aug 2002 15:57:12 +0000 Subject: Kill hciattach on unplug --- pcmcia/bluetooth | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pcmcia/bluetooth b/pcmcia/bluetooth index 220adc72..503484d9 100755 --- a/pcmcia/bluetooth +++ b/pcmcia/bluetooth @@ -5,7 +5,8 @@ # PCMCIA Bluetooth device initialization # Written by Maxim Krasnyanskiy # -# This script requires cardmgr 3.2.1 or later +# This script requires new cardmgr and expects following +# environment variables FUNCTION, VENDORID, CARDNAME # # @@ -24,13 +25,13 @@ start_serial() { IRQ=`setserial /dev/$DEVICE | sed -e 's/.*IRQ: //'` setserial /dev/$DEVICE irq 0 ; setserial /dev/$DEVICE irq $IRQ - /sbin/hciattach $DEVICE $MANFID + /sbin/hciattach $DEVICE $MANFID > /tmp/pcmcia } stop_serial() { - return + do_fuser -k -HUP /dev/$DEVICE > /dev/null } suspend_serial() { - do_fuser -k -HUP /dev/$DEVICE > /dev/null + stop_serial } resume_serial() { start_serial -- cgit