HomeFreeBSD

linuxkpi: Add some basic swap functions

Description

linuxkpi: Add some basic swap functions

These are used by kms-drm to determine various heuristics relate
memory conditions.

The number of free swap pages is just a variable, and it can be
much cheaper by either adding a new getter, or simply extern'ing
swap_total. However, this patch opts to use the more expensive,
existing interface - since this isn't an operation in a high per
path.

This allows us to remove some more gpl linuxkpi and do the follo
kms-drm:
git rm linuxkpi/gplv2/include/linux/swap.h

Reviewed by: mmacy, Johannes Lundberg <johalun0@gmail.com>
Approved by: emaste (mentor)
Differential Revision: https://reviews.freebsd.org/D18052

Details

Provenance
bwidawskAuthored on Nov 20 2018, 10:49 PM
Parents
rGedce78c2c444: Define AHCI_PORT_IDENT and increase by 1 the VTBLK_BLK_ID_BYTES
Branches
Unknown
Tags
Unknown