Files
Fuchun Liao 740d42d181 ANDROID: vendor_hooks: Add vendor_hook in futex to fix the OEM scheduling priority bug
Add vendor_hook in futex to fix the bug where OEM passes scheduling
priority to the futex owner but fails to restore it.

1) OEM vendors pass the priority to the futex owner in
trace_android_vh_futex_wait_start() and are supposed to restore it in
trace_android_vh_futex_wait_end(). However, due to the missing
trace_android_vh_futex_wait_end hook, the priority cannot be restored.

2) In kernel 6.6/6.1, futex_wait() uses goto out, so only one
trace_android_vh_futex_wait_end() is required. In kernel 6.12, there
are two return statements in the middle of futex_wait(), so
trace_android_vh_futex_wait_end hooks must also be added at these
return positions.

Bug: 429315946
Fixes: 4f417c9c41 ("ANDROID: vendor_hooks: Add hooks for oem futex optimization")
Change-Id: Id2e2d28603509c2cadc3511e16e24c96c98c5b75
Signed-off-by: Fuchun Liao <lfc@oppo.com>
2025-07-09 21:46:36 -07:00
..