android_kernel_motorola_sm6225/net/xdp
Geert Uytterhoeven a5a16e4352 xsk: Fix umem fill/completion queue mmap on 32-bit
With gcc-4.1.2 on 32-bit:

    net/xdp/xsk.c:663: warning: integer constant is too large for ‘long’ type
    net/xdp/xsk.c:665: warning: integer constant is too large for ‘long’ type

Add the missing "ULL" suffixes to the large XDP_UMEM_PGOFF_*_RING values
to fix this.

    net/xdp/xsk.c:663: warning: comparison is always false due to limited range of data type
    net/xdp/xsk.c:665: warning: comparison is always false due to limited range of data type

"unsigned long" is 32-bit on 32-bit systems, hence the offset is
truncated, and can never be equal to any of the XDP_UMEM_PGOFF_*_RING
values.  Use loff_t (and the required cast) to fix this.

Fixes: 423f38329d ("xsk: add umem fill queue support and mmap")
Fixes: fe2308328c ("xsk: add umem completion queue support and mmap")
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Björn Töpel <bjorn.topel@intel.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
2018-06-08 00:18:02 +02:00
..
Kconfig
Makefile xsk: remove newline at end of file 2018-05-18 16:07:02 +02:00
xdp_umem.c xsk: wire upp Tx zero-copy functions 2018-06-05 15:48:34 +02:00
xdp_umem.h xsk: wire upp Tx zero-copy functions 2018-06-05 15:48:34 +02:00
xdp_umem_props.h xsk: new descriptor addressing scheme 2018-06-04 17:21:02 +02:00
xsk.c xsk: Fix umem fill/completion queue mmap on 32-bit 2018-06-08 00:18:02 +02:00
xsk_queue.c xsk: new descriptor addressing scheme 2018-06-04 17:21:02 +02:00
xsk_queue.h xsk: wire upp Tx zero-copy functions 2018-06-05 15:48:34 +02:00