- Revert previous change of atm storage pools -> uma_zones until a solution
to atm_free() is written.
This commit is contained in:
parent
ad5ada62ef
commit
b148c4db98
@ -709,7 +709,7 @@ atm_cm_listen(epp, token, ap, copp)
|
||||
/*
|
||||
* Get an attribute block and save listening attributes
|
||||
*/
|
||||
cop->co_lattr = uma_zalloc(atm_attributes_zone, 0);
|
||||
cop->co_lattr = (Atm_attributes *)atm_allocate(&atm_attributes_pool);
|
||||
if (cop->co_lattr == NULL) {
|
||||
err = ENOMEM;
|
||||
goto done;
|
||||
|
@ -79,7 +79,13 @@ int atm_print_data = 0;
|
||||
int atm_version = ATM_VERSION;
|
||||
struct timeval atm_debugtime = {0, 0};
|
||||
|
||||
uma_zone_t atm_attributes_zone;
|
||||
struct sp_info atm_attributes_pool = {
|
||||
"atm attributes pool", /* si_name */
|
||||
sizeof(Atm_attributes), /* si_blksiz */
|
||||
10, /* si_blkcnt */
|
||||
100 /* si_maxallow */
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
* Local functions
|
||||
@ -93,7 +99,13 @@ static KTimeout_ret atm_timexp(void *);
|
||||
static struct atm_time *atm_timeq = NULL;
|
||||
static struct atm_time atm_compactimer = {0, 0};
|
||||
|
||||
static uma_zone_t atm_stackq_zone;
|
||||
static struct sp_info atm_stackq_pool = {
|
||||
"Service stack queue pool", /* si_name */
|
||||
sizeof(struct stackq_entry), /* si_blksiz */
|
||||
10, /* si_blkcnt */
|
||||
10 /* si_maxallow */
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
* Initialize ATM kernel
|
||||
@ -123,17 +135,6 @@ atm_initialize()
|
||||
mtx_init(&atm_intrq.ifq_mtx, "atm_inq", NULL, MTX_DEF);
|
||||
atmintrq_present = 1;
|
||||
|
||||
atm_attributes_zone = uma_zcreate("atm_attributes",
|
||||
sizeof(Atm_attributes), (uma_ctor)&atm_uma_ctor, NULL, NULL, NULL,
|
||||
UMA_ALIGN_PTR, 0);
|
||||
uma_zone_set_max(atm_attributes_zone, 100);
|
||||
|
||||
atm_stackq_zone = uma_zcreate("atm_stackq",
|
||||
sizeof(struct stackq_entry), (uma_ctor)&atm_uma_ctor, NULL, NULL,
|
||||
NULL,
|
||||
UMA_ALIGN_PTR, 0);
|
||||
uma_zone_set_max(atm_stackq_zone, 10);
|
||||
|
||||
register_netisr(NETISR_ATM, atm_intr);
|
||||
|
||||
/*
|
||||
@ -745,7 +746,7 @@ atm_stack_enq(cmd, func, token, cvp, arg1, arg2)
|
||||
/*
|
||||
* Get a new queue entry for this call
|
||||
*/
|
||||
sqp = uma_zalloc(atm_stackq_zone, 0);
|
||||
sqp = (struct stackq_entry *)atm_allocate(&atm_stackq_pool);
|
||||
if (sqp == NULL) {
|
||||
(void) splx(s);
|
||||
return (ENOMEM);
|
||||
|
@ -40,9 +40,6 @@
|
||||
|
||||
|
||||
#ifdef _KERNEL
|
||||
|
||||
#include <vm/uma.h>
|
||||
|
||||
/*
|
||||
* Global variable declarations
|
||||
*/
|
||||
@ -66,7 +63,7 @@ extern int atm_debug;
|
||||
extern struct timeval atm_debugtime;
|
||||
extern int atm_dev_print;
|
||||
extern int atm_print_data;
|
||||
extern uma_zone_t atm_attributes_zone;
|
||||
extern struct sp_info atm_attributes_pool;
|
||||
|
||||
extern struct pr_usrreqs atm_dgram_usrreqs;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user