device/generic/common
リビジョン | 37976583c6d540054b2c450207773fc24ec7add0 (tree) |
---|---|
日時 | 2016-10-12 23:23:54 |
作者 | Jaap Jan Meijer <jjmeijer88@gmai...> |
コミッター | Jaap Jan Meijer |
Merge remote-tracking branch 'x86/nougat-x86' into cm-14.0-x86
@@ -48,6 +48,7 @@ function init_hal_bluetooth() | ||
48 | 48 | case "$PRODUCT" in |
49 | 49 | T10*TA|HP*Omni*) |
50 | 50 | BTUART_PORT=/dev/ttyS1 |
51 | + set_property hal.bluetooth.uart.proto bcm | |
51 | 52 | ;; |
52 | 53 | MacBookPro8*) |
53 | 54 | rmmod b43 |
@@ -68,15 +69,13 @@ function init_hal_bluetooth() | ||
68 | 69 | for bt in $(lsusb -v | awk ' /Class:.E0/ { print $9 } '); do |
69 | 70 | chown 1002.1002 $bt && chmod 660 $bt |
70 | 71 | done |
71 | - modprobe btusb | |
72 | 72 | ;; |
73 | 73 | esac |
74 | 74 | |
75 | 75 | if [ -n "$BTUART_PORT" ]; then |
76 | 76 | set_property hal.bluetooth.uart $BTUART_PORT |
77 | 77 | chown bluetooth.bluetooth $BTUART_PORT |
78 | - start btattach:-B$BTUART_PORT | |
79 | - log -t hciconfig -p i "`hciconfig`" | |
78 | + start btattach | |
80 | 79 | fi |
81 | 80 | } |
82 | 81 |
@@ -405,16 +404,6 @@ function do_bootcomplete() | ||
405 | 404 | post_bootcomplete |
406 | 405 | } |
407 | 406 | |
408 | -function do_hci() | |
409 | -{ | |
410 | - local hci=`hciconfig | grep ^hci | cut -d: -f1` | |
411 | - local btd="`getprop init.svc.bluetoothd`" | |
412 | - log -t bluetoothd -p i "$btd ($hci)" | |
413 | - if [ -n "`getprop hal.bluetooth.uart`" ]; then | |
414 | - [ "`getprop init.svc.bluetoothd`" = "running" ] && hciconfig $hci up | |
415 | - fi | |
416 | -} | |
417 | - | |
418 | 407 | PATH=/sbin:/system/bin:/system/xbin |
419 | 408 | |
420 | 409 | DMIPATH=/sys/class/dmi/id |
@@ -455,9 +444,6 @@ case "$1" in | ||
455 | 444 | bootcomplete) |
456 | 445 | do_bootcomplete |
457 | 446 | ;; |
458 | - hci) | |
459 | - do_hci | |
460 | - ;; | |
461 | 447 | init|"") |
462 | 448 | do_init |
463 | 449 | ;; |
@@ -1,4 +1,3 @@ | ||
1 | -import /init.bluetooth.rc | |
2 | 1 | import /init.superuser.rc |
3 | 2 | |
4 | 3 | on early-init |
@@ -103,7 +102,7 @@ service powerbtnd /system/bin/powerbtnd | ||
103 | 102 | service logcat /system/bin/logcat -v threadtime -f /data/log.txt |
104 | 103 | class debug |
105 | 104 | |
106 | -service btattach /system/bin/btattach -Pbcm | |
105 | +service btattach /system/bin/btattach | |
107 | 106 | class main |
108 | 107 | disabled |
109 | 108 | oneshot |
@@ -129,12 +128,6 @@ on property:sys.boot_completed=1 | ||
129 | 128 | write /proc/sys/kernel/ctrl-alt-del 0 |
130 | 129 | exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh bootcomplete |
131 | 130 | |
132 | -on property:init.svc.bluetoothd=running | |
133 | - exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh hci | |
134 | - | |
135 | -on property:init.svc.bluetoothd=stopped | |
136 | - exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh hci | |
137 | - | |
138 | 131 | on property:net.dns1=* |
139 | 132 | exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh netconsole |
140 | 133 |
@@ -64,6 +64,11 @@ PRODUCT_PACKAGES += \ | ||
64 | 64 | ntfsfix \ |
65 | 65 | tune2fs \ |
66 | 66 | |
67 | +PRODUCT_PACKAGES += \ | |
68 | + btattach \ | |
69 | + hciconfig \ | |
70 | + hcitool \ | |
71 | + | |
67 | 72 | # Third party apps |
68 | 73 | PRODUCT_PACKAGES += \ |
69 | 74 | Eleven \ |