rosemary: Patch Goodix fingerprint HAL to ignore conflicting events

This will fix the long standing issue of the screenshot button
combination not working properly in AOSP for Goodix sensors.

The patch will replace the first instruction of the
'gf_hal_send_key_event' function with a ret so that the touch
events which conflict with AOSP do not get reported to userspace.

Change-Id: I9e15a46b519fd7f75e39af4690c271aa63af4790
This commit is contained in:
R0rt1z2
2022-12-07 17:11:44 +00:00
committed by Matsvei Niaverau
parent 19b6978f54
commit 59e0aa7dec

View File

@@ -84,6 +84,10 @@ function blob_fixup {
vendor/lib64/libcam.halsensor.so) vendor/lib64/libcam.halsensor.so)
"${PATCHELF}" --add-needed "libshim_utils.so" "${2}" "${PATCHELF}" --add-needed "libshim_utils.so" "${2}"
;; ;;
vendor/lib64/libgf_hal.so)
xxd -p "${2}" | sed "s/ffc301d1fd7b06a9fd830191e8031f2ae2037db2a94300d14ad03bd54a15/000080d2c0035fd6fd830191e8031f2ae2037db2a94300d14ad03bd54a15/g" | xxd -r -p > "${2}".patched
mv "${2}".patched "${2}"
;;
vendor/bin/hw/android.hardware.keymaster@4.0-service.beanpod) vendor/bin/hw/android.hardware.keymaster@4.0-service.beanpod)
"${PATCHELF}" --add-needed "libshim_beanpod.so" "${2}" "${PATCHELF}" --add-needed "libshim_beanpod.so" "${2}"
;; ;;