Reintroduce EGL mitigations from Android P.

These mitigations are still necessary for GSI images with P vendor
partitions to pass Q CTS. This is essentially a revert of commit
30c1d90f1c08e2258f39e9328dcfa16fecbc9441 adjusted to match the changes
introduced in the meantime.

Bug: 124411631
Test: Pixel XL boots, CtsVrTestCases passes on Pixel 3 GSI+P
Change-Id: I38bddfddda411337f5ed77b7e4899b922386f331
3 files changed