Shad Ansari | 2f7f9be | 2017-06-07 13:34:53 -0700 | [diff] [blame^] | 1 | /****************************************************************************** |
| 2 | * |
| 3 | * <:copyright-BRCM:2016:DUAL/GPL:standard |
| 4 | * |
| 5 | * Copyright (c) 2016 Broadcom |
| 6 | * All Rights Reserved |
| 7 | * |
| 8 | * Unless you and Broadcom execute a separate written software license |
| 9 | * agreement governing use of this software, this software is licensed |
| 10 | * to you under the terms of the GNU General Public License version 2 |
| 11 | * (the "GPL"), available at http://www.broadcom.com/licenses/GPLv2.php, |
| 12 | * with the following added to such license: |
| 13 | * |
| 14 | * As a special exception, the copyright holders of this software give |
| 15 | * you permission to link this software with independent modules, and |
| 16 | * to copy and distribute the resulting executable under terms of your |
| 17 | * choice, provided that you also meet, for each linked independent |
| 18 | * module, the terms and conditions of the license of that module. |
| 19 | * An independent module is a module which is not derived from this |
| 20 | * software. The special exception does not apply to any modifications |
| 21 | * of the software. |
| 22 | * |
| 23 | * Not withstanding the above, under no circumstances may you combine |
| 24 | * this software in any way with any other Broadcom software provided |
| 25 | * under a license other than the GPL, without Broadcom's express prior |
| 26 | * written consent. |
| 27 | * |
| 28 | * :> |
| 29 | * |
| 30 | *****************************************************************************/ |
| 31 | |
| 32 | /** |
| 33 | * @file bal_switch_util.h |
| 34 | * |
| 35 | * @brief Switch App interfaces header file |
| 36 | * |
| 37 | * This file expose the APIs to the core to configure the switchs |
| 38 | * with regarding to the operation of access terminal and flow. |
| 39 | * |
| 40 | * @defgroup sw_util Switch Util |
| 41 | * @ingroup core |
| 42 | */ |
| 43 | |
| 44 | #ifndef _BAL_SWITCH_UTIL_H_ |
| 45 | #define _BAL_SWITCH_UTIL_H_ |
| 46 | |
| 47 | /*@{*/ |
| 48 | |
| 49 | #include <acc_term_fsm.h> |
| 50 | #include <flow_fsm.h> |
| 51 | #include <group_fsm.h> |
| 52 | #include <tm_sched_fsm.h> |
| 53 | #include <tm_queue_fsm.h> |
| 54 | |
| 55 | |
| 56 | #include <bcmcli.h> |
| 57 | #include <bal_utils_msg.h> |
| 58 | |
| 59 | #define BCM_DEVICE_KT2 0xb450 |
| 60 | #define BCM_DEVICE_ARAD_PLUS 0x8660 |
| 61 | #define BCM_DEVICE_ARAD 0x8650 |
| 62 | #define BCM_DEVICE_QAX 0x8470 |
| 63 | |
| 64 | /* Function Prototypes for external */ |
| 65 | bcmos_errno sw_util_access_terminal_set(acc_term_inst *p_acc_term, bal_util_oper_acc_term opt_type); |
| 66 | bcmos_errno sw_util_flow_info_validate(void *p_msg); |
| 67 | bcmos_errno sw_util_flow_set(flow_inst *p_flow, bal_util_oper_flow opt_type); |
| 68 | bcmos_errno sw_util_flow_finish(void); |
| 69 | bcmos_errno sw_util_interface_set(acc_term_interface *p_interface_inst, bal_util_oper_if opt_type); |
| 70 | bcmos_errno sw_util_group_info_validate(void *p_msg); |
| 71 | bcmos_errno sw_util_group_set(group_inst *p_group_inst, bal_util_oper_group opt_type); |
| 72 | bcmos_errno sw_util_group_finish(void); |
| 73 | bcmos_errno sw_util_init(void); |
| 74 | bcmos_errno sw_util_cli_init(bcmcli_entry *top_dir); |
| 75 | bcmos_errno sw_util_finish(void); |
| 76 | |
| 77 | |
| 78 | bcmos_errno sw_util_tm_sched_validate(void *p_msg); |
| 79 | bcmos_errno sw_util_tm_sched_set(tm_sched_inst *p_tm_sched_inst); |
| 80 | bcmos_errno sw_util_tm_sched_clear(tm_sched_inst *p_tm_sched_inst); |
| 81 | |
| 82 | bcmos_errno sw_util_tm_queue_validate(void *p_msg); |
| 83 | bcmos_errno sw_util_tm_queue_set(tm_queue_inst *p_tm_queue_inst); |
| 84 | bcmos_errno sw_util_tm_queue_clear(tm_queue_inst *p_tm_queue_inst); |
| 85 | |
| 86 | |
| 87 | /* switch util log id */ |
| 88 | extern dev_log_id log_id_sw_util; |
| 89 | |
| 90 | /*@}*/ |
| 91 | |
| 92 | #endif /* _BAL_SWITCH_UTIL_H_ */ |
| 93 | |