Re: [PATCH 6/6] lib/scatterlist: Fix overflow check in sgl_alloc_order

Bart Van Assche
2018-10-03T15:35:01Z

> It is necessary to ensure types on both sides of the comparison are of the
> same width. Otherwise the check overflows sooner than expect due left hand
> side being an unsigned long length, and the right hand side unsigned int
> number of elements multiplied by element size.

Reviewed-by: Bart Van Assche <bvanassche@acm.org>