ngoquang2708 / android_device_samsung_vivalto3gvn

Device tree for Samsung Galaxy V SM-G313HZ
7 stars 8 forks source link

The display framebuffer cannot be initialized #95

Open ngoquang2708 opened 6 years ago

ngoquang2708 commented 6 years ago

https://gist.github.com/ngoquang2708/184dc1f24ccaf66dbd0bc075e19bb6e2

diepquynh commented 6 years ago

Well, I have done all stuffs you mentioned, except not closing the hnd->fd

And from what you've observed, since the FB device is opened 2 times (first is to open to check if fb device exist, second time is to get buffer data from it, idk why), not closing fb handle will cause fd leaks. That's the first caveat

Second, it is clear that libui will use HIDL's implementation of importBuffer method, as you can see in the callback function. Still, for now we have no choice other than forcing it not to use the shared fd, and instead directly get the mapped fb fd. Touching shared fd will cause stupid behavior of mali

diepquynh commented 6 years ago

Mali uses ION fd with default ION implementation, that's why we have to close fd