lib/logic_iomem: Fix 32-bit build
authorJohannes Berg <johannes.berg@intel.com>
Wed, 15 Sep 2021 18:30:21 +0000 (20:30 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jan 2022 10:03:44 +0000 (11:03 +0100)
commit6c72a5bc4df4565164569d4833efc6f19c44dcbc
tree651f8209ec0ec0664aa0e489ae38eb8e31d67b16
parentb53c2307b18c4fdcbb46b340c5a13aae49b2b369
lib/logic_iomem: Fix 32-bit build

[ Upstream commit 4e84139e14af5ea60772cc4f33d7059aec76e0eb ]

On a 32-bit build, the (unsigned long long) casts throw warnings
(or errors) due to being to a different integer size. Cast to
uintptr_t first (with the __force for sparse) and then further
to get the consistent print on 32 and 64-bit.

Fixes: ca2e334232b6 ("lib: add iomem emulation (logic_iomem)")
Reported-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Sasha Levin <sashal@kernel.org>
lib/logic_iomem.c