]> git.karo-electronics.de Git - karo-tx-linux.git/commit
xen: avoid type warning in xchg_xen_ulong
authorArnd Bergmann <arnd@arndb.de>
Thu, 8 Jun 2017 08:53:10 +0000 (10:53 +0200)
committerStefano Stabellini <sstabellini@kernel.org>
Thu, 8 Jun 2017 22:07:38 +0000 (15:07 -0700)
commit9cc91f212111cdcbefa02dcdb7dd443f224bf52c
treef72416924479a8f9fba793a1a6c0844761dde545
parenta2237ae761d9baa0e814e61140ca4524e31eb92b
xen: avoid type warning in xchg_xen_ulong

The improved type-checking version of container_of() triggers a warning for
xchg_xen_ulong, pointing out that 'xen_ulong_t' is unsigned, but atomic64_t
contains a signed value:

drivers/xen/events/events_2l.c: In function 'evtchn_2l_handle_events':
drivers/xen/events/events_2l.c:187:1020: error: call to '__compiletime_assert_187' declared with attribute error: pointer type mismatch in container_of()

This adds a cast to work around the warning.

Cc: Ian Abbott <abbotti@mev.co.uk>
Fixes: 85323a991d40 ("xen: arm: mandate EABI and use generic atomic operations.")
Fixes: daa2ac80834d ("kernel.h: handle pointers to arrays better in container_of()")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Stefano Stabellini <sstabellini@kernel.org>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Acked-by: Ian Abbott <abbotti@mev.co.uk>
arch/arm/include/asm/xen/events.h