Changeset View
Changeset View
Standalone View
Standalone View
sys/kern/kern_mbuf.c
Show All 28 Lines | |||||
#include <sys/cdefs.h> | #include <sys/cdefs.h> | ||||
__FBSDID("$FreeBSD$"); | __FBSDID("$FreeBSD$"); | ||||
#include "opt_param.h" | #include "opt_param.h" | ||||
#include <sys/param.h> | #include <sys/param.h> | ||||
#include <sys/conf.h> | #include <sys/conf.h> | ||||
#include <sys/domainset.h> | |||||
#include <sys/malloc.h> | #include <sys/malloc.h> | ||||
#include <sys/systm.h> | #include <sys/systm.h> | ||||
#include <sys/mbuf.h> | #include <sys/mbuf.h> | ||||
#include <sys/domain.h> | #include <sys/domain.h> | ||||
#include <sys/eventhandler.h> | #include <sys/eventhandler.h> | ||||
#include <sys/kernel.h> | #include <sys/kernel.h> | ||||
#include <sys/limits.h> | #include <sys/limits.h> | ||||
#include <sys/lock.h> | #include <sys/lock.h> | ||||
▲ Show 20 Lines • Show All 540 Lines • ▼ Show 20 Lines | |||||
*/ | */ | ||||
static void * | static void * | ||||
mbuf_jumbo_alloc(uma_zone_t zone, vm_size_t bytes, int domain, uint8_t *flags, | mbuf_jumbo_alloc(uma_zone_t zone, vm_size_t bytes, int domain, uint8_t *flags, | ||||
int wait) | int wait) | ||||
{ | { | ||||
/* Inform UMA that this allocator uses kernel_map/object. */ | /* Inform UMA that this allocator uses kernel_map/object. */ | ||||
*flags = UMA_SLAB_KERNEL; | *flags = UMA_SLAB_KERNEL; | ||||
return ((void *)kmem_alloc_contig_domain(domain, bytes, wait, | return ((void *)kmem_alloc_contig_domainset(DOMAINSET_FIXED(domain), | ||||
(vm_paddr_t)0, ~(vm_paddr_t)0, 1, 0, VM_MEMATTR_DEFAULT)); | bytes, wait, (vm_paddr_t)0, ~(vm_paddr_t)0, 1, 0, | ||||
VM_MEMATTR_DEFAULT)); | |||||
} | } | ||||
/* | /* | ||||
* Constructor for Mbuf master zone. | * Constructor for Mbuf master zone. | ||||
* | * | ||||
* The 'arg' pointer points to a mb_args structure which | * The 'arg' pointer points to a mb_args structure which | ||||
* contains call-specific information required to support the | * contains call-specific information required to support the | ||||
* mbuf allocation API. See mbuf.h. | * mbuf allocation API. See mbuf.h. | ||||
▲ Show 20 Lines • Show All 543 Lines • Show Last 20 Lines |