hwc: Check for >1 overlay used in idle timeout

It was observed during ADTF runs than we get repeated redraws when
there are no layers to render.

This is because the check in prepare() will reset force_sgx to 0
when there are 1 or less layers. The side effect of this is to
cause a redraw every idle period.

Instead of doing this, account for the number of overlays used
for the primary display before calling the invalidate() api. This
logic should be satisfactory most current usecases.

Change-Id: I4b9cb44ebe250a6a46a6da27a1db94e88d6f26f3
Signed-off-by: Tony Lofthouse <a0741364@ti.com>
(cherry picked from commit c044e832219dd2aa81ae11e4ec883d09bf2fb885)
1 file changed