1*4581Ssherrym /* 2*4581Ssherrym * CDDL HEADER START 3*4581Ssherrym * 4*4581Ssherrym * The contents of this file are subject to the terms of the 5*4581Ssherrym * Common Development and Distribution License (the "License"). 6*4581Ssherrym * You may not use this file except in compliance with the License. 7*4581Ssherrym * 8*4581Ssherrym * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9*4581Ssherrym * or http://www.opensolaris.org/os/licensing. 10*4581Ssherrym * See the License for the specific language governing permissions 11*4581Ssherrym * and limitations under the License. 12*4581Ssherrym * 13*4581Ssherrym * When distributing Covered Code, include this CDDL HEADER in each 14*4581Ssherrym * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15*4581Ssherrym * If applicable, add the following below this CDDL HEADER, with the 16*4581Ssherrym * fields enclosed by brackets "[]" replaced with your own identifying 17*4581Ssherrym * information: Portions Copyright [yyyy] [name of copyright owner] 18*4581Ssherrym * 19*4581Ssherrym * CDDL HEADER END 20*4581Ssherrym */ 21*4581Ssherrym 22*4581Ssherrym /* 23*4581Ssherrym * Copyright 2007 Sun Microsystems, Inc. All rights reserved. 24*4581Ssherrym * Use is subject to license terms. 25*4581Ssherrym */ 26*4581Ssherrym 27*4581Ssherrym #ifndef _UCODE_ERRNO_H 28*4581Ssherrym #define _UCODE_ERRNO_H 29*4581Ssherrym 30*4581Ssherrym #pragma ident "%Z%%M% %I% %E% SMI" 31*4581Ssherrym 32*4581Ssherrym #ifdef __cplusplus 33*4581Ssherrym extern "C" { 34*4581Ssherrym #endif 35*4581Ssherrym 36*4581Ssherrym typedef enum ucode_errno { 37*4581Ssherrym EM_OK, /* No error */ 38*4581Ssherrym EM_FILESIZE, /* File size is invalid */ 39*4581Ssherrym EM_OPENFILE, /* Failed to open file */ 40*4581Ssherrym EM_FILEFORMAT, /* Not a valid microcode file */ 41*4581Ssherrym EM_HEADER, /* File header is invalid */ 42*4581Ssherrym EM_CHECKSUM, /* Checksum is invalid */ 43*4581Ssherrym EM_INVALIDARG, /* Invalid argument(s) */ 44*4581Ssherrym EM_NOMATCH, /* No matching microcode found */ 45*4581Ssherrym EM_HIGHERREV, /* File does not contain higher revision microcode */ 46*4581Ssherrym EM_NOTSUP, /* Processor does not support microcode operations */ 47*4581Ssherrym EM_UPDATE, /* Failed to update to the latest revision */ 48*4581Ssherrym EM_SYS, /* System call failed. See errno */ 49*4581Ssherrym EM_NOVENDOR, /* File must start with vendor string */ 50*4581Ssherrym EM_NOMEM /* Not enough memory */ 51*4581Ssherrym } ucode_errno_t; 52*4581Ssherrym 53*4581Ssherrym extern const char *ucode_strerror(ucode_errno_t); 54*4581Ssherrym extern const char *ucode_errname(ucode_errno_t); 55*4581Ssherrym 56*4581Ssherrym #ifdef __cplusplus 57*4581Ssherrym } 58*4581Ssherrym #endif 59*4581Ssherrym 60*4581Ssherrym #endif /* _UCODE_ERRNO_H */ 61