PG_SLAB no longer serves a useful purpose, since m->object is no
longer abused to store pointer to slab. Remove it. Reviewed by: alc Sponsored by: The FreeBSD Foundation Approved by: re (hrs)
This commit is contained in:
parent
85fdd534cf
commit
9eab548476
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=255626
@ -404,15 +404,9 @@ static __inline uma_slab_t
|
|||||||
vtoslab(vm_offset_t va)
|
vtoslab(vm_offset_t va)
|
||||||
{
|
{
|
||||||
vm_page_t p;
|
vm_page_t p;
|
||||||
uma_slab_t slab;
|
|
||||||
|
|
||||||
p = PHYS_TO_VM_PAGE(pmap_kextract(va));
|
p = PHYS_TO_VM_PAGE(pmap_kextract(va));
|
||||||
slab = (uma_slab_t )p->plinks.s.pv;
|
return ((uma_slab_t)p->plinks.s.pv);
|
||||||
|
|
||||||
if (p->flags & PG_SLAB)
|
|
||||||
return (slab);
|
|
||||||
else
|
|
||||||
return (NULL);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static __inline void
|
static __inline void
|
||||||
@ -422,7 +416,6 @@ vsetslab(vm_offset_t va, uma_slab_t slab)
|
|||||||
|
|
||||||
p = PHYS_TO_VM_PAGE(pmap_kextract(va));
|
p = PHYS_TO_VM_PAGE(pmap_kextract(va));
|
||||||
p->plinks.s.pv = slab;
|
p->plinks.s.pv = slab;
|
||||||
p->flags |= PG_SLAB;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -968,8 +968,7 @@ vm_page_insert_after(vm_page_t m, vm_object_t object, vm_pindex_t pindex,
|
|||||||
KASSERT(m->object == NULL,
|
KASSERT(m->object == NULL,
|
||||||
("vm_page_insert_after: page already inserted"));
|
("vm_page_insert_after: page already inserted"));
|
||||||
if (mpred != NULL) {
|
if (mpred != NULL) {
|
||||||
KASSERT(mpred->object == object ||
|
KASSERT(mpred->object == object,
|
||||||
(mpred->flags & PG_SLAB) != 0,
|
|
||||||
("vm_page_insert_after: object doesn't contain mpred"));
|
("vm_page_insert_after: object doesn't contain mpred"));
|
||||||
KASSERT(mpred->pindex < pindex,
|
KASSERT(mpred->pindex < pindex,
|
||||||
("vm_page_insert_after: mpred doesn't precede pindex"));
|
("vm_page_insert_after: mpred doesn't precede pindex"));
|
||||||
@ -1019,8 +1018,7 @@ vm_page_insert_radixdone(vm_page_t m, vm_object_t object, vm_page_t mpred)
|
|||||||
KASSERT(object != NULL && m->object == object,
|
KASSERT(object != NULL && m->object == object,
|
||||||
("vm_page_insert_radixdone: page %p has inconsistent object", m));
|
("vm_page_insert_radixdone: page %p has inconsistent object", m));
|
||||||
if (mpred != NULL) {
|
if (mpred != NULL) {
|
||||||
KASSERT(mpred->object == object ||
|
KASSERT(mpred->object == object,
|
||||||
(mpred->flags & PG_SLAB) != 0,
|
|
||||||
("vm_page_insert_after: object doesn't contain mpred"));
|
("vm_page_insert_after: object doesn't contain mpred"));
|
||||||
KASSERT(mpred->pindex < m->pindex,
|
KASSERT(mpred->pindex < m->pindex,
|
||||||
("vm_page_insert_after: mpred doesn't precede pindex"));
|
("vm_page_insert_after: mpred doesn't precede pindex"));
|
||||||
|
@ -325,7 +325,6 @@ extern struct mtx_padalign pa_lock[];
|
|||||||
#define PG_FICTITIOUS 0x0004 /* physical page doesn't exist */
|
#define PG_FICTITIOUS 0x0004 /* physical page doesn't exist */
|
||||||
#define PG_ZERO 0x0008 /* page is zeroed */
|
#define PG_ZERO 0x0008 /* page is zeroed */
|
||||||
#define PG_MARKER 0x0010 /* special queue marker page */
|
#define PG_MARKER 0x0010 /* special queue marker page */
|
||||||
#define PG_SLAB 0x0020 /* object pointer is actually a slab */
|
|
||||||
#define PG_WINATCFLS 0x0040 /* flush dirty page on inactive q */
|
#define PG_WINATCFLS 0x0040 /* flush dirty page on inactive q */
|
||||||
#define PG_NODUMP 0x0080 /* don't include this page in a dump */
|
#define PG_NODUMP 0x0080 /* don't include this page in a dump */
|
||||||
#define PG_UNHOLDFREE 0x0100 /* delayed free of a held page */
|
#define PG_UNHOLDFREE 0x0100 /* delayed free of a held page */
|
||||||
|
@ -502,8 +502,7 @@ vm_reserv_alloc_page(vm_object_t object, vm_pindex_t pindex, vm_page_t mpred)
|
|||||||
* Look for an existing reservation.
|
* Look for an existing reservation.
|
||||||
*/
|
*/
|
||||||
if (mpred != NULL) {
|
if (mpred != NULL) {
|
||||||
KASSERT(mpred->object == object ||
|
KASSERT(mpred->object == object,
|
||||||
(mpred->flags & PG_SLAB) != 0,
|
|
||||||
("vm_reserv_alloc_page: object doesn't contain mpred"));
|
("vm_reserv_alloc_page: object doesn't contain mpred"));
|
||||||
KASSERT(mpred->pindex < pindex,
|
KASSERT(mpred->pindex < pindex,
|
||||||
("vm_reserv_alloc_page: mpred doesn't precede pindex"));
|
("vm_reserv_alloc_page: mpred doesn't precede pindex"));
|
||||||
|
Loading…
Reference in New Issue
Block a user