Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F103051313
D46063.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
5 KB
Referenced Files
None
Subscribers
None
D46063.diff
View Options
Index: ObsoleteFiles.inc
===================================================================
--- ObsoleteFiles.inc
+++ ObsoleteFiles.inc
@@ -51,6 +51,10 @@
# xargs -n1 | sort | uniq -d;
# done
+# 20240721: retire vm_page_alloc_freelist
+OLD_FILES+=usr/share/man/man9/vm_page_alloc_freelist.9.gz
+OLD_FILES+=usr/share/man/man9/vm_page_alloc_freelist_domain.9.gz
+
# 20240716: retire mergemaster
OLD_FILES+=usr/sbin/mergemaster
OLD_FILES+=usr/share/man/man8/mergemaster.8.gz
Index: share/man/man9/Makefile
===================================================================
--- share/man/man9/Makefile
+++ share/man/man9/Makefile
@@ -2384,8 +2384,6 @@
vm_page_alloc.9 vm_page_alloc_contig_domain.9 \
vm_page_alloc.9 vm_page_alloc_domain.9 \
vm_page_alloc.9 vm_page_alloc_domain_after.9 \
- vm_page_alloc.9 vm_page_alloc_freelist.9 \
- vm_page_alloc.9 vm_page_alloc_freelist_domain.9 \
vm_page_alloc.9 vm_page_alloc_noobj.9 \
vm_page_alloc.9 vm_page_alloc_noobj_contig.9 \
vm_page_alloc.9 vm_page_alloc_noobj_contig_domain.9 \
Index: share/man/man9/vm_page_alloc.9
===================================================================
--- share/man/man9/vm_page_alloc.9
+++ share/man/man9/vm_page_alloc.9
@@ -28,7 +28,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
.\" DAMAGE.
.\"
-.Dd November 11, 2021
+.Dd July 21, 2024
.Dt VM_PAGE_ALLOC 9
.Os
.Sh NAME
@@ -87,17 +87,6 @@
.Fa "vm_page_t mpred"
.Fc
.Ft vm_page_t
-.Fo vm_page_alloc_freelist
-.Fa "int freelist"
-.Fa "int req"
-.Fc
-.Ft vm_page_t
-.Fo vm_page_alloc_freelist_domain
-.Fa "int domain"
-.Fa "int freelist"
-.Fa "int req"
-.Fc
-.Ft vm_page_t
.Fo vm_page_alloc_noobj
.Fa "int req"
.Fc
@@ -212,19 +201,6 @@
will carry the machine-dependent encoding of the memory attribute.
Additionally, the direct mapping of the page, if any, will be updated to
reflect the requested memory attribute.
-.Pp
-The
-.Fn vm_page_alloc_freelist
-and
-.Fn vm_page_alloc_freelist_domain
-functions behave identically to
-.Fn vm_page_alloc_noobj
-and
-.Fn vm_page_alloc_noobj_domain ,
-respectively, except that a successful allocation will return a page from the
-specified physical memory freelist.
-These functions are not intended for use outside of the virtual memory
-subsystem and exist only to support the requirements of certain platforms.
.Sh REQUEST FLAGS
All page allocator functions accept a
.Fa req
Index: sys/vm/vm_page.h
===================================================================
--- sys/vm/vm_page.h
+++ sys/vm/vm_page.h
@@ -614,8 +614,6 @@
vm_pindex_t pindex, int domain, int req, u_long npages, vm_paddr_t low,
vm_paddr_t high, u_long alignment, vm_paddr_t boundary,
vm_memattr_t memattr);
-vm_page_t vm_page_alloc_freelist(int, int);
-vm_page_t vm_page_alloc_freelist_domain(int, int, int);
vm_page_t vm_page_alloc_noobj(int);
vm_page_t vm_page_alloc_noobj_domain(int, int);
vm_page_t vm_page_alloc_noobj_contig(int req, u_long npages, vm_paddr_t low,
Index: sys/vm/vm_page.c
===================================================================
--- sys/vm/vm_page.c
+++ sys/vm/vm_page.c
@@ -2406,11 +2406,10 @@
/*
* Allocate a physical page that is not intended to be inserted into a VM
- * object. If the "freelist" parameter is not equal to VM_NFREELIST, then only
- * pages from the specified vm_phys freelist will be returned.
+ * object.
*/
-static __always_inline vm_page_t
-_vm_page_alloc_noobj_domain(int domain, const int freelist, int req)
+vm_page_t
+vm_page_alloc_noobj_domain(int domain, int req)
{
struct vm_domain *vmd;
vm_page_t m;
@@ -2426,8 +2425,7 @@
flags = (req & VM_ALLOC_NODUMP) != 0 ? PG_NODUMP : 0;
vmd = VM_DOMAIN(domain);
again:
- if (freelist == VM_NFREELIST &&
- vmd->vmd_pgcache[VM_FREEPOOL_DIRECT].zone != NULL) {
+ if (vmd->vmd_pgcache[VM_FREEPOOL_DIRECT].zone != NULL) {
m = uma_zalloc(vmd->vmd_pgcache[VM_FREEPOOL_DIRECT].zone,
M_NOWAIT | M_NOVM);
if (m != NULL) {
@@ -2438,17 +2436,12 @@
if (vm_domain_allocate(vmd, req, 1)) {
vm_domain_free_lock(vmd);
- if (freelist == VM_NFREELIST)
- m = vm_phys_alloc_pages(domain, VM_FREEPOOL_DIRECT, 0);
- else
- m = vm_phys_alloc_freelist_pages(domain, freelist,
- VM_FREEPOOL_DIRECT, 0);
+ m = vm_phys_alloc_pages(domain, VM_FREEPOOL_DIRECT, 0);
vm_domain_free_unlock(vmd);
if (m == NULL) {
vm_domain_freecnt_inc(vmd, 1);
#if VM_NRESERVLEVEL > 0
- if (freelist == VM_NFREELIST &&
- vm_reserv_reclaim_inactive(domain))
+ if (vm_reserv_reclaim_inactive(domain))
goto again;
#endif
}
@@ -2482,32 +2475,6 @@
return (m);
}
-vm_page_t
-vm_page_alloc_freelist(int freelist, int req)
-{
- struct vm_domainset_iter di;
- vm_page_t m;
- int domain;
-
- vm_domainset_iter_page_init(&di, NULL, 0, &domain, &req);
- do {
- m = vm_page_alloc_freelist_domain(domain, freelist, req);
- if (m != NULL)
- break;
- } while (vm_domainset_iter_page(&di, NULL, &domain) == 0);
-
- return (m);
-}
-
-vm_page_t
-vm_page_alloc_freelist_domain(int domain, int freelist, int req)
-{
- KASSERT(freelist >= 0 && freelist < VM_NFREELIST,
- ("%s: invalid freelist %d", __func__, freelist));
-
- return (_vm_page_alloc_noobj_domain(domain, freelist, req));
-}
-
vm_page_t
vm_page_alloc_noobj(int req)
{
@@ -2525,12 +2492,6 @@
return (m);
}
-vm_page_t
-vm_page_alloc_noobj_domain(int domain, int req)
-{
- return (_vm_page_alloc_noobj_domain(domain, VM_NFREELIST, req));
-}
-
vm_page_t
vm_page_alloc_noobj_contig(int req, u_long npages, vm_paddr_t low,
vm_paddr_t high, u_long alignment, vm_paddr_t boundary,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Nov 21, 7:22 AM (22 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14756828
Default Alt Text
D46063.diff (5 KB)
Attached To
Mode
D46063: vm: Retire vm_page_alloc_freelist{,_domain}()
Attached
Detach File
Event Timeline
Log In to Comment