From: Leon Romanovsky <leonro@xxxxxxxxxxxx> Hi, This is the outcome from the following discussion [1]. Changes: * Reuse implementation agreed by Jason and Rasmus * Added test (maybe not full, but good enough) * Updated mlx5 code to use new helper. Thanks [1] https://lore.kernel.org/lkml/20180624082353.16138-9-leon@xxxxxxxxxx/ Jason Gunthorpe (1): overflow.h: Add arithmetic shift helper Leon Romanovsky (2): test_overflow: Add shift overflow tests RDMA/mlx5: Fix shift overflow in mlx5_ib_create_wq drivers/infiniband/hw/mlx5/qp.c | 5 +- include/linux/overflow.h | 23 +++ lib/test_overflow.c | 351 ++++++++++++++++++++-------------------- 3 files changed, 204 insertions(+), 175 deletions(-) -- 2.14.4 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html