1/**************************************************************************** 2 **************************************************************************** 3 *** 4 *** This header was automatically generated from a Linux kernel header 5 *** of the same name, to make information necessary for userspace to 6 *** call into the kernel available to libc. It contains only constants, 7 *** structures, and macros generated from the original header, and thus, 8 *** contains no copyrightable information. 9 *** 10 *** To edit the content of this header, modify the corresponding 11 *** source file (e.g. under external/kernel-headers/original/) then 12 *** run bionic/libc/kernel/tools/update_all.py 13 *** 14 *** Any manual change here will be lost the next time this script will 15 *** be run. You've been warned! 16 *** 17 **************************************************************************** 18 ****************************************************************************/ 19#ifndef _ASM_SGI_SN0_HUBNI_H 20#define _ASM_SGI_SN0_HUBNI_H 21#ifndef __ASSEMBLY__ 22#include <linux/types.h> 23/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 24#endif 25#define NI_BASE 0x600000 26#define NI_BASE_TABLES 0x630000 27#define NI_STATUS_REV_ID 0x600000 28/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 29#define NI_PORT_RESET 0x600008 30#define NI_PROTECTION 0x600010 31#define NI_GLOBAL_PARMS 0x600018 32#define NI_SCRATCH_REG0 0x600100 33/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 34#define NI_SCRATCH_REG1 0x600108 35#define NI_DIAG_PARMS 0x600110 36#define NI_VECTOR_PARMS 0x600200 37#define NI_VECTOR 0x600208 38/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 39#define NI_VECTOR_DATA 0x600210 40#define NI_VECTOR_STATUS 0x600300 41#define NI_RETURN_VECTOR 0x600308 42#define NI_VECTOR_READ_DATA 0x600310 43/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 44#define NI_VECTOR_CLEAR 0x600380 45#define NI_IO_PROTECT 0x600400 46#define NI_IO_PROT_OVRRD 0x600408 47#define NI_AGE_CPU0_MEMORY 0x600500 48/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 49#define NI_AGE_CPU0_PIO 0x600508 50#define NI_AGE_CPU1_MEMORY 0x600510 51#define NI_AGE_CPU1_PIO 0x600518 52#define NI_AGE_GBR_MEMORY 0x600520 53/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 54#define NI_AGE_GBR_PIO 0x600528 55#define NI_AGE_IO_MEMORY 0x600530 56#define NI_AGE_IO_PIO 0x600538 57#define NI_AGE_REG_MIN NI_AGE_CPU0_MEMORY 58/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 59#define NI_AGE_REG_MAX NI_AGE_IO_PIO 60#define NI_PORT_PARMS 0x608000 61#define NI_PORT_ERROR 0x608008 62#define NI_PORT_ERROR_CLEAR 0x608088 63/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 64#define NI_META_TABLE0 0x638000 65#define NI_META_TABLE(_x) (NI_META_TABLE0 + (8 * (_x))) 66#define NI_META_ENTRIES 32 67#define NI_LOCAL_TABLE0 0x638100 68/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 69#define NI_LOCAL_TABLE(_x) (NI_LOCAL_TABLE0 + (8 * (_x))) 70#define NI_LOCAL_ENTRIES 16 71#define NSRI_8BITMODE_SHFT 30 72#define NSRI_8BITMODE_MASK (UINT64_CAST 0x1 << 30) 73/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 74#define NSRI_LINKUP_SHFT 29 75#define NSRI_LINKUP_MASK (UINT64_CAST 0x1 << 29) 76#define NSRI_DOWNREASON_SHFT 28 77#define NSRI_DOWNREASON_MASK (UINT64_CAST 0x1 << 28) 78/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 79#define NSRI_MORENODES_SHFT 18 80#define NSRI_MORENODES_MASK (UINT64_CAST 1 << 18) 81#define MORE_MEMORY 0 82#define MORE_NODES 1 83/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 84#define NSRI_REGIONSIZE_SHFT 17 85#define NSRI_REGIONSIZE_MASK (UINT64_CAST 1 << 17) 86#define REGIONSIZE_FINE 1 87#define REGIONSIZE_COARSE 0 88/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 89#define NSRI_NODEID_SHFT 8 90#define NSRI_NODEID_MASK (UINT64_CAST 0x1ff << 8) 91#define NSRI_REV_SHFT 4 92#define NSRI_REV_MASK (UINT64_CAST 0xf << 4) 93/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 94#define NSRI_CHIPID_SHFT 0 95#define NSRI_CHIPID_MASK (UINT64_CAST 0xf) 96#define NASID_TO_FINEREG_SHFT 0 97#define NASID_TO_COARSEREG_SHFT 3 98/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 99#define NPR_PORTRESET (UINT64_CAST 1 << 7) 100#define NPR_LINKRESET (UINT64_CAST 1 << 1) 101#define NPR_LOCALRESET (UINT64_CAST 1) 102#define NPROT_RESETOK (UINT64_CAST 1) 103/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 104#define NGP_MAXRETRY_SHFT 48 105#define NGP_MAXRETRY_MASK (UINT64_CAST 0x3ff << 48) 106#define NGP_TAILTOWRAP_SHFT 32 107#define NGP_TAILTOWRAP_MASK (UINT64_CAST 0xffff << 32) 108/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 109#define NGP_CREDITTOVAL_SHFT 16 110#define NGP_CREDITTOVAL_MASK (UINT64_CAST 0xf << 16) 111#define NGP_TAILTOVAL_SHFT 4 112#define NGP_TAILTOVAL_MASK (UINT64_CAST 0xf << 4) 113/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 114#define NDP_PORTTORESET (UINT64_CAST 1 << 18) 115#define NDP_LLP8BITMODE (UINT64_CAST 1 << 12) 116#define NDP_PORTDISABLE (UINT64_CAST 1 << 6) 117#define NDP_SENDERROR (UINT64_CAST 1) 118/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 119#define NVP_PIOID_SHFT 40 120#define NVP_PIOID_MASK (UINT64_CAST 0x3ff << 40) 121#define NVP_WRITEID_SHFT 32 122#define NVP_WRITEID_MASK (UINT64_CAST 0xff << 32) 123/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 124#define NVP_ADDRESS_MASK (UINT64_CAST 0xffff8) 125#define NVP_TYPE_SHFT 0 126#define NVP_TYPE_MASK (UINT64_CAST 0x3) 127#define NVS_VALID (UINT64_CAST 1 << 63) 128/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 129#define NVS_OVERRUN (UINT64_CAST 1 << 62) 130#define NVS_TARGET_SHFT 51 131#define NVS_TARGET_MASK (UINT64_CAST 0x3ff << 51) 132#define NVS_PIOID_SHFT 40 133/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 134#define NVS_PIOID_MASK (UINT64_CAST 0x3ff << 40) 135#define NVS_WRITEID_SHFT 32 136#define NVS_WRITEID_MASK (UINT64_CAST 0xff << 32) 137#define NVS_ADDRESS_MASK (UINT64_CAST 0xfffffff8) 138/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 139#define NVS_TYPE_SHFT 0 140#define NVS_TYPE_MASK (UINT64_CAST 0x7) 141#define NVS_ERROR_MASK (UINT64_CAST 0x4) 142#define PIOTYPE_READ 0 143/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 144#define PIOTYPE_WRITE 1 145#define PIOTYPE_UNDEFINED 2 146#define PIOTYPE_EXCHANGE 3 147#define PIOTYPE_ADDR_ERR 4 148/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 149#define PIOTYPE_CMD_ERR 5 150#define PIOTYPE_PROT_ERR 6 151#define PIOTYPE_UNKNOWN 7 152#define NAGE_VCH_SHFT 10 153/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 154#define NAGE_VCH_MASK (UINT64_CAST 3 << 10) 155#define NAGE_CC_SHFT 8 156#define NAGE_CC_MASK (UINT64_CAST 3 << 8) 157#define NAGE_AGE_SHFT 0 158/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 159#define NAGE_AGE_MASK (UINT64_CAST 0xff) 160#define NAGE_MASK (NAGE_VCH_MASK | NAGE_CC_MASK | NAGE_AGE_MASK) 161#define VCHANNEL_A 0 162#define VCHANNEL_B 1 163/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 164#define VCHANNEL_ANY 2 165#define NPP_NULLTO_SHFT 10 166#define NPP_NULLTO_MASK (UINT64_CAST 0x3f << 16) 167#define NPP_MAXBURST_SHFT 0 168/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 169#define NPP_MAXBURST_MASK (UINT64_CAST 0x3ff) 170#define NPP_RESET_DFLT_HUB20 ((UINT64_CAST 1 << NPP_NULLTO_SHFT) | (UINT64_CAST 0x3f0 << NPP_MAXBURST_SHFT)) 171#define NPP_RESET_DEFAULTS ((UINT64_CAST 6 << NPP_NULLTO_SHFT) | (UINT64_CAST 0x3f0 << NPP_MAXBURST_SHFT)) 172#define NPE_LINKRESET (UINT64_CAST 1 << 37) 173/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 174#define NPE_INTERNALERROR (UINT64_CAST 1 << 36) 175#define NPE_BADMESSAGE (UINT64_CAST 1 << 35) 176#define NPE_BADDEST (UINT64_CAST 1 << 34) 177#define NPE_FIFOOVERFLOW (UINT64_CAST 1 << 33) 178/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 179#define NPE_CREDITTO_SHFT 28 180#define NPE_CREDITTO_MASK (UINT64_CAST 0xf << 28) 181#define NPE_TAILTO_SHFT 24 182#define NPE_TAILTO_MASK (UINT64_CAST 0xf << 24) 183/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 184#define NPE_RETRYCOUNT_SHFT 16 185#define NPE_RETRYCOUNT_MASK (UINT64_CAST 0xff << 16) 186#define NPE_CBERRCOUNT_SHFT 8 187#define NPE_CBERRCOUNT_MASK (UINT64_CAST 0xff << 8) 188/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 189#define NPE_SNERRCOUNT_SHFT 0 190#define NPE_SNERRCOUNT_MASK (UINT64_CAST 0xff << 0) 191#define NPE_MASK 0x3effffffff 192#define NPE_COUNT_MAX 0xff 193/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 194#define NPE_FATAL_ERRORS (NPE_LINKRESET | NPE_INTERNALERROR | NPE_BADMESSAGE | NPE_BADDEST | NPE_FIFOOVERFLOW | NPE_CREDITTO_MASK | NPE_TAILTO_MASK) 195#define NMT_EXIT_PORT_MASK (UINT64_CAST 0xf) 196#define NLT_EXIT_PORT_MASK (UINT64_CAST 0xf) 197#ifndef __ASSEMBLY__ 198/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 199typedef union hubni_port_error_u { 200 u64 nipe_reg_value; 201 struct { 202 u64 nipe_rsvd: 26, 203/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 204 nipe_lnk_reset: 1, 205 nipe_intl_err: 1, 206 nipe_bad_msg: 1, 207 nipe_bad_dest: 1, 208/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 209 nipe_fifo_ovfl: 1, 210 nipe_rsvd1: 1, 211 nipe_credit_to: 4, 212 nipe_tail_to: 4, 213/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 214 nipe_retry_cnt: 8, 215 nipe_cb_cnt: 8, 216 nipe_sn_cnt: 8; 217 } nipe_fields_s; 218/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 219} hubni_port_error_t; 220#define NI_LLP_RETRY_MAX 0xff 221#define NI_LLP_CB_MAX 0xff 222#define NI_LLP_SN_MAX 0xff 223/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ 224#endif 225#endif 226