[Xiaomi Mi MIX  ROMs, Kernels, Recoveries, & Other ] heindrix:
[NOTES]

Guys, there are many members encounter blackscreen (after system boot) after flashing the driver on the LATEST Pie ROM (it's happening after September security patch).

Looks like it's due to the hardening security.

This method fixed that blackscreen problem : https://xdaforums.com/showpost.php?p=78355758&postcount=1047

Or the better way is, to tell your dev to include this blobs in the rom directly, that way the rom will boot successfully.

I will try to solve the issue ASAP, best regards.

[DISCLAIMER]

* flash it with your own risk, don't blame me if it's not working for you, make sure to backup before you messed up.

* there are possibilities that maybe this driver won't work on some ROMs.

* there are possibilities that maybe this driver won't work on some CPUs that hasn't been tested.

[README]

* to check your GPU driver OpenGL ES version, use AIDA64 (like shown on the picture in attachment). download : https://play.google.com/store/apps/details?id=com.finalwire.aida64&hl=en_US

* to check your GPU driver Vulkan version, use Vulkan Hardware Capability Viewer (like shown on the picture attachment). download : https://play.google.com/store/apps/details?id=de.saschawillems.vulkancapsviewer&hl=en_US

* if your current driver have higher version and don't have any bugs, no need to flash this driver.

* check your device compatibility in compatibility list section.

* some tester said the benchmark score go higher and 3D heavy games are smoother using latest GPU driver, you can try to take before and after benchmark pictures and post it here to prove it.

* the driver is interchangeable (can be flashed over the top of another version, it will be replaced).

[COMPATIBILITY]

PROJECT :

* Non-Treble

* Treble

OS :

* Android 8.0 : V@313

* Android 8.1 : V@313

* Android 9.0 : V@313 | V@330 | V@331

CPU :

* Snapdragon 430 = msm8937 (tested)

* Snapdragon 435 = msm8940

* Snapdragon 625/626 = msm8953 (tested)

* Snapdragon 650 = msm8956 (not compatible)

* Snapdragon 652/653 = msm8976

* Snapdragon 820/821 = msm8996 (tested)

* Snapdragon 835 = msm8998 (tested)

* Snapdragon 429 = sdm429

* Snapdragon 439 = sdm439

* Snapdragon 450 = sdm450

* Snapdragon 630 = sdm630

* Snapdragon 632 = sdm632

* Snapdragon 636 = sdm636

* Snapdragon 660 = sdm660 (tested)

[INSTRUCTIONS]

1]. find out what is your CPU model number, you can see it in COMPATIBILITY section, on CPU sub-section. for example, my CPU is Snapdragon 821, so the CPU model number is msm8996.

2]. download the zip file. rename file in the zip file with name "vulkan.xxx.so" in system/(vendor)/lib/hw and system/(vendor)/lib64/hw to "vulkan.CpuModelNumber.so". for example, for me, i rename "vulkan.xxx.so" to "vulkan.msm8996.so".

you can use this app to rename the file inside the zip file : https://play.google.com/store/apps/details?id=com.rarlab.rar

DO NOT EDIT FILE NAMED "a5xx", ONLY EDIT FILE NAMED "vulkan.xxx.so", I HAVE TO MENTION THIS BECAUSE SOME GENIUS DECIDE TO DO THINGS BY THEIR OWN REGARDLESS FOLLOWING THE INSTRUCTIONS THAT HAS GIVEN STEP BY STEP.

3]. boot into TWRP

4]. make sure your SYSTEM and VENDOR partitions are not read only.

5]. just in case, mount SYSTEM and VENDOR partitions before flash the zip file.

6]. flash the modified zip file, wipe Dalvik Cache and Cache.

7]. after flash, boot into system, and check if your GPU Version driver has changed (you can use AIDA64). and you can test benchmark if you want (i suggest 3DMark or Antutu).

8]. this step is optional/additional : to boost GPU performance a little bit again, please add this code in system/vendor/build.prop (or in system/build.prop if you can't find it in system/vendor/build.prop). and please check if there's the same code line in your default build.prop, remove it so it won't conflicting each other. code to add :

com.qc.hardware=true

debug.composition.type=gpu

debug.egl.hw=1

debug.egl.profiler=1

debug.enabletr=true

debug.gralloc.enable_fb_ubwc=1

debug.overlayui.enable=1

debug.performance.tuning=1

debug.qc.hardware=true

debug.qctwa.preservebuf=1

debug.qctwa.statusbar=1

debug.sf.hw=1

debug.sf.latch_unsignaled=1

dev.pm.dyn_samplingrate=1

hw3d.force=1

hwui.disable_vsync=true

hwui.render_dirty_regions=false

ro.config.enable.hw_accel=true

ro.fb.mode=1

ro.product.gpu.driver=1

ro.sf.compbypass.enable=0

[DOWNLOADS]

https://drive.google.com/drive/folders/1JN05hFMijXq2Xpn_tFv1AJWodVnQYTsu

[BUGS REPORTING]

* provide device model.

* provide ROM name, android version, and treble/non-treble version.

* which file did you flash.

* provide logcat, preferable taken with adb using verbose option. how to : https://xdaforums.com/showthread.php?t=2185929

* I WILL NEVER TRY TO INSPECT/FIX ANYTHING IF YOU DON'T SEND LOGS, SAME GOES I WILL NEVER REPLY YOUR MESSAGE IF YOU DON'T SEND LOGS.

[OTHER STUFFS]

* Do this only if you get stock camera app force close : https://xdaforums.com/showpost.php?p=77971228&postcount=803

* A little help from [MENTION=4694376]LilBlinx[/MENTION] for msm8953 devices : https://xdaforums.com/showpost.php?p=78574409&postcount=1123

[CREDITS]

* Source : v313 : https://www.coolapk.com/feed/7290260 | v319 : https://www.coolapk.com/feed/7483860 | v328 : https://github.com/LineageOS | v330 : https://github.com/syberia-project

* Driver Author : v313, v319椿的神之圍樓 | v328, v330, v331 : [MENTION=8436723]heindrix[/MENTION]

* Informant : [MENTION=8729958]llinn[/MENTION]

* WHY DON'T YOU CREATE MAGISK MODULE?

Well, i just believe the performance will be better to flash the driver directly into its designated directory, rather than mounting it from an image and load it later when booting (which is what is magisk doing). For me, some other things is okay to make it into a magisk module, but not a driver, period.