fb: JZ4770: Avoid possible early return from wait-for-vsync

Previously, if FBIO_WAITFORVSYNC was called very soon after vsync, it
would return immediately rather than wait for the next vsync.

The problem was that we couldn't tell apart processes waiting for the
last vsync from new registrations. This was solved by adding a frame
counter.

I found this approach in the ps3fb driver and implemented a similar
solution here. One difference is that we wake up all listeners instead
of just one on vsync; in my opinion this is the desired behavior.