Commit Graph

62 Commits

Author SHA1 Message Date
followmsi d4ded6fe79 flo: Finally move init files to vendor 2021-12-02 15:13:44 +01:00
followmsi ce421e972f flo: Use sys.io.scheduler for 12
Take logic from lineage-iosched.rc

As "prebuilt/common/etc/init/lineage-iosched.rc" has been removed
be135083d6
2021-12-02 13:33:03 +01:00
shivatejapeddi 2d4b81e342 flo: Set BPF support level
This allows a legacy device launched with Android (pre-)O and running
a pre-4.9-P+ kernel to declare itself as not eBPF capable.
2021-11-25 13:35:03 +01:00
Nolen Johnson 1b44da642f Revert "flo: fstab latemount cache too"
* This caused numerous issues. The biggest of which being that /cache's
  block device was labeled incorrectly as it was latemounted. Due to
  this, Lineage Updater would fail to write to /cache directories for
  updates, causing them to fail.

* Lesson learned, several optimizations Google included on the Pixel's
  won't work/aren't feasible on non-A/B devices.

This reverts commit ed5a9106b1dfcfa1f1790d68e49bfc1d17e285f6.

Change-Id: I21f277c6888e06453866b8fd99004f38dce07ebb
2021-11-24 15:51:09 +01:00
elektroschmock 11cdaa374f flo: fstab: Mount persist with noatime flag
If the noatime flag isn't set the atime information is updated on
every read access. This is bad for performance and flash lifetime.

Change-Id: I9d1a64e1a876dd239fc4593c2d7ffa75790f3a6a
2021-11-24 15:49:08 +01:00
Arne Coucheron 52bb1cf88a flo: rootdir: Start camera server in early_hal class
Starting it in early-boot unfortunately made it not load when
device was encrypted.

Change-Id: I62ab18927d5c9522bc70c4221a89f0489feb9f03
2021-11-24 14:38:03 +01:00
Nolen Johnson da21d0eac7 flo: Switch to CFQ
Change-Id: If2aeb088a70605268c4c83a8892b7a7d1b430e9e
2021-11-24 14:37:38 +01:00
Nolen Johnson a2663ffcb0 flo: Enable swap on vendor fstab
Change-Id: I4dbaa273a21889d6a60cd2b0de84c56daba9c4c6
2021-11-24 14:36:55 +01:00
Nolen Johnson 8c0bd88363 flo: Enable and uze ZRAM
Change-Id: Idd94fe045ee7b0a631dcc174bf3e4ad1f19fe62f
2021-11-24 14:35:58 +01:00
Daniel Jarai d8c6d1aad3 flo: Move QCamera sockets from /data to /dev/socket/qcamera
Change-Id: I0241f6e0a3f56f0bbe34bb44997596d074efcec9
Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-12-21 16:41:33 +01:00
Daniel Jarai 698082de71 flo: sensors: Move sensor sockets from /data to /dev/socket/sensors
Change-Id: I0e238d10cbaf7f9560f1993f03a8c9cc6c7e1195
Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-12-21 16:39:12 +01:00
Daniel Jarai b496e07b28 flo: sensors: Run the sensor daemon as 'system' user/group instead of 'root'
This allows us to get rid of the dac_override SELinux rules, by applying
proper permissions to the files managed by the daemon. While at it, also
Treble-ized the location of said files.

Change-Id: I344b4c80412af0b22dc35da234ef3c9f88983761
Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-12-21 16:38:00 +01:00
D. Andrei Măceș 958facf8d1 flo: init: Bring back /data/misc/location/gpsone_d
The entire /data/misc/location is gone with Pie, and our GPS HALs
(specifically, libloc_eng) need to write in there.

Change-Id: Ic5462b21b1098604f29de0baeabdfac9abaa58fa
Signed-off-by: D. Andrei Măceș <andrei@unlegacy-android.org>
Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-12-11 08:39:59 +01:00
Alessandro Astone 96313d5c60 flo: gps: Make use of gps_debug.conf to set xtra servers
* Just bind mount gps.conf to gps_debug.conf
   We can't directly build gps_debug.conf because it's a common target
   and we're not allowed to override targets anymore.

