Re: [PATCH] mm: Fail when offset == num in first check of vm_map_pages_zero()

2019-06-01 Thread Miguel Ojeda
On Wed, May 29, 2019 at 9:09 AM Souptick Joarder wrote: > > On Wed, May 29, 2019 at 1:38 AM Miguel Ojeda > wrote: > > > > If the user asks us for offset == num, we should already fail in the > > first check, i.e. the one testing for offsets beyond the object. > > > > At the moment, we are failing

Re: [PATCH] mm: Fail when offset == num in first check of vm_map_pages_zero()

2019-05-29 Thread Souptick Joarder
On Wed, May 29, 2019 at 1:38 AM Miguel Ojeda wrote: > > If the user asks us for offset == num, we should already fail in the > first check, i.e. the one testing for offsets beyond the object. > > At the moment, we are failing on the second test anyway, > since count cannot be 0. Still, to agree wi

[PATCH] mm: Fail when offset == num in first check of vm_map_pages_zero()

2019-05-28 Thread Miguel Ojeda
If the user asks us for offset == num, we should already fail in the first check, i.e. the one testing for offsets beyond the object. At the moment, we are failing on the second test anyway, since count cannot be 0. Still, to agree with the comment of the first test, we should first there. Signed