-
Notifications
You must be signed in to change notification settings - Fork 290
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
[Pie] [xiaomi] Use persist.sys.phh.xiaomi.dt2w prop to control DT2W #139
Conversation
efd654c
to
4879c32
Compare
You'll need to tell me on what it has been tested. I've been told that some device have /dev/input dt2w control but not /proc. I'd like to keep the /dev/input at least as fallback if no node has been found |
Testes on whyred as well. |
4879c32
to
93e199d
Compare
Done. |
FWIW I can confirm my Mi 9 (cepheus) doesn't have any of those /proc nodes, so I confirm the /dev/input is needed As for proc_dt2w_gesture, please don't do it with genfscon, but do it in rw-system.sh with chcon. genfscon conflicts are not resolved, which means that if vendor has a genfscon proc proc_dt2w_gesture with another label/context, the device will simply not boot (or reboot to bootloader in stock AOSP, reboot to recovery in my GSI) |
Except for that, good for me. Feel free to bother me more to have this merged |
Hi @phhusson, thanks for the tips about genfscon conflicts! However I have no idea how to fix this now since we can't |
See
552f710
I have a known issue that this is dangerous because it's possible to inject
shell commands, but I'll fix it later
Le sam. 21 mars 2020 à 13:33, Michael Cheah <notifications@github.com> a
écrit :
… Hi @phhusson <https://github.com/phhusson>, thanks for the tips about
genfscon conflicts! However I have no idea how to fix this now since we
can't chcon on /proc 😞 Maybe we should just forget the whole idea about
setting DT2W thru proc node?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#139 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAAA4OUTBRHCXMFAFDQHNALRISX23ANCNFSM4KAW75UA>
.
|
Ok, what do you think about this: cheah@e016ce1? If it looks good to you then I'll update the PR and TrebleApp. This way we can even remove the sepolicy for |
TrebleApp will look like this: cheah/treble_app@7b6789b |
Fixed based on comments and also ran it thru PR for Android 10 branch: #146 |
@phhusson bump in case you missed it 🙂 |
On stock kernel, the /proc gesture nodes are created to control DT2W
whyred: https://github.com/MiCode/Xiaomi_Kernel_OpenSource/blob/tulip-p-oss/drivers/input/touchscreen/lct_tp_gesture.c#L98
daisy: https://github.com/MiCode/Xiaomi_Kernel_OpenSource/blob/daisy-p-oss/drivers/input/touchscreen/gt917d/gt9xx.c#L1795
We can write "1" to these /proc nodes to enable DT2W and "0" to disable it
Related PR: phhusson/treble_app#21