···423424static int __change_page_attr(unsigned long address, struct cpa_data *cpa)425{0426 struct page *kpte_page;427- int level, do_split;428 pte_t *kpte;429430repeat:···476 * and just change the pte:477 */478 do_split = try_preserve_large_page(kpte, address, cpa);479- if (do_split < 0)480- return do_split;481-482 /*483 * When the range fits into the existing large page,484 * return. cp->numpages and cpa->tlbflush have been updated in485 * try_large_page:486 */487- if (do_split == 0)488- return 0;489490 /*491 * We have to split the large page:492 */493- do_split = split_large_page(kpte, address);494- if (do_split)495- return do_split;496- cpa->flushtlb = 1;0497498- goto repeat;499}500501/**
···423424static int __change_page_attr(unsigned long address, struct cpa_data *cpa)425{426+ int level, do_split, err;427 struct page *kpte_page;0428 pte_t *kpte;429430repeat:···476 * and just change the pte:477 */478 do_split = try_preserve_large_page(kpte, address, cpa);000479 /*480 * When the range fits into the existing large page,481 * return. cp->numpages and cpa->tlbflush have been updated in482 * try_large_page:483 */484+ if (do_split <= 0)485+ return do_split;486487 /*488 * We have to split the large page:489 */490+ err = split_large_page(kpte, address);491+ if (!err) {492+ cpa->flushtlb = 1;493+ goto repeat;494+ }495496+ return err;497}498499/**