The client request time SHOULD be bigger than the last vblank time. To make
sure it, we forcely set the last vblank time to the client request time when
the req_time is smaller than the last_time.
Change-Id: Ib1dbec907fa04693d6df05b8260e300f6032563e
last = private_vblank->last_time;
req = wait_info->req_time;
+ /* make sure that req time is bigger than last. */
+ if (req < last)
+ req = last;
+
skip = (unsigned int)((req - last) / private_vblank->vblank_gap + TDM_TIME_MARGIN);
prev = last + private_vblank->vblank_gap * skip;
last = private_vblank->last_time;
req = wait_info->req_time;
+ /* make sure that req time is bigger than last. */
+ if (req < last)
+ req = last;
+
skip = (unsigned int)((req - last) / private_vblank->vblank_gap + TDM_TIME_MARGIN);
prev = last + private_vblank->vblank_gap * skip;