Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

events : Change preferences for haptics vars #93

Open
wants to merge 5 commits into
base: android-11.0
Choose a base branch
from

Conversation

Yilliee
Copy link

@Yilliee Yilliee commented Apr 3, 2022

The previous configuration had set the preference of
checking for the activation file to be the greatest
which made the AIDL_HAPTICS and SAMSUNG_HAPTICS var
useless incase the activation file existed.
For some devices, the activation file does indeed
exist but is not used by the kernel which results in broken
haptics.

AndroiableDroid and others added 5 commits December 26, 2021 11:04
Signed-off-by: Mohd Faraz <[email protected]>
The libziparchive TWRP using was outdated, not supported a zip
size more than 4 GiB. With the development of technologies,
Obviously it was not enough for ROM packages, like Xiaomi's
MIUI for Vitrual A/B devices (for example Redmi K40 [alioth])
is more than 4 GiB and TWRP couldn't handle it properly.
Since we have updated libziparchive to latest version, we could
switch ZipEntry to ZipEntry64 so that TWRP can support a ROM
package if its size more than 4 GiB.

Co-authored-by: sekaiacg <[email protected]>
Signed-off-by: GarfieldHan <[email protected]>
Change-Id: Iee811554bb08e02bf2bd8e9057511f36caefdc9d
Signed-off-by: Mohd Faraz <[email protected]>
This commit will add EROFS Filesystem mount support

Since Huawei announced the new file system EROFS and successfully
merged into mainline. More and more OEMs switch the ext4 filesystem
to EROFS filesystem for system/vendor/odm/product partitions like
Oplus (OPPO / Realme / OnePlus).

Test: Import the latest fstab from system, build and boot. EROFS-based
partions like system and vendor partitions were sucessfully mounted.

Notes: Although I tried to change 'ext4' to 'erofs' for correct partition
in twrp.flags, but it was still recognized as 'ext4'. So you can just copy
the line related erofs partitions from recovery.fstab and TWRP will failed
to recognize the line in twrp.flags, and then skip this line, so the issue
was solved.

Signed-off-by: GarfieldHan <[email protected]>
Change-Id: I49a04e4465f1d92eb589ad6d86b6db9b58d720eb
Enhanced Read-Only File System (EROFS) has been included in Linux
kernel, many Linux distributions, buildroot and Android AOSP for
a while. Plus, nowadays, it's known that EROFS has been commercially
used by several Android vendors for their system partitions.

This patch adds support for detecting EROFS filesystem to libblkid.

Since util-linux/util-linux@cd129b7 introduced blkid_probe_set_block_size
function to report filesystem block size, TWRP is using blkid 2.25.0, which
means blkid_probe_set_block_size wasn't supported and required, so remove
the blkszbits judgement and blkid_probe_set_block_size for fixing building.

Test: Add erofs mount point to twrp.flags, build and boot
OP4A7A:/ # logcat | grep erofs
I (6)[571:recovery]erofs: (device dm-0): mounted with opts: , root inode @ nid 58.
I (6)[571:recovery]erofs: (device dm-9): mounted with opts: , root inode @ nid 43.
I (6)[571:recovery]erofs: (device dm-1): mounted with opts: , root inode @ nid 52.
I (6)[571:recovery]erofs: (device dm-10): mounted with opts: , root inode @ nid 45.
I (6)[571:recovery]erofs: (device dm-8): mounted with opts: , root inode @ nid 42.
I (0)[571:recovery]erofs: (device dm-12): mounted with opts: , root inode @ nid 38.
I (3)[571:recovery]erofs: (device dm-0): mounted with opts: , root inode @ nid 58.
I (3)[571:recovery]erofs: (device dm-1): mounted with opts: , root inode @ nid 52.
I (3)[571:recovery]erofs: (device dm-0): mounted with opts: , root inode @ nid 58.
I (3)[571:recovery]erofs: (device dm-0): mounted with opts: , root inode @ nid 58.
I (3)[571:recovery]erofs: (device dm-9): mounted with opts: , root inode @ nid 43.
I (2)[571:recovery]erofs: (device dm-1): mounted with opts: , root inode @ nid 52.
I (2)[571:recovery]erofs: (device dm-10): mounted with opts: , root inode @ nid 45.
I (2)[571:recovery]erofs: (device dm-8): mounted with opts: , root inode @ nid 42.
I (2)[571:recovery]erofs: (device dm-12): mounted with opts: , root inode @ nid 38.
I (6)[571:recovery]erofs: (device dm-0): mounted with opts: , root inode @ nid 58.
I (6)[571:recovery]erofs: (device dm-0): mounted with opts: , root inode @ nid 58.

OP4A7A:/ # cat /tmp/recovery.log | grep erofs
   Current_File_System: erofs
   Fstab_File_System: erofs
   Current_File_System: erofs
   Fstab_File_System: erofs
   Fstab_File_System: erofs
   Current_File_System: erofs
   Fstab_File_System: erofs
   Current_File_System: erofs
   Fstab_File_System: erofs
   Current_File_System: erofs
   Fstab_File_System: erofs
   Current_File_System: erofs
   Fstab_File_System: erofs

Now TWRP can recognize the EROFS filesystem perfectly after setting fs in twrp.flags

Signed-off-by: Gao Xiang <[email protected]>
[@pomelohan: Adapt for TWRP's libblkid version and add erofs.c to build]
Co-authored-by: GarfieldHan <[email protected]>
Signed-off-by: GarfieldHan <[email protected]>
Change-Id: I00263757b5b6ed881165e65795ef849d86763165
The previous configuration had set the preference of
checking for the activation file to be the greatest
which made the AIDL_HAPTICS and SAMSUNG_HAPTICS var
useless incase the activation file existed.
For some devices, the activation file does indeed
exist but is not used by the kernel.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants