cvmx-spx0-defs.h revision 232812
1189251Ssam/***********************license start*************** 2214734Srpaulo * Copyright (c) 2003-2012 Cavium Inc. (support@cavium.com). All rights 3214734Srpaulo * reserved. 4189251Ssam * 5252726Srpaulo * 6252726Srpaulo * Redistribution and use in source and binary forms, with or without 7189251Ssam * modification, are permitted provided that the following conditions are 8189251Ssam * met: 9189251Ssam * 10189251Ssam * * Redistributions of source code must retain the above copyright 11189251Ssam * notice, this list of conditions and the following disclaimer. 12214734Srpaulo * 13214734Srpaulo * * Redistributions in binary form must reproduce the above 14189251Ssam * copyright notice, this list of conditions and the following 15252726Srpaulo * disclaimer in the documentation and/or other materials provided 16189251Ssam * with the distribution. 17189251Ssam 18189251Ssam * * Neither the name of Cavium Inc. nor the names of 19189251Ssam * its contributors may be used to endorse or promote products 20189251Ssam * derived from this software without specific prior written 21189251Ssam * permission. 22189251Ssam 23189251Ssam * This Software, including technical data, may be subject to U.S. export control 24189251Ssam * laws, including the U.S. Export Administration Act and its associated 25189251Ssam * regulations, and may be subject to export or import regulations in other 26324739Sgordon * countries. 27189251Ssam 28189251Ssam * TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS PROVIDED "AS IS" 29189251Ssam * AND WITH ALL FAULTS AND CAVIUM INC. MAKES NO PROMISES, REPRESENTATIONS OR 30189251Ssam * WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY, OR OTHERWISE, WITH RESPECT TO 31189251Ssam * THE SOFTWARE, INCLUDING ITS CONDITION, ITS CONFORMITY TO ANY REPRESENTATION OR 32189251Ssam * DESCRIPTION, OR THE EXISTENCE OF ANY LATENT OR PATENT DEFECTS, AND CAVIUM 33324739Sgordon * SPECIFICALLY DISCLAIMS ALL IMPLIED (IF ANY) WARRANTIES OF TITLE, 34324739Sgordon * MERCHANTABILITY, NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, LACK OF 35324739Sgordon * VIRUSES, ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION OR 36324739Sgordon * CORRESPONDENCE TO DESCRIPTION. THE ENTIRE RISK ARISING OUT OF USE OR 37324739Sgordon * PERFORMANCE OF THE SOFTWARE LIES WITH YOU. 38324739Sgordon ***********************license end**************************************/ 39189251Ssam 40189251Ssam 41189251Ssam/** 42189251Ssam * cvmx-spx0-defs.h 43189251Ssam * 44214734Srpaulo * Configuration and status register (CSR) type definitions for 45189251Ssam * Octeon spx0. 46189251Ssam * 47189251Ssam * This file is auto generated. Do not edit. 48252726Srpaulo * 49189251Ssam * <hr>$Revision$<hr> 50189251Ssam * 51189251Ssam */ 52189251Ssam#ifndef __CVMX_SPX0_DEFS_H__ 53189251Ssam#define __CVMX_SPX0_DEFS_H__ 54189251Ssam 55189251Ssam#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 56189251Ssam#define CVMX_SPX0_PLL_BW_CTL CVMX_SPX0_PLL_BW_CTL_FUNC() 57189251Ssamstatic inline uint64_t CVMX_SPX0_PLL_BW_CTL_FUNC(void) 58189251Ssam{ 59189251Ssam if (!(OCTEON_IS_MODEL(OCTEON_CN38XX))) 60189251Ssam cvmx_warn("CVMX_SPX0_PLL_BW_CTL not supported on this chip\n"); 61189251Ssam return CVMX_ADD_IO_SEG(0x0001180090000388ull); 62189251Ssam} 63189251Ssam#else 64189251Ssam#define CVMX_SPX0_PLL_BW_CTL (CVMX_ADD_IO_SEG(0x0001180090000388ull)) 65189251Ssam#endif 66189251Ssam#if CVMX_ENABLE_CSR_ADDRESS_CHECKING 67189251Ssam#define CVMX_SPX0_PLL_SETTING CVMX_SPX0_PLL_SETTING_FUNC() 68189251Ssamstatic inline uint64_t CVMX_SPX0_PLL_SETTING_FUNC(void) 69189251Ssam{ 70189251Ssam if (!(OCTEON_IS_MODEL(OCTEON_CN38XX))) 71189251Ssam cvmx_warn("CVMX_SPX0_PLL_SETTING not supported on this chip\n"); 72189251Ssam return CVMX_ADD_IO_SEG(0x0001180090000380ull); 73189251Ssam} 74189251Ssam#else 75189251Ssam#define CVMX_SPX0_PLL_SETTING (CVMX_ADD_IO_SEG(0x0001180090000380ull)) 76189251Ssam#endif 77189251Ssam 78189251Ssam/** 79189251Ssam * cvmx_spx0_pll_bw_ctl 80189251Ssam */ 81189251Ssamunion cvmx_spx0_pll_bw_ctl { 82189251Ssam uint64_t u64; 83189251Ssam struct cvmx_spx0_pll_bw_ctl_s { 84189251Ssam#ifdef __BIG_ENDIAN_BITFIELD 85189251Ssam uint64_t reserved_5_63 : 59; 86189251Ssam uint64_t bw_ctl : 5; /**< Core PLL bandwidth control */ 87189251Ssam#else 88214734Srpaulo uint64_t bw_ctl : 5; 89189251Ssam uint64_t reserved_5_63 : 59; 90189251Ssam#endif 91189251Ssam } s; 92189251Ssam struct cvmx_spx0_pll_bw_ctl_s cn38xx; 93189251Ssam struct cvmx_spx0_pll_bw_ctl_s cn38xxp2; 94189251Ssam}; 95189251Ssamtypedef union cvmx_spx0_pll_bw_ctl cvmx_spx0_pll_bw_ctl_t; 96189251Ssam 97189251Ssam/** 98252726Srpaulo * cvmx_spx0_pll_setting 99252726Srpaulo */ 100252726Srpaulounion cvmx_spx0_pll_setting { 101252726Srpaulo uint64_t u64; 102189251Ssam struct cvmx_spx0_pll_setting_s { 103252726Srpaulo#ifdef __BIG_ENDIAN_BITFIELD 104252726Srpaulo uint64_t reserved_17_63 : 47; 105252726Srpaulo uint64_t setting : 17; /**< Core PLL setting */ 106252726Srpaulo#else 107252726Srpaulo uint64_t setting : 17; 108252726Srpaulo uint64_t reserved_17_63 : 47; 109252726Srpaulo#endif 110252726Srpaulo } s; 111252726Srpaulo struct cvmx_spx0_pll_setting_s cn38xx; 112252726Srpaulo struct cvmx_spx0_pll_setting_s cn38xxp2; 113189251Ssam}; 114189251Ssamtypedef union cvmx_spx0_pll_setting cvmx_spx0_pll_setting_t; 115189251Ssam 116189251Ssam#endif 117189251Ssam