mem.h revision 915c848a88eb557ea392ee7f2fe90ade2edd1fd1
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
/*
* Copyright (c) 2015, Joyent, Inc. All rights reserved.
*/
#ifndef _SYS_MEM_H
#define _SYS_MEM_H
#ifdef __cplusplus
extern "C" {
#endif
/*
* Memory Device Minor Numbers
*/
/*
* Private ioctl for libkvm: translate virtual address to physical address.
*/
typedef struct mem_vtop {
void *m_va;
} mem_vtop_t;
#if defined(_SYSCALL32)
typedef struct mem_vtop32 {
} mem_vtop32_t;
#endif
/*
* Private ioctls for fmd(1M). These interfaces are Sun Private. Applications
* and drivers should not make use of these interfaces: they can change without
* notice and programs that consume them will fail to run on future releases.
*/
/*
* Bits returned from MEM_PAGE_GETERRORS ioctl for use by fmd(1M).
*/
#define MEM_PAGE_ERR_NONE 0x0
#define MEM_PAGE_ERR_MULTI_CE 0x1
#define MEM_PAGE_ERR_UE 0x2
#define MEM_PAGE_ERR_FMA_REQ 0x8
typedef struct mem_name {
} mem_name_t;
#if defined(_SYSCALL32)
typedef struct mem_name32 {
} mem_name32_t;
#endif /* _SYSCALL32 */
typedef struct mem_info {
int m_segments; /* # of segments */
int m_banks; /* # of banks in segment */
int m_mcid; /* associated memory controller id */
} mem_info_t;
#ifdef _KERNEL
typedef struct mm_logentry {
#endif /* _KERNEL */
#ifdef __cplusplus
}
#endif
#endif /* _SYS_MEM_H */