[PATCH AUTOSEL for 4.4 099/101] RDMA/cma: Avoid triggering undefined behavior

2017-12-07 Thread alexander . levin
From: Bart Van Assche [ Upstream commit c0b64f58e8d49570aa9ee55d880f92c20ff0166b ] According to the C standard the behavior of computations with integer operands is as follows: * A computation involving unsigned operands can never overflow, because a result that cannot

[PATCH AUTOSEL for 4.4 099/101] RDMA/cma: Avoid triggering undefined behavior

2017-12-07 Thread alexander . levin
From: Bart Van Assche [ Upstream commit c0b64f58e8d49570aa9ee55d880f92c20ff0166b ] According to the C standard the behavior of computations with integer operands is as follows: * A computation involving unsigned operands can never overflow, because a result that cannot be represented by the