File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -1207,7 +1207,7 @@ static long __get_user_pages(struct mm_struct *mm,
12071207 if (!vma && in_gate_area (mm , start )) {
12081208 ret = get_gate_page (mm , start & PAGE_MASK ,
12091209 gup_flags , & vma ,
1210- pages ? & pages [ i ] : NULL );
1210+ pages ? & page : NULL );
12111211 if (ret )
12121212 goto out ;
12131213 ctx .page_mask = 0 ;
@@ -1277,19 +1277,18 @@ static long __get_user_pages(struct mm_struct *mm,
12771277 ret = PTR_ERR (page );
12781278 goto out ;
12791279 }
1280-
1281- goto next_page ;
12821280 } else if (IS_ERR (page )) {
12831281 ret = PTR_ERR (page );
12841282 goto out ;
12851283 }
1284+ next_page :
12861285 if (pages ) {
12871286 pages [i ] = page ;
12881287 flush_anon_page (vma , page , start );
12891288 flush_dcache_page (page );
12901289 ctx .page_mask = 0 ;
12911290 }
1292- next_page :
1291+
12931292 page_increm = 1 + (~(start >> PAGE_SHIFT ) & ctx .page_mask );
12941293 if (page_increm > nr_pages )
12951294 page_increm = nr_pages ;
You can’t perform that action at this time.
0 commit comments