2fc0bbe814
If the next bind is just an extension of the previous one, join both in the same bind operation. Due to how mip levels are laid in memory, this can only happen for mip level 0. As of today xe.ko doesn't try to join contiguous operations for us. Due to how rebinds happen each additional rebind operation may end up resulting in many extra things done, so these simple checks end up saving us a lot of cycles the Kernel would otherwise waste. This will be true even after we issue all binds in a single ioctl. Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26036>