phymod_custom_config.h (3705B)
1 /* 2 * 3 * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file. 4 * 5 * Copyright 2007-2019 Broadcom Inc. All rights reserved. 6 * 7 * System interface definitions for Switch SDK 8 */ 9 10 #ifndef __PHYMOD_CUSTOM_CONFIG_H__ 11 #define __PHYMOD_CUSTOM_CONFIG_H__ 12 13 #define PHYMOD_EAGLE_SUPPORT 14 #define PHYMOD_FALCON_SUPPORT 15 #define PHYMOD_FALCON16_SUPPORT 16 #define PHYMOD_MERLIN16_SUPPORT 17 #define PHYMOD_QSGMIIE_SUPPORT 18 #define PHYMOD_TSCE_SUPPORT 19 #define PHYMOD_TSCF_SUPPORT 20 #define PHYMOD_TSCF16_SUPPORT 21 #define PHYMOD_TSCE16_SUPPORT 22 #define PHYMOD_VIPER_SUPPORT 23 #define PHYMOD_FURIA_SUPPORT 24 #define PHYMOD_SESTO_SUPPORT 25 #define PHYMOD_QUADRA28_SUPPORT 26 #define PHYMOD_QTCE_SUPPORT 27 #define PHYMOD_HURACAN_SUPPORT 28 #define PHYMOD_MADURA_SUPPORT 29 #define PHYMOD_DINO_SUPPORT 30 #define PHYMOD_PHY8806X_SUPPORT 31 #define PHYMOD_TSCE_DPLL_SUPPORT 32 #define PHYMOD_EAGLE_DPLL_SUPPORT 33 #define PHYMOD_FALCON_DPLL_SUPPORT 34 #define PHYMOD_TSCF_GEN3_SUPPORT 35 #define PHYMOD_BLACKHAWK_SUPPORT 36 #define PHYMOD_TSCBH_SUPPORT 37 #define PHYMOD_NULL_SUPPORT 38 39 #define PHYMOD_DEBUG_ERROR(stuff_) 40 #define PHYMOD_DEBUG_VERBOSE(stuff_) 41 #define PHYMOD_DIAG_OUT(stuff_) 42 #define PHYMOD_DEBUG_WARN(stuff_) 43 44 #define PHYMOD_USLEEP my_usleep 45 #define PHYMOD_SLEEP my_sleep 46 #define PHYMOD_MALLOC my_malloc 47 #define PHYMOD_FREE my_free 48 49 #ifndef TOOLS_NO_SIGNED_STDINT 50 #define int8_t unsigned char 51 #define int16_t short 52 #define int32_t int 53 #endif 54 55 #define PHYMOD_CONFIG_DEFINE_INT8_T 0 56 #define PHYMOD_CONFIG_DEFINE_INT16_T 0 57 #define PHYMOD_CONFIG_DEFINE_INT32_T 0 58 59 typedef unsigned long size_t; 60 61 extern void *my_memset(void *dest,int c,size_t cnt); 62 extern void *my_memcpy(void *dest,const void *src,size_t cnt); 63 64 extern int my_strcmp(const char *dest,const char *src); 65 extern int my_strncmp(const char *dest,const char *src,size_t cnt); 66 extern char *my_strncpy(char *dest,const char *src,size_t cnt); 67 extern char *my_strchr(const char *dest,int c); 68 extern char *my_strstr(const char *dest,const char *src); 69 extern size_t my_strlen(const char *str); 70 extern char *my_strcpy(char *dest,const char *src); 71 extern char *my_strcat(char *dest,const char *src); 72 extern char *my_strncat(char *dest,const char *src,size_t cnt); 73 74 extern unsigned long my_strtoul(const char *s, char **end, int base); 75 76 extern int my_snprintf(char *buf, size_t bufsize, const char *fmt, ...) 77 __attribute__ ((format (printf, 3, 4))); 78 extern int my_sprintf(char *buf, const char *fmt, ...) 79 __attribute__ ((format (printf, 2, 3))); 80 81 extern unsigned long my_time_usecs(); 82 extern void my_srand(unsigned int seed); 83 extern int my_rand(); 84 extern int my_spl(int level); 85 extern int my_splhi(void); 86 87 88 89 #define PHYMOD_MEMSET my_memset 90 #define PHYMOD_MEMCPY my_memcpy 91 92 #define PHYMOD_STRCMP my_strcmp 93 #define PHYMOD_STRNCMP my_strncmp 94 #define PHYMOD_STRNCPY my_strncpy 95 #define PHYMOD_STRCHR my_strchr 96 #define PHYMOD_STRSTR my_strstr 97 #define PHYMOD_STRLEN my_strlen 98 #define PHYMOD_STRCPY my_strcpy 99 #define PHYMOD_STRCAT my_strcat 100 #define PHYMOD_STRNCAT my_strncat 101 102 #define PHYMOD_STRTOUL my_strtoul 103 104 #define PHYMOD_SPRINTF my_sprintf 105 #define PHYMOD_SNPRINTF my_snprintf 106 107 #define PHYMOD_TIME_USECS my_time_usecs 108 #define PHYMOD_SRAND my_srand 109 #define PHYMOD_RAND my_rand 110 #define PHYMOD_SPL my_spl 111 #define PHYMOD_SPLHI my_splhi 112 113 /* No need to define size_t */ 114 #define PHYMOD_CONFIG_DEFINE_SIZE_T 0 115 116 #ifdef TOOLS_UINT32_IS_LONG 117 #define PHYMOD_CONFIG_TYPE_UINT32_T unsigned long 118 #define PHYMOD_CONFIG_MACRO_PRIu32 "ul" 119 #endif 120 121 #define LOG_WARN(ls_, stuff_) 122 #define BSL_META_U(u_, str_) 123 #define BSL_LS_SOC_PHY 124 #endif /* __PHYMOD_CUSTOM_CONFIG_H__ */