iris: devinfo->no_hw is unlikely

This is one of those places where we can very safely add
likely/unlikely.

Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
Reviewed-by: Rohan Garg <rohan.garg@intel.com>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37559>
This commit is contained in:
Paulo Zanoni
2025-09-18 12:43:24 -07:00
committed by Marge Bot
parent 258eae939f
commit caca0b0e29
2 changed files with 2 additions and 2 deletions
@@ -387,7 +387,7 @@ i915_batch_submit(struct iris_batch *batch)
}
int ret = 0;
if (!batch->screen->devinfo->no_hw) {
if (likely(!batch->screen->devinfo->no_hw)) {
do {
ret = intel_ioctl(batch->screen->fd, DRM_IOCTL_I915_GEM_EXECBUFFER2, &execbuf);
} while (ret && errno == ENOMEM);
@@ -408,7 +408,7 @@ xe_batch_submit(struct iris_batch *batch)
.syncs = (uintptr_t)syncs,
.num_syncs = sync_len,
};
if (!batch->screen->devinfo->no_hw) {
if (likely(!batch->screen->devinfo->no_hw)) {
ret = intel_ioctl(iris_bufmgr_get_fd(bufmgr), DRM_IOCTL_XE_EXEC, &exec);
if (ret) {