drm/i915: Generalize ring_space to take a ringbuf