Revert "Revert "support for HWC < 1.0""

This reverts commit 91f310cc5312b451f884cfe2f934d47a8bfd25b2.
Revert "Revert "SurfaceFlinger: HWC 0.3: Strict aliasing""

This reverts commit ac5ae517e89fbec2944fd5694415b59f92241147.
Revert "Revert "sf: Fix detection of 0.3 hwcomposer""

This reverts commit a4860554395f64e5983be0ce5337a0052d0cfe67.