Thiyagarajan Subramani | 89fffc0 | 2019-05-13 21:33:20 +0000 | [diff] [blame] | 1 | /* |
| 2 | Copyright (C) 2018 Open Networking Foundation |
| 3 | |
| 4 | This program is free software: you can redistribute it and/or modify |
| 5 | it under the terms of the GNU General Public License as published by |
| 6 | the Free Software Foundation, either version 3 of the License, or |
| 7 | (at your option) any later version. |
| 8 | |
| 9 | This program is distributed in the hope that it will be useful, |
| 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 | GNU General Public License for more details. |
| 13 | |
| 14 | You should have received a copy of the GNU General Public License |
| 15 | along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 16 | */ |
| 17 | #ifndef __BCMCLI_SESSION_H__ |
| 18 | #define __BCMCLI_SESSION_H__ |
| 19 | #include "bcmos_errno.h" |
| 20 | // This is a stub header file for unit test case only |
| 21 | typedef int bcmcli_session; |
| 22 | typedef char bcmcli_entry[50]; |
| 23 | typedef char bcmcli_cmd_parm; |
| 24 | struct bcmos_task { |
| 25 | char task_name[50]; |
| 26 | }; |
| 27 | |
| 28 | typedef struct bcmcli_session_parm { |
| 29 | void *get_prompt; |
| 30 | int access_right; |
| 31 | } bcmcli_session_parm; |
| 32 | |
| 33 | #define BCMCLI_ACCESS_ADMIN 0xff |
| 34 | #define BUG_ON // |
| 35 | #define BCMCLI_MAKE_CMD_NOPARM(ptr, command1, command2, command3) |
| 36 | #define BAL_API_VERSION 3 |
| 37 | |
| 38 | |
| 39 | extern bool bcmcli_is_stopped(bcmcli_session *sess); |
| 40 | extern bool bcmcli_parse(bcmcli_session *sess, char *s); |
| 41 | extern bool bcmcli_driver(bcmcli_session *sess); |
| 42 | extern void bcmcli_token_destroy(void *); |
| 43 | extern void bcmcli_session_close(bcmcli_session *sess); |
| 44 | extern bcmos_errno bcm_api_cli_set_commands(bcmcli_session *sess); |
| 45 | extern void bcmcli_stop(bcmcli_session *sess); |
| 46 | extern void bcmcli_session_print(bcmcli_session *sess, const char *s); |
| 47 | extern bcmos_errno bcmcli_session_open(bcmcli_session_parm *mon_sess, bcmcli_session **curr_sess); |
| 48 | #endif |
| 49 | |