Re: [PATCH v2] mm: Fix possible off-by-one in walk_pte_range()

From: Mikael Pettersson
Date: Wed Apr 16 2008 - 03:50:23 EST


Johannes Weiner writes:
> From: Johannes Weiner <hannes@xxxxxxxxxxxx>
> Subject: [PATCH] mm: Fix possible off-by-one in walk_pte_range()
>
> After the loop in walk_pte_range() pte might point to the first address
> after the pmd it walks. The pte_unmap() is then applied to something
> bad.
>
> Spotted by Roel Kluin and Andreas Schwab.
>
> Signed-off-by: Johannes Weiner <hannes@xxxxxxxxxxxx>
> CC: Roel Kluin <12o3l@xxxxxxxxxx>
> CC: Andreas Schwab <schwab@xxxxxxx>
> CC: Matt Mackall <mpm@xxxxxxxxxxx>
> CC: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>

Thanks, v2 looks much nicer.

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