Re: 2.5.67-mm3

From: Andrew Morton (akpm@digeo.com)
Date: Mon Apr 14 2003 - 23:31:14 EST


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.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Apr 15 2003 - 22:00:34 EST