Change-Id: Ia3c96665b50b0fe478e44186d1c65be723acbf5a
2020-12-11 08:38:21 +01:00
Arne Coucheron 158f54fc64 flo: rootdir: Start camera server from early boot
Solves random issue with camera orientation and flash not
being detected during boot.

Change-Id: I90db0064a1ca3cbeac89c1ab80c6f87038b40a4f
2020-12-06 21:34:19 +01:00
Jimmy Chen a2a6d605e9 flo: wifi: Move supplicant service init to wpa_supplicant
Bug: 138790309
Test: boot and wifi function is ok
Change-Id: I35cf3e03566443e20799623045eacd423fd7f5c4
2020-12-06 21:13:42 +01:00
Arne Coucheron 9d2dc20395 flo: Disable serial console notification
Google added a check for this prop in R, and if it's running
it will show a notification about it that it's impacting performance.
Why it's not disabled by default I don't know, so just force disable
it here.

Change-Id: Ia06ef15388e7e701ed526664e7748f133ad01ee2
2020-11-28 10:29:47 +01:00
followmsi 91b5ce56a9 flo: wait_for_prop hwservicemanager.ready 2020-11-06 11:48:02 +01:00
D. Andrei Măceș db2e6b8929 flo: init: I/O tweaks
Change-Id: I455547d746b53683eac26241541b65d904404bad
(cherry picked from commit 9bcda749ff2ff9bdef0bf36300574ec6e4ea857f)
2020-11-06 10:48:25 +01:00
Daniel Jarai d8d75db746 flo: Fix thermald permission issues
The owner of /sys/class/leds/lcd-backlight/brightness is system.
Since thermald runs as root, and this node has 644 perms, writing it
generates a dac_override denial. Changing the perms to 664 fixes the
issue.

Change-Id: Ic7a3bc583c2e52c5799ef536c4b9ea07a921e54b
Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-11-06 10:48:06 +01:00
voron00 f3d2373aa3 flo: rootdir: Remove 'critical' field from charger
This is no longer needed as charger runs in system group now.

Change-Id: I1e668463701787f21875e77a64f1fe7a9142ec4d
2020-11-06 10:46:31 +01:00
Subbaraman Narayanamurthy f76fbc328b flo: rootdir: Add CAP_SYS_BOOT for charger
Add CAP_SYS_BOOT capability for charger service so that it can
shutdown/reboot the system.

Change-Id: I17ccba74d5a3c38bd751c55bcf42fb3689d730a7
2020-11-06 10:46:31 +01:00
Subbaraman Narayanamurthy cbd756cb05 flo: rootdir: Change user/group permission for charger
Make charger binary run as system instead of root. Since it
needs to handle input key events, add input as a supplemental
group in addition to system and graphics.

Change-Id: Id1dc46f335087147b7d8cf674664c26f0b511de1
2020-11-06 10:46:30 +01:00
Sandeep Patil 49c24c24c3 flo: rootdir: Use /charger symlink to launch healthd
Makes this consistent with other targets and maken sure
any changes in healthd will be transparent to targets as long
as the symlink is maintained.

Update the seclabel accordingly too.

Test: Tested charge-only mode

Change-Id: Ic71e32f52c39bc45eae8d2552259695934592fc7
Signed-off-by: Sandeep Patil <sspatil@google.com>
2020-11-06 10:46:09 +01:00
Daniel Jarai dc098e20b9 flo: rootdir: Disable suspend/resume debugging
Change-Id: I1fbc0d33de44a675de3b204905c07c6d89224012
Signed-off-by: Daniel Jarai <jaraidaniel@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-11-06 10:45:43 +01:00
Devin Kim 136f71d618 flo: Fix the modem crash on encryption phone
There is an efs sync problem because of class type of rmt_storage service.
When encrypting phone, modem crash may occur due to not being able to sync
properly between AP and CP. So, rmt_storage class should be a core class.

