Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adjust to recent user page API changes
4.6.0 basically renamed get_user_pages() to get_user_pages_remote() and introduced a new get_user_pages() that always works on the current task.[1] Distinguish the two APIs based on kernel version we're compiling for. Also, there seems to have been a massive cleansing of page_cache_release(page) in favour of put_page(page)[2] which was an alias for put_page(page)[3] since 2.6.0. Before that beginning with 2.4.0 both page_cache_release(page) and put_page(page) have been aliases for __free_page(page). So using put_page() instead of page_cache_release(page) will produce identical code for anything after 2.4.0. [1] https://lkml.org/lkml/2016/2/10/555 [2] https://www.spinics.net/lists/linux-fsdevel/msg95923.html [3] https://www.spinics.net/lists/linux-fsdevel/msg95922.html
- Loading branch information