• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  * Description: the header file of hcc private interfacer.
15  * Author:
16  * Create: 2021-05-13
17  */
18 
19 #ifndef HCC_ADAPT_HEADER
20 #define HCC_ADAPT_HEADER
21 
22 #include "td_type.h"
23 #include "hcc.h"
24 #include "hcc_queue.h"
25 
26 #ifdef __cplusplus
27 #if __cplusplus
28 extern "C" {
29 #endif
30 #endif
31 
32 hcc_unc_struc *hcc_alloc_unc_buf(hcc_handler *hcc);
33 td_void hcc_free_unc_buf(hcc_handler *hcc, hcc_unc_struc *unc_buf);
34 hcc_unc_struc* hcc_adapt_alloc_unc_buf(hcc_handler *hcc, td_u32 len, hcc_queue_type queue_id);
35 td_void hcc_adapt_mem_free(hcc_handler *hcc, hcc_unc_struc *unc_buf);
36 td_void hcc_unc_buf_enqueue(hcc_handler *hcc, hcc_queue_type queue_id, hcc_unc_struc *unc_buf);
37 ext_errno hcc_bus_rx_handler(hcc_bus *bus, td_u8 queue_id, hcc_data_queue *assembled_head);
38 td_u32 hcc_adapt_alloc_priv_buf(
39     hcc_handler *hcc, hcc_queue_type queue_id, td_u32 buf_len, td_u8 **buf, td_u8 **user_param);
40 td_void hcc_adapt_free_priv_buf(hcc_handler *hcc, hcc_queue_type queue_id, td_u8 *buf, td_u8 *user_param);
41 
42 #ifdef __cplusplus
43 #if __cplusplus
44 }
45 #endif
46 #endif
47 
48 #endif /* HCC_ADAPT_HEADER */
49