Hi, the commit 11f056a3f0b87e86267efa8b5ac9d36a343c9dc1 (r600g: Set tiling information for BOs being shared.) breaks r300g build, but most importantly, I am pretty sure it also breaks glGenerateMipmap on r300g and kernels without RADEON_CS_KEEP_TILING_FLAGS support. The problem is with this hunk:
diff --git a/src/gallium/winsys/radeon/drm/radeon_drm_bo.c b/src/gallium/winsys/radeon/drm/radeon_drm_bo.c index ec33ab5..86d35c1 100644 --- a/src/gallium/winsys/radeon/drm/radeon_drm_bo.c +++ b/src/gallium/winsys/radeon/drm/radeon_drm_bo.c @@ -670,23 +684,19 @@ static void radeon_bo_get_tiling(struct pb_buffer *_buf, } static void radeon_bo_set_tiling(struct pb_buffer *_buf, - struct radeon_winsys_cs *rcs, enum radeon_bo_layout microtiled, enum radeon_bo_layout macrotiled, + unsigned bankw, unsigned bankh, + unsigned tile_split, + unsigned stencil_tile_split, + unsigned mtilea, uint32_t pitch) { struct radeon_bo *bo = get_radeon_bo(_buf); - struct radeon_drm_cs *cs = radeon_drm_cs(rcs); struct drm_radeon_gem_set_tiling args; memset(&args, 0, sizeof(args)); - /* Tiling determines how DRM treats the buffer data. - * We must flush CS when changing it if the buffer is referenced. */ - if (cs && radeon_bo_is_referenced_by_cs(cs, bo)) { - cs->flush_cs(cs->flush_data, 0); - } - while (p_atomic_read(&bo->num_active_ioctls)) { sched_yield(); } The flush must stay there. The CS ioctl without RADEON_CS_KEEP_TILING_FLAGS always overwrites renderbuffer tiling flags, which causes that r300g must re-set the flags in set_framebuffer_state everytime there is a switch between macrotiled and non-macrotiled mipmap levels. The flush is needed so that the unflushed commands using the old tiling flags aren't changed (the tiling flags are written into the command stream in the CS ioctl). Marek _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev