1 /* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9 * or http://www.opensolaris.org/os/licensing. 10 * See the License for the specific language governing permissions 11 * and limitations under the License. 12 * 13 * When distributing Covered Code, include this CDDL HEADER in each 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15 * If applicable, add the following below this CDDL HEADER, with the 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 /* 22 * Copyright 2010 Sun Microsystems, Inc. All rights reserved. 23 * Use is subject to license terms. 24 */ 25 26 #include <sys/types.h> 27 #include <sys/cmn_err.h> 28 #include <sys/errno.h> 29 #include <sys/debug.h> 30 #include <vm/page.h> 31 #include <sys/mem_config.h> 32 #include <sys/mem_cage.h> 33 34 /* These should be in a platform stubs file. */ 35 36 int kcage_on; 37 kthread_id_t kcage_cageout_thread; 38 pgcnt_t kcage_freemem; 39 pgcnt_t kcage_throttlefree; 40 pgcnt_t kcage_minfree; 41 pgcnt_t kcage_desfree; 42 pgcnt_t kcage_needfree; 43 pgcnt_t kcage_lotsfree = 1; 44 45 #if !defined(__x86) || defined(__xpv) 46 /*ARGSUSED*/ 47 int 48 kphysm_setup_func_register(kphysm_setup_vector_t *vec, void *arg) 49 { 50 return (0); 51 } 52 53 /*ARGSUSED*/ 54 void 55 kphysm_setup_func_unregister(kphysm_setup_vector_t *vec, void *arg) 56 { 57 } 58 #endif 59 60 /*ARGSUSED*/ 61 int 62 kcage_create_throttle(pgcnt_t npages, int flags) 63 { 64 return (0); 65 } 66 67 void 68 kcage_cageout_init(void) 69 { 70 } 71 72 void 73 kcage_cageout_wakeup() 74 { 75 } 76 77 void 78 kcage_tick() 79 { 80 } 81 82 /*ARGSUSED*/ 83 int 84 kcage_current_pfn(pfn_t *pfn) 85 { 86 return (0); 87 } 88