From: Kamil Konieczny <kamil.konieczny@linux.intel.com>
To: igt-dev@lists.freedesktop.org
Cc: "Kamil Konieczny" <kamil.konieczny@linux.intel.com>,
"Arvind Yadav" <arvind.yadav@intel.com>,
"Nishit Sharma" <nishit.sharma@intel.com>,
"Zbigniew Kempczyński" <zbigniew.kempczynski@intel.com>
Subject: [PATCH i-g-t v2 2/2] tests/intel/xe_madvise: Fix armhf compilation
Date: Fri, 17 Apr 2026 20:11:57 +0200 [thread overview]
Message-ID: <20260417181157.177299-3-kamil.konieczny@linux.intel.com> (raw)
In-Reply-To: <20260417181157.177299-1-kamil.konieczny@linux.intel.com>
There are a compiler errors on armhf, related to a cast from pointer
to uint64_t:
../tests/intel/xe_madvise.c:201:20: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
201 | igt_assert_eq_u64((uint64_t)ptr, (uint64_t)MAP_FAILED);
| ^
Fix it by using igt_assert_eq_ptr() macro.
Cc: Arvind Yadav <arvind.yadav@intel.com>
Cc: Nishit Sharma <nishit.sharma@intel.com>
Cc: "Zbigniew Kempczyński" <zbigniew.kempczynski@intel.com>
Fixes: 42d669fde782 ("tests/intel/xe_madvise: Add purged-mmap-blocked subtest")
Signed-off-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
---
tests/intel/xe_madvise.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/intel/xe_madvise.c b/tests/intel/xe_madvise.c
index 805de793a..e9bf55ff5 100644
--- a/tests/intel/xe_madvise.c
+++ b/tests/intel/xe_madvise.c
@@ -198,7 +198,7 @@ static void test_purged_mmap_blocked(int fd)
igt_assert_eq(igt_ioctl(fd, DRM_IOCTL_XE_GEM_MMAP_OFFSET, &mmo), 0);
ptr = mmap(NULL, bo_size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, mmo.offset);
- igt_assert_eq_u64((uint64_t)ptr, (uint64_t)MAP_FAILED);
+ igt_assert_eq_ptr(ptr, MAP_FAILED);
igt_assert_eq(errno, EINVAL);
gem_close(fd, bo);
@@ -340,7 +340,7 @@ static void test_dontneed_before_mmap(int fd)
/* mmap() on a DONTNEED BO must fail with EBUSY. */
ptr = mmap(NULL, bo_size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, mmo.offset);
- igt_assert_eq_u64((uint64_t)ptr, (uint64_t)MAP_FAILED);
+ igt_assert_eq_ptr(ptr, MAP_FAILED);
igt_assert_eq(errno, EBUSY);
/* Restore to WILLNEED before cleanup */
--
2.53.0
next prev parent reply other threads:[~2026-04-17 18:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-17 18:11 [PATCH i-g-t v2 0/2] Add assert for pointers compare and fix armhf compilation Kamil Konieczny
2026-04-17 18:11 ` [PATCH i-g-t v2 1/2] lib/igt_core: Create asserts for pointer comparision Kamil Konieczny
2026-04-20 10:26 ` Karthik B S
2026-04-17 18:11 ` Kamil Konieczny [this message]
2026-04-20 10:27 ` [PATCH i-g-t v2 2/2] tests/intel/xe_madvise: Fix armhf compilation Karthik B S
2026-04-21 11:51 ` ✗ Fi.CI.BAT: failure for Add assert for pointers compare and fix armhf compilation (rev2) Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260417181157.177299-3-kamil.konieczny@linux.intel.com \
--to=kamil.konieczny@linux.intel.com \
--cc=arvind.yadav@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=nishit.sharma@intel.com \
--cc=zbigniew.kempczynski@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox