1135446Strhodes/***********************license start*************** 2254402Serwin * Copyright (c) 2003-2012 Cavium Inc. (support@cavium.com). All rights 3135446Strhodes * reserved. 4135446Strhodes * 5193149Sdougb * 6135446Strhodes * Redistribution and use in source and binary forms, with or without 7135446Strhodes * modification, are permitted provided that the following conditions are 8135446Strhodes * met: 9135446Strhodes * 10135446Strhodes * * Redistributions of source code must retain the above copyright 11135446Strhodes * notice, this list of conditions and the following disclaimer. 12135446Strhodes * 13135446Strhodes * * Redistributions in binary form must reproduce the above 14135446Strhodes * copyright notice, this list of conditions and the following 15135446Strhodes * disclaimer in the documentation and/or other materials provided 16135446Strhodes * with the distribution. 17135446Strhodes 18234010Sdougb * * Neither the name of Cavium Inc. nor the names of 19135446Strhodes * its contributors may be used to endorse or promote products 20170222Sdougb * derived from this software without specific prior written 21170222Sdougb * permission. 22170222Sdougb 23135446Strhodes * This Software, including technical data, may be subject to U.S. export control 24135446Strhodes * laws, including the U.S. Export Administration Act and its associated 25135446Strhodes * regulations, and may be subject to export or import regulations in other 26135446Strhodes * countries. 27135446Strhodes 28135446Strhodes * TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS PROVIDED "AS IS" 29135446Strhodes * AND WITH ALL FAULTS AND CAVIUM INC. MAKES NO PROMISES, REPRESENTATIONS OR 30135446Strhodes * WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY, OR OTHERWISE, WITH RESPECT TO 31135446Strhodes * THE SOFTWARE, INCLUDING ITS CONDITION, ITS CONFORMITY TO ANY REPRESENTATION OR 32135446Strhodes * DESCRIPTION, OR THE EXISTENCE OF ANY LATENT OR PATENT DEFECTS, AND CAVIUM 33135446Strhodes * SPECIFICALLY DISCLAIMS ALL IMPLIED (IF ANY) WARRANTIES OF TITLE, 34193149Sdougb * MERCHANTABILITY, NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, LACK OF 35193149Sdougb * VIRUSES, ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION OR 36193149Sdougb * CORRESPONDENCE TO DESCRIPTION. THE ENTIRE RISK ARISING OUT OF USE OR 37135446Strhodes * PERFORMANCE OF THE SOFTWARE LIES WITH YOU. 38135446Strhodes ***********************license end**************************************/ 39135446Strhodes 40135446Strhodes 41135446Strhodes/** 42135446Strhodes * cvmx-asxx-defs.h 43135446Strhodes * 44135446Strhodes * Configuration and status register (CSR) type definitions for 45135446Strhodes * Octeon asxx. 46135446Strhodes * 47135446Strhodes * This file is auto generated. Do not edit. 48170222Sdougb * 49135446Strhodes * <hr>$Revision$<hr> 50135446Strhodes * 51135446Strhodes */ 52135446Strhodes#ifndef __CVMX_ASXX_DEFS_H__ 53135446Strhodes#define __CVMX_ASXX_DEFS_H__ 54135446Strhodes 55135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 56135446Strhodesstatic inline uint64_t CVMX_ASXX_GMII_RX_CLK_SET(unsigned long block_id) 57135446Strhodes{ 58135446Strhodes if (!( 59135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 60135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 61135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))))) 62135446Strhodes cvmx_warn("CVMX_ASXX_GMII_RX_CLK_SET(%lu) is invalid on this chip\n", block_id); 63135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000180ull); 64135446Strhodes} 65135446Strhodes#else 66135446Strhodes#define CVMX_ASXX_GMII_RX_CLK_SET(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000180ull)) 67135446Strhodes#endif 68135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 69135446Strhodesstatic inline uint64_t CVMX_ASXX_GMII_RX_DAT_SET(unsigned long block_id) 70135446Strhodes{ 71135446Strhodes if (!( 72135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 73135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 74135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))))) 75135446Strhodes cvmx_warn("CVMX_ASXX_GMII_RX_DAT_SET(%lu) is invalid on this chip\n", block_id); 76135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000188ull); 77135446Strhodes} 78135446Strhodes#else 79135446Strhodes#define CVMX_ASXX_GMII_RX_DAT_SET(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000188ull)) 80135446Strhodes#endif 81135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 82135446Strhodesstatic inline uint64_t CVMX_ASXX_INT_EN(unsigned long block_id) 83135446Strhodes{ 84135446Strhodes if (!( 85135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 86135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 87135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 88135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))) || 89135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 90135446Strhodes cvmx_warn("CVMX_ASXX_INT_EN(%lu) is invalid on this chip\n", block_id); 91135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000018ull) + ((block_id) & 1) * 0x8000000ull; 92135446Strhodes} 93135446Strhodes#else 94135446Strhodes#define CVMX_ASXX_INT_EN(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000018ull) + ((block_id) & 1) * 0x8000000ull) 95135446Strhodes#endif 96135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 97135446Strhodesstatic inline uint64_t CVMX_ASXX_INT_REG(unsigned long block_id) 98135446Strhodes{ 99135446Strhodes if (!( 100135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 101135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 102135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 103135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))) || 104135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 105135446Strhodes cvmx_warn("CVMX_ASXX_INT_REG(%lu) is invalid on this chip\n", block_id); 106135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000010ull) + ((block_id) & 1) * 0x8000000ull; 107135446Strhodes} 108135446Strhodes#else 109135446Strhodes#define CVMX_ASXX_INT_REG(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000010ull) + ((block_id) & 1) * 0x8000000ull) 110135446Strhodes#endif 111135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 112135446Strhodesstatic inline uint64_t CVMX_ASXX_MII_RX_DAT_SET(unsigned long block_id) 113135446Strhodes{ 114135446Strhodes if (!( 115135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 116135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))))) 117135446Strhodes cvmx_warn("CVMX_ASXX_MII_RX_DAT_SET(%lu) is invalid on this chip\n", block_id); 118135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000190ull); 119135446Strhodes} 120135446Strhodes#else 121135446Strhodes#define CVMX_ASXX_MII_RX_DAT_SET(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000190ull)) 122135446Strhodes#endif 123135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 124135446Strhodesstatic inline uint64_t CVMX_ASXX_PRT_LOOP(unsigned long block_id) 125135446Strhodes{ 126135446Strhodes if (!( 127135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 128135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 129135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 130135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))) || 131135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 132135446Strhodes cvmx_warn("CVMX_ASXX_PRT_LOOP(%lu) is invalid on this chip\n", block_id); 133135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000040ull) + ((block_id) & 1) * 0x8000000ull; 134165071Sdougb} 135135446Strhodes#else 136135446Strhodes#define CVMX_ASXX_PRT_LOOP(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000040ull) + ((block_id) & 1) * 0x8000000ull) 137135446Strhodes#endif 138135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 139135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_BYPASS(unsigned long block_id) 140135446Strhodes{ 141135446Strhodes if (!( 142135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 143135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 144135446Strhodes cvmx_warn("CVMX_ASXX_RLD_BYPASS(%lu) is invalid on this chip\n", block_id); 145135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000248ull) + ((block_id) & 1) * 0x8000000ull; 146135446Strhodes} 147135446Strhodes#else 148135446Strhodes#define CVMX_ASXX_RLD_BYPASS(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000248ull) + ((block_id) & 1) * 0x8000000ull) 149165071Sdougb#endif 150135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 151135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_BYPASS_SETTING(unsigned long block_id) 152135446Strhodes{ 153135446Strhodes if (!( 154135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 155135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 156135446Strhodes cvmx_warn("CVMX_ASXX_RLD_BYPASS_SETTING(%lu) is invalid on this chip\n", block_id); 157135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000250ull) + ((block_id) & 1) * 0x8000000ull; 158135446Strhodes} 159193149Sdougb#else 160135446Strhodes#define CVMX_ASXX_RLD_BYPASS_SETTING(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000250ull) + ((block_id) & 1) * 0x8000000ull) 161135446Strhodes#endif 162135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 163135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_COMP(unsigned long block_id) 164193149Sdougb{ 165135446Strhodes if (!( 166165071Sdougb (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 167135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 168135446Strhodes cvmx_warn("CVMX_ASXX_RLD_COMP(%lu) is invalid on this chip\n", block_id); 169135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000220ull) + ((block_id) & 1) * 0x8000000ull; 170135446Strhodes} 171165071Sdougb#else 172193149Sdougb#define CVMX_ASXX_RLD_COMP(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000220ull) + ((block_id) & 1) * 0x8000000ull) 173135446Strhodes#endif 174135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 175135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_DATA_DRV(unsigned long block_id) 176193149Sdougb{ 177135446Strhodes if (!( 178135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 179135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 180193149Sdougb cvmx_warn("CVMX_ASXX_RLD_DATA_DRV(%lu) is invalid on this chip\n", block_id); 181193149Sdougb return CVMX_ADD_IO_SEG(0x00011800B0000218ull) + ((block_id) & 1) * 0x8000000ull; 182193149Sdougb} 183193149Sdougb#else 184193149Sdougb#define CVMX_ASXX_RLD_DATA_DRV(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000218ull) + ((block_id) & 1) * 0x8000000ull) 185193149Sdougb#endif 186193149Sdougb#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 187135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_FCRAM_MODE(unsigned long block_id) 188193149Sdougb{ 189135446Strhodes if (!( 190135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))))) 191135446Strhodes cvmx_warn("CVMX_ASXX_RLD_FCRAM_MODE(%lu) is invalid on this chip\n", block_id); 192135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000210ull) + ((block_id) & 1) * 0x8000000ull; 193135446Strhodes} 194135446Strhodes#else 195135446Strhodes#define CVMX_ASXX_RLD_FCRAM_MODE(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000210ull) + ((block_id) & 1) * 0x8000000ull) 196135446Strhodes#endif 197135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 198135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_NCTL_STRONG(unsigned long block_id) 199135446Strhodes{ 200135446Strhodes if (!( 201135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 202135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 203135446Strhodes cvmx_warn("CVMX_ASXX_RLD_NCTL_STRONG(%lu) is invalid on this chip\n", block_id); 204135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000230ull) + ((block_id) & 1) * 0x8000000ull; 205135446Strhodes} 206135446Strhodes#else 207135446Strhodes#define CVMX_ASXX_RLD_NCTL_STRONG(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000230ull) + ((block_id) & 1) * 0x8000000ull) 208135446Strhodes#endif 209135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 210135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_NCTL_WEAK(unsigned long block_id) 211135446Strhodes{ 212135446Strhodes if (!( 213135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 214135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 215193149Sdougb cvmx_warn("CVMX_ASXX_RLD_NCTL_WEAK(%lu) is invalid on this chip\n", block_id); 216135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000240ull) + ((block_id) & 1) * 0x8000000ull; 217135446Strhodes} 218135446Strhodes#else 219135446Strhodes#define CVMX_ASXX_RLD_NCTL_WEAK(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000240ull) + ((block_id) & 1) * 0x8000000ull) 220135446Strhodes#endif 221135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 222135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_PCTL_STRONG(unsigned long block_id) 223135446Strhodes{ 224135446Strhodes if (!( 225135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 226135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 227135446Strhodes cvmx_warn("CVMX_ASXX_RLD_PCTL_STRONG(%lu) is invalid on this chip\n", block_id); 228135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000228ull) + ((block_id) & 1) * 0x8000000ull; 229135446Strhodes} 230135446Strhodes#else 231135446Strhodes#define CVMX_ASXX_RLD_PCTL_STRONG(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000228ull) + ((block_id) & 1) * 0x8000000ull) 232135446Strhodes#endif 233135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 234135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_PCTL_WEAK(unsigned long block_id) 235135446Strhodes{ 236135446Strhodes if (!( 237135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 238135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 239135446Strhodes cvmx_warn("CVMX_ASXX_RLD_PCTL_WEAK(%lu) is invalid on this chip\n", block_id); 240135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000238ull) + ((block_id) & 1) * 0x8000000ull; 241135446Strhodes} 242135446Strhodes#else 243135446Strhodes#define CVMX_ASXX_RLD_PCTL_WEAK(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000238ull) + ((block_id) & 1) * 0x8000000ull) 244135446Strhodes#endif 245135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 246135446Strhodesstatic inline uint64_t CVMX_ASXX_RLD_SETTING(unsigned long block_id) 247135446Strhodes{ 248135446Strhodes if (!( 249135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 250135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 251135446Strhodes cvmx_warn("CVMX_ASXX_RLD_SETTING(%lu) is invalid on this chip\n", block_id); 252135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000258ull) + ((block_id) & 1) * 0x8000000ull; 253135446Strhodes} 254135446Strhodes#else 255135446Strhodes#define CVMX_ASXX_RLD_SETTING(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000258ull) + ((block_id) & 1) * 0x8000000ull) 256135446Strhodes#endif 257135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 258135446Strhodesstatic inline uint64_t CVMX_ASXX_RX_CLK_SETX(unsigned long offset, unsigned long block_id) 259135446Strhodes{ 260135446Strhodes if (!( 261135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && (((offset <= 2)) && ((block_id == 0)))) || 262135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && (((offset <= 2)) && ((block_id == 0)))) || 263135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && (((offset <= 3)) && ((block_id <= 1)))) || 264135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && (((offset <= 2)) && ((block_id == 0)))) || 265135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && (((offset <= 3)) && ((block_id <= 1)))))) 266135446Strhodes cvmx_warn("CVMX_ASXX_RX_CLK_SETX(%lu,%lu) is invalid on this chip\n", offset, block_id); 267135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000020ull) + (((offset) & 3) + ((block_id) & 1) * 0x1000000ull) * 8; 268135446Strhodes} 269135446Strhodes#else 270135446Strhodes#define CVMX_ASXX_RX_CLK_SETX(offset, block_id) (CVMX_ADD_IO_SEG(0x00011800B0000020ull) + (((offset) & 3) + ((block_id) & 1) * 0x1000000ull) * 8) 271135446Strhodes#endif 272135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 273135446Strhodesstatic inline uint64_t CVMX_ASXX_RX_PRT_EN(unsigned long block_id) 274135446Strhodes{ 275135446Strhodes if (!( 276135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 277135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 278135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 279135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))) || 280135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 281135446Strhodes cvmx_warn("CVMX_ASXX_RX_PRT_EN(%lu) is invalid on this chip\n", block_id); 282135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000000ull) + ((block_id) & 1) * 0x8000000ull; 283135446Strhodes} 284135446Strhodes#else 285135446Strhodes#define CVMX_ASXX_RX_PRT_EN(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000000ull) + ((block_id) & 1) * 0x8000000ull) 286135446Strhodes#endif 287135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 288135446Strhodesstatic inline uint64_t CVMX_ASXX_RX_WOL(unsigned long block_id) 289135446Strhodes{ 290135446Strhodes if (!( 291135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))))) 292135446Strhodes cvmx_warn("CVMX_ASXX_RX_WOL(%lu) is invalid on this chip\n", block_id); 293135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000100ull) + ((block_id) & 1) * 0x8000000ull; 294135446Strhodes} 295135446Strhodes#else 296135446Strhodes#define CVMX_ASXX_RX_WOL(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000100ull) + ((block_id) & 1) * 0x8000000ull) 297135446Strhodes#endif 298135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 299135446Strhodesstatic inline uint64_t CVMX_ASXX_RX_WOL_MSK(unsigned long block_id) 300135446Strhodes{ 301135446Strhodes if (!( 302135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))))) 303135446Strhodes cvmx_warn("CVMX_ASXX_RX_WOL_MSK(%lu) is invalid on this chip\n", block_id); 304135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000108ull) + ((block_id) & 1) * 0x8000000ull; 305135446Strhodes} 306135446Strhodes#else 307135446Strhodes#define CVMX_ASXX_RX_WOL_MSK(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000108ull) + ((block_id) & 1) * 0x8000000ull) 308135446Strhodes#endif 309135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 310135446Strhodesstatic inline uint64_t CVMX_ASXX_RX_WOL_POWOK(unsigned long block_id) 311135446Strhodes{ 312135446Strhodes if (!( 313135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))))) 314135446Strhodes cvmx_warn("CVMX_ASXX_RX_WOL_POWOK(%lu) is invalid on this chip\n", block_id); 315135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000118ull) + ((block_id) & 1) * 0x8000000ull; 316135446Strhodes} 317135446Strhodes#else 318135446Strhodes#define CVMX_ASXX_RX_WOL_POWOK(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000118ull) + ((block_id) & 1) * 0x8000000ull) 319135446Strhodes#endif 320135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 321135446Strhodesstatic inline uint64_t CVMX_ASXX_RX_WOL_SIG(unsigned long block_id) 322135446Strhodes{ 323135446Strhodes if (!( 324135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))))) 325135446Strhodes cvmx_warn("CVMX_ASXX_RX_WOL_SIG(%lu) is invalid on this chip\n", block_id); 326135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000110ull) + ((block_id) & 1) * 0x8000000ull; 327135446Strhodes} 328135446Strhodes#else 329135446Strhodes#define CVMX_ASXX_RX_WOL_SIG(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000110ull) + ((block_id) & 1) * 0x8000000ull) 330135446Strhodes#endif 331135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 332135446Strhodesstatic inline uint64_t CVMX_ASXX_TX_CLK_SETX(unsigned long offset, unsigned long block_id) 333135446Strhodes{ 334135446Strhodes if (!( 335135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && (((offset <= 2)) && ((block_id == 0)))) || 336135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && (((offset <= 2)) && ((block_id == 0)))) || 337135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && (((offset <= 3)) && ((block_id <= 1)))) || 338135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && (((offset <= 2)) && ((block_id == 0)))) || 339135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && (((offset <= 3)) && ((block_id <= 1)))))) 340135446Strhodes cvmx_warn("CVMX_ASXX_TX_CLK_SETX(%lu,%lu) is invalid on this chip\n", offset, block_id); 341135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000048ull) + (((offset) & 3) + ((block_id) & 1) * 0x1000000ull) * 8; 342135446Strhodes} 343135446Strhodes#else 344135446Strhodes#define CVMX_ASXX_TX_CLK_SETX(offset, block_id) (CVMX_ADD_IO_SEG(0x00011800B0000048ull) + (((offset) & 3) + ((block_id) & 1) * 0x1000000ull) * 8) 345135446Strhodes#endif 346135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 347135446Strhodesstatic inline uint64_t CVMX_ASXX_TX_COMP_BYP(unsigned long block_id) 348135446Strhodes{ 349135446Strhodes if (!( 350135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 351135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 352135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 353135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))) || 354135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 355135446Strhodes cvmx_warn("CVMX_ASXX_TX_COMP_BYP(%lu) is invalid on this chip\n", block_id); 356135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000068ull) + ((block_id) & 1) * 0x8000000ull; 357135446Strhodes} 358135446Strhodes#else 359135446Strhodes#define CVMX_ASXX_TX_COMP_BYP(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000068ull) + ((block_id) & 1) * 0x8000000ull) 360135446Strhodes#endif 361135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 362135446Strhodesstatic inline uint64_t CVMX_ASXX_TX_HI_WATERX(unsigned long offset, unsigned long block_id) 363135446Strhodes{ 364135446Strhodes if (!( 365135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && (((offset <= 2)) && ((block_id == 0)))) || 366135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && (((offset <= 2)) && ((block_id == 0)))) || 367135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && (((offset <= 3)) && ((block_id <= 1)))) || 368135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && (((offset <= 2)) && ((block_id == 0)))) || 369135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && (((offset <= 3)) && ((block_id <= 1)))))) 370135446Strhodes cvmx_warn("CVMX_ASXX_TX_HI_WATERX(%lu,%lu) is invalid on this chip\n", offset, block_id); 371135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000080ull) + (((offset) & 3) + ((block_id) & 1) * 0x1000000ull) * 8; 372135446Strhodes} 373135446Strhodes#else 374135446Strhodes#define CVMX_ASXX_TX_HI_WATERX(offset, block_id) (CVMX_ADD_IO_SEG(0x00011800B0000080ull) + (((offset) & 3) + ((block_id) & 1) * 0x1000000ull) * 8) 375135446Strhodes#endif 376135446Strhodes#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 377135446Strhodesstatic inline uint64_t CVMX_ASXX_TX_PRT_EN(unsigned long block_id) 378135446Strhodes{ 379135446Strhodes if (!( 380135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN30XX) && ((block_id == 0))) || 381135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN31XX) && ((block_id == 0))) || 382135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN38XX) && ((block_id <= 1))) || 383135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN50XX) && ((block_id == 0))) || 384135446Strhodes (OCTEON_IS_MODEL(OCTEON_CN58XX) && ((block_id <= 1))))) 385135446Strhodes cvmx_warn("CVMX_ASXX_TX_PRT_EN(%lu) is invalid on this chip\n", block_id); 386135446Strhodes return CVMX_ADD_IO_SEG(0x00011800B0000008ull) + ((block_id) & 1) * 0x8000000ull; 387135446Strhodes} 388135446Strhodes#else 389135446Strhodes#define CVMX_ASXX_TX_PRT_EN(block_id) (CVMX_ADD_IO_SEG(0x00011800B0000008ull) + ((block_id) & 1) * 0x8000000ull) 390135446Strhodes#endif 391135446Strhodes 392135446Strhodes/** 393135446Strhodes * cvmx_asx#_gmii_rx_clk_set 394135446Strhodes * 395135446Strhodes * ASX_GMII_RX_CLK_SET = GMII Clock delay setting 396135446Strhodes * 397135446Strhodes */ 398135446Strhodesunion cvmx_asxx_gmii_rx_clk_set { 399135446Strhodes uint64_t u64; 400135446Strhodes struct cvmx_asxx_gmii_rx_clk_set_s { 401135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 402135446Strhodes uint64_t reserved_5_63 : 59; 403135446Strhodes uint64_t setting : 5; /**< Setting to place on the RXCLK (GMII receive clk) 404135446Strhodes delay line. The intrinsic delay can range from 405135446Strhodes 50ps to 80ps per tap. */ 406135446Strhodes#else 407135446Strhodes uint64_t setting : 5; 408135446Strhodes uint64_t reserved_5_63 : 59; 409135446Strhodes#endif 410135446Strhodes } s; 411135446Strhodes struct cvmx_asxx_gmii_rx_clk_set_s cn30xx; 412135446Strhodes struct cvmx_asxx_gmii_rx_clk_set_s cn31xx; 413135446Strhodes struct cvmx_asxx_gmii_rx_clk_set_s cn50xx; 414135446Strhodes}; 415135446Strhodestypedef union cvmx_asxx_gmii_rx_clk_set cvmx_asxx_gmii_rx_clk_set_t; 416135446Strhodes 417135446Strhodes/** 418135446Strhodes * cvmx_asx#_gmii_rx_dat_set 419135446Strhodes * 420135446Strhodes * ASX_GMII_RX_DAT_SET = GMII Clock delay setting 421135446Strhodes * 422135446Strhodes */ 423135446Strhodesunion cvmx_asxx_gmii_rx_dat_set { 424135446Strhodes uint64_t u64; 425135446Strhodes struct cvmx_asxx_gmii_rx_dat_set_s { 426135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 427135446Strhodes uint64_t reserved_5_63 : 59; 428135446Strhodes uint64_t setting : 5; /**< Setting to place on the RXD (GMII receive data) 429135446Strhodes delay lines. The intrinsic delay can range from 430135446Strhodes 50ps to 80ps per tap. */ 431135446Strhodes#else 432135446Strhodes uint64_t setting : 5; 433135446Strhodes uint64_t reserved_5_63 : 59; 434135446Strhodes#endif 435135446Strhodes } s; 436135446Strhodes struct cvmx_asxx_gmii_rx_dat_set_s cn30xx; 437135446Strhodes struct cvmx_asxx_gmii_rx_dat_set_s cn31xx; 438135446Strhodes struct cvmx_asxx_gmii_rx_dat_set_s cn50xx; 439135446Strhodes}; 440135446Strhodestypedef union cvmx_asxx_gmii_rx_dat_set cvmx_asxx_gmii_rx_dat_set_t; 441135446Strhodes 442135446Strhodes/** 443135446Strhodes * cvmx_asx#_int_en 444135446Strhodes * 445135446Strhodes * ASX_INT_EN = Interrupt Enable 446135446Strhodes * 447135446Strhodes */ 448135446Strhodesunion cvmx_asxx_int_en { 449135446Strhodes uint64_t u64; 450135446Strhodes struct cvmx_asxx_int_en_s { 451135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 452135446Strhodes uint64_t reserved_12_63 : 52; 453135446Strhodes uint64_t txpsh : 4; /**< TX FIFO overflow on RMGII port */ 454135446Strhodes uint64_t txpop : 4; /**< TX FIFO underflow on RMGII port */ 455135446Strhodes uint64_t ovrflw : 4; /**< RX FIFO overflow on RMGII port */ 456135446Strhodes#else 457135446Strhodes uint64_t ovrflw : 4; 458135446Strhodes uint64_t txpop : 4; 459135446Strhodes uint64_t txpsh : 4; 460135446Strhodes uint64_t reserved_12_63 : 52; 461153816Sdougb#endif 462153816Sdougb } s; 463135446Strhodes struct cvmx_asxx_int_en_cn30xx { 464153816Sdougb#ifdef __BIG_ENDIAN_BITFIELD 465153816Sdougb uint64_t reserved_11_63 : 53; 466135446Strhodes uint64_t txpsh : 3; /**< TX FIFO overflow on RMGII port */ 467153816Sdougb uint64_t reserved_7_7 : 1; 468135446Strhodes uint64_t txpop : 3; /**< TX FIFO underflow on RMGII port */ 469153816Sdougb uint64_t reserved_3_3 : 1; 470135446Strhodes uint64_t ovrflw : 3; /**< RX FIFO overflow on RMGII port */ 471135446Strhodes#else 472135446Strhodes uint64_t ovrflw : 3; 473135446Strhodes uint64_t reserved_3_3 : 1; 474153816Sdougb uint64_t txpop : 3; 475153816Sdougb uint64_t reserved_7_7 : 1; 476153816Sdougb uint64_t txpsh : 3; 477153816Sdougb uint64_t reserved_11_63 : 53; 478153816Sdougb#endif 479153816Sdougb } cn30xx; 480135446Strhodes struct cvmx_asxx_int_en_cn30xx cn31xx; 481135446Strhodes struct cvmx_asxx_int_en_s cn38xx; 482135446Strhodes struct cvmx_asxx_int_en_s cn38xxp2; 483135446Strhodes struct cvmx_asxx_int_en_cn30xx cn50xx; 484135446Strhodes struct cvmx_asxx_int_en_s cn58xx; 485135446Strhodes struct cvmx_asxx_int_en_s cn58xxp1; 486135446Strhodes}; 487135446Strhodestypedef union cvmx_asxx_int_en cvmx_asxx_int_en_t; 488135446Strhodes 489135446Strhodes/** 490135446Strhodes * cvmx_asx#_int_reg 491135446Strhodes * 492135446Strhodes * ASX_INT_REG = Interrupt Register 493135446Strhodes * 494135446Strhodes */ 495135446Strhodesunion cvmx_asxx_int_reg { 496135446Strhodes uint64_t u64; 497135446Strhodes struct cvmx_asxx_int_reg_s { 498135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 499135446Strhodes uint64_t reserved_12_63 : 52; 500135446Strhodes uint64_t txpsh : 4; /**< TX FIFO overflow on RMGII port */ 501135446Strhodes uint64_t txpop : 4; /**< TX FIFO underflow on RMGII port */ 502135446Strhodes uint64_t ovrflw : 4; /**< RX FIFO overflow on RMGII port */ 503135446Strhodes#else 504135446Strhodes uint64_t ovrflw : 4; 505193149Sdougb uint64_t txpop : 4; 506135446Strhodes uint64_t txpsh : 4; 507135446Strhodes uint64_t reserved_12_63 : 52; 508135446Strhodes#endif 509135446Strhodes } s; 510135446Strhodes struct cvmx_asxx_int_reg_cn30xx { 511135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 512135446Strhodes uint64_t reserved_11_63 : 53; 513135446Strhodes uint64_t txpsh : 3; /**< TX FIFO overflow on RMGII port */ 514135446Strhodes uint64_t reserved_7_7 : 1; 515135446Strhodes uint64_t txpop : 3; /**< TX FIFO underflow on RMGII port */ 516165071Sdougb uint64_t reserved_3_3 : 1; 517135446Strhodes uint64_t ovrflw : 3; /**< RX FIFO overflow on RMGII port */ 518135446Strhodes#else 519135446Strhodes uint64_t ovrflw : 3; 520135446Strhodes uint64_t reserved_3_3 : 1; 521135446Strhodes uint64_t txpop : 3; 522135446Strhodes uint64_t reserved_7_7 : 1; 523153816Sdougb uint64_t txpsh : 3; 524135446Strhodes uint64_t reserved_11_63 : 53; 525135446Strhodes#endif 526135446Strhodes } cn30xx; 527135446Strhodes struct cvmx_asxx_int_reg_cn30xx cn31xx; 528135446Strhodes struct cvmx_asxx_int_reg_s cn38xx; 529135446Strhodes struct cvmx_asxx_int_reg_s cn38xxp2; 530135446Strhodes struct cvmx_asxx_int_reg_cn30xx cn50xx; 531135446Strhodes struct cvmx_asxx_int_reg_s cn58xx; 532135446Strhodes struct cvmx_asxx_int_reg_s cn58xxp1; 533135446Strhodes}; 534135446Strhodestypedef union cvmx_asxx_int_reg cvmx_asxx_int_reg_t; 535135446Strhodes 536135446Strhodes/** 537135446Strhodes * cvmx_asx#_mii_rx_dat_set 538135446Strhodes * 539254402Serwin * ASX_MII_RX_DAT_SET = GMII Clock delay setting 540135446Strhodes * 541135446Strhodes */ 542135446Strhodesunion cvmx_asxx_mii_rx_dat_set { 543135446Strhodes uint64_t u64; 544135446Strhodes struct cvmx_asxx_mii_rx_dat_set_s { 545135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 546135446Strhodes uint64_t reserved_5_63 : 59; 547135446Strhodes uint64_t setting : 5; /**< Setting to place on the RXD (MII receive data) 548135446Strhodes delay lines. The intrinsic delay can range from 549135446Strhodes 50ps to 80ps per tap. */ 550135446Strhodes#else 551135446Strhodes uint64_t setting : 5; 552135446Strhodes uint64_t reserved_5_63 : 59; 553135446Strhodes#endif 554135446Strhodes } s; 555135446Strhodes struct cvmx_asxx_mii_rx_dat_set_s cn30xx; 556135446Strhodes struct cvmx_asxx_mii_rx_dat_set_s cn50xx; 557135446Strhodes}; 558135446Strhodestypedef union cvmx_asxx_mii_rx_dat_set cvmx_asxx_mii_rx_dat_set_t; 559135446Strhodes 560135446Strhodes/** 561135446Strhodes * cvmx_asx#_prt_loop 562135446Strhodes * 563135446Strhodes * ASX_PRT_LOOP = Internal Loopback mode - TX FIFO output goes into RX FIFO (and maybe pins) 564135446Strhodes * 565135446Strhodes */ 566135446Strhodesunion cvmx_asxx_prt_loop { 567135446Strhodes uint64_t u64; 568135446Strhodes struct cvmx_asxx_prt_loop_s { 569135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 570135446Strhodes uint64_t reserved_8_63 : 56; 571135446Strhodes uint64_t ext_loop : 4; /**< External Loopback Enable 572135446Strhodes 0 = No Loopback (TX FIFO is filled by RMGII) 573135446Strhodes 1 = RX FIFO drives the TX FIFO 574135446Strhodes - GMX_PRT_CFG[DUPLEX] must be 1 (FullDuplex) 575135446Strhodes - GMX_PRT_CFG[SPEED] must be 1 (GigE speed) 576135446Strhodes - core clock > 250MHZ 577135446Strhodes - rxc must not deviate from the +-50ppm 578135446Strhodes - if txc>rxc, idle cycle may drop over time */ 579135446Strhodes uint64_t int_loop : 4; /**< Internal Loopback Enable 580135446Strhodes 0 = No Loopback (RX FIFO is filled by RMGII pins) 581135446Strhodes 1 = TX FIFO drives the RX FIFO 582135446Strhodes Note, in internal loop-back mode, the RGMII link 583135446Strhodes status is not used (since there is no real PHY). 584135446Strhodes Software cannot use the inband status. */ 585135446Strhodes#else 586135446Strhodes uint64_t int_loop : 4; 587135446Strhodes uint64_t ext_loop : 4; 588135446Strhodes uint64_t reserved_8_63 : 56; 589135446Strhodes#endif 590135446Strhodes } s; 591135446Strhodes struct cvmx_asxx_prt_loop_cn30xx { 592135446Strhodes#ifdef __BIG_ENDIAN_BITFIELD 593135446Strhodes uint64_t reserved_7_63 : 57; 594135446Strhodes uint64_t ext_loop : 3; /**< External Loopback Enable 595135446Strhodes 0 = No Loopback (TX FIFO is filled by RMGII) 596135446Strhodes 1 = RX FIFO drives the TX FIFO 597135446Strhodes - GMX_PRT_CFG[DUPLEX] must be 1 (FullDuplex) 598135446Strhodes - GMX_PRT_CFG[SPEED] must be 1 (GigE speed) 599135446Strhodes - core clock > 250MHZ 600135446Strhodes - rxc must not deviate from the +-50ppm 601135446Strhodes - if txc>rxc, idle cycle may drop over time */ 602135446Strhodes uint64_t reserved_3_3 : 1; 603135446Strhodes uint64_t int_loop : 3; /**< Internal Loopback Enable 604135446Strhodes 0 = No Loopback (RX FIFO is filled by RMGII pins) 605 1 = TX FIFO drives the RX FIFO 606 - GMX_PRT_CFG[DUPLEX] must be 1 (FullDuplex) 607 - GMX_PRT_CFG[SPEED] must be 1 (GigE speed) 608 - GMX_TX_CLK[CLK_CNT] must be 1 609 Note, in internal loop-back mode, the RGMII link 610 status is not used (since there is no real PHY). 611 Software cannot use the inband status. */ 612#else 613 uint64_t int_loop : 3; 614 uint64_t reserved_3_3 : 1; 615 uint64_t ext_loop : 3; 616 uint64_t reserved_7_63 : 57; 617#endif 618 } cn30xx; 619 struct cvmx_asxx_prt_loop_cn30xx cn31xx; 620 struct cvmx_asxx_prt_loop_s cn38xx; 621 struct cvmx_asxx_prt_loop_s cn38xxp2; 622 struct cvmx_asxx_prt_loop_cn30xx cn50xx; 623 struct cvmx_asxx_prt_loop_s cn58xx; 624 struct cvmx_asxx_prt_loop_s cn58xxp1; 625}; 626typedef union cvmx_asxx_prt_loop cvmx_asxx_prt_loop_t; 627 628/** 629 * cvmx_asx#_rld_bypass 630 * 631 * ASX_RLD_BYPASS 632 * 633 */ 634union cvmx_asxx_rld_bypass { 635 uint64_t u64; 636 struct cvmx_asxx_rld_bypass_s { 637#ifdef __BIG_ENDIAN_BITFIELD 638 uint64_t reserved_1_63 : 63; 639 uint64_t bypass : 1; /**< When set, the rld_dll setting is bypassed with 640 ASX_RLD_BYPASS_SETTING */ 641#else 642 uint64_t bypass : 1; 643 uint64_t reserved_1_63 : 63; 644#endif 645 } s; 646 struct cvmx_asxx_rld_bypass_s cn38xx; 647 struct cvmx_asxx_rld_bypass_s cn38xxp2; 648 struct cvmx_asxx_rld_bypass_s cn58xx; 649 struct cvmx_asxx_rld_bypass_s cn58xxp1; 650}; 651typedef union cvmx_asxx_rld_bypass cvmx_asxx_rld_bypass_t; 652 653/** 654 * cvmx_asx#_rld_bypass_setting 655 * 656 * ASX_RLD_BYPASS_SETTING 657 * 658 */ 659union cvmx_asxx_rld_bypass_setting { 660 uint64_t u64; 661 struct cvmx_asxx_rld_bypass_setting_s { 662#ifdef __BIG_ENDIAN_BITFIELD 663 uint64_t reserved_5_63 : 59; 664 uint64_t setting : 5; /**< The rld_dll setting bypass value */ 665#else 666 uint64_t setting : 5; 667 uint64_t reserved_5_63 : 59; 668#endif 669 } s; 670 struct cvmx_asxx_rld_bypass_setting_s cn38xx; 671 struct cvmx_asxx_rld_bypass_setting_s cn38xxp2; 672 struct cvmx_asxx_rld_bypass_setting_s cn58xx; 673 struct cvmx_asxx_rld_bypass_setting_s cn58xxp1; 674}; 675typedef union cvmx_asxx_rld_bypass_setting cvmx_asxx_rld_bypass_setting_t; 676 677/** 678 * cvmx_asx#_rld_comp 679 * 680 * ASX_RLD_COMP 681 * 682 */ 683union cvmx_asxx_rld_comp { 684 uint64_t u64; 685 struct cvmx_asxx_rld_comp_s { 686#ifdef __BIG_ENDIAN_BITFIELD 687 uint64_t reserved_9_63 : 55; 688 uint64_t pctl : 5; /**< PCTL Compensation Value 689 These bits reflect the computed compensation 690 values from the built-in compensation circuit. */ 691 uint64_t nctl : 4; /**< These bits reflect the computed compensation 692 values from the built-in compensation circuit. */ 693#else 694 uint64_t nctl : 4; 695 uint64_t pctl : 5; 696 uint64_t reserved_9_63 : 55; 697#endif 698 } s; 699 struct cvmx_asxx_rld_comp_cn38xx { 700#ifdef __BIG_ENDIAN_BITFIELD 701 uint64_t reserved_8_63 : 56; 702 uint64_t pctl : 4; /**< These bits reflect the computed compensation 703 values from the built-in compensation circuit. */ 704 uint64_t nctl : 4; /**< These bits reflect the computed compensation 705 values from the built-in compensation circuit. */ 706#else 707 uint64_t nctl : 4; 708 uint64_t pctl : 4; 709 uint64_t reserved_8_63 : 56; 710#endif 711 } cn38xx; 712 struct cvmx_asxx_rld_comp_cn38xx cn38xxp2; 713 struct cvmx_asxx_rld_comp_s cn58xx; 714 struct cvmx_asxx_rld_comp_s cn58xxp1; 715}; 716typedef union cvmx_asxx_rld_comp cvmx_asxx_rld_comp_t; 717 718/** 719 * cvmx_asx#_rld_data_drv 720 * 721 * ASX_RLD_DATA_DRV 722 * 723 */ 724union cvmx_asxx_rld_data_drv { 725 uint64_t u64; 726 struct cvmx_asxx_rld_data_drv_s { 727#ifdef __BIG_ENDIAN_BITFIELD 728 uint64_t reserved_8_63 : 56; 729 uint64_t pctl : 4; /**< These bits specify a driving strength (positive 730 integer) for the RLD I/Os when the built-in 731 compensation circuit is bypassed. */ 732 uint64_t nctl : 4; /**< These bits specify a driving strength (positive 733 integer) for the RLD I/Os when the built-in 734 compensation circuit is bypassed. */ 735#else 736 uint64_t nctl : 4; 737 uint64_t pctl : 4; 738 uint64_t reserved_8_63 : 56; 739#endif 740 } s; 741 struct cvmx_asxx_rld_data_drv_s cn38xx; 742 struct cvmx_asxx_rld_data_drv_s cn38xxp2; 743 struct cvmx_asxx_rld_data_drv_s cn58xx; 744 struct cvmx_asxx_rld_data_drv_s cn58xxp1; 745}; 746typedef union cvmx_asxx_rld_data_drv cvmx_asxx_rld_data_drv_t; 747 748/** 749 * cvmx_asx#_rld_fcram_mode 750 * 751 * ASX_RLD_FCRAM_MODE 752 * 753 */ 754union cvmx_asxx_rld_fcram_mode { 755 uint64_t u64; 756 struct cvmx_asxx_rld_fcram_mode_s { 757#ifdef __BIG_ENDIAN_BITFIELD 758 uint64_t reserved_1_63 : 63; 759 uint64_t mode : 1; /**< Memory Mode 760 - 0: RLDRAM 761 - 1: FCRAM */ 762#else 763 uint64_t mode : 1; 764 uint64_t reserved_1_63 : 63; 765#endif 766 } s; 767 struct cvmx_asxx_rld_fcram_mode_s cn38xx; 768 struct cvmx_asxx_rld_fcram_mode_s cn38xxp2; 769}; 770typedef union cvmx_asxx_rld_fcram_mode cvmx_asxx_rld_fcram_mode_t; 771 772/** 773 * cvmx_asx#_rld_nctl_strong 774 * 775 * ASX_RLD_NCTL_STRONG 776 * 777 */ 778union cvmx_asxx_rld_nctl_strong { 779 uint64_t u64; 780 struct cvmx_asxx_rld_nctl_strong_s { 781#ifdef __BIG_ENDIAN_BITFIELD 782 uint64_t reserved_5_63 : 59; 783 uint64_t nctl : 5; /**< Duke's drive control */ 784#else 785 uint64_t nctl : 5; 786 uint64_t reserved_5_63 : 59; 787#endif 788 } s; 789 struct cvmx_asxx_rld_nctl_strong_s cn38xx; 790 struct cvmx_asxx_rld_nctl_strong_s cn38xxp2; 791 struct cvmx_asxx_rld_nctl_strong_s cn58xx; 792 struct cvmx_asxx_rld_nctl_strong_s cn58xxp1; 793}; 794typedef union cvmx_asxx_rld_nctl_strong cvmx_asxx_rld_nctl_strong_t; 795 796/** 797 * cvmx_asx#_rld_nctl_weak 798 * 799 * ASX_RLD_NCTL_WEAK 800 * 801 */ 802union cvmx_asxx_rld_nctl_weak { 803 uint64_t u64; 804 struct cvmx_asxx_rld_nctl_weak_s { 805#ifdef __BIG_ENDIAN_BITFIELD 806 uint64_t reserved_5_63 : 59; 807 uint64_t nctl : 5; /**< UNUSED (not needed for CN58XX) */ 808#else 809 uint64_t nctl : 5; 810 uint64_t reserved_5_63 : 59; 811#endif 812 } s; 813 struct cvmx_asxx_rld_nctl_weak_s cn38xx; 814 struct cvmx_asxx_rld_nctl_weak_s cn38xxp2; 815 struct cvmx_asxx_rld_nctl_weak_s cn58xx; 816 struct cvmx_asxx_rld_nctl_weak_s cn58xxp1; 817}; 818typedef union cvmx_asxx_rld_nctl_weak cvmx_asxx_rld_nctl_weak_t; 819 820/** 821 * cvmx_asx#_rld_pctl_strong 822 * 823 * ASX_RLD_PCTL_STRONG 824 * 825 */ 826union cvmx_asxx_rld_pctl_strong { 827 uint64_t u64; 828 struct cvmx_asxx_rld_pctl_strong_s { 829#ifdef __BIG_ENDIAN_BITFIELD 830 uint64_t reserved_5_63 : 59; 831 uint64_t pctl : 5; /**< Duke's drive control */ 832#else 833 uint64_t pctl : 5; 834 uint64_t reserved_5_63 : 59; 835#endif 836 } s; 837 struct cvmx_asxx_rld_pctl_strong_s cn38xx; 838 struct cvmx_asxx_rld_pctl_strong_s cn38xxp2; 839 struct cvmx_asxx_rld_pctl_strong_s cn58xx; 840 struct cvmx_asxx_rld_pctl_strong_s cn58xxp1; 841}; 842typedef union cvmx_asxx_rld_pctl_strong cvmx_asxx_rld_pctl_strong_t; 843 844/** 845 * cvmx_asx#_rld_pctl_weak 846 * 847 * ASX_RLD_PCTL_WEAK 848 * 849 */ 850union cvmx_asxx_rld_pctl_weak { 851 uint64_t u64; 852 struct cvmx_asxx_rld_pctl_weak_s { 853#ifdef __BIG_ENDIAN_BITFIELD 854 uint64_t reserved_5_63 : 59; 855 uint64_t pctl : 5; /**< UNUSED (not needed for CN58XX) */ 856#else 857 uint64_t pctl : 5; 858 uint64_t reserved_5_63 : 59; 859#endif 860 } s; 861 struct cvmx_asxx_rld_pctl_weak_s cn38xx; 862 struct cvmx_asxx_rld_pctl_weak_s cn38xxp2; 863 struct cvmx_asxx_rld_pctl_weak_s cn58xx; 864 struct cvmx_asxx_rld_pctl_weak_s cn58xxp1; 865}; 866typedef union cvmx_asxx_rld_pctl_weak cvmx_asxx_rld_pctl_weak_t; 867 868/** 869 * cvmx_asx#_rld_setting 870 * 871 * ASX_RLD_SETTING 872 * 873 */ 874union cvmx_asxx_rld_setting { 875 uint64_t u64; 876 struct cvmx_asxx_rld_setting_s { 877#ifdef __BIG_ENDIAN_BITFIELD 878 uint64_t reserved_13_63 : 51; 879 uint64_t dfaset : 5; /**< RLD ClkGen DLL Setting(debug) */ 880 uint64_t dfalag : 1; /**< RLD ClkGen DLL Lag Error(debug) */ 881 uint64_t dfalead : 1; /**< RLD ClkGen DLL Lead Error(debug) */ 882 uint64_t dfalock : 1; /**< RLD ClkGen DLL Lock acquisition(debug) */ 883 uint64_t setting : 5; /**< RLDCK90 DLL Setting(debug) */ 884#else 885 uint64_t setting : 5; 886 uint64_t dfalock : 1; 887 uint64_t dfalead : 1; 888 uint64_t dfalag : 1; 889 uint64_t dfaset : 5; 890 uint64_t reserved_13_63 : 51; 891#endif 892 } s; 893 struct cvmx_asxx_rld_setting_cn38xx { 894#ifdef __BIG_ENDIAN_BITFIELD 895 uint64_t reserved_5_63 : 59; 896 uint64_t setting : 5; /**< This is the read-only true rld dll_setting. */ 897#else 898 uint64_t setting : 5; 899 uint64_t reserved_5_63 : 59; 900#endif 901 } cn38xx; 902 struct cvmx_asxx_rld_setting_cn38xx cn38xxp2; 903 struct cvmx_asxx_rld_setting_s cn58xx; 904 struct cvmx_asxx_rld_setting_s cn58xxp1; 905}; 906typedef union cvmx_asxx_rld_setting cvmx_asxx_rld_setting_t; 907 908/** 909 * cvmx_asx#_rx_clk_set# 910 * 911 * ASX_RX_CLK_SET = RGMII Clock delay setting 912 * 913 * 914 * Notes: 915 * Setting to place on the open-loop RXC (RGMII receive clk) 916 * delay line, which can delay the recieved clock. This 917 * can be used if the board and/or transmitting device 918 * has not otherwise delayed the clock. 919 * 920 * A value of SETTING=0 disables the delay line. The delay 921 * line should be disabled unless the transmitter or board 922 * does not delay the clock. 923 * 924 * Note that this delay line provides only a coarse control 925 * over the delay. Generally, it can only reliably provide 926 * a delay in the range 1.25-2.5ns, which may not be adequate 927 * for some system applications. 928 * 929 * The open loop delay line selects 930 * from among a series of tap positions. Each incremental 931 * tap position adds a delay of 50ps to 135ps per tap, depending 932 * on the chip, its temperature, and the voltage. 933 * To achieve from 1.25-2.5ns of delay on the recieved 934 * clock, a fixed value of SETTING=24 may work. 935 * For more precision, we recommend the following settings 936 * based on the chip voltage: 937 * 938 * VDD SETTING 939 * ----------------------------- 940 * 1.0 18 941 * 1.05 19 942 * 1.1 21 943 * 1.15 22 944 * 1.2 23 945 * 1.25 24 946 * 1.3 25 947 */ 948union cvmx_asxx_rx_clk_setx { 949 uint64_t u64; 950 struct cvmx_asxx_rx_clk_setx_s { 951#ifdef __BIG_ENDIAN_BITFIELD 952 uint64_t reserved_5_63 : 59; 953 uint64_t setting : 5; /**< Setting to place on the open-loop RXC delay line */ 954#else 955 uint64_t setting : 5; 956 uint64_t reserved_5_63 : 59; 957#endif 958 } s; 959 struct cvmx_asxx_rx_clk_setx_s cn30xx; 960 struct cvmx_asxx_rx_clk_setx_s cn31xx; 961 struct cvmx_asxx_rx_clk_setx_s cn38xx; 962 struct cvmx_asxx_rx_clk_setx_s cn38xxp2; 963 struct cvmx_asxx_rx_clk_setx_s cn50xx; 964 struct cvmx_asxx_rx_clk_setx_s cn58xx; 965 struct cvmx_asxx_rx_clk_setx_s cn58xxp1; 966}; 967typedef union cvmx_asxx_rx_clk_setx cvmx_asxx_rx_clk_setx_t; 968 969/** 970 * cvmx_asx#_rx_prt_en 971 * 972 * ASX_RX_PRT_EN = RGMII Port Enable 973 * 974 */ 975union cvmx_asxx_rx_prt_en { 976 uint64_t u64; 977 struct cvmx_asxx_rx_prt_en_s { 978#ifdef __BIG_ENDIAN_BITFIELD 979 uint64_t reserved_4_63 : 60; 980 uint64_t prt_en : 4; /**< Port enable. Must be set for Octane to receive 981 RMGII traffic. When this bit clear on a given 982 port, then the all RGMII cycles will appear as 983 inter-frame cycles. */ 984#else 985 uint64_t prt_en : 4; 986 uint64_t reserved_4_63 : 60; 987#endif 988 } s; 989 struct cvmx_asxx_rx_prt_en_cn30xx { 990#ifdef __BIG_ENDIAN_BITFIELD 991 uint64_t reserved_3_63 : 61; 992 uint64_t prt_en : 3; /**< Port enable. Must be set for Octane to receive 993 RMGII traffic. When this bit clear on a given 994 port, then the all RGMII cycles will appear as 995 inter-frame cycles. */ 996#else 997 uint64_t prt_en : 3; 998 uint64_t reserved_3_63 : 61; 999#endif 1000 } cn30xx; 1001 struct cvmx_asxx_rx_prt_en_cn30xx cn31xx; 1002 struct cvmx_asxx_rx_prt_en_s cn38xx; 1003 struct cvmx_asxx_rx_prt_en_s cn38xxp2; 1004 struct cvmx_asxx_rx_prt_en_cn30xx cn50xx; 1005 struct cvmx_asxx_rx_prt_en_s cn58xx; 1006 struct cvmx_asxx_rx_prt_en_s cn58xxp1; 1007}; 1008typedef union cvmx_asxx_rx_prt_en cvmx_asxx_rx_prt_en_t; 1009 1010/** 1011 * cvmx_asx#_rx_wol 1012 * 1013 * ASX_RX_WOL = RGMII RX Wake on LAN status register 1014 * 1015 */ 1016union cvmx_asxx_rx_wol { 1017 uint64_t u64; 1018 struct cvmx_asxx_rx_wol_s { 1019#ifdef __BIG_ENDIAN_BITFIELD 1020 uint64_t reserved_2_63 : 62; 1021 uint64_t status : 1; /**< Copy of PMCSR[15] - PME_status */ 1022 uint64_t enable : 1; /**< Copy of PMCSR[8] - PME_enable */ 1023#else 1024 uint64_t enable : 1; 1025 uint64_t status : 1; 1026 uint64_t reserved_2_63 : 62; 1027#endif 1028 } s; 1029 struct cvmx_asxx_rx_wol_s cn38xx; 1030 struct cvmx_asxx_rx_wol_s cn38xxp2; 1031}; 1032typedef union cvmx_asxx_rx_wol cvmx_asxx_rx_wol_t; 1033 1034/** 1035 * cvmx_asx#_rx_wol_msk 1036 * 1037 * ASX_RX_WOL_MSK = RGMII RX Wake on LAN byte mask 1038 * 1039 */ 1040union cvmx_asxx_rx_wol_msk { 1041 uint64_t u64; 1042 struct cvmx_asxx_rx_wol_msk_s { 1043#ifdef __BIG_ENDIAN_BITFIELD 1044 uint64_t msk : 64; /**< Bytes to include in the CRC signature */ 1045#else 1046 uint64_t msk : 64; 1047#endif 1048 } s; 1049 struct cvmx_asxx_rx_wol_msk_s cn38xx; 1050 struct cvmx_asxx_rx_wol_msk_s cn38xxp2; 1051}; 1052typedef union cvmx_asxx_rx_wol_msk cvmx_asxx_rx_wol_msk_t; 1053 1054/** 1055 * cvmx_asx#_rx_wol_powok 1056 * 1057 * ASX_RX_WOL_POWOK = RGMII RX Wake on LAN Power OK 1058 * 1059 */ 1060union cvmx_asxx_rx_wol_powok { 1061 uint64_t u64; 1062 struct cvmx_asxx_rx_wol_powok_s { 1063#ifdef __BIG_ENDIAN_BITFIELD 1064 uint64_t reserved_1_63 : 63; 1065 uint64_t powerok : 1; /**< Power OK */ 1066#else 1067 uint64_t powerok : 1; 1068 uint64_t reserved_1_63 : 63; 1069#endif 1070 } s; 1071 struct cvmx_asxx_rx_wol_powok_s cn38xx; 1072 struct cvmx_asxx_rx_wol_powok_s cn38xxp2; 1073}; 1074typedef union cvmx_asxx_rx_wol_powok cvmx_asxx_rx_wol_powok_t; 1075 1076/** 1077 * cvmx_asx#_rx_wol_sig 1078 * 1079 * ASX_RX_WOL_SIG = RGMII RX Wake on LAN CRC signature 1080 * 1081 */ 1082union cvmx_asxx_rx_wol_sig { 1083 uint64_t u64; 1084 struct cvmx_asxx_rx_wol_sig_s { 1085#ifdef __BIG_ENDIAN_BITFIELD 1086 uint64_t reserved_32_63 : 32; 1087 uint64_t sig : 32; /**< CRC signature */ 1088#else 1089 uint64_t sig : 32; 1090 uint64_t reserved_32_63 : 32; 1091#endif 1092 } s; 1093 struct cvmx_asxx_rx_wol_sig_s cn38xx; 1094 struct cvmx_asxx_rx_wol_sig_s cn38xxp2; 1095}; 1096typedef union cvmx_asxx_rx_wol_sig cvmx_asxx_rx_wol_sig_t; 1097 1098/** 1099 * cvmx_asx#_tx_clk_set# 1100 * 1101 * ASX_TX_CLK_SET = RGMII Clock delay setting 1102 * 1103 * 1104 * Notes: 1105 * Setting to place on the open-loop TXC (RGMII transmit clk) 1106 * delay line, which can delay the transmited clock. This 1107 * can be used if the board and/or transmitting device 1108 * has not otherwise delayed the clock. 1109 * 1110 * A value of SETTING=0 disables the delay line. The delay 1111 * line should be disabled unless the transmitter or board 1112 * does not delay the clock. 1113 * 1114 * Note that this delay line provides only a coarse control 1115 * over the delay. Generally, it can only reliably provide 1116 * a delay in the range 1.25-2.5ns, which may not be adequate 1117 * for some system applications. 1118 * 1119 * The open loop delay line selects 1120 * from among a series of tap positions. Each incremental 1121 * tap position adds a delay of 50ps to 135ps per tap, depending 1122 * on the chip, its temperature, and the voltage. 1123 * To achieve from 1.25-2.5ns of delay on the recieved 1124 * clock, a fixed value of SETTING=24 may work. 1125 * For more precision, we recommend the following settings 1126 * based on the chip voltage: 1127 * 1128 * VDD SETTING 1129 * ----------------------------- 1130 * 1.0 18 1131 * 1.05 19 1132 * 1.1 21 1133 * 1.15 22 1134 * 1.2 23 1135 * 1.25 24 1136 * 1.3 25 1137 */ 1138union cvmx_asxx_tx_clk_setx { 1139 uint64_t u64; 1140 struct cvmx_asxx_tx_clk_setx_s { 1141#ifdef __BIG_ENDIAN_BITFIELD 1142 uint64_t reserved_5_63 : 59; 1143 uint64_t setting : 5; /**< Setting to place on the open-loop TXC delay line */ 1144#else 1145 uint64_t setting : 5; 1146 uint64_t reserved_5_63 : 59; 1147#endif 1148 } s; 1149 struct cvmx_asxx_tx_clk_setx_s cn30xx; 1150 struct cvmx_asxx_tx_clk_setx_s cn31xx; 1151 struct cvmx_asxx_tx_clk_setx_s cn38xx; 1152 struct cvmx_asxx_tx_clk_setx_s cn38xxp2; 1153 struct cvmx_asxx_tx_clk_setx_s cn50xx; 1154 struct cvmx_asxx_tx_clk_setx_s cn58xx; 1155 struct cvmx_asxx_tx_clk_setx_s cn58xxp1; 1156}; 1157typedef union cvmx_asxx_tx_clk_setx cvmx_asxx_tx_clk_setx_t; 1158 1159/** 1160 * cvmx_asx#_tx_comp_byp 1161 * 1162 * ASX_TX_COMP_BYP = RGMII Clock delay setting 1163 * 1164 */ 1165union cvmx_asxx_tx_comp_byp { 1166 uint64_t u64; 1167 struct cvmx_asxx_tx_comp_byp_s { 1168#ifdef __BIG_ENDIAN_BITFIELD 1169 uint64_t reserved_0_63 : 64; 1170#else 1171 uint64_t reserved_0_63 : 64; 1172#endif 1173 } s; 1174 struct cvmx_asxx_tx_comp_byp_cn30xx { 1175#ifdef __BIG_ENDIAN_BITFIELD 1176 uint64_t reserved_9_63 : 55; 1177 uint64_t bypass : 1; /**< Compensation bypass */ 1178 uint64_t pctl : 4; /**< PCTL Compensation Value (see Duke) */ 1179 uint64_t nctl : 4; /**< NCTL Compensation Value (see Duke) */ 1180#else 1181 uint64_t nctl : 4; 1182 uint64_t pctl : 4; 1183 uint64_t bypass : 1; 1184 uint64_t reserved_9_63 : 55; 1185#endif 1186 } cn30xx; 1187 struct cvmx_asxx_tx_comp_byp_cn30xx cn31xx; 1188 struct cvmx_asxx_tx_comp_byp_cn38xx { 1189#ifdef __BIG_ENDIAN_BITFIELD 1190 uint64_t reserved_8_63 : 56; 1191 uint64_t pctl : 4; /**< PCTL Compensation Value (see Duke) */ 1192 uint64_t nctl : 4; /**< NCTL Compensation Value (see Duke) */ 1193#else 1194 uint64_t nctl : 4; 1195 uint64_t pctl : 4; 1196 uint64_t reserved_8_63 : 56; 1197#endif 1198 } cn38xx; 1199 struct cvmx_asxx_tx_comp_byp_cn38xx cn38xxp2; 1200 struct cvmx_asxx_tx_comp_byp_cn50xx { 1201#ifdef __BIG_ENDIAN_BITFIELD 1202 uint64_t reserved_17_63 : 47; 1203 uint64_t bypass : 1; /**< Compensation bypass */ 1204 uint64_t reserved_13_15 : 3; 1205 uint64_t pctl : 5; /**< PCTL Compensation Value (see Duke) */ 1206 uint64_t reserved_5_7 : 3; 1207 uint64_t nctl : 5; /**< NCTL Compensation Value (see Duke) */ 1208#else 1209 uint64_t nctl : 5; 1210 uint64_t reserved_5_7 : 3; 1211 uint64_t pctl : 5; 1212 uint64_t reserved_13_15 : 3; 1213 uint64_t bypass : 1; 1214 uint64_t reserved_17_63 : 47; 1215#endif 1216 } cn50xx; 1217 struct cvmx_asxx_tx_comp_byp_cn58xx { 1218#ifdef __BIG_ENDIAN_BITFIELD 1219 uint64_t reserved_13_63 : 51; 1220 uint64_t pctl : 5; /**< PCTL Compensation Value (see Duke) */ 1221 uint64_t reserved_5_7 : 3; 1222 uint64_t nctl : 5; /**< NCTL Compensation Value (see Duke) */ 1223#else 1224 uint64_t nctl : 5; 1225 uint64_t reserved_5_7 : 3; 1226 uint64_t pctl : 5; 1227 uint64_t reserved_13_63 : 51; 1228#endif 1229 } cn58xx; 1230 struct cvmx_asxx_tx_comp_byp_cn58xx cn58xxp1; 1231}; 1232typedef union cvmx_asxx_tx_comp_byp cvmx_asxx_tx_comp_byp_t; 1233 1234/** 1235 * cvmx_asx#_tx_hi_water# 1236 * 1237 * ASX_TX_HI_WATER = RGMII TX FIFO Hi WaterMark 1238 * 1239 */ 1240union cvmx_asxx_tx_hi_waterx { 1241 uint64_t u64; 1242 struct cvmx_asxx_tx_hi_waterx_s { 1243#ifdef __BIG_ENDIAN_BITFIELD 1244 uint64_t reserved_4_63 : 60; 1245 uint64_t mark : 4; /**< TX FIFO HiWatermark to stall GMX 1246 Value of 0 maps to 16 1247 Reset value changed from 10 in pass1 1248 Pass1 settings (assuming 125 tclk) 1249 - 325-375: 12 1250 - 375-437: 11 1251 - 437-550: 10 1252 - 550-687: 9 */ 1253#else 1254 uint64_t mark : 4; 1255 uint64_t reserved_4_63 : 60; 1256#endif 1257 } s; 1258 struct cvmx_asxx_tx_hi_waterx_cn30xx { 1259#ifdef __BIG_ENDIAN_BITFIELD 1260 uint64_t reserved_3_63 : 61; 1261 uint64_t mark : 3; /**< TX FIFO HiWatermark to stall GMX 1262 Value 0 maps to 8. */ 1263#else 1264 uint64_t mark : 3; 1265 uint64_t reserved_3_63 : 61; 1266#endif 1267 } cn30xx; 1268 struct cvmx_asxx_tx_hi_waterx_cn30xx cn31xx; 1269 struct cvmx_asxx_tx_hi_waterx_s cn38xx; 1270 struct cvmx_asxx_tx_hi_waterx_s cn38xxp2; 1271 struct cvmx_asxx_tx_hi_waterx_cn30xx cn50xx; 1272 struct cvmx_asxx_tx_hi_waterx_s cn58xx; 1273 struct cvmx_asxx_tx_hi_waterx_s cn58xxp1; 1274}; 1275typedef union cvmx_asxx_tx_hi_waterx cvmx_asxx_tx_hi_waterx_t; 1276 1277/** 1278 * cvmx_asx#_tx_prt_en 1279 * 1280 * ASX_TX_PRT_EN = RGMII Port Enable 1281 * 1282 */ 1283union cvmx_asxx_tx_prt_en { 1284 uint64_t u64; 1285 struct cvmx_asxx_tx_prt_en_s { 1286#ifdef __BIG_ENDIAN_BITFIELD 1287 uint64_t reserved_4_63 : 60; 1288 uint64_t prt_en : 4; /**< Port enable. Must be set for Octane to send 1289 RMGII traffic. When this bit clear on a given 1290 port, then all RGMII cycles will appear as 1291 inter-frame cycles. */ 1292#else 1293 uint64_t prt_en : 4; 1294 uint64_t reserved_4_63 : 60; 1295#endif 1296 } s; 1297 struct cvmx_asxx_tx_prt_en_cn30xx { 1298#ifdef __BIG_ENDIAN_BITFIELD 1299 uint64_t reserved_3_63 : 61; 1300 uint64_t prt_en : 3; /**< Port enable. Must be set for Octane to send 1301 RMGII traffic. When this bit clear on a given 1302 port, then all RGMII cycles will appear as 1303 inter-frame cycles. */ 1304#else 1305 uint64_t prt_en : 3; 1306 uint64_t reserved_3_63 : 61; 1307#endif 1308 } cn30xx; 1309 struct cvmx_asxx_tx_prt_en_cn30xx cn31xx; 1310 struct cvmx_asxx_tx_prt_en_s cn38xx; 1311 struct cvmx_asxx_tx_prt_en_s cn38xxp2; 1312 struct cvmx_asxx_tx_prt_en_cn30xx cn50xx; 1313 struct cvmx_asxx_tx_prt_en_s cn58xx; 1314 struct cvmx_asxx_tx_prt_en_s cn58xxp1; 1315}; 1316typedef union cvmx_asxx_tx_prt_en cvmx_asxx_tx_prt_en_t; 1317 1318#endif 1319