mesa: Fix detection of invalidating both depth and stencil.