Here is a second revision of the early RFC patch set I wanted to send out to get some review and feedback on. I've been working to enable the drm_hwcomposer for HiKey and HiKey960 boards in AOSP, and this patchset contains the required changes to the drm_hwcomposer code to get things working. I'm really quite naive when it comes to graphics, and I'm sure I don't fully understand the drm_hwcomposer code, so forgive me if I've done anything terribly stupid here. The first two patches are, I think, mostly straightforward, the first being a bug fix, and the second adding an importer for the ARM gralloc implementations. The next two patches, while largely reworked from v1, are still a bit iffy, and I'd appreciate guidance on how to improve them. The third forcing client composition if there is only one layer and the fourth providing a glFinish() fallback which fixes on-screen tearing when the gl compositior fails to initalize. I also have two additional patches, which I've not included here - as they still need work, which get the glcompositor to properly function on HiKey960. But the curious can find them here: https://github.com/johnstultz-work/drm_hwcomposer/commits/drm_hwc If anyone wants to try the code out on either a HiKey or HiKey960, you will need just the 4 patches here on top of the freedesktop/master branch of drm_hwcomposer. You'll also need the freedesktop/master branch of libdrm. You'll need the following patches to the device/linaro/hikey project: https://github.com/johnstultz-work/android_device_linaro_hikey/commits/drm_hwc And you'll need to replace the kernel Image-dtb with one built from the following tree: https://git.linaro.org/people/john.stultz/android-dev.git/log/?h=dev/hikey-hwcomposer-deps Any thoughts or feedback will be very much appreciated! Many thanks to Rob Herring and Matt Szczesiak for help to get this working so far! And Sean Paul for his recent help working out the crtc activiation bug. Thanks so much for your time! -john Cc: Marissa Wall <marissaw@xxxxxxxxxx> Cc: Sean Paul <seanpaul@xxxxxxxxxx> Cc: Dmitry Shmidt <dimitrysh@xxxxxxxxxx> Cc: Robert Foss <robert.foss@xxxxxxxxxxxxx> Cc: Matt Szczesiak <matt.szczesiak@xxxxxxx> Cc: Liviu Dudau <Liviu.Dudau@xxxxxxx> Cc: David Hanna <david.hanna11@xxxxxxxxx> Cc: Rob Herring <rob.herring@xxxxxxxxxx> John Stultz (4): drm_hwcomposer: Make sure we set the active state when doing modesets drm_hwcomposer: Add platformhisi buffer importer for hikey and hikey960 drm_hwcomposer: Use client compositing if there is only one plane drm_hwcomposer: Try to fallback if GLCompisition fails Android.mk | 15 +++- drmdisplaycompositor.cpp | 11 +++ drmhwctwo.cpp | 7 ++ platformhisi.cpp | 200 +++++++++++++++++++++++++++++++++++++++++++++++ platformhisi.h | 50 ++++++++++++ 5 files changed, 282 insertions(+), 1 deletion(-) create mode 100644 platformhisi.cpp create mode 100644 platformhisi.h -- 2.7.4 _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/dri-devel