Replace the killall to pgrep 35/146935/2
authorHyuk Lee <hyuk0512.lee@samsung.com>
Thu, 31 Aug 2017 07:39:49 +0000 (16:39 +0900)
committerHyuk Lee <hyuk0512.lee@samsung.com>
Thu, 31 Aug 2017 10:25:06 +0000 (19:25 +0900)
Change-Id: Iede2adb3cdfb66c82e25f31e1e118c7f18910f6d
Signed-off-by: Hyuk Lee <hyuk0512.lee@samsung.com>
scripts/bt-dev-end.sh

index 37bafad..54350b4 100755 (executable)
@@ -1,5 +1,6 @@
 #!/bin/sh
 PATH=/bin:/usr/bin:/sbin:/usr/sbin
+PGREP=/usr/bin/pgrep
 
 #
 # Script for stopping Broadcom UART Bluetooth stack
@@ -14,11 +15,13 @@ if [ $REVISION_NUM == "0006" ]; then
        rmmod bt_drv.ko
        rmmod st_drv.ko
        sleep 1
-       killall uim_rfkill
+       UIM_RFKILL_PID=$($PGREP uim_rfkill)
+       kill $UIM_RFKILL_PID
        exit 0
 fi
 
-killall hciattach
+HCIATTACH_PID=$($PGREP hciattach)
+kill $HCIATTACH_PID
 
 # Turn off Bluetooth Chip
 /usr/sbin/rfkill block bluetooth