From: Scott Wood Date: Fri, 22 Nov 2013 00:26:42 +0000 (-0600) Subject: powerpc/booke: Only check for hugetlb in flush if vma != NULL X-Git-Tag: v3.13-rc2~23^2~6^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d742aa152f27448d39ce65fb829e396d10cd63a9;p=pandora-kernel.git powerpc/booke: Only check for hugetlb in flush if vma != NULL And in flush_hugetlb_page(), don't check whether vma is NULL after we've already dereferenced it. This was found by Dan using static analysis as described here: https://lists.ozlabs.org/pipermail/linuxppc-dev/2013-November/113161.html We currently get away with this because the callers that currently pass NULL for vma seem to be 32-bit-only (e.g. highmem, and CONFIG_DEBUG_PGALLOC in pgtable_32.c) Hugetlb is currently 64-bit only, so we never saw a NULL vma here. Signed-off-by: Scott Wood Reported-by: Dan Carpenter --- Reading git-diff-tree failed