| 1 | #ifndef __BDK_CSRS_FUSF_H__ |
| 2 | #define __BDK_CSRS_FUSF_H__ |
| 3 | /* This file is auto-generated. Do not edit */ |
| 4 | |
| 5 | /***********************license start*************** |
| 6 | * Copyright (c) 2003-2017 Cavium Inc. ([email protected]). All rights |
| 7 | * reserved. |
| 8 | * |
| 9 | * |
| 10 | * Redistribution and use in source and binary forms, with or without |
| 11 | * modification, are permitted provided that the following conditions are |
| 12 | * met: |
| 13 | * |
| 14 | * * Redistributions of source code must retain the above copyright |
| 15 | * notice, this list of conditions and the following disclaimer. |
| 16 | * |
| 17 | * * Redistributions in binary form must reproduce the above |
| 18 | * copyright notice, this list of conditions and the following |
| 19 | * disclaimer in the documentation and/or other materials provided |
| 20 | * with the distribution. |
| 21 | |
| 22 | * * Neither the name of Cavium Inc. nor the names of |
| 23 | * its contributors may be used to endorse or promote products |
| 24 | * derived from this software without specific prior written |
| 25 | * permission. |
| 26 | |
| 27 | * This Software, including technical data, may be subject to U.S. export control |
| 28 | * laws, including the U.S. Export Administration Act and its associated |
| 29 | * regulations, and may be subject to export or import regulations in other |
| 30 | * countries. |
| 31 | |
| 32 | * TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS PROVIDED "AS IS" |
| 33 | * AND WITH ALL FAULTS AND CAVIUM NETWORKS MAKES NO PROMISES, REPRESENTATIONS OR |
| 34 | * WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY, OR OTHERWISE, WITH RESPECT TO |
| 35 | * THE SOFTWARE, INCLUDING ITS CONDITION, ITS CONFORMITY TO ANY REPRESENTATION OR |
| 36 | * DESCRIPTION, OR THE EXISTENCE OF ANY LATENT OR PATENT DEFECTS, AND CAVIUM |
| 37 | * SPECIFICALLY DISCLAIMS ALL IMPLIED (IF ANY) WARRANTIES OF TITLE, |
| 38 | * MERCHANTABILITY, NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, LACK OF |
| 39 | * VIRUSES, ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION OR |
| 40 | * CORRESPONDENCE TO DESCRIPTION. THE ENTIRE RISK ARISING OUT OF USE OR |
| 41 | * PERFORMANCE OF THE SOFTWARE LIES WITH YOU. |
| 42 | ***********************license end**************************************/ |
| 43 | |
| 44 | |
| 45 | /** |
| 46 | * @file |
| 47 | * |
| 48 | * Configuration and status register (CSR) address and type definitions for |
| 49 | * Cavium FUSF. |
| 50 | * |
| 51 | * This file is auto generated. Do not edit. |
| 52 | * |
| 53 | */ |
| 54 | |
| 55 | /** |
| 56 | * Enumeration fusf_bar_e |
| 57 | * |
| 58 | * Field Fuse Base Address Register Enumeration |
| 59 | * Enumerates the base address registers. |
| 60 | */ |
| 61 | #define BDK_FUSF_BAR_E_FUSF_PF_BAR0 (0x87e004000000ll) |
| 62 | #define BDK_FUSF_BAR_E_FUSF_PF_BAR0_SIZE 0x10000ull |
| 63 | |
| 64 | /** |
| 65 | * Enumeration fusf_fuse_num_e |
| 66 | * |
| 67 | * Field Fuse Fuse Number Enumeration |
| 68 | * Enumerates the fuse numbers. |
| 69 | */ |
| 70 | #define BDK_FUSF_FUSE_NUM_E_CRYPT_NO_DIS (0xe) |
| 71 | #define BDK_FUSF_FUSE_NUM_E_CRYPT_SSK_DIS (0xf) |
| 72 | #define BDK_FUSF_FUSE_NUM_E_DIS_HUK (0xd) |
| 73 | #define BDK_FUSF_FUSE_NUM_E_EKX(a) (0x500 + (a)) |
| 74 | #define BDK_FUSF_FUSE_NUM_E_FJ_CORE0 (0xc) |
| 75 | #define BDK_FUSF_FUSE_NUM_E_FJ_DIS (9) |
| 76 | #define BDK_FUSF_FUSE_NUM_E_FJ_TIMEOUTX(a) (0xa + (a)) |
| 77 | #define BDK_FUSF_FUSE_NUM_E_FUSF_LCK (0) |
| 78 | #define BDK_FUSF_FUSE_NUM_E_HUKX(a) (0x480 + (a)) |
| 79 | #define BDK_FUSF_FUSE_NUM_E_MFG_LCK (6) |
| 80 | #define BDK_FUSF_FUSE_NUM_E_ROM_SCRIPT_DISABLE (0x1e) |
| 81 | #define BDK_FUSF_FUSE_NUM_E_ROM_T_CNTX(a) (0x20 + (a)) |
| 82 | #define BDK_FUSF_FUSE_NUM_E_ROTPKX(a) (0x300 + (a)) |
| 83 | #define BDK_FUSF_FUSE_NUM_E_ROT_LCK (2) |
| 84 | #define BDK_FUSF_FUSE_NUM_E_RSVD128X(a) (0x80 + (a)) |
| 85 | #define BDK_FUSF_FUSE_NUM_E_RSVD16X(a) (0x10 + (a)) |
| 86 | #define BDK_FUSF_FUSE_NUM_E_RSVD256X(a) (0x100 + (a)) |
| 87 | #define BDK_FUSF_FUSE_NUM_E_RSVD4X(a) (4 + (a)) |
| 88 | #define BDK_FUSF_FUSE_NUM_E_RSVD5 (5) |
| 89 | #define BDK_FUSF_FUSE_NUM_E_RSVD512X(a) (0x200 + (a)) |
| 90 | #define BDK_FUSF_FUSE_NUM_E_RSVD64X(a) (0x40 + (a)) |
| 91 | #define BDK_FUSF_FUSE_NUM_E_RSVD7 (7) |
| 92 | #define BDK_FUSF_FUSE_NUM_E_SPI_SAFEMODE (0x1f) |
| 93 | #define BDK_FUSF_FUSE_NUM_E_SSKX(a) (0x400 + (a)) |
| 94 | #define BDK_FUSF_FUSE_NUM_E_SSK_LCK (1) |
| 95 | #define BDK_FUSF_FUSE_NUM_E_SWX(a) (0x600 + (a)) |
| 96 | #define BDK_FUSF_FUSE_NUM_E_SW_LCK (3) |
| 97 | #define BDK_FUSF_FUSE_NUM_E_TRUST_DIS (4) |
| 98 | #define BDK_FUSF_FUSE_NUM_E_TRUST_LVL_CHK (7) |
| 99 | #define BDK_FUSF_FUSE_NUM_E_TZ_FORCE2 (8) |
| 100 | |
| 101 | /** |
| 102 | * Register (RSL) fusf_bnk_dat# |
| 103 | * |
| 104 | * Field Fuse Bank Store Register |
| 105 | * The initial state of FUSF_BNK_DAT() is as if bank15 were just read. |
| 106 | * i.e. DAT* = fus[2047:1920]. |
| 107 | */ |
| 108 | union bdk_fusf_bnk_datx |
| 109 | { |
| 110 | uint64_t u; |
| 111 | struct bdk_fusf_bnk_datx_s |
| 112 | { |
| 113 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 114 | uint64_t dat : 64; /**< [ 63: 0](SR/W/H) Efuse bank store. For read operations, the DAT gets the fus bank last read. For write |
| 115 | operations, the DAT determines which fuses to blow. */ |
| 116 | #else /* Word 0 - Little Endian */ |
| 117 | uint64_t dat : 64; /**< [ 63: 0](SR/W/H) Efuse bank store. For read operations, the DAT gets the fus bank last read. For write |
| 118 | operations, the DAT determines which fuses to blow. */ |
| 119 | #endif /* Word 0 - End */ |
| 120 | } s; |
| 121 | /* struct bdk_fusf_bnk_datx_s cn8; */ |
| 122 | struct bdk_fusf_bnk_datx_cn9 |
| 123 | { |
| 124 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 125 | uint64_t dat : 64; /**< [ 63: 0](SR/W/H) Efuse bank store. For read operations, [DAT] gets the fus bank last read. For write |
| 126 | operations, [DAT] determines which fuses to blow. */ |
| 127 | #else /* Word 0 - Little Endian */ |
| 128 | uint64_t dat : 64; /**< [ 63: 0](SR/W/H) Efuse bank store. For read operations, [DAT] gets the fus bank last read. For write |
| 129 | operations, [DAT] determines which fuses to blow. */ |
| 130 | #endif /* Word 0 - End */ |
| 131 | } cn9; |
| 132 | }; |
| 133 | typedef union bdk_fusf_bnk_datx bdk_fusf_bnk_datx_t; |
| 134 | |
| 135 | static inline uint64_t BDK_FUSF_BNK_DATX(unsigned long a) __attribute__ ((pure, always_inline)); |
| 136 | static inline uint64_t BDK_FUSF_BNK_DATX(unsigned long a) |
| 137 | { |
| 138 | if (a<=1) |
| 139 | return 0x87e004000120ll + 8ll * ((a) & 0x1); |
| 140 | __bdk_csr_fatal("FUSF_BNK_DATX", 1, a, 0, 0, 0); |
| 141 | } |
| 142 | |
| 143 | #define typedef_BDK_FUSF_BNK_DATX(a) bdk_fusf_bnk_datx_t |
| 144 | #define bustype_BDK_FUSF_BNK_DATX(a) BDK_CSR_TYPE_RSL |
| 145 | #define basename_BDK_FUSF_BNK_DATX(a) "FUSF_BNK_DATX" |
| 146 | #define device_bar_BDK_FUSF_BNK_DATX(a) 0x0 /* PF_BAR0 */ |
| 147 | #define busnum_BDK_FUSF_BNK_DATX(a) (a) |
| 148 | #define arguments_BDK_FUSF_BNK_DATX(a) (a),-1,-1,-1 |
| 149 | |
| 150 | /** |
| 151 | * Register (RSL) fusf_const |
| 152 | * |
| 153 | * Field Fuse Constants Register |
| 154 | */ |
| 155 | union bdk_fusf_const |
| 156 | { |
| 157 | uint64_t u; |
| 158 | struct bdk_fusf_const_s |
| 159 | { |
| 160 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 161 | uint64_t reserved_8_63 : 56; |
| 162 | uint64_t fuse_banks : 8; /**< [ 7: 0](SRO) Number of 128-bit field fuse banks present. */ |
| 163 | #else /* Word 0 - Little Endian */ |
| 164 | uint64_t fuse_banks : 8; /**< [ 7: 0](SRO) Number of 128-bit field fuse banks present. */ |
| 165 | uint64_t reserved_8_63 : 56; |
| 166 | #endif /* Word 0 - End */ |
| 167 | } s; |
| 168 | /* struct bdk_fusf_const_s cn; */ |
| 169 | }; |
| 170 | typedef union bdk_fusf_const bdk_fusf_const_t; |
| 171 | |
| 172 | #define BDK_FUSF_CONST BDK_FUSF_CONST_FUNC() |
| 173 | static inline uint64_t BDK_FUSF_CONST_FUNC(void) __attribute__ ((pure, always_inline)); |
| 174 | static inline uint64_t BDK_FUSF_CONST_FUNC(void) |
| 175 | { |
| 176 | if (CAVIUM_IS_MODEL(CAVIUM_CN9XXX)) |
| 177 | return 0x87e004000130ll; |
| 178 | __bdk_csr_fatal("FUSF_CONST", 0, 0, 0, 0, 0); |
| 179 | } |
| 180 | |
| 181 | #define typedef_BDK_FUSF_CONST bdk_fusf_const_t |
| 182 | #define bustype_BDK_FUSF_CONST BDK_CSR_TYPE_RSL |
| 183 | #define basename_BDK_FUSF_CONST "FUSF_CONST" |
| 184 | #define device_bar_BDK_FUSF_CONST 0x0 /* PF_BAR0 */ |
| 185 | #define busnum_BDK_FUSF_CONST 0 |
| 186 | #define arguments_BDK_FUSF_CONST -1,-1,-1,-1 |
| 187 | |
| 188 | /** |
| 189 | * Register (RSL) fusf_ctl |
| 190 | * |
| 191 | * Field Fuse Control Register |
| 192 | */ |
| 193 | union bdk_fusf_ctl |
| 194 | { |
| 195 | uint64_t u; |
| 196 | struct bdk_fusf_ctl_s |
| 197 | { |
| 198 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 199 | uint64_t rom_t_cnt : 32; /**< [ 63: 32](SRO) ROM trusted counter. Reads field fuses FUSF_FUSE_NUM_E::ROM_T_CNT(). */ |
| 200 | uint64_t spi_safemode : 1; /**< [ 31: 31](SRO) Reserved. |
| 201 | Internal: |
| 202 | SPI safemode. Reads field fuses FUSF_FUSE_NUM_E::SPI_SAFEMODE. */ |
| 203 | uint64_t rom_script_disable : 1; /**< [ 30: 30](SRO) ROM script disable. Reads field fuses FUSF_FUSE_NUM_E::ROM_SCRIPT_DISABLE. */ |
| 204 | uint64_t fuse16 : 14; /**< [ 29: 16](SRO) Reserved. */ |
| 205 | uint64_t crypt_ssk_dis : 1; /**< [ 15: 15](SRO) SSK crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_SSK_DIS. */ |
| 206 | uint64_t crypt_no_dis : 1; /**< [ 14: 14](SRO) No-crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_NO_DIS. */ |
| 207 | uint64_t fj_dis_huk : 1; /**< [ 13: 13](SRO) Flash-jump HUK secret hiding. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS_HUK. */ |
| 208 | uint64_t fj_core0 : 1; /**< [ 12: 12](SRO) Flash-jump core 0 only. Reads field fuse FUSF_FUSE_NUM_E::FJ_CORE0. */ |
| 209 | uint64_t fj_timeout : 2; /**< [ 11: 10](SRO) Flash-jump timeout. Reads field fuse FUSF_FUSE_NUM_E::FJ_TIMEOUT(). */ |
| 210 | uint64_t fj_dis : 1; /**< [ 9: 9](SRO) Flash-jump disable. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS. */ |
| 211 | uint64_t tz_force2 : 1; /**< [ 8: 8](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 212 | uint64_t trust_lvl_chk : 1; /**< [ 7: 7](SRO) Trust level check. Reads field fuse FUSF_FUSE_NUM_E::TRUST_LVL_CHK. */ |
| 213 | uint64_t mfg_lck : 1; /**< [ 6: 6](SRO) Manufacturing lock. Reads field fuse FUSF_FUSE_NUM_E::MFG_LCK. */ |
| 214 | uint64_t fuse5 : 1; /**< [ 5: 5](SRO) Unallocated fuse. */ |
| 215 | uint64_t trust_dis : 1; /**< [ 4: 4](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 216 | uint64_t sw_lck : 1; /**< [ 3: 3](SRO) Software fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SW_LCK. */ |
| 217 | uint64_t rot_lck : 1; /**< [ 2: 2](SRO) Root-of-trust fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::ROT_LCK. */ |
| 218 | uint64_t ssk_lck : 1; /**< [ 1: 1](SRO) Secret symmetric key fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SSK_LCK. */ |
| 219 | uint64_t fusf_lck : 1; /**< [ 0: 0](SRO) Total field fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::FUSF_LCK. */ |
| 220 | #else /* Word 0 - Little Endian */ |
| 221 | uint64_t fusf_lck : 1; /**< [ 0: 0](SRO) Total field fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::FUSF_LCK. */ |
| 222 | uint64_t ssk_lck : 1; /**< [ 1: 1](SRO) Secret symmetric key fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SSK_LCK. */ |
| 223 | uint64_t rot_lck : 1; /**< [ 2: 2](SRO) Root-of-trust fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::ROT_LCK. */ |
| 224 | uint64_t sw_lck : 1; /**< [ 3: 3](SRO) Software fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SW_LCK. */ |
| 225 | uint64_t trust_dis : 1; /**< [ 4: 4](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 226 | uint64_t fuse5 : 1; /**< [ 5: 5](SRO) Unallocated fuse. */ |
| 227 | uint64_t mfg_lck : 1; /**< [ 6: 6](SRO) Manufacturing lock. Reads field fuse FUSF_FUSE_NUM_E::MFG_LCK. */ |
| 228 | uint64_t trust_lvl_chk : 1; /**< [ 7: 7](SRO) Trust level check. Reads field fuse FUSF_FUSE_NUM_E::TRUST_LVL_CHK. */ |
| 229 | uint64_t tz_force2 : 1; /**< [ 8: 8](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 230 | uint64_t fj_dis : 1; /**< [ 9: 9](SRO) Flash-jump disable. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS. */ |
| 231 | uint64_t fj_timeout : 2; /**< [ 11: 10](SRO) Flash-jump timeout. Reads field fuse FUSF_FUSE_NUM_E::FJ_TIMEOUT(). */ |
| 232 | uint64_t fj_core0 : 1; /**< [ 12: 12](SRO) Flash-jump core 0 only. Reads field fuse FUSF_FUSE_NUM_E::FJ_CORE0. */ |
| 233 | uint64_t fj_dis_huk : 1; /**< [ 13: 13](SRO) Flash-jump HUK secret hiding. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS_HUK. */ |
| 234 | uint64_t crypt_no_dis : 1; /**< [ 14: 14](SRO) No-crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_NO_DIS. */ |
| 235 | uint64_t crypt_ssk_dis : 1; /**< [ 15: 15](SRO) SSK crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_SSK_DIS. */ |
| 236 | uint64_t fuse16 : 14; /**< [ 29: 16](SRO) Reserved. */ |
| 237 | uint64_t rom_script_disable : 1; /**< [ 30: 30](SRO) ROM script disable. Reads field fuses FUSF_FUSE_NUM_E::ROM_SCRIPT_DISABLE. */ |
| 238 | uint64_t spi_safemode : 1; /**< [ 31: 31](SRO) Reserved. |
| 239 | Internal: |
| 240 | SPI safemode. Reads field fuses FUSF_FUSE_NUM_E::SPI_SAFEMODE. */ |
| 241 | uint64_t rom_t_cnt : 32; /**< [ 63: 32](SRO) ROM trusted counter. Reads field fuses FUSF_FUSE_NUM_E::ROM_T_CNT(). */ |
| 242 | #endif /* Word 0 - End */ |
| 243 | } s; |
| 244 | struct bdk_fusf_ctl_cn8 |
| 245 | { |
| 246 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 247 | uint64_t rom_t_cnt : 32; /**< [ 63: 32](SRO) ROM trusted counter. Reads field fuses FUSF_FUSE_NUM_E::ROM_T_CNT(). */ |
| 248 | uint64_t reserved_16_31 : 16; |
| 249 | uint64_t crypt_ssk_dis : 1; /**< [ 15: 15](SRO) SSK crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_SSK_DIS. */ |
| 250 | uint64_t crypt_no_dis : 1; /**< [ 14: 14](SRO) No-crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_NO_DIS. */ |
| 251 | uint64_t fj_dis_huk : 1; /**< [ 13: 13](SRO) Flash-jump HUK secret hiding. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS_HUK. */ |
| 252 | uint64_t fj_core0 : 1; /**< [ 12: 12](SRO) Flash-jump core 0 only. Reads field fuse FUSF_FUSE_NUM_E::FJ_CORE0. */ |
| 253 | uint64_t fj_timeout : 2; /**< [ 11: 10](SRO) Flash-jump timeout. Reads field fuse FUSF_FUSE_NUM_E::FJ_TIMEOUT(). */ |
| 254 | uint64_t fj_dis : 1; /**< [ 9: 9](SRO) Flash-jump disable. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS. */ |
| 255 | uint64_t tz_force2 : 1; /**< [ 8: 8](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 256 | uint64_t reserved_4_7 : 4; |
| 257 | uint64_t sw_lck : 1; /**< [ 3: 3](SRO) Software fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SW_LCK. */ |
| 258 | uint64_t rot_lck : 1; /**< [ 2: 2](SRO) Root-of-trust fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::ROT_LCK. */ |
| 259 | uint64_t ssk_lck : 1; /**< [ 1: 1](SRO) Secret symmetric key fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SSK_LCK. */ |
| 260 | uint64_t fusf_lck : 1; /**< [ 0: 0](SRO) Total field fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::FUSF_LCK. */ |
| 261 | #else /* Word 0 - Little Endian */ |
| 262 | uint64_t fusf_lck : 1; /**< [ 0: 0](SRO) Total field fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::FUSF_LCK. */ |
| 263 | uint64_t ssk_lck : 1; /**< [ 1: 1](SRO) Secret symmetric key fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SSK_LCK. */ |
| 264 | uint64_t rot_lck : 1; /**< [ 2: 2](SRO) Root-of-trust fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::ROT_LCK. */ |
| 265 | uint64_t sw_lck : 1; /**< [ 3: 3](SRO) Software fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SW_LCK. */ |
| 266 | uint64_t reserved_4_7 : 4; |
| 267 | uint64_t tz_force2 : 1; /**< [ 8: 8](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 268 | uint64_t fj_dis : 1; /**< [ 9: 9](SRO) Flash-jump disable. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS. */ |
| 269 | uint64_t fj_timeout : 2; /**< [ 11: 10](SRO) Flash-jump timeout. Reads field fuse FUSF_FUSE_NUM_E::FJ_TIMEOUT(). */ |
| 270 | uint64_t fj_core0 : 1; /**< [ 12: 12](SRO) Flash-jump core 0 only. Reads field fuse FUSF_FUSE_NUM_E::FJ_CORE0. */ |
| 271 | uint64_t fj_dis_huk : 1; /**< [ 13: 13](SRO) Flash-jump HUK secret hiding. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS_HUK. */ |
| 272 | uint64_t crypt_no_dis : 1; /**< [ 14: 14](SRO) No-crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_NO_DIS. */ |
| 273 | uint64_t crypt_ssk_dis : 1; /**< [ 15: 15](SRO) SSK crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_SSK_DIS. */ |
| 274 | uint64_t reserved_16_31 : 16; |
| 275 | uint64_t rom_t_cnt : 32; /**< [ 63: 32](SRO) ROM trusted counter. Reads field fuses FUSF_FUSE_NUM_E::ROM_T_CNT(). */ |
| 276 | #endif /* Word 0 - End */ |
| 277 | } cn8; |
| 278 | struct bdk_fusf_ctl_cn9 |
| 279 | { |
| 280 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 281 | uint64_t rom_t_cnt : 32; /**< [ 63: 32](SRO) ROM trusted counter. Reads field fuses FUSF_FUSE_NUM_E::ROM_T_CNT(). */ |
| 282 | uint64_t spi_safemode : 1; /**< [ 31: 31](SRO) Reserved. |
| 283 | Internal: |
| 284 | SPI safemode. Reads field fuses FUSF_FUSE_NUM_E::SPI_SAFEMODE. */ |
| 285 | uint64_t rom_script_disable : 1; /**< [ 30: 30](SRO) ROM script disable. Reads field fuses FUSF_FUSE_NUM_E::ROM_SCRIPT_DISABLE. */ |
| 286 | uint64_t fuse16 : 14; /**< [ 29: 16](SRO) Reserved. */ |
| 287 | uint64_t crypt_ssk_dis : 1; /**< [ 15: 15](SRO) SSK crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_SSK_DIS. */ |
| 288 | uint64_t crypt_no_dis : 1; /**< [ 14: 14](SRO) No-crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_NO_DIS. */ |
| 289 | uint64_t fj_dis_huk : 1; /**< [ 13: 13](SRO) Flash-jump HUK secret hiding. Reads field fuse FUSF_FUSE_NUM_E::DIS_HUK. */ |
| 290 | uint64_t fj_core0 : 1; /**< [ 12: 12](SRO) Flash-jump core 0 only. Reads field fuse FUSF_FUSE_NUM_E::FJ_CORE0. */ |
| 291 | uint64_t fj_timeout : 2; /**< [ 11: 10](SRO) Flash-jump timeout. Reads field fuse FUSF_FUSE_NUM_E::FJ_TIMEOUT(). */ |
| 292 | uint64_t fj_dis : 1; /**< [ 9: 9](SRO) Flash-jump disable. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS. */ |
| 293 | uint64_t tz_force2 : 1; /**< [ 8: 8](SRO) Trusted mode force override. Reads field fuse FUSF_FUSE_NUM_E::TZ_FORCE2. */ |
| 294 | uint64_t trust_lvl_chk : 1; /**< [ 7: 7](SRO) Trust level check. Reads field fuse FUSF_FUSE_NUM_E::TRUST_LVL_CHK. */ |
| 295 | uint64_t mfg_lck : 1; /**< [ 6: 6](SRO) Manufacturing lock. Reads field fuse FUSF_FUSE_NUM_E::MFG_LCK. */ |
| 296 | uint64_t fuse5 : 1; /**< [ 5: 5](SRO) Unallocated fuse. */ |
| 297 | uint64_t trust_dis : 1; /**< [ 4: 4](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 298 | uint64_t sw_lck : 1; /**< [ 3: 3](SRO) Software fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SW_LCK. */ |
| 299 | uint64_t rot_lck : 1; /**< [ 2: 2](SRO) Root-of-trust fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::ROT_LCK. */ |
| 300 | uint64_t ssk_lck : 1; /**< [ 1: 1](SRO) Secret symmetric key fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SSK_LCK. */ |
| 301 | uint64_t fusf_lck : 1; /**< [ 0: 0](SRO) Total field fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::FUSF_LCK. */ |
| 302 | #else /* Word 0 - Little Endian */ |
| 303 | uint64_t fusf_lck : 1; /**< [ 0: 0](SRO) Total field fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::FUSF_LCK. */ |
| 304 | uint64_t ssk_lck : 1; /**< [ 1: 1](SRO) Secret symmetric key fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SSK_LCK. */ |
| 305 | uint64_t rot_lck : 1; /**< [ 2: 2](SRO) Root-of-trust fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::ROT_LCK. */ |
| 306 | uint64_t sw_lck : 1; /**< [ 3: 3](SRO) Software fuse lockdown. Reads field fuse FUSF_FUSE_NUM_E::SW_LCK. */ |
| 307 | uint64_t trust_dis : 1; /**< [ 4: 4](SRO) Disable Trustzone. Reads field fuse FUSF_FUSE_NUM_E::TRUST_DIS. */ |
| 308 | uint64_t fuse5 : 1; /**< [ 5: 5](SRO) Unallocated fuse. */ |
| 309 | uint64_t mfg_lck : 1; /**< [ 6: 6](SRO) Manufacturing lock. Reads field fuse FUSF_FUSE_NUM_E::MFG_LCK. */ |
| 310 | uint64_t trust_lvl_chk : 1; /**< [ 7: 7](SRO) Trust level check. Reads field fuse FUSF_FUSE_NUM_E::TRUST_LVL_CHK. */ |
| 311 | uint64_t tz_force2 : 1; /**< [ 8: 8](SRO) Trusted mode force override. Reads field fuse FUSF_FUSE_NUM_E::TZ_FORCE2. */ |
| 312 | uint64_t fj_dis : 1; /**< [ 9: 9](SRO) Flash-jump disable. Reads field fuse FUSF_FUSE_NUM_E::FJ_DIS. */ |
| 313 | uint64_t fj_timeout : 2; /**< [ 11: 10](SRO) Flash-jump timeout. Reads field fuse FUSF_FUSE_NUM_E::FJ_TIMEOUT(). */ |
| 314 | uint64_t fj_core0 : 1; /**< [ 12: 12](SRO) Flash-jump core 0 only. Reads field fuse FUSF_FUSE_NUM_E::FJ_CORE0. */ |
| 315 | uint64_t fj_dis_huk : 1; /**< [ 13: 13](SRO) Flash-jump HUK secret hiding. Reads field fuse FUSF_FUSE_NUM_E::DIS_HUK. */ |
| 316 | uint64_t crypt_no_dis : 1; /**< [ 14: 14](SRO) No-crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_NO_DIS. */ |
| 317 | uint64_t crypt_ssk_dis : 1; /**< [ 15: 15](SRO) SSK crypt disable. Reads field fuse FUSF_FUSE_NUM_E::CRYPT_SSK_DIS. */ |
| 318 | uint64_t fuse16 : 14; /**< [ 29: 16](SRO) Reserved. */ |
| 319 | uint64_t rom_script_disable : 1; /**< [ 30: 30](SRO) ROM script disable. Reads field fuses FUSF_FUSE_NUM_E::ROM_SCRIPT_DISABLE. */ |
| 320 | uint64_t spi_safemode : 1; /**< [ 31: 31](SRO) Reserved. |
| 321 | Internal: |
| 322 | SPI safemode. Reads field fuses FUSF_FUSE_NUM_E::SPI_SAFEMODE. */ |
| 323 | uint64_t rom_t_cnt : 32; /**< [ 63: 32](SRO) ROM trusted counter. Reads field fuses FUSF_FUSE_NUM_E::ROM_T_CNT(). */ |
| 324 | #endif /* Word 0 - End */ |
| 325 | } cn9; |
| 326 | }; |
| 327 | typedef union bdk_fusf_ctl bdk_fusf_ctl_t; |
| 328 | |
| 329 | #define BDK_FUSF_CTL BDK_FUSF_CTL_FUNC() |
| 330 | static inline uint64_t BDK_FUSF_CTL_FUNC(void) __attribute__ ((pure, always_inline)); |
| 331 | static inline uint64_t BDK_FUSF_CTL_FUNC(void) |
| 332 | { |
| 333 | return 0x87e004000000ll; |
| 334 | } |
| 335 | |
| 336 | #define typedef_BDK_FUSF_CTL bdk_fusf_ctl_t |
| 337 | #define bustype_BDK_FUSF_CTL BDK_CSR_TYPE_RSL |
| 338 | #define basename_BDK_FUSF_CTL "FUSF_CTL" |
| 339 | #define device_bar_BDK_FUSF_CTL 0x0 /* PF_BAR0 */ |
| 340 | #define busnum_BDK_FUSF_CTL 0 |
| 341 | #define arguments_BDK_FUSF_CTL -1,-1,-1,-1 |
| 342 | |
| 343 | /** |
| 344 | * Register (RSL) fusf_eco |
| 345 | * |
| 346 | * INTERNAL: FUSF ECO Register |
| 347 | */ |
| 348 | union bdk_fusf_eco |
| 349 | { |
| 350 | uint64_t u; |
| 351 | struct bdk_fusf_eco_s |
| 352 | { |
| 353 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 354 | uint64_t reserved_32_63 : 32; |
| 355 | uint64_t eco_rw : 32; /**< [ 31: 0](R/W) ECO flops. |
| 356 | This field is always reinitialized on a chip domain reset. */ |
| 357 | #else /* Word 0 - Little Endian */ |
| 358 | uint64_t eco_rw : 32; /**< [ 31: 0](R/W) ECO flops. |
| 359 | This field is always reinitialized on a chip domain reset. */ |
| 360 | uint64_t reserved_32_63 : 32; |
| 361 | #endif /* Word 0 - End */ |
| 362 | } s; |
| 363 | /* struct bdk_fusf_eco_s cn; */ |
| 364 | }; |
| 365 | typedef union bdk_fusf_eco bdk_fusf_eco_t; |
| 366 | |
| 367 | #define BDK_FUSF_ECO BDK_FUSF_ECO_FUNC() |
| 368 | static inline uint64_t BDK_FUSF_ECO_FUNC(void) __attribute__ ((pure, always_inline)); |
| 369 | static inline uint64_t BDK_FUSF_ECO_FUNC(void) |
| 370 | { |
| 371 | if (CAVIUM_IS_MODEL(CAVIUM_CN9XXX)) |
| 372 | return 0x87e004000118ll; |
| 373 | __bdk_csr_fatal("FUSF_ECO", 0, 0, 0, 0, 0); |
| 374 | } |
| 375 | |
| 376 | #define typedef_BDK_FUSF_ECO bdk_fusf_eco_t |
| 377 | #define bustype_BDK_FUSF_ECO BDK_CSR_TYPE_RSL |
| 378 | #define basename_BDK_FUSF_ECO "FUSF_ECO" |
| 379 | #define device_bar_BDK_FUSF_ECO 0x0 /* PF_BAR0 */ |
| 380 | #define busnum_BDK_FUSF_ECO 0 |
| 381 | #define arguments_BDK_FUSF_ECO -1,-1,-1,-1 |
| 382 | |
| 383 | /** |
| 384 | * Register (RSL) fusf_ek# |
| 385 | * |
| 386 | * Field Fuse ECC Private Endorsement Key Registers |
| 387 | */ |
| 388 | union bdk_fusf_ekx |
| 389 | { |
| 390 | uint64_t u; |
| 391 | struct bdk_fusf_ekx_s |
| 392 | { |
| 393 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 394 | uint64_t dat : 64; /**< [ 63: 0](SRO) ECC private endorsement key. Reads field fuses FUSF_FUSE_NUM_E::EK(). */ |
| 395 | #else /* Word 0 - Little Endian */ |
| 396 | uint64_t dat : 64; /**< [ 63: 0](SRO) ECC private endorsement key. Reads field fuses FUSF_FUSE_NUM_E::EK(). */ |
| 397 | #endif /* Word 0 - End */ |
| 398 | } s; |
| 399 | /* struct bdk_fusf_ekx_s cn; */ |
| 400 | }; |
| 401 | typedef union bdk_fusf_ekx bdk_fusf_ekx_t; |
| 402 | |
| 403 | static inline uint64_t BDK_FUSF_EKX(unsigned long a) __attribute__ ((pure, always_inline)); |
| 404 | static inline uint64_t BDK_FUSF_EKX(unsigned long a) |
| 405 | { |
| 406 | if (a<=3) |
| 407 | return 0x87e0040000a0ll + 8ll * ((a) & 0x3); |
| 408 | __bdk_csr_fatal("FUSF_EKX", 1, a, 0, 0, 0); |
| 409 | } |
| 410 | |
| 411 | #define typedef_BDK_FUSF_EKX(a) bdk_fusf_ekx_t |
| 412 | #define bustype_BDK_FUSF_EKX(a) BDK_CSR_TYPE_RSL |
| 413 | #define basename_BDK_FUSF_EKX(a) "FUSF_EKX" |
| 414 | #define device_bar_BDK_FUSF_EKX(a) 0x0 /* PF_BAR0 */ |
| 415 | #define busnum_BDK_FUSF_EKX(a) (a) |
| 416 | #define arguments_BDK_FUSF_EKX(a) (a),-1,-1,-1 |
| 417 | |
| 418 | /** |
| 419 | * Register (RSL) fusf_huk# |
| 420 | * |
| 421 | * Field Fuse Hardware Unique Key Registers |
| 422 | */ |
| 423 | union bdk_fusf_hukx |
| 424 | { |
| 425 | uint64_t u; |
| 426 | struct bdk_fusf_hukx_s |
| 427 | { |
| 428 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 429 | uint64_t dat : 64; /**< [ 63: 0](SRO) Hardware unique key (HUK). Reads field fuses FUSF_FUSE_NUM_E::HUK(). */ |
| 430 | #else /* Word 0 - Little Endian */ |
| 431 | uint64_t dat : 64; /**< [ 63: 0](SRO) Hardware unique key (HUK). Reads field fuses FUSF_FUSE_NUM_E::HUK(). */ |
| 432 | #endif /* Word 0 - End */ |
| 433 | } s; |
| 434 | /* struct bdk_fusf_hukx_s cn; */ |
| 435 | }; |
| 436 | typedef union bdk_fusf_hukx bdk_fusf_hukx_t; |
| 437 | |
| 438 | static inline uint64_t BDK_FUSF_HUKX(unsigned long a) __attribute__ ((pure, always_inline)); |
| 439 | static inline uint64_t BDK_FUSF_HUKX(unsigned long a) |
| 440 | { |
| 441 | if (a<=1) |
| 442 | return 0x87e004000090ll + 8ll * ((a) & 0x1); |
| 443 | __bdk_csr_fatal("FUSF_HUKX", 1, a, 0, 0, 0); |
| 444 | } |
| 445 | |
| 446 | #define typedef_BDK_FUSF_HUKX(a) bdk_fusf_hukx_t |
| 447 | #define bustype_BDK_FUSF_HUKX(a) BDK_CSR_TYPE_RSL |
| 448 | #define basename_BDK_FUSF_HUKX(a) "FUSF_HUKX" |
| 449 | #define device_bar_BDK_FUSF_HUKX(a) 0x0 /* PF_BAR0 */ |
| 450 | #define busnum_BDK_FUSF_HUKX(a) (a) |
| 451 | #define arguments_BDK_FUSF_HUKX(a) (a),-1,-1,-1 |
| 452 | |
| 453 | /** |
| 454 | * Register (RSL) fusf_prog |
| 455 | * |
| 456 | * Field Fuse Programming Register |
| 457 | */ |
| 458 | union bdk_fusf_prog |
| 459 | { |
| 460 | uint64_t u; |
| 461 | struct bdk_fusf_prog_s |
| 462 | { |
| 463 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 464 | uint64_t reserved_16_63 : 48; |
| 465 | uint64_t efuse : 1; /**< [ 15: 15](SR/W) Efuse storage. When set, the data is written directly to the efuse |
| 466 | bank. When cleared, data is soft blown to local storage. |
| 467 | A soft blown fuse is subject to lockdown fuses. |
| 468 | Soft blown fuses will become active after a chip domain reset |
| 469 | but will not persist through a cold domain reset. */ |
| 470 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 471 | programming voltage applied. Required to be set when |
| 472 | programming fuses (ie. [EFUSE] and [PROG] set). */ |
| 473 | uint64_t reserved_8_13 : 6; |
| 474 | uint64_t addr : 4; /**< [ 7: 4](SR/W) Indicates which of bank of 128 fuses to blow. Software |
| 475 | should not change this field while the FUSF_PROG[PROG] bit is set. */ |
| 476 | uint64_t reserved_3 : 1; |
| 477 | uint64_t prog_pin : 1; /**< [ 2: 2](SRO) Efuse program voltage (EFUS_PROG) is applied. |
| 478 | Internal: |
| 479 | Indicates state of pi_efuse_pgm_ext not pi_efuse_pgm_int. */ |
| 480 | uint64_t sft : 1; /**< [ 1: 1](SR/W/H) When set with [PROG], causes only the local storage to change and will not blow |
| 481 | any fuses. Hardware will clear when the program operation is complete. */ |
| 482 | uint64_t reserved_0 : 1; |
| 483 | #else /* Word 0 - Little Endian */ |
| 484 | uint64_t reserved_0 : 1; |
| 485 | uint64_t sft : 1; /**< [ 1: 1](SR/W/H) When set with [PROG], causes only the local storage to change and will not blow |
| 486 | any fuses. Hardware will clear when the program operation is complete. */ |
| 487 | uint64_t prog_pin : 1; /**< [ 2: 2](SRO) Efuse program voltage (EFUS_PROG) is applied. |
| 488 | Internal: |
| 489 | Indicates state of pi_efuse_pgm_ext not pi_efuse_pgm_int. */ |
| 490 | uint64_t reserved_3 : 1; |
| 491 | uint64_t addr : 4; /**< [ 7: 4](SR/W) Indicates which of bank of 128 fuses to blow. Software |
| 492 | should not change this field while the FUSF_PROG[PROG] bit is set. */ |
| 493 | uint64_t reserved_8_13 : 6; |
| 494 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 495 | programming voltage applied. Required to be set when |
| 496 | programming fuses (ie. [EFUSE] and [PROG] set). */ |
| 497 | uint64_t efuse : 1; /**< [ 15: 15](SR/W) Efuse storage. When set, the data is written directly to the efuse |
| 498 | bank. When cleared, data is soft blown to local storage. |
| 499 | A soft blown fuse is subject to lockdown fuses. |
| 500 | Soft blown fuses will become active after a chip domain reset |
| 501 | but will not persist through a cold domain reset. */ |
| 502 | uint64_t reserved_16_63 : 48; |
| 503 | #endif /* Word 0 - End */ |
| 504 | } s; |
| 505 | struct bdk_fusf_prog_cn88xxp1 |
| 506 | { |
| 507 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 508 | uint64_t reserved_4_63 : 60; |
| 509 | uint64_t volt_en : 1; /**< [ 3: 3](SWO) Enable programming voltage. Asserts EFUSE_ENABLE_L opep-drain output pin. */ |
| 510 | uint64_t prog_pin : 1; /**< [ 2: 2](SRO) Efuse program voltage (EFUS_PROG) is applied. |
| 511 | Internal: |
| 512 | Indicates state of pi_efuse_pgm_ext not pi_efuse_pgm_int. */ |
| 513 | uint64_t sft : 1; /**< [ 1: 1](SR/W/H) When set with [PROG], causes only the local storage to change and will not blow |
| 514 | any fuses. Hardware will clear when the program operation is complete. */ |
| 515 | uint64_t prog : 1; /**< [ 0: 0](SR/W/H) When written to 1 by software, blow the fuse bank. Hardware clears this bit when |
| 516 | the program operation is complete. |
| 517 | |
| 518 | To write a bank of fuses, software must set FUSF_WADR[ADDR] to the bank to be |
| 519 | programmed and then set each bit within FUSF_BNK_DATX to indicate which fuses to blow. |
| 520 | |
| 521 | Once FUSF_WADR[ADDR], and DAT are setup, software can write to FUSF_PROG[PROG] |
| 522 | to start the bank write and poll on [PROG]. Once PROG is clear, the bank write |
| 523 | is complete. MIO_FUS_READ_TIMES[WRSTB_WH] set the time for the hardware to |
| 524 | clear this bit. A soft blow is still subject to lockdown fuses. After a |
| 525 | soft/warm reset, the chip behaves as though the fuses were actually blown. A |
| 526 | cold reset restores the actual fuse values. */ |
| 527 | #else /* Word 0 - Little Endian */ |
| 528 | uint64_t prog : 1; /**< [ 0: 0](SR/W/H) When written to 1 by software, blow the fuse bank. Hardware clears this bit when |
| 529 | the program operation is complete. |
| 530 | |
| 531 | To write a bank of fuses, software must set FUSF_WADR[ADDR] to the bank to be |
| 532 | programmed and then set each bit within FUSF_BNK_DATX to indicate which fuses to blow. |
| 533 | |
| 534 | Once FUSF_WADR[ADDR], and DAT are setup, software can write to FUSF_PROG[PROG] |
| 535 | to start the bank write and poll on [PROG]. Once PROG is clear, the bank write |
| 536 | is complete. MIO_FUS_READ_TIMES[WRSTB_WH] set the time for the hardware to |
| 537 | clear this bit. A soft blow is still subject to lockdown fuses. After a |
| 538 | soft/warm reset, the chip behaves as though the fuses were actually blown. A |
| 539 | cold reset restores the actual fuse values. */ |
| 540 | uint64_t sft : 1; /**< [ 1: 1](SR/W/H) When set with [PROG], causes only the local storage to change and will not blow |
| 541 | any fuses. Hardware will clear when the program operation is complete. */ |
| 542 | uint64_t prog_pin : 1; /**< [ 2: 2](SRO) Efuse program voltage (EFUS_PROG) is applied. |
| 543 | Internal: |
| 544 | Indicates state of pi_efuse_pgm_ext not pi_efuse_pgm_int. */ |
| 545 | uint64_t volt_en : 1; /**< [ 3: 3](SWO) Enable programming voltage. Asserts EFUSE_ENABLE_L opep-drain output pin. */ |
| 546 | uint64_t reserved_4_63 : 60; |
| 547 | #endif /* Word 0 - End */ |
| 548 | } cn88xxp1; |
| 549 | struct bdk_fusf_prog_cn9 |
| 550 | { |
| 551 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 552 | uint64_t reserved_16_63 : 48; |
| 553 | uint64_t efuse : 1; /**< [ 15: 15](SR/W) Efuse storage. When set, the data is written directly to the efuse |
| 554 | bank. When cleared, data is soft blown to local storage. |
| 555 | A soft blown fuse is subject to lockdown fuses. |
| 556 | Soft blown fuses will become active after a chip domain reset |
| 557 | but will not persist through a cold domain reset. */ |
| 558 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 559 | programming voltage applied. Required to be set when |
| 560 | programming fuses (ie. [EFUSE] and [PROG] set). */ |
| 561 | uint64_t volt_en : 1; /**< [ 13: 13](SR/W) Enable programming voltage. Asserts EFUSE_ENABLE_L open-drain output pin. */ |
| 562 | uint64_t prog : 1; /**< [ 12: 12](SR/W/H) Internal: |
| 563 | When written to one by software, blow the fuse bank. Hardware will |
| 564 | clear the field when the program operation is complete. |
| 565 | To write a bank of fuses, software must write the fuse data into |
| 566 | FUSF_BNK_DAT(). Then it writes the ADDR and EFUSE fields of this register |
| 567 | and sets the PROG bit. Hardware will clear the [PROG] when the write is |
| 568 | completed. New fuses will become active after a chip domain reset. */ |
| 569 | uint64_t reserved_8_11 : 4; |
| 570 | uint64_t addr : 4; /**< [ 7: 4](SR/W) Indicates which of bank of 128 fuses to blow. Software |
| 571 | should not change this field while the FUSF_PROG[PROG] bit is set. */ |
| 572 | uint64_t reserved_0_3 : 4; |
| 573 | #else /* Word 0 - Little Endian */ |
| 574 | uint64_t reserved_0_3 : 4; |
| 575 | uint64_t addr : 4; /**< [ 7: 4](SR/W) Indicates which of bank of 128 fuses to blow. Software |
| 576 | should not change this field while the FUSF_PROG[PROG] bit is set. */ |
| 577 | uint64_t reserved_8_11 : 4; |
| 578 | uint64_t prog : 1; /**< [ 12: 12](SR/W/H) Internal: |
| 579 | When written to one by software, blow the fuse bank. Hardware will |
| 580 | clear the field when the program operation is complete. |
| 581 | To write a bank of fuses, software must write the fuse data into |
| 582 | FUSF_BNK_DAT(). Then it writes the ADDR and EFUSE fields of this register |
| 583 | and sets the PROG bit. Hardware will clear the [PROG] when the write is |
| 584 | completed. New fuses will become active after a chip domain reset. */ |
| 585 | uint64_t volt_en : 1; /**< [ 13: 13](SR/W) Enable programming voltage. Asserts EFUSE_ENABLE_L open-drain output pin. */ |
| 586 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 587 | programming voltage applied. Required to be set when |
| 588 | programming fuses (ie. [EFUSE] and [PROG] set). */ |
| 589 | uint64_t efuse : 1; /**< [ 15: 15](SR/W) Efuse storage. When set, the data is written directly to the efuse |
| 590 | bank. When cleared, data is soft blown to local storage. |
| 591 | A soft blown fuse is subject to lockdown fuses. |
| 592 | Soft blown fuses will become active after a chip domain reset |
| 593 | but will not persist through a cold domain reset. */ |
| 594 | uint64_t reserved_16_63 : 48; |
| 595 | #endif /* Word 0 - End */ |
| 596 | } cn9; |
| 597 | struct bdk_fusf_prog_cn81xx |
| 598 | { |
| 599 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 600 | uint64_t reserved_4_63 : 60; |
| 601 | uint64_t volt_en : 1; /**< [ 3: 3](SR/W) Enable programming voltage. Asserts EFUSE_ENABLE_L open-drain output pin. */ |
| 602 | uint64_t prog_pin : 1; /**< [ 2: 2](SRO) Efuse program voltage (EFUS_PROG) is applied. |
| 603 | Internal: |
| 604 | Indicates state of pi_efuse_pgm_ext not pi_efuse_pgm_int. */ |
| 605 | uint64_t sft : 1; /**< [ 1: 1](SR/W/H) When set with [PROG], causes only the local storage to change and will not blow |
| 606 | any fuses. Hardware will clear when the program operation is complete. */ |
| 607 | uint64_t prog : 1; /**< [ 0: 0](SR/W/H) When written to 1 by software, blow the fuse bank. Hardware clears this bit when |
| 608 | the program operation is complete. |
| 609 | |
| 610 | To write a bank of fuses, software must set FUSF_WADR[ADDR] to the bank to be |
| 611 | programmed and then set each bit within FUSF_BNK_DATX to indicate which fuses to blow. |
| 612 | |
| 613 | Once FUSF_WADR[ADDR], and DAT are setup, software can write to FUSF_PROG[PROG] |
| 614 | to start the bank write and poll on [PROG]. Once PROG is clear, the bank write |
| 615 | is complete. MIO_FUS_READ_TIMES[WRSTB_WH] set the time for the hardware to |
| 616 | clear this bit. A soft blow is still subject to lockdown fuses. After a |
| 617 | soft/warm reset, the chip behaves as though the fuses were actually blown. A |
| 618 | cold reset restores the actual fuse values. */ |
| 619 | #else /* Word 0 - Little Endian */ |
| 620 | uint64_t prog : 1; /**< [ 0: 0](SR/W/H) When written to 1 by software, blow the fuse bank. Hardware clears this bit when |
| 621 | the program operation is complete. |
| 622 | |
| 623 | To write a bank of fuses, software must set FUSF_WADR[ADDR] to the bank to be |
| 624 | programmed and then set each bit within FUSF_BNK_DATX to indicate which fuses to blow. |
| 625 | |
| 626 | Once FUSF_WADR[ADDR], and DAT are setup, software can write to FUSF_PROG[PROG] |
| 627 | to start the bank write and poll on [PROG]. Once PROG is clear, the bank write |
| 628 | is complete. MIO_FUS_READ_TIMES[WRSTB_WH] set the time for the hardware to |
| 629 | clear this bit. A soft blow is still subject to lockdown fuses. After a |
| 630 | soft/warm reset, the chip behaves as though the fuses were actually blown. A |
| 631 | cold reset restores the actual fuse values. */ |
| 632 | uint64_t sft : 1; /**< [ 1: 1](SR/W/H) When set with [PROG], causes only the local storage to change and will not blow |
| 633 | any fuses. Hardware will clear when the program operation is complete. */ |
| 634 | uint64_t prog_pin : 1; /**< [ 2: 2](SRO) Efuse program voltage (EFUS_PROG) is applied. |
| 635 | Internal: |
| 636 | Indicates state of pi_efuse_pgm_ext not pi_efuse_pgm_int. */ |
| 637 | uint64_t volt_en : 1; /**< [ 3: 3](SR/W) Enable programming voltage. Asserts EFUSE_ENABLE_L open-drain output pin. */ |
| 638 | uint64_t reserved_4_63 : 60; |
| 639 | #endif /* Word 0 - End */ |
| 640 | } cn81xx; |
| 641 | /* struct bdk_fusf_prog_cn81xx cn83xx; */ |
| 642 | /* struct bdk_fusf_prog_cn81xx cn88xxp2; */ |
| 643 | }; |
| 644 | typedef union bdk_fusf_prog bdk_fusf_prog_t; |
| 645 | |
| 646 | #define BDK_FUSF_PROG BDK_FUSF_PROG_FUNC() |
| 647 | static inline uint64_t BDK_FUSF_PROG_FUNC(void) __attribute__ ((pure, always_inline)); |
| 648 | static inline uint64_t BDK_FUSF_PROG_FUNC(void) |
| 649 | { |
| 650 | return 0x87e004000110ll; |
| 651 | } |
| 652 | |
| 653 | #define typedef_BDK_FUSF_PROG bdk_fusf_prog_t |
| 654 | #define bustype_BDK_FUSF_PROG BDK_CSR_TYPE_RSL |
| 655 | #define basename_BDK_FUSF_PROG "FUSF_PROG" |
| 656 | #define device_bar_BDK_FUSF_PROG 0x0 /* PF_BAR0 */ |
| 657 | #define busnum_BDK_FUSF_PROG 0 |
| 658 | #define arguments_BDK_FUSF_PROG -1,-1,-1,-1 |
| 659 | |
| 660 | /** |
| 661 | * Register (RSL) fusf_rcmd |
| 662 | * |
| 663 | * Field Fuse Read Command Register |
| 664 | * To read an efuse, software writes FUSF_RCMD[ADDR, PEND] with the byte address of |
| 665 | * the fuse in |
| 666 | * question, then software can poll FUSF_RCMD[PEND]. When [PEND] is clear and if the efuse read |
| 667 | * went to the efuse banks (e.g. EFUSE was set on the read), software can read FUSF_BNK_DATx |
| 668 | * which contains all 128 fuses in the bank associated in ADDR. |
| 669 | */ |
| 670 | union bdk_fusf_rcmd |
| 671 | { |
| 672 | uint64_t u; |
| 673 | struct bdk_fusf_rcmd_s |
| 674 | { |
| 675 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 676 | uint64_t reserved_15_63 : 49; |
| 677 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 678 | programming voltage applied. Required to be cleared when |
| 679 | reading fuses directly (ie. [EFUSE] and [PEND] set). */ |
| 680 | uint64_t reserved_13 : 1; |
| 681 | uint64_t pend : 1; /**< [ 12: 12](SR/W/H) Software sets this bit on a write to start FUSE read operation. |
| 682 | Hardware clears the bit when the read is complete and the DAT is |
| 683 | valid. MIO_FUS_READ_TIMES[RDSTB_WH] determines the time for this |
| 684 | operation. */ |
| 685 | uint64_t reserved_11 : 1; |
| 686 | uint64_t addr_hi : 2; /**< [ 10: 9](SR/W) Upper fuse address bits to extend space beyond 2k fuses. Valid range is |
| 687 | 0x0. Enumerated by FUSF_FUSE_NUM_E\<9:8\>. */ |
| 688 | uint64_t reserved_0_8 : 9; |
| 689 | #else /* Word 0 - Little Endian */ |
| 690 | uint64_t reserved_0_8 : 9; |
| 691 | uint64_t addr_hi : 2; /**< [ 10: 9](SR/W) Upper fuse address bits to extend space beyond 2k fuses. Valid range is |
| 692 | 0x0. Enumerated by FUSF_FUSE_NUM_E\<9:8\>. */ |
| 693 | uint64_t reserved_11 : 1; |
| 694 | uint64_t pend : 1; /**< [ 12: 12](SR/W/H) Software sets this bit on a write to start FUSE read operation. |
| 695 | Hardware clears the bit when the read is complete and the DAT is |
| 696 | valid. MIO_FUS_READ_TIMES[RDSTB_WH] determines the time for this |
| 697 | operation. */ |
| 698 | uint64_t reserved_13 : 1; |
| 699 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 700 | programming voltage applied. Required to be cleared when |
| 701 | reading fuses directly (ie. [EFUSE] and [PEND] set). */ |
| 702 | uint64_t reserved_15_63 : 49; |
| 703 | #endif /* Word 0 - End */ |
| 704 | } s; |
| 705 | struct bdk_fusf_rcmd_cn8 |
| 706 | { |
| 707 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 708 | uint64_t reserved_24_63 : 40; |
| 709 | uint64_t reserved_16_23 : 8; |
| 710 | uint64_t reserved_13_15 : 3; |
| 711 | uint64_t pend : 1; /**< [ 12: 12](SR/W/H) Software sets this bit on a write to start FUSE read operation. |
| 712 | Hardware clears the bit when the read is complete and the DAT is |
| 713 | valid. MIO_FUS_READ_TIMES[RDSTB_WH] determines the time for this |
| 714 | operation. */ |
| 715 | uint64_t reserved_11 : 1; |
| 716 | uint64_t addr_hi : 2; /**< [ 10: 9](SR/W) Upper fuse address bits to extend space beyond 2k fuses. Valid range is |
| 717 | 0x0. Enumerated by FUSF_FUSE_NUM_E\<9:8\>. */ |
| 718 | uint64_t efuse : 1; /**< [ 8: 8](SR/W) When set, return data from the efuse storage rather than the local storage. |
| 719 | Software should not change this field while the FUSF_RCMD[PEND] is set. |
| 720 | It should wait for the hardware to clear the bit first. */ |
| 721 | uint64_t addr : 8; /**< [ 7: 0](SR/W) The byte address of the fuse to read. Enumerated by FUSF_FUSE_NUM_E\<7:0\>. */ |
| 722 | #else /* Word 0 - Little Endian */ |
| 723 | uint64_t addr : 8; /**< [ 7: 0](SR/W) The byte address of the fuse to read. Enumerated by FUSF_FUSE_NUM_E\<7:0\>. */ |
| 724 | uint64_t efuse : 1; /**< [ 8: 8](SR/W) When set, return data from the efuse storage rather than the local storage. |
| 725 | Software should not change this field while the FUSF_RCMD[PEND] is set. |
| 726 | It should wait for the hardware to clear the bit first. */ |
| 727 | uint64_t addr_hi : 2; /**< [ 10: 9](SR/W) Upper fuse address bits to extend space beyond 2k fuses. Valid range is |
| 728 | 0x0. Enumerated by FUSF_FUSE_NUM_E\<9:8\>. */ |
| 729 | uint64_t reserved_11 : 1; |
| 730 | uint64_t pend : 1; /**< [ 12: 12](SR/W/H) Software sets this bit on a write to start FUSE read operation. |
| 731 | Hardware clears the bit when the read is complete and the DAT is |
| 732 | valid. MIO_FUS_READ_TIMES[RDSTB_WH] determines the time for this |
| 733 | operation. */ |
| 734 | uint64_t reserved_13_15 : 3; |
| 735 | uint64_t reserved_16_23 : 8; |
| 736 | uint64_t reserved_24_63 : 40; |
| 737 | #endif /* Word 0 - End */ |
| 738 | } cn8; |
| 739 | struct bdk_fusf_rcmd_cn9 |
| 740 | { |
| 741 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 742 | uint64_t reserved_16_63 : 48; |
| 743 | uint64_t efuse : 1; /**< [ 15: 15](SR/W) Efuse storage. When set, the return data is from the efuse |
| 744 | bank directly. When cleared data is read from the local storage. */ |
| 745 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 746 | programming voltage applied. Required to be cleared when |
| 747 | reading fuses directly (ie. [EFUSE] and [PEND] set). */ |
| 748 | uint64_t reserved_13 : 1; |
| 749 | uint64_t pend : 1; /**< [ 12: 12](SR/W/H) Software sets this bit to one on a write operation that starts |
| 750 | the fuse read operation. Hardware clears this bit when the read |
| 751 | operation is complete and FUS_BNK_DAT() is valid. |
| 752 | FUS_READ_TIMES[RDSTB_WH] determines the time for the operation |
| 753 | to complete. */ |
| 754 | uint64_t reserved_8_11 : 4; |
| 755 | uint64_t addr : 4; /**< [ 7: 4](SR/W) Address. Specifies the bank address of 128 fuses to read. |
| 756 | Software should not change this field while [PEND] |
| 757 | is set. It must wait for the hardware to clear it. */ |
| 758 | uint64_t reserved_0_3 : 4; |
| 759 | #else /* Word 0 - Little Endian */ |
| 760 | uint64_t reserved_0_3 : 4; |
| 761 | uint64_t addr : 4; /**< [ 7: 4](SR/W) Address. Specifies the bank address of 128 fuses to read. |
| 762 | Software should not change this field while [PEND] |
| 763 | is set. It must wait for the hardware to clear it. */ |
| 764 | uint64_t reserved_8_11 : 4; |
| 765 | uint64_t pend : 1; /**< [ 12: 12](SR/W/H) Software sets this bit to one on a write operation that starts |
| 766 | the fuse read operation. Hardware clears this bit when the read |
| 767 | operation is complete and FUS_BNK_DAT() is valid. |
| 768 | FUS_READ_TIMES[RDSTB_WH] determines the time for the operation |
| 769 | to complete. */ |
| 770 | uint64_t reserved_13 : 1; |
| 771 | uint64_t voltage : 1; /**< [ 14: 14](SRO) Efuse programming voltage status. When set, EFUSE banks have |
| 772 | programming voltage applied. Required to be cleared when |
| 773 | reading fuses directly (ie. [EFUSE] and [PEND] set). */ |
| 774 | uint64_t efuse : 1; /**< [ 15: 15](SR/W) Efuse storage. When set, the return data is from the efuse |
| 775 | bank directly. When cleared data is read from the local storage. */ |
| 776 | uint64_t reserved_16_63 : 48; |
| 777 | #endif /* Word 0 - End */ |
| 778 | } cn9; |
| 779 | }; |
| 780 | typedef union bdk_fusf_rcmd bdk_fusf_rcmd_t; |
| 781 | |
| 782 | #define BDK_FUSF_RCMD BDK_FUSF_RCMD_FUNC() |
| 783 | static inline uint64_t BDK_FUSF_RCMD_FUNC(void) __attribute__ ((pure, always_inline)); |
| 784 | static inline uint64_t BDK_FUSF_RCMD_FUNC(void) |
| 785 | { |
| 786 | return 0x87e004000100ll; |
| 787 | } |
| 788 | |
| 789 | #define typedef_BDK_FUSF_RCMD bdk_fusf_rcmd_t |
| 790 | #define bustype_BDK_FUSF_RCMD BDK_CSR_TYPE_RSL |
| 791 | #define basename_BDK_FUSF_RCMD "FUSF_RCMD" |
| 792 | #define device_bar_BDK_FUSF_RCMD 0x0 /* PF_BAR0 */ |
| 793 | #define busnum_BDK_FUSF_RCMD 0 |
| 794 | #define arguments_BDK_FUSF_RCMD -1,-1,-1,-1 |
| 795 | |
| 796 | /** |
| 797 | * Register (RSL) fusf_rotpk# |
| 798 | * |
| 799 | * Field Fuse Root-of-Trust Public Key Registers |
| 800 | */ |
| 801 | union bdk_fusf_rotpkx |
| 802 | { |
| 803 | uint64_t u; |
| 804 | struct bdk_fusf_rotpkx_s |
| 805 | { |
| 806 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 807 | uint64_t dat : 64; /**< [ 63: 0](SRO) Hash of the root-of-trust public key (ROTPK). Reads field fuses FUSF_FUSE_NUM_E::ROTPK(). */ |
| 808 | #else /* Word 0 - Little Endian */ |
| 809 | uint64_t dat : 64; /**< [ 63: 0](SRO) Hash of the root-of-trust public key (ROTPK). Reads field fuses FUSF_FUSE_NUM_E::ROTPK(). */ |
| 810 | #endif /* Word 0 - End */ |
| 811 | } s; |
| 812 | /* struct bdk_fusf_rotpkx_s cn; */ |
| 813 | }; |
| 814 | typedef union bdk_fusf_rotpkx bdk_fusf_rotpkx_t; |
| 815 | |
| 816 | static inline uint64_t BDK_FUSF_ROTPKX(unsigned long a) __attribute__ ((pure, always_inline)); |
| 817 | static inline uint64_t BDK_FUSF_ROTPKX(unsigned long a) |
| 818 | { |
| 819 | if (a<=3) |
| 820 | return 0x87e004000060ll + 8ll * ((a) & 0x3); |
| 821 | __bdk_csr_fatal("FUSF_ROTPKX", 1, a, 0, 0, 0); |
| 822 | } |
| 823 | |
| 824 | #define typedef_BDK_FUSF_ROTPKX(a) bdk_fusf_rotpkx_t |
| 825 | #define bustype_BDK_FUSF_ROTPKX(a) BDK_CSR_TYPE_RSL |
| 826 | #define basename_BDK_FUSF_ROTPKX(a) "FUSF_ROTPKX" |
| 827 | #define device_bar_BDK_FUSF_ROTPKX(a) 0x0 /* PF_BAR0 */ |
| 828 | #define busnum_BDK_FUSF_ROTPKX(a) (a) |
| 829 | #define arguments_BDK_FUSF_ROTPKX(a) (a),-1,-1,-1 |
| 830 | |
| 831 | /** |
| 832 | * Register (RSL) fusf_ssk# |
| 833 | * |
| 834 | * Field Fuse Secret Symmetric Key Registers |
| 835 | */ |
| 836 | union bdk_fusf_sskx |
| 837 | { |
| 838 | uint64_t u; |
| 839 | struct bdk_fusf_sskx_s |
| 840 | { |
| 841 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 842 | uint64_t dat : 64; /**< [ 63: 0](SRO) Secret symmetric key (SSK). Reads field fuses FUSF_FUSE_NUM_E::SSK(). */ |
| 843 | #else /* Word 0 - Little Endian */ |
| 844 | uint64_t dat : 64; /**< [ 63: 0](SRO) Secret symmetric key (SSK). Reads field fuses FUSF_FUSE_NUM_E::SSK(). */ |
| 845 | #endif /* Word 0 - End */ |
| 846 | } s; |
| 847 | /* struct bdk_fusf_sskx_s cn; */ |
| 848 | }; |
| 849 | typedef union bdk_fusf_sskx bdk_fusf_sskx_t; |
| 850 | |
| 851 | static inline uint64_t BDK_FUSF_SSKX(unsigned long a) __attribute__ ((pure, always_inline)); |
| 852 | static inline uint64_t BDK_FUSF_SSKX(unsigned long a) |
| 853 | { |
| 854 | if (a<=1) |
| 855 | return 0x87e004000080ll + 8ll * ((a) & 0x1); |
| 856 | __bdk_csr_fatal("FUSF_SSKX", 1, a, 0, 0, 0); |
| 857 | } |
| 858 | |
| 859 | #define typedef_BDK_FUSF_SSKX(a) bdk_fusf_sskx_t |
| 860 | #define bustype_BDK_FUSF_SSKX(a) BDK_CSR_TYPE_RSL |
| 861 | #define basename_BDK_FUSF_SSKX(a) "FUSF_SSKX" |
| 862 | #define device_bar_BDK_FUSF_SSKX(a) 0x0 /* PF_BAR0 */ |
| 863 | #define busnum_BDK_FUSF_SSKX(a) (a) |
| 864 | #define arguments_BDK_FUSF_SSKX(a) (a),-1,-1,-1 |
| 865 | |
| 866 | /** |
| 867 | * Register (RSL) fusf_sw# |
| 868 | * |
| 869 | * Field Fuse Software Fuses Registers |
| 870 | */ |
| 871 | union bdk_fusf_swx |
| 872 | { |
| 873 | uint64_t u; |
| 874 | struct bdk_fusf_swx_s |
| 875 | { |
| 876 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 877 | uint64_t dat : 64; /**< [ 63: 0](SRO) Software assigned fuse data. Reads field fuses FUSF_FUSE_NUM_E::SW(). */ |
| 878 | #else /* Word 0 - Little Endian */ |
| 879 | uint64_t dat : 64; /**< [ 63: 0](SRO) Software assigned fuse data. Reads field fuses FUSF_FUSE_NUM_E::SW(). */ |
| 880 | #endif /* Word 0 - End */ |
| 881 | } s; |
| 882 | /* struct bdk_fusf_swx_s cn; */ |
| 883 | }; |
| 884 | typedef union bdk_fusf_swx bdk_fusf_swx_t; |
| 885 | |
| 886 | static inline uint64_t BDK_FUSF_SWX(unsigned long a) __attribute__ ((pure, always_inline)); |
| 887 | static inline uint64_t BDK_FUSF_SWX(unsigned long a) |
| 888 | { |
| 889 | if (a<=7) |
| 890 | return 0x87e0040000c0ll + 8ll * ((a) & 0x7); |
| 891 | __bdk_csr_fatal("FUSF_SWX", 1, a, 0, 0, 0); |
| 892 | } |
| 893 | |
| 894 | #define typedef_BDK_FUSF_SWX(a) bdk_fusf_swx_t |
| 895 | #define bustype_BDK_FUSF_SWX(a) BDK_CSR_TYPE_RSL |
| 896 | #define basename_BDK_FUSF_SWX(a) "FUSF_SWX" |
| 897 | #define device_bar_BDK_FUSF_SWX(a) 0x0 /* PF_BAR0 */ |
| 898 | #define busnum_BDK_FUSF_SWX(a) (a) |
| 899 | #define arguments_BDK_FUSF_SWX(a) (a),-1,-1,-1 |
| 900 | |
| 901 | /** |
| 902 | * Register (RSL) fusf_wadr |
| 903 | * |
| 904 | * Field Fuse Write Address Register |
| 905 | */ |
| 906 | union bdk_fusf_wadr |
| 907 | { |
| 908 | uint64_t u; |
| 909 | struct bdk_fusf_wadr_s |
| 910 | { |
| 911 | #if __BYTE_ORDER == __BIG_ENDIAN /* Word 0 - Big Endian */ |
| 912 | uint64_t reserved_4_63 : 60; |
| 913 | uint64_t addr : 4; /**< [ 3: 0](SR/W) Indicates which of the banks of 128 fuses to blow. Enumerated by FUSF_FUSE_NUM_E\<10:7\>. */ |
| 914 | #else /* Word 0 - Little Endian */ |
| 915 | uint64_t addr : 4; /**< [ 3: 0](SR/W) Indicates which of the banks of 128 fuses to blow. Enumerated by FUSF_FUSE_NUM_E\<10:7\>. */ |
| 916 | uint64_t reserved_4_63 : 60; |
| 917 | #endif /* Word 0 - End */ |
| 918 | } s; |
| 919 | /* struct bdk_fusf_wadr_s cn; */ |
| 920 | }; |
| 921 | typedef union bdk_fusf_wadr bdk_fusf_wadr_t; |
| 922 | |
| 923 | #define BDK_FUSF_WADR BDK_FUSF_WADR_FUNC() |
| 924 | static inline uint64_t BDK_FUSF_WADR_FUNC(void) __attribute__ ((pure, always_inline)); |
| 925 | static inline uint64_t BDK_FUSF_WADR_FUNC(void) |
| 926 | { |
| 927 | if (CAVIUM_IS_MODEL(CAVIUM_CN8XXX)) |
| 928 | return 0x87e004000108ll; |
| 929 | __bdk_csr_fatal("FUSF_WADR", 0, 0, 0, 0, 0); |
| 930 | } |
| 931 | |
| 932 | #define typedef_BDK_FUSF_WADR bdk_fusf_wadr_t |
| 933 | #define bustype_BDK_FUSF_WADR BDK_CSR_TYPE_RSL |
| 934 | #define basename_BDK_FUSF_WADR "FUSF_WADR" |
| 935 | #define device_bar_BDK_FUSF_WADR 0x0 /* PF_BAR0 */ |
| 936 | #define busnum_BDK_FUSF_WADR 0 |
| 937 | #define arguments_BDK_FUSF_WADR -1,-1,-1,-1 |
| 938 | |
| 939 | #endif /* __BDK_CSRS_FUSF_H__ */ |