Skip to content

Commit

Permalink
xsk: relax UMEM headroom alignment
Browse files Browse the repository at this point in the history
This patch removes the 64B alignment of the UMEM headroom. There is
really no reason for it, and having a headroom less than 64B should be
valid.

Fixes: c0c77d8 ("xsk: add user memory registration support sockopt")
Signed-off-by: Björn Töpel <bjorn.topel@intel.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
  • Loading branch information
Björn Töpel authored and Daniel Borkmann committed Sep 19, 2019
1 parent a0791f0 commit 733ef7f
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions net/xdp/xdp_umem.c
Original file line number Diff line number Diff line change
Expand Up @@ -383,8 +383,6 @@ static int xdp_umem_reg(struct xdp_umem *umem, struct xdp_umem_reg *mr)
return -EINVAL;
}

headroom = ALIGN(headroom, 64);

size_chk = chunk_size - headroom - XDP_PACKET_HEADROOM;
if (size_chk < 0)
return -EINVAL;
Expand Down

0 comments on commit 733ef7f

Please sign in to comment.