gbm: lock and release buffer in swap buffers

Otherwise mesa prints "libEGL debug: EGL user error 0x300d
(EGL_BAD_SURFACE) in dri2_swap_buffers" when environment
variable EGL_LOG_LEVEL=debug.

Fixes #17: https://github.com/waffle-gl/waffle/pull/17
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>