hwc/overlay: validate and prepare frame
Send the entire frame (array of overlays) to driver, so that it would
check pipes params and the whole frame wrt bandwidth and SMP.
Now, the overlay's commit API just prepares an overlay object but
makes no ioctl calls.
If the driver finds the frame, as a whole, to be not ok, the
validation fails and overlay/hwc return silently.
If a certain overlay object is mis-configured or pipes are
unavailable, the driver sets the number of objects it processed.
Overlay uses this to dump the incorrect config.
Change-Id: Ifb2b7fadc6bd6d9d94a35ba3908fbd832f41447f
diff --git a/libhwcomposer/hwc_fbupdate.h b/libhwcomposer/hwc_fbupdate.h
index 4b449c8..da4cdfc 100644
--- a/libhwcomposer/hwc_fbupdate.h
+++ b/libhwcomposer/hwc_fbupdate.h
@@ -39,7 +39,9 @@
virtual ~IFBUpdate() {};
// Sets up members and prepares overlay if conditions are met
virtual bool prepare(hwc_context_t *ctx, hwc_display_contents_1 *list,
- int fbZorder) = 0;
+ int fbZorder) = 0;
+ virtual bool prepareAndValidate(hwc_context_t *ctx,
+ hwc_display_contents_1 *list, int fbZorder);
// Draws layer
virtual bool draw(hwc_context_t *ctx, private_handle_t *hnd) = 0;
//Reset values