tomahawk3_tdm.h (2232B)
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 * File: tomahawk3_tdm.h 8 */ 9 10 11 #ifndef _SOC_TOMAHAWK3_TDM_H_ 12 #define _SOC_TOMAHAWK3_TDM_H_ 13 14 #include <soc/esw/port.h> 15 #include <soc/init/tomahawk3_flexport_defines.h> 16 #include <soc/init/tomahawk3_set_tdm.h> 17 #include <soc/init/tomahawk3_ep_init.h> 18 19 /*** START SDK API COMMON CODE ***/ 20 21 typedef enum { 22 TDM_IDB_PORT_SCHED, 23 TDM_IDB_PKT_SCHED, 24 TDM_MMU_MAIN_SCHED, 25 TDM_MMU_EB_PORT_SCHED, 26 TDM_MMU_EB_PKT_SCHED 27 } tdm_sched_inst_name_e; 28 29 30 extern int soc_tomahawk3_tdm_set_cal_config( 31 int unit, 32 soc_port_schedule_state_t *port_schedule_state, 33 tdm_sched_inst_name_e sched_inst_name, 34 int pipe, 35 int phy_port, 36 int is_port_down); 37 38 extern int soc_tomahawk3_tdm_clear_edb_credit_counter_per_port( 39 int unit, 40 soc_port_schedule_state_t *port_schedule_state, 41 tdm_sched_inst_name_e sched_inst_name, 42 int pipe_num, 43 int phy_port, 44 int is_port_down); 45 46 extern int soc_tomahawk3_tdm_clear_edb_credit_counter( 47 int unit, 48 soc_port_schedule_state_t *port_schedule_state); 49 50 extern int soc_tomahawk3_tdm_set_out_port_map( 51 int unit, 52 soc_port_schedule_state_t *port_schedule_state); 53 54 extern int soc_tomahawk3_tdm_idb_init( 55 int unit, 56 soc_port_schedule_state_t *port_schedule_state); 57 58 extern int soc_tomahawk3_tdm_mmu_init( 59 int unit, 60 soc_port_schedule_state_t *port_schedule_state); 61 62 extern void soc_tomahawk3_get_pipe_map( 63 int unit, 64 soc_port_schedule_state_t *port_schedule_state, 65 uint32 *pipe_map); 66 67 extern int soc_tomahawk3_tdm_init( 68 int unit, 69 soc_port_schedule_state_t *port_schedule_state); 70 71 extern int soc_tomahawk3_tdm_sched_flexport( 72 int unit, 73 soc_port_schedule_state_t *port_schedule_state, 74 tdm_sched_inst_name_e sched_inst_name, 75 int ports_down); 76 77 extern int soc_tomahawk3_tdm_idb_flexport( 78 int unit, 79 soc_port_schedule_state_t *port_schedule_state); 80 81 extern int soc_tomahawk3_tdm_mmu_flexport( 82 int unit, 83 soc_port_schedule_state_t *port_schedule_state); 84 85 /*** END SDK API COMMON CODE ***/ 86 87 #endif