!UPSTREAM: meta: fix meta clear of layered framebuffers

TODO:
- Improve commit message.
HACK