Bug: 11325693
Change-Id: Ic51c3ab363b2de664c268b2ba0216b81e76189dc
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
2020-11-06 10:45:20 +01:00
followmsi f3aacd4bce init.flo.usb.rc: Fix build
host_init_verifier: Command 'write /sys/class/android_usb/android0/iSerial $ro.serialno' (device/asus/flo/rootdir/etc/init.flo.usb.rc:21) failed: using deprecated syntax for specifying property 'ro.serialno', use ${name} instead
host_init_verifier: Command 'write /sys/class/android_usb/android0/iManufacturer $ro.product.manufacturer' (device/asus/flo/rootdir/etc/init.flo.usb.rc:22) failed: using deprecated syntax for specifying property 'ro.product.manufacturer', use ${name} instead
host_init_verifier: Command 'write /sys/class/android_usb/android0/iProduct $ro.product.model' (device/asus/flo/rootdir/etc/init.flo.usb.rc:23) failed: using deprecated syntax for specifying property 'ro.product.model', use ${name} instead
host_init_verifier: Command 'setprop sys.usb.state $sys.usb.config' (device/asus/flo/rootdir/etc/init.flo.usb.rc:156) failed: using deprecated syntax for specifying property 'sys.usb.config', use ${name} instead
host_init_verifier: Failed to parse init script 'device/asus/flo/rootdir/etc/init.flo.usb.rc' with 4 errors
2020-11-05 12:27:53 +01:00
followmsi 8a937521e2 flo: fix usb 2019-10-12 20:03:41 +02:00
followmsi 8874fe598d Revert "flo/deb: switch to BOARD_ROOT_EXTRA_SYMLINKS"
This reverts commit bea7346621.
2019-10-10 19:25:56 +02:00
followmsi 082ac2b503 Revert "Revert "flo: Add supplicant 1.2 to init.flo.rc""
This reverts commit ae90cdae00.
2019-10-10 19:25:16 +02:00
followmsi ae90cdae00 Revert "flo: Add supplicant 1.2 to init.flo.rc"
This reverts commit 6303b8f8ba.
2019-10-08 09:45:52 +02:00
followmsi 6303b8f8ba flo: Add supplicant 1.2 to init.flo.rc
Change-Id: Ibef8f892d330141792cd617104c53adff0825c63
2019-10-01 11:16:35 +02:00
followmsi bea7346621 flo/deb: switch to BOARD_ROOT_EXTRA_SYMLINKS
Change-Id: I0c7d4704b2e4afa883dfd67fa5d4ff6edbd1ebcf
2019-09-25 23:38:03 +02:00
followmsi a5dd874dae flo: setup first_stage_mount
Change-Id: Ie5f9bcbe7e218c0525b544768df187fcf36f75db
2019-09-21 17:58:04 +02:00
followmsi 010167d79e flo: remove LOCAL_MODULE_TAGS := eng
Change-Id: I2ff423c9585ac473171a59cd6c2ea4ad4fe359fa
2019-09-21 17:08:44 +02:00
voron00 7ec078b018 flo/deb: fix permissions for hardware video enc/dec
Fixes parsing of hardware OMX codecs.

Change-Id: Ia9b63bcdedae2b59044e3e0757037f46846f9c4e
2019-05-06 13:31:31 +02:00
Den Kondakov a41eb49fd0 init: remove qcom_oncrpc and qcom_diag
Based on dmesg:
 init: /init.duma.rc: 267: Unable to decode GID for 'qcom_oncrpc': getpwnam failed: No such file or directory
 init: /init.duma.rc: 384: Unable to decode GID for 'qcom_diag': getpwnam failed: No such file or directory
2019-01-23 22:29:59 +01:00
followmsi 96df871d9d flo: Add seclabel for BT 2019-01-19 22:29:34 +01:00
dianlujitao ad0d600840 flo: Rename bt props for new HAL
Change-Id: I1afd110bffed0f43b1afcbef99be8a3776d24e0b
2018-12-19 02:43:06 +00:00
Adrian DC 04f9313ac8 flo: init: Resolve kernel trace_marker permissions on post-fs
* The permissions were not set to 222 instead of 220,
    thus introducing regular logs from libcutils:
    "cutils-trace: Error opening trace file: Permission denied (13)"

 * Refers to frameworks/native/cmds/atrace/atrace.rc

