On Sat, Dec 19, 2020 at 05:04:33PM +, Kalesh Singh wrote:
> When `next < old_addr`, `next - old_addr` arithmetic underflows
> causing `extent` to be incorrect.
>
> Make `extent` the smaller of `next - old_addr` or `old_end - old_addr`.
>
> Reported-by: Guenter Roeck
> Signed-off-by: Kalesh S
When `next < old_addr`, `next - old_addr` arithmetic underflows
causing `extent` to be incorrect.
Make `extent` the smaller of `next - old_addr` or `old_end - old_addr`.
Reported-by: Guenter Roeck
Signed-off-by: Kalesh Singh
---
mm/mremap.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion
2 matches
Mail list logo