17c478bd9Sstevel@tonic-gate /* 27c478bd9Sstevel@tonic-gate * CDDL HEADER START 37c478bd9Sstevel@tonic-gate * 47c478bd9Sstevel@tonic-gate * The contents of this file are subject to the terms of the 57c478bd9Sstevel@tonic-gate * Common Development and Distribution License, Version 1.0 only 67c478bd9Sstevel@tonic-gate * (the "License"). You may not use this file except in compliance 77c478bd9Sstevel@tonic-gate * with the License. 87c478bd9Sstevel@tonic-gate * 97c478bd9Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 107c478bd9Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 117c478bd9Sstevel@tonic-gate * See the License for the specific language governing permissions 127c478bd9Sstevel@tonic-gate * and limitations under the License. 137c478bd9Sstevel@tonic-gate * 147c478bd9Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 157c478bd9Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 167c478bd9Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 177c478bd9Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 187c478bd9Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 197c478bd9Sstevel@tonic-gate * 207c478bd9Sstevel@tonic-gate * CDDL HEADER END 217c478bd9Sstevel@tonic-gate */ 227c478bd9Sstevel@tonic-gate /* 237c478bd9Sstevel@tonic-gate * Copyright 2005 Sun Microsystems, Inc. All rights reserved. 247c478bd9Sstevel@tonic-gate * Use is subject to license terms. 257c478bd9Sstevel@tonic-gate */ 267c478bd9Sstevel@tonic-gate 277c478bd9Sstevel@tonic-gate #ifndef _SYS_ERRCLASSIFY_H 287c478bd9Sstevel@tonic-gate #define _SYS_ERRCLASSIFY_H 297c478bd9Sstevel@tonic-gate 307c478bd9Sstevel@tonic-gate #pragma ident "%Z%%M% %I% %E% SMI" 317c478bd9Sstevel@tonic-gate 327c478bd9Sstevel@tonic-gate #ifdef __cplusplus 337c478bd9Sstevel@tonic-gate extern "C" { 347c478bd9Sstevel@tonic-gate #endif 357c478bd9Sstevel@tonic-gate 367c478bd9Sstevel@tonic-gate #ifndef _ASM 377c478bd9Sstevel@tonic-gate 387c478bd9Sstevel@tonic-gate #include <sys/errorq.h> 397c478bd9Sstevel@tonic-gate 407c478bd9Sstevel@tonic-gate /* 417c478bd9Sstevel@tonic-gate * Note that the order in the following must be kept in sync with that 427c478bd9Sstevel@tonic-gate * in the sun4u DE cmd_memerr.c and with the cetypes array of us3_common.c 437c478bd9Sstevel@tonic-gate */ 447c478bd9Sstevel@tonic-gate typedef enum { 457c478bd9Sstevel@tonic-gate /* 467c478bd9Sstevel@tonic-gate * The first byte (256 values) is for type and can be sequential. 477c478bd9Sstevel@tonic-gate */ 487c478bd9Sstevel@tonic-gate CE_DISP_UNKNOWN, 497c478bd9Sstevel@tonic-gate CE_DISP_INTERMITTENT, 507c478bd9Sstevel@tonic-gate CE_DISP_POSS_PERS, 517c478bd9Sstevel@tonic-gate CE_DISP_PERS, 527c478bd9Sstevel@tonic-gate CE_DISP_LEAKY, 537c478bd9Sstevel@tonic-gate CE_DISP_POSS_STICKY, 547c478bd9Sstevel@tonic-gate CE_DISP_STICKY, 557c478bd9Sstevel@tonic-gate /* 567c478bd9Sstevel@tonic-gate * The next byte encodes the next action as a bitmask 577c478bd9Sstevel@tonic-gate */ 587c478bd9Sstevel@tonic-gate CE_ACT_DONE = 0x100, 597c478bd9Sstevel@tonic-gate CE_ACT_LKYCHK = 0x200, 607c478bd9Sstevel@tonic-gate CE_ACT_PTNRCHK = 0x400, 617c478bd9Sstevel@tonic-gate /* 627c478bd9Sstevel@tonic-gate * Keep this as the last entry. Not all entries of the type lookup 637c478bd9Sstevel@tonic-gate * table are used and this value is the "uninitialized" pattern. 647c478bd9Sstevel@tonic-gate */ 657c478bd9Sstevel@tonic-gate CE_DISP_BAD = 0xbadbad1 667c478bd9Sstevel@tonic-gate } ce_dispact_t; 677c478bd9Sstevel@tonic-gate 687c478bd9Sstevel@tonic-gate /* 697c478bd9Sstevel@tonic-gate * Extract disposition or action from a ce_dispact_t 707c478bd9Sstevel@tonic-gate */ 717c478bd9Sstevel@tonic-gate #define CE_DISP(dispact) \ 727c478bd9Sstevel@tonic-gate (dispact & 0xff) 737c478bd9Sstevel@tonic-gate #define CE_ACT(dispact) \ 747c478bd9Sstevel@tonic-gate (dispact & 0xff00) 757c478bd9Sstevel@tonic-gate 767c478bd9Sstevel@tonic-gate /* 777c478bd9Sstevel@tonic-gate * Short string names for classification types. 787c478bd9Sstevel@tonic-gate */ 797c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_U "U" 807c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_I "I" 817c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_PP "PP" 827c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_P "P" 837c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_L "L" 847c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_PS "PS" 857c478bd9Sstevel@tonic-gate #define CE_DISP_DESC_S "S" 867c478bd9Sstevel@tonic-gate 877c478bd9Sstevel@tonic-gate /* 887c478bd9Sstevel@tonic-gate * Various sun4u CPU types use different Ecache state encodings. 897c478bd9Sstevel@tonic-gate * For CE classification the following unified scheme is used. 907c478bd9Sstevel@tonic-gate */ 917c478bd9Sstevel@tonic-gate #define EC_STATE_M 0x4 927c478bd9Sstevel@tonic-gate #define EC_STATE_O 0x3 937c478bd9Sstevel@tonic-gate #define EC_STATE_E 0x2 947c478bd9Sstevel@tonic-gate #define EC_STATE_S 0x1 957c478bd9Sstevel@tonic-gate #define EC_STATE_I 0x0 967c478bd9Sstevel@tonic-gate 977c478bd9Sstevel@tonic-gate /* 987c478bd9Sstevel@tonic-gate * Macros to generate the initial CE classification table (in both kernel and 997c478bd9Sstevel@tonic-gate * userland). An array size CE_INITDISPTBL_SIZE of ce_dispact_t should be 1007c478bd9Sstevel@tonic-gate * defined and passed by name to ECC_INITDISPTBL_POPULATE which will populate 1017c478bd9Sstevel@tonic-gate * the array slots that are use and set the unused ones to CE_DISP_BAD. 1027c478bd9Sstevel@tonic-gate * 1037c478bd9Sstevel@tonic-gate * To perform a lookup use CE_DISPACT passing the name of the same 1047c478bd9Sstevel@tonic-gate * array and the afarmatch, ecstate, ce1 and ce2 information. 1057c478bd9Sstevel@tonic-gate * 1067c478bd9Sstevel@tonic-gate * Other macros defined here should not be used directly. 1077c478bd9Sstevel@tonic-gate * 1087c478bd9Sstevel@tonic-gate * CE_INITDISPTBL_INDEX will generate an index as follows: 1097c478bd9Sstevel@tonic-gate * 1107c478bd9Sstevel@tonic-gate * <5> afar match 1117c478bd9Sstevel@tonic-gate * <4:2> line state 1127c478bd9Sstevel@tonic-gate * <1> ce2 - CE seen on lddphys of scrub algorithm (after writeback) 1137c478bd9Sstevel@tonic-gate * <0> ce1 - CE seen on CASXA of scrub algorithm (before writeback) 1147c478bd9Sstevel@tonic-gate * 1157c478bd9Sstevel@tonic-gate * When the afar does not match line state must be zero. 1167c478bd9Sstevel@tonic-gate */ 1177c478bd9Sstevel@tonic-gate #define CE_INITDISPTBL_SIZE (1 << 6) 1187c478bd9Sstevel@tonic-gate #define CE_INITDISPTBL_INDEX(afarmatch, ecstate, ce1, ce2) \ 1197c478bd9Sstevel@tonic-gate ((afarmatch) << 5 | (ecstate) << 2 | (ce2) << 1 | (ce1)) 1207c478bd9Sstevel@tonic-gate 1217c478bd9Sstevel@tonic-gate #define CE_DISPACT(array, afarmatch, ecstate, ce1, ce2) \ 1227c478bd9Sstevel@tonic-gate (array[CE_INITDISPTBL_INDEX(afarmatch, ecstate, ce1, ce2)]) 1237c478bd9Sstevel@tonic-gate 1247c478bd9Sstevel@tonic-gate #define CE_INITDISPTBL_POPULATE(a) \ 1257c478bd9Sstevel@tonic-gate { \ 1267c478bd9Sstevel@tonic-gate int i; \ 1277c478bd9Sstevel@tonic-gate for (i = 0; i < CE_INITDISPTBL_SIZE; ++i) \ 1287c478bd9Sstevel@tonic-gate a[i] = CE_DISP_BAD; \ 1297c478bd9Sstevel@tonic-gate /* \ 1307c478bd9Sstevel@tonic-gate * afar ec ce1 ce2 initial disp and next action \ 1317c478bd9Sstevel@tonic-gate * match state \ 1327c478bd9Sstevel@tonic-gate */ \ 1337c478bd9Sstevel@tonic-gate CE_DISPACT(a, 0, 0, 0, 0) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1347c478bd9Sstevel@tonic-gate CE_DISPACT(a, 0, 0, 0, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1357c478bd9Sstevel@tonic-gate CE_DISPACT(a, 0, 0, 1, 0) = CE_DISP_POSS_PERS | CE_ACT_LKYCHK; \ 1367c478bd9Sstevel@tonic-gate CE_DISPACT(a, 0, 0, 1, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1377c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_M, 0, 0) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1387c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_M, 0, 1) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1397c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_M, 1, 0) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1407c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_M, 1, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1417c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_O, 0, 0) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1427c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_O, 0, 1) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1437c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_O, 1, 0) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1447c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_O, 1, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1457c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_E, 0, 0) = CE_DISP_INTERMITTENT | CE_ACT_DONE; \ 1467c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_E, 0, 1) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1477c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_E, 1, 0) = CE_DISP_POSS_PERS | CE_ACT_LKYCHK; \ 1487c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_E, 1, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1497c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_S, 0, 0) = CE_DISP_INTERMITTENT | CE_ACT_DONE; \ 1507c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_S, 0, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1517c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_S, 1, 0) = CE_DISP_POSS_PERS | CE_ACT_LKYCHK; \ 1527c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_S, 1, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1537c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_I, 0, 0) = CE_DISP_UNKNOWN | CE_ACT_DONE; \ 1547c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_I, 0, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1557c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_I, 1, 0) = CE_DISP_POSS_PERS | CE_ACT_LKYCHK; \ 1567c478bd9Sstevel@tonic-gate CE_DISPACT(a, 1, EC_STATE_I, 1, 1) = CE_DISP_POSS_STICKY | CE_ACT_PTNRCHK; \ 1577c478bd9Sstevel@tonic-gate } 1587c478bd9Sstevel@tonic-gate 1597c478bd9Sstevel@tonic-gate #endif /* !_ASM */ 1607c478bd9Sstevel@tonic-gate 1617c478bd9Sstevel@tonic-gate /* 1627c478bd9Sstevel@tonic-gate * Legacy error type names corresponding to the flt_status bits 1637c478bd9Sstevel@tonic-gate */ 1647c478bd9Sstevel@tonic-gate #define ERR_TYPE_DESC_INTERMITTENT "Intermittent" 1657c478bd9Sstevel@tonic-gate #define ERR_TYPE_DESC_PERSISTENT "Persistent" 1667c478bd9Sstevel@tonic-gate #define ERR_TYPE_DESC_STICKY "Sticky" 1677c478bd9Sstevel@tonic-gate #define ERR_TYPE_DESC_UNKNOWN "Unknown" 1687c478bd9Sstevel@tonic-gate 1697c478bd9Sstevel@tonic-gate /* 1707c478bd9Sstevel@tonic-gate * flt_disp for a CE will record all scrub test data for the extended 1717c478bd9Sstevel@tonic-gate * classification attempt. 1727c478bd9Sstevel@tonic-gate * 1737c478bd9Sstevel@tonic-gate * -------------------------------------------------------------------------- 1747c478bd9Sstevel@tonic-gate * | | partner | | | leaky | partner | detector | 1757c478bd9Sstevel@tonic-gate * | partner id | type | - | skipcode | results | results | results | 1767c478bd9Sstevel@tonic-gate * |63 32|31 30| |27 24|23 16|15 8|7 0| 1777c478bd9Sstevel@tonic-gate * -------------------------------------------------------------------------- 1787c478bd9Sstevel@tonic-gate */ 1797c478bd9Sstevel@tonic-gate #define CE_XDIAG_DTCRMASK 0xffULL 1807c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRSHIFT 8 1817c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRMASK (0xffULL << CE_XDIAG_PTNRSHIFT) 1827c478bd9Sstevel@tonic-gate #define CE_XDIAG_LKYSHIFT 16 1837c478bd9Sstevel@tonic-gate #define CE_XDIAG_LKYMASK (0xffULL << CE_XDIAG_LKYSHIFT) 1847c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIPCODESHIFT 24 1857c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIPCODEMASK (0xfULL << CE_XDIAG_SKIPCODESHIFT) 1867c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRTYPESHIFT 30 1877c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRTYPEMASK (0x3ULL << CE_XDIAG_PTNRTYPESHIFT) 1887c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRIDSHIFT 32 1897c478bd9Sstevel@tonic-gate 1907c478bd9Sstevel@tonic-gate /* 1917c478bd9Sstevel@tonic-gate * Given a CE flt_disp set the given field 1927c478bd9Sstevel@tonic-gate */ 1937c478bd9Sstevel@tonic-gate #define CE_XDIAG_SETPTNRID(disp, id) \ 1947c478bd9Sstevel@tonic-gate ((disp) |= (uint64_t)(id) << CE_XDIAG_PTNRIDSHIFT) 1957c478bd9Sstevel@tonic-gate #define CE_XDIAG_SETPTNRTYPE(disp, type) \ 1967c478bd9Sstevel@tonic-gate ((disp) |= (uint64_t)type << CE_XDIAG_PTNRTYPESHIFT) 1977c478bd9Sstevel@tonic-gate #define CE_XDIAG_SETSKIPCODE(disp, code) \ 1987c478bd9Sstevel@tonic-gate ((disp) |= (uint64_t)code << CE_XDIAG_SKIPCODESHIFT) 1997c478bd9Sstevel@tonic-gate #define CE_XDIAG_SETLKYINFO(disp, result) \ 2007c478bd9Sstevel@tonic-gate ((disp) |= (uint64_t)result << CE_XDIAG_LKYSHIFT) 2017c478bd9Sstevel@tonic-gate #define CE_XDIAG_SETPTNRINFO(disp, result) \ 2027c478bd9Sstevel@tonic-gate ((disp) |= (uint64_t)result << CE_XDIAG_PTNRSHIFT) 2037c478bd9Sstevel@tonic-gate #define CE_XDIAG_SETDTCRINFO(disp, result) \ 2047c478bd9Sstevel@tonic-gate ((disp) |= (uint64_t)result) 2057c478bd9Sstevel@tonic-gate 2067c478bd9Sstevel@tonic-gate /* 2077c478bd9Sstevel@tonic-gate * Given a CE flt_disp extract the requested component 2087c478bd9Sstevel@tonic-gate */ 2097c478bd9Sstevel@tonic-gate #define CE_XDIAG_DTCRINFO(disp) ((disp) & CE_XDIAG_DTCRMASK) 2107c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRINFO(disp) (((disp) & CE_XDIAG_PTNRMASK) >> \ 2117c478bd9Sstevel@tonic-gate CE_XDIAG_PTNRSHIFT) 2127c478bd9Sstevel@tonic-gate #define CE_XDIAG_LKYINFO(disp) (((disp) & CE_XDIAG_LKYMASK) >> \ 2137c478bd9Sstevel@tonic-gate CE_XDIAG_LKYSHIFT) 2147c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIPCODE(disp) (((disp) & CE_XDIAG_SKIPCODEMASK) >> \ 2157c478bd9Sstevel@tonic-gate CE_XDIAG_SKIPCODESHIFT) 2167c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRTYPE(disp) (((disp) & CE_XDIAG_PTNRTYPEMASK) >> \ 2177c478bd9Sstevel@tonic-gate CE_XDIAG_PTNRTYPESHIFT) 2187c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNRID(disp) ((disp) >> CE_XDIAG_PTNRIDSHIFT) 2197c478bd9Sstevel@tonic-gate 2207c478bd9Sstevel@tonic-gate /* 2217c478bd9Sstevel@tonic-gate * Format of individual detector/partner/leaky test results. CE_XDIAG_EXTALG 2227c478bd9Sstevel@tonic-gate * in the detector case indicates that the extended classification algorithm 2237c478bd9Sstevel@tonic-gate * has been applied; common code uses this to distinguish between old and new. 2247c478bd9Sstevel@tonic-gate * In the partner check and leaky check cases CE_XDIAG_EXTALG is used to 2257c478bd9Sstevel@tonic-gate * indicate that the given test has run and recorded its results in its 2267c478bd9Sstevel@tonic-gate * result field. 2277c478bd9Sstevel@tonic-gate */ 2287c478bd9Sstevel@tonic-gate #define CE_XDIAG_STATE_MASK 0x7 /* Low 3 bits are for MOESI state */ 2297c478bd9Sstevel@tonic-gate #define CE_XDIAG_AFARMATCH 0x08 /* Line at e$ index matched AFAR */ 2307c478bd9Sstevel@tonic-gate #define CE_XDIAG_NOLOGOUT 0x10 /* Logout data unavailable */ 2317c478bd9Sstevel@tonic-gate #define CE_XDIAG_CE1 0x20 /* CE logged on casx during scrub */ 2327c478bd9Sstevel@tonic-gate #define CE_XDIAG_CE2 0x40 /* CE logged on post-scrub reread */ 2337c478bd9Sstevel@tonic-gate #define CE_XDIAG_EXTALG 0x80 /* Extended algorithm applied */ 2347c478bd9Sstevel@tonic-gate 2357c478bd9Sstevel@tonic-gate /* 2367c478bd9Sstevel@tonic-gate * Extract classification information for detector/partner. Expects 2377c478bd9Sstevel@tonic-gate * a value from one of CE_XDIAG_{DTCR,PTNR,LKY}_INFO. 2387c478bd9Sstevel@tonic-gate */ 2397c478bd9Sstevel@tonic-gate #define CE_XDIAG_AFARMATCHED(c) (((c) & CE_XDIAG_AFARMATCH) != 0) 2407c478bd9Sstevel@tonic-gate #define CE_XDIAG_LOGOUTVALID(c) (((c) & CE_XDIAG_NOLOGOUT) == 0) 2417c478bd9Sstevel@tonic-gate #define CE_XDIAG_CE1SEEN(c) (((c) & CE_XDIAG_CE1) != 0) 2427c478bd9Sstevel@tonic-gate #define CE_XDIAG_CE2SEEN(c) (((c) & CE_XDIAG_CE2) != 0) 2437c478bd9Sstevel@tonic-gate #define CE_XDIAG_STATE(c) (CE_XDIAG_AFARMATCHED(c) ? \ 2447c478bd9Sstevel@tonic-gate ((c) & CE_XDIAG_STATE_MASK) : 0) 2457c478bd9Sstevel@tonic-gate #define CE_XDIAG_EXT_ALG_APPLIED(c) (((c) & CE_XDIAG_EXTALG) != 0) 2467c478bd9Sstevel@tonic-gate 2477c478bd9Sstevel@tonic-gate /* 2487c478bd9Sstevel@tonic-gate * A leaky or partner test is considered valid if the line was not present 2497c478bd9Sstevel@tonic-gate * in cache, or was present but Invalid, at the time of the additional scrub. 2507c478bd9Sstevel@tonic-gate */ 2517c478bd9Sstevel@tonic-gate #define CE_XDIAG_TESTVALID(c) (CE_XDIAG_EXT_ALG_APPLIED(c) && \ 2527c478bd9Sstevel@tonic-gate (!CE_XDIAG_AFARMATCHED(c) || CE_XDIAG_STATE(c) == EC_STATE_I)) 2537c478bd9Sstevel@tonic-gate 2547c478bd9Sstevel@tonic-gate /* 2557c478bd9Sstevel@tonic-gate * Skipcodes - reasons for not applying extended diags; 4 bits 2567c478bd9Sstevel@tonic-gate */ 2577c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_NOPP 0x1 /* Can't lookup page pointer */ 2587c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_PAGEDET 0x2 /* Page deteriorating/retired */ 2597c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_NOTMEM 0x3 /* AFAR is not memory */ 2607c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_DUPFAIL 0x4 /* errorq recirculate failed */ 2617c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_NOPTNR 0x5 /* no suitable partner avail */ 2627c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_UNIPROC 0x6 /* test needs 2 or more cpus */ 2637c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_ACTBAD 0x7 /* bad action lookup - bug */ 2647c478bd9Sstevel@tonic-gate #define CE_XDIAG_SKIP_NOSCRUB 0x8 /* detector did not scrub */ 2657c478bd9Sstevel@tonic-gate 2667c478bd9Sstevel@tonic-gate /* 2677c478bd9Sstevel@tonic-gate * Partner type information. 2687c478bd9Sstevel@tonic-gate */ 2697c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNR_REMOTE 0x0 /* partner in different lgroup */ 2707c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNR_LOCAL 0x1 /* partner in same lgroup */ 2717c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNR_SIBLING 0x2 /* partner is a sibling core */ 2727c478bd9Sstevel@tonic-gate #define CE_XDIAG_PTNR_SELF 0x3 /* partnered self */ 2737c478bd9Sstevel@tonic-gate 2747c478bd9Sstevel@tonic-gate #ifdef __cplusplus 2757c478bd9Sstevel@tonic-gate } 2767c478bd9Sstevel@tonic-gate #endif 2777c478bd9Sstevel@tonic-gate 2787c478bd9Sstevel@tonic-gate #endif /* _SYS_ERRCLASSIFY_H */ 279