Change-Id: I236ea25d2f2068f9f86a43492807f5f05e92da96
2018-12-19 02:43:05 +00:00
Adrian DC a2699cda8e flo: init: Resolve vendor HALs for early bootanimation start
* Adapt the service from configstore-hal-1-0 service
    to vendor.configstore-hal for AOSP P

 * Also update gralloc-2-0 to vendor.gralloc-2-0

 * Resolves surfaceflinger first launch crash
    due to configstore not being running earlier enough

Change-Id: I5aae6d8357ce71933e7c6673e9e4d37adb55a6af
2018-12-19 02:43:05 +00:00
Jerry Zhang 334bd16d35 flo: Set sys.usb.ffs.aio_compat
The kernel does not support aio with ffs.
Set the property so adb/mtp know to use the compatible
functions, and the same while in recovery.

Bug: 37916658
Test: Use adb / use adb in recovery
Change-Id: Id35a05fcb9952dcf7239bd15a61cc620537419bc
2018-10-12 04:02:57 +00:00
Roshan Pius 4d93b56264 flo: Don't start supplicant with interfaces
Framework will now add interface to supplicant (via HIDL) when it
needs to control an interface, so don't specify them in the startup
params.

Bug: 69426063
Test: Device boots up and able to connect to wifi.
Change-Id: I817d28093f8b982e3806c212babd888c0f5eb7c0
2018-10-12 04:02:56 +00:00
Roshan Pius bf93099afa flo: wpa_supplicant(hidl): Add support for starting HAL lazily
Bug: 72394251
Test: Able to start supplicant from framework using
ISupplicant.getService()
Change-Id: I19b8434e7241b9028e7dc86316ec9d5512affcca
2018-10-12 04:02:55 +00:00
Jeff Vander Stoep 7fe414acc4 flo: wpa_supplicant: Move control sockets to /data/vendor
Treble compliance.

Bug: 70228425
Bug: 70393317
Test: complete wifi test in b/70393317
Test: verify sockets exist in /data/vendor/wifi/wpa/sockets

Change-Id: I0bfc3a351419f0a03498e79664949f353369bf1b
2018-10-12 04:02:54 +00:00
Jeff Vander Stoep a5477a0e09 flo: wifi_supplicant: deprecate entropy.bin
Wpa_supplicant's random pool is not necessary on Android. Randomness
is already provided by the entropymixer service which ensures
sufficient entropy is maintained across reboots. Commit b410eb1913
'Initialize /dev/urandom earlier in boot' seeds /dev/urandom with
that entropy before either wpa_supplicant or hostapd are run.

Bug: 34980020
Test: Use wifi and wifi tethering on flo
Change-Id: Iaa2a8a42e4e3fd941c5be0f8fa691245cdb429e9
2018-10-12 04:02:54 +00:00
Artem Borisov d6944f50b5 flo: Disable ZRAM
Meh. Even with the relatively good kernel impl this doesn't work
really good for us. New zram driver doesn't correlate very well
with our ancient code in mm. This leads to a noticeable performance
degradation when the kernel starts to swap the pages into zram disk and device
becomes a laggy mess after several days of uptime even without
very active usage.

Change-Id: Ib885bcfe3961bb76ec72985a5b51f86234a6a081
2018-03-30 20:32:55 +03:00
Artem Borisov bc27e3380c flo: Enable early boot animation start
* Split our fstab into two stages: early and late mount.
 * Start bootanimation and graphics before /data and /cache mounting

Change-Id: I42f8bb460db80e86616c92b11752242c086b4aec
2018-02-10 09:58:29 +00:00
Wei Wang f4c1afcda1 flo: Enable zram on boot_complete
This help to save ~50ms in boot time and bootanim shown time

Bug: 62957152
Change-Id: Icabec31aa677bd606ca8735fe9d2acb54e88bd75
2018-02-10 09:58:29 +00:00
Wei Wang c4376f08be flo: Accelerate boot by paralleling device enable
Some QCOM devices require sysfs to trigger boot/init which are blocking
the init process.
[    7.453205] init: Command 'write /sys/kernel/boot_adsp/boot 1' action=post-fs-data (/init.angler.rc:166) returned 0 took 271.936ms.
This CL is to put those slow to start devices in a
separate service and wait for the service to be done later on.

Bug: 32712851
Test: On device
Change-Id: Idd4e965f122cbc8421b443a41573d363112dfa50
2018-01-13 11:58:00 +00:00