From cccb6476315b82e9caa4c5e922d6481aa06af200 Mon Sep 17 00:00:00 2001 From: LUCA DURANDO Date: Mon, 19 Feb 2024 09:40:53 +0100 Subject: [PATCH] Final Fix Version --- README.md | 6 +++--- module.prop | 8 ++++---- service.sh | 8 +++++--- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 04d7f386..e5a1c11a 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ -MGLRUDISABLER +MGLRU FIX - MGLRUDISABLER = ***!*** THIS MODULE IS A WORKAROUND FOR FREEZES AND CRASHES ON 1.5.3(/HOTFIX) ON NOTHING PHONE (1) -REMEMBER TO DISABLE IT BEFORE UPDATING THE PHONE TO A NEWER SW VERSION +REMEMBER TO DISABLE IT BEFORE UPDATING THE PHONE TO A NEWER FW VERSION ***!*** SPECIAL THANKS @@ -20,7 +20,7 @@ HOW TO INSTALL 2. Open Magisk, select Modules, Install from storage and go pick the latest downloaded module -3. V3 users can simply reboot their phones, while for V1 and V2 cold boot is necessary, so fully power off your device before turning it back on. +3. V3 and Fix users can simply reboot their phones, while for V1 and V2 cold boot is necessary, so fully power off your device before turning it back on. 4. Enjoy diff --git a/module.prop b/module.prop index 8c811e07..1dd935f6 100644 --- a/module.prop +++ b/module.prop @@ -1,7 +1,7 @@ id=mglru-fix -name=MGLRU Disabler -version=v3 -versionCode=3 +name=MGLRU Fix +version=1.0 +versionCode=4 author=LukeSkyD -description=Prevent freezes on MGLRU devices using magisk by disabling MGLRU on every boot +description=Fix freezes on MGLRU devices by using magisk and disabling MGLRU template=3 diff --git a/service.sh b/service.sh index e331ac33..32d5508c 100644 --- a/service.sh +++ b/service.sh @@ -1,4 +1,4 @@ -# MGLRU-FIX stops crashes by rendering non-functional the MGLRU feature +# MGLRU-FIX stops crashes on 1.5.3 / (.HOTFIX) by rendering non-functional the MGLRU feature # Copyright (C) 2023 Luca Durando # # This program is free software: you can redistribute it and/or modify @@ -14,5 +14,7 @@ # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see . -echo 0 > /sys/kernel/mm/lru_gen/enabled -chmod 444 /sys/kernel/mm/lru_gen/enabled +if [ "$(getprop ro.nothing.version.id)" = "1.5.3" ]; then + echo 0 > /sys/kernel/mm/lru_gen/enabled + chmod 444 /sys/kernel/mm/lru_gen/enabled +fi \ No newline at end of file