Skip to content
Commit 1985a881 authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Jon Mason
Browse files

ntb: perf test: fix address space confusion



The ntb driver assigns between pointers an __iomem tokens, and
also casts them to 64-bit integers, which results in compiler
warnings on 32-bit systems:

drivers/ntb/test/ntb_perf.c: In function 'perf_copy':
drivers/ntb/test/ntb_perf.c:213:10: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
  vbase = (u64)(u64 *)mw->vbase;
          ^
drivers/ntb/test/ntb_perf.c:214:14: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
  dst_vaddr = (u64)(u64 *)dst;
              ^

This adds __iomem annotations where needed and changes the temporary
variables to iomem pointers to avoid casting them to u64. I did not
see the problem in linux-next earlier, but it show showed up in
4.5-rc1.

Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Acked-by: default avatarDave Jiang <dave.jiang@intel.com>
Fixes: 8a7b6a77 ("ntb: ntb perf tool")
Signed-off-by: default avatarJon Mason <jdmason@kudzu.us>
parent b562e44f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment