Move PlaneLayout lookup to GraphicBuffer
This keeps GraphicBufferMapper's lock closer to a raw
lock avoiding the PlaneLayout query if nobody is asking for it,
reduces code duplication between Gralloc 4 & 5, and enables
caching of the PlaneLayout to minimize queries
Partial step towards an extended lock buffer API
Also begin modernizing the API surface using a proper
Result<T> along with an error enum class
Test: make && atest
Bug: 288142323
Change-Id: Ib4590b7a3b839a993f6c747c5f09a6312f7ab329
6 files changed