Page MenuHomeFreeBSD

vm_object: drop unnecessary vm_object.h header
ClosedPublic

Authored by dougm on Apr 30 2025, 7:05 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Oct 13, 10:41 PM
Unknown Object (File)
Tue, Sep 30, 4:24 PM
Unknown Object (File)
Sep 5 2025, 12:38 PM
Unknown Object (File)
Aug 30 2025, 9:49 AM
Unknown Object (File)
Aug 26 2025, 1:37 PM
Unknown Object (File)
Aug 15 2025, 3:09 PM
Unknown Object (File)
Aug 12 2025, 1:46 PM
Unknown Object (File)
Aug 6 2025, 8:03 AM
Subscribers

Details

Summary

The header vm_object.h is included in vm_phys.h and uma_core.h, where it is not necessary. Remove it.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dougm requested review of this revision.Apr 30 2025, 7:05 AM
dougm created this revision.

Did you checked that vm/vm_object.h does not get pulled through any other header? E.g. you can add a temporal fragment like

#ifdef _VM_OBJECT_
#error "vm/vm_object.h still included"
#endif

to these two .c files to be sure.

This revision is now accepted and ready to land.Apr 30 2025, 8:12 AM
In D50081#1142343, @kib wrote:

Did you checked that vm/vm_object.h does not get pulled through any other header?

I ran this command:

:src $ grep -r --include=*.[h] vm_object.h .
./sys/compat/linuxkpi/common/include/linux/list.h:#include <vm/vm_object.h>
./sys/compat/linuxkpi/common/include/linux/gfp.h:#include <vm/vm_object.h>
./sys/contrib/openzfs/include/os/freebsd/spl/sys/vnode.h:#include <vm/vm_object.h>
./sys/contrib/openzfs/include/os/freebsd/zfs/sys/zfs_znode_impl.h:#include <vm/vm_object.h>
./sys/dev/drm2/drmP.h:#include <vm/vm_object.h>
./sys/fs/nfs/nfsport.h:#include <vm/vm_object.h>

and concluded that neither of these files was including a file that included vm_object.h.

vm_phys.h and uma_core.h

Presumably you meant .c.

This revision was automatically updated to reflect the committed changes.