]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm, hugetlb: move the error handle logic out of normal code path
authorJianyu Zhan <nasa4836@gmail.com>
Thu, 22 May 2014 00:43:24 +0000 (10:43 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 22 May 2014 00:43:24 +0000 (10:43 +1000)
commit2924506bb3f6c9223f971f4d5aecb14e014c8dbe
tree49d2d534181118470c7a2370030e8fd800978e77
parentcded1637108ea2ccb2ab67fba4cd925300fd6054
mm, hugetlb: move the error handle logic out of normal code path

alloc_huge_page() now mixes normal code path with error handle logic.
This patches move out the error handle logic, to make normal code path
more clean and redue code duplicate.

Signed-off-by: Jianyu Zhan <nasa4836@gmail.com>
Acked-by: Davidlohr Bueso <davidlohr@hp.com>
Reviewed-by: Michal Hocko <mhocko@suse.cz>
Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/hugetlb.c