-
Notifications
You must be signed in to change notification settings - Fork 34
Open
Labels
Description
Tree: halium-7.1
- Create manifest - santoni
- Boot image and system image build successfully
- Device boots into rootfs,
usb: Manufacturer: GNU/Linux Deviceappears indmesgon host. - LXC container starts and does not crash
- libhybris tests
- test_gps
- test_hwcomposer
- test_lights
- test_vibrator
- test_wifi
- test_sensors
- test_audio
- test_camera
- test_input
- test_nfc (not avaliable)
- test_recorder
Troubleshooting:
- libnativehelper ScopedPthreadMutexLock.h missing
Added manually inlibnativehelper/include/nativehelperdownload here.
Maybe I'm missing a project in my manifest.xml?, I know there must be a better way to fix this.
It was, Halium/android was missing android_libcore repo Add libcore android#17 - signapk.jar was missing/not found
Fixed by removing all .apk/.jar references insideproprietary-files.txtin device tree Loup-ROM/android_device_xiaomi_santoni@28243c1
Loup-ROM/android_device_xiaomi_santoni@4d16924 - failed to allocate "X" blocks, out of space?:
error: ext4_allocate_best_fit_partial: failed to allocate "X" blocks, out of space?
fixed after using this patch Make system.img the right size for the device halium-scripts#4 - lxc crashing,
/var/lib/lxc/android/rootfs Input/output error
fixed after removing f2fs support in device tree Loup-ROM/android_device_xiaomi_santoni@07c073b - pm-service, dmesg being flooded with this:
kernel: IPC_RTR: msm_ipc_router_bind: pm-service Do not have permissions
fixed by applying this patch to the kernel Halium/android_kernel_lge_bullhead@a34bb3a...0b64b0c
and addingpm-servicetonet_rawgroup Loup-ROM/android_device_xiaomi_santoni@46d4423 - wifi
for wifi to work I had to run this:echo sta > /sys/module/wlan/parameters/fwpath - Device reboots while installing a different rootfs: Installing a different rootfs (plasma,ubports,etc) causes a reboot because the extraction process fills all the RAM, so the installation never finishes. Sending a different busybox binary doesn't help.
The solution is to add a swap device temporarily and reduce the aggressiveness of the LMK.
Add these lines beforeecho "transfering rootfs tarball ... "inhalium-installscript
# Check if we have a swap device enabled
if [ $(do_shell "cat /proc/swaps | wc -l") -lt 2 ]
then
echo "Enabling swap device"
SWAP=1
do_shell "dd if=/dev/zero of=/data/tmpswap bs=2048M count=1"
do_shell "mkswap /data/tmpswap"
do_shell "swapon /data/tmpswap"
# We need to low the aggressiveness of LMK so the device doesn't reboot.
echo "Reducing LowMemoryKiller agressiveness"
do_shell "echo 9999 > /sys/module/lowmemorykiller/parameters/adj"
do_shell "echo 1 > /sys/module/lowmemorykiller/parameters/minfree"
fi
Then add these inside cleanup_device function to remove the swap file.
if [ -n "$SWAP" ]
then
do_shell "sync"
do_shell "swapoff /data/tmpswap"
do_shell "rm -rf /data/tmpswap"
fi
Sources
- fixup-mountpoints: [santoni] Add Xiaomi Redmi 4X to fixup-mountpoints mer-hybris/hybris-boot#131
- kernel: https://github.com/bitrvmpd/msm-3.18/tree/halium-7.1
- device tree: https://github.com/bitrvmpd/android_device_xiaomi_santoni/tree/halium-7.1
- vendor tree: https://github.com/Nikesh001/android_vendor_xiaomi_santoni/tree/cm-14.1