device/generic/common
Revisión | 271176133bba4beaaf08d0f24f5389aa5e9e1b71 (tree) |
---|---|
Tiempo | 2019-06-20 18:19:23 |
Autor | Chih-Wei Huang <cwhuang@linu...> |
Commiter | Chih-Wei Huang |
Merge remote-tracking branch 'x86/oreo-x86' into pie-x86
@@ -17,7 +17,6 @@ | ||
17 | 17 | #ifndef _BDROID_BUILDCFG_H |
18 | 18 | #define _BDROID_BUILDCFG_H |
19 | 19 | |
20 | -#define BTM_DEF_LOCAL_NAME "Android-x86" | |
21 | 20 | // At present either USB or UART is supported |
22 | 21 | #define BLUETOOTH_HCI_USE_USB TRUE |
23 | 22 | // Bluetooth Low Power Mode is supported on BT4.0 |
@@ -0,0 +1,2 @@ | ||
1 | +touch.deviceType = touchScreen | |
2 | +touch.orientationAware = 1 |
@@ -15,6 +15,13 @@ function set_prop_if_empty() | ||
15 | 15 | [ -z "$(getprop $1)" ] && set_property "$1" "$2" |
16 | 16 | } |
17 | 17 | |
18 | +function rmmod_if_exist() | |
19 | +{ | |
20 | + for m in $*; do | |
21 | + [ -d /sys/module/$m ] && rmmod $m | |
22 | + done | |
23 | +} | |
24 | + | |
18 | 25 | function init_misc() |
19 | 26 | { |
20 | 27 | # device information |
@@ -30,6 +37,27 @@ function init_misc() | ||
30 | 37 | # enable sdcardfs if /data is not mounted on tmpfs or 9p |
31 | 38 | mount | grep /data\ | grep -qE 'tmpfs|9p' |
32 | 39 | [ $? -ne 0 ] && modprobe sdcardfs |
40 | + | |
41 | + # remove wl if it's not used | |
42 | + local wifi | |
43 | + if [ -d /sys/class/net/wlan0 ]; then | |
44 | + wifi=$(basename `readlink /sys/class/net/wlan0/device/driver`) | |
45 | + [ "$wifi" != "wl" ] && rmmod_if_exist wl | |
46 | + fi | |
47 | + | |
48 | + # enable virt_wifi if needed | |
49 | + local eth=`getprop net.virt_wifi eth0` | |
50 | + if [ -d /sys/class/net/$eth -a "$VIRT_WIFI" != "0" ]; then | |
51 | + if [ -n "$wifi" -a "$VIRT_WIFI" = "1" ]; then | |
52 | + rmmod_if_exist iwlmvm $wifi | |
53 | + fi | |
54 | + if [ ! -d /sys/class/net/wlan0 ]; then | |
55 | + ifconfig $eth down | |
56 | + ip link set $eth name wifi_eth | |
57 | + ifconfig wifi_eth up | |
58 | + ip link add link wifi_eth name wlan0 type virt_wifi | |
59 | + fi | |
60 | + fi | |
33 | 61 | } |
34 | 62 | |
35 | 63 | function init_hal_audio() |
@@ -288,7 +316,7 @@ function init_hal_sensors() | ||
288 | 316 | *i7Stylus*|*M80TA*) |
289 | 317 | set_property ro.iio.accel.x.opt_scale -1 |
290 | 318 | ;; |
291 | - *ONDATablet*) | |
319 | + *LenovoMIIX320*|*ONDATablet*) | |
292 | 320 | set_property ro.iio.accel.order 102 |
293 | 321 | set_property ro.iio.accel.x.opt_scale -1 |
294 | 322 | set_property ro.iio.accel.y.opt_scale -1 |
@@ -48,8 +48,10 @@ PRODUCT_PACKAGES += \ | ||
48 | 48 | android.hardware.light@2.0-service |
49 | 49 | |
50 | 50 | # Memtrack HAL |
51 | -#PRODUCT_PACKAGES += \ | |
52 | - android.hardware.memtrack@1.0-impl | |
51 | +PRODUCT_PACKAGES += \ | |
52 | + memtrack.default \ | |
53 | + android.hardware.memtrack@1.0-impl \ | |
54 | + android.hardware.memtrack@1.0-service | |
53 | 55 | |
54 | 56 | # Power HAL |
55 | 57 | PRODUCT_PACKAGES += \ |