git: 8cf307284f6c - stable/14 - LinuxKPI: add dev_alloc_pages()
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 22 Apr 2024 19:43:58 UTC
The branch stable/14 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=8cf307284f6c1508b5c075155c711a7d3a8dab39 commit 8cf307284f6c1508b5c075155c711a7d3a8dab39 Author: Bjoern A. Zeeb <bz@FreeBSD.org> AuthorDate: 2024-04-02 09:44:29 +0000 Commit: Bjoern A. Zeeb <bz@FreeBSD.org> CommitDate: 2024-04-22 16:59:45 +0000 LinuxKPI: add dev_alloc_pages() Add dev_alloc_pages() though it seems a weird KPI, not passing a dev despite its name. Used by updated wireless driver. Sponsored by: The FreeBSD Foundation Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D44588 (cherry picked from commit 738c02ba24c66391870067602f1c9c030d5c5e5d) --- sys/compat/linuxkpi/common/include/linux/gfp.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/gfp.h b/sys/compat/linuxkpi/common/include/linux/gfp.h index c5de09e896de..2fcc0dc05f29 100644 --- a/sys/compat/linuxkpi/common/include/linux/gfp.h +++ b/sys/compat/linuxkpi/common/include/linux/gfp.h @@ -138,6 +138,12 @@ __free_page(struct page *page) linux_free_pages(page, 0); } +static inline struct page * +dev_alloc_pages(unsigned int order) +{ + return (linux_alloc_pages(GFP_ATOMIC, order)); +} + /* * Page management for mapped pages: */