algo_synce.h (1978B)
1 /* 2 * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file. 3 * 4 * Copyright 2007-2020 Broadcom Inc. All rights reserved. 5 */ 6 7 /** \file algo_synce.c 8 * 9 * Include: 10 * SyncE DB initialization and deinitialization. 11 * SyncE DB set and get functions. 12 */ 13 14 #ifndef ALGO_SYNCE_H_INCLUDED 15 /* 16 * { 17 */ 18 #define ALGO_SYNCE_H_INCLUDED 19 20 #ifndef BCM_DNX_SUPPORT 21 #error "This file is for use by DNX (JR2) family only!" 22 #endif 23 24 /* 25 * Includes. 26 * { 27 */ 28 #include <shared/shrextend/shrextend_debug.h> 29 #include <soc/dnxc/swstate/auto_generated/types/dnxc_types.h> 30 #include <soc/dnx/dbal/auto_generated/dbal_defines_fields.h> 31 32 /* 33 * } 34 */ 35 /* 36 * Macros. 37 * { 38 */ 39 /* 40 * } 41 */ 42 /* 43 * TypeDefs. 44 * { 45 */ 46 47 /* 48 * Module Init / Deinit 49 * { 50 */ 51 /** 52 * \brief - 53 * Init algo synce module for cool boot mode. 54 * 55 * \param [in] unit - Unit #. 56 * 57 * \return 58 * see shr_error_e 59 * \remark 60 * * None 61 * \see 62 * * None 63 */ 64 shr_error_e dnx_algo_synce_init( 65 int unit); 66 /* 67 * } 68 */ 69 70 /* 71 * } 72 */ 73 74 /* 75 * synce Set/Get functions 76 * { 77 */ 78 79 /** 80 * \brief - 81 * Set Fabric synce enable status in SW DB. 82 * 83 * \param [in] unit - unit #. 84 * \param [in] synce_index - Master or slave synce. 85 * \param [in] enable - Enable or disable. 86 * 87 * \return 88 * See shr_error_e 89 * \remark 90 * * None 91 * \see 92 * * None 93 */ 94 95 shr_error_e dnx_algo_fabric_synce_enable_set( 96 int unit, 97 dbal_enum_value_field_synce_index_e synce_index, 98 int enable); 99 /** 100 * \brief - 101 * Get Fabric synce enable status in SW DB. 102 * 103 * \param [in] unit - unit #. 104 * \param [in] synce_index - Master or slave synce. 105 * \param [out] enable - Enable or disable. 106 * 107 * \return 108 * See shr_error_e 109 * \remark 110 * * None 111 * \see 112 * * None 113 */ 114 115 shr_error_e dnx_algo_fabric_synce_enable_get( 116 int unit, 117 dbal_enum_value_field_synce_index_e synce_index, 118 int *enable); 119 /* 120 * } 121 */ 122 123 /* 124 * } 125 */ 126 #endif /*_ALGO_SYNCE_H_INCLUDED_*/