Re: 2.5.67-mm3

Andrew Morton
2003-04-15T04:31:14Z

William Lee Irwin III <wli@holomorphy.com> wrote:
>
> + for (; addr < (unsigned long)uaddr + size && !ret; addr += PAGE_SIZE)
> + ret = __put_user(0, (char *)max(addr, (unsigned long)uaddr));

This hurts my brain. If anything, it should be formulated as a do-while loop.

But I'm not sure we should really bother, because relatively large amounts of
stuff is broken for PAGE_SIZE != PAGE_CACHE_SIZE anyway. tmpfs comes to
mind...

If page clustering needs to redo this code (and I assume it does) then that
would be an argument in favour.