1*5113495bSYour Name /* 2*5113495bSYour Name * Copyright (c) 2016-2021 The Linux Foundation. All rights reserved. 3*5113495bSYour Name * Copyright (c) 2021,2023 Qualcomm Innovation Center, Inc. All rights reserved. 4*5113495bSYour Name * 5*5113495bSYour Name * Permission to use, copy, modify, and/or distribute this software for 6*5113495bSYour Name * any purpose with or without fee is hereby granted, provided that the 7*5113495bSYour Name * above copyright notice and this permission notice appear in all 8*5113495bSYour Name * copies. 9*5113495bSYour Name * 10*5113495bSYour Name * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL 11*5113495bSYour Name * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED 12*5113495bSYour Name * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE 13*5113495bSYour Name * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL 14*5113495bSYour Name * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR 15*5113495bSYour Name * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER 16*5113495bSYour Name * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 17*5113495bSYour Name * PERFORMANCE OF THIS SOFTWARE. 18*5113495bSYour Name */ 19*5113495bSYour Name 20*5113495bSYour Name #ifndef _HAL_LI_API_H_ 21*5113495bSYour Name #define _HAL_LI_API_H_ 22*5113495bSYour Name 23*5113495bSYour Name #include "hal_li_hw_headers.h" 24*5113495bSYour Name #include "hal_api.h" 25*5113495bSYour Name 26*5113495bSYour Name /** 27*5113495bSYour Name * hal_set_link_desc_addr_li() - Setup link descriptor in a buffer_addr_info 28*5113495bSYour Name * HW structure 29*5113495bSYour Name * 30*5113495bSYour Name * @desc: Descriptor entry (from WBM_IDLE_LINK ring) 31*5113495bSYour Name * @cookie: SW cookie for the buffer/descriptor 32*5113495bSYour Name * @link_desc_paddr: Physical address of link descriptor entry 33*5113495bSYour Name * @bm_id: idle link BM id 34*5113495bSYour Name */ 35*5113495bSYour Name void hal_set_link_desc_addr_li(void *desc, uint32_t cookie, 36*5113495bSYour Name qdf_dma_addr_t link_desc_paddr, 37*5113495bSYour Name uint8_t bm_id); 38*5113495bSYour Name 39*5113495bSYour Name /** 40*5113495bSYour Name * hal_tx_init_data_ring_li() - Initialize all the TCL Descriptors in SRNG 41*5113495bSYour Name * @hal_soc_hdl: Handle to HAL SoC structure 42*5113495bSYour Name * @hal_ring_hdl: Handle to HAL SRNG structure 43*5113495bSYour Name * 44*5113495bSYour Name * Return: none 45*5113495bSYour Name */ 46*5113495bSYour Name void hal_tx_init_data_ring_li(hal_soc_handle_t hal_soc_hdl, 47*5113495bSYour Name hal_ring_handle_t hal_ring_hdl); 48*5113495bSYour Name 49*5113495bSYour Name /** 50*5113495bSYour Name * hal_hw_txrx_default_ops_attach_li(): Add default ops for Lithium chips 51*5113495bSYour Name * @hal_soc: hal_soc handle 52*5113495bSYour Name * 53*5113495bSYour Name * Return: None 54*5113495bSYour Name */ 55*5113495bSYour Name void hal_hw_txrx_default_ops_attach_li(struct hal_soc *hal_soc); 56*5113495bSYour Name 57*5113495bSYour Name uint32_t hal_rx_wbm_err_src_get_li(hal_ring_desc_t ring_desc); 58*5113495bSYour Name uint8_t hal_rx_ret_buf_manager_get_li(hal_ring_desc_t ring_desc); 59*5113495bSYour Name 60*5113495bSYour Name /** 61*5113495bSYour Name * hal_reo_qdesc_setup_li() - Setup HW REO queue descriptor 62*5113495bSYour Name * @hal_soc_hdl: Opaque HAL SOC handle 63*5113495bSYour Name * @tid: TID 64*5113495bSYour Name * @ba_window_size: BlockAck window size 65*5113495bSYour Name * @start_seq: Starting sequence number 66*5113495bSYour Name * @hw_qdesc_vaddr: Virtual address of REO queue descriptor memory 67*5113495bSYour Name * @hw_qdesc_paddr: Physical address of REO queue descriptor memory 68*5113495bSYour Name * @pn_type: PN type (one of the types defined in 'enum hal_pn_type') 69*5113495bSYour Name * @vdev_stats_id: vdev_stats_id 70*5113495bSYour Name */ 71*5113495bSYour Name void hal_reo_qdesc_setup_li(hal_soc_handle_t hal_soc_hdl, 72*5113495bSYour Name int tid, uint32_t ba_window_size, 73*5113495bSYour Name uint32_t start_seq, void *hw_qdesc_vaddr, 74*5113495bSYour Name qdf_dma_addr_t hw_qdesc_paddr, 75*5113495bSYour Name int pn_type, uint8_t vdev_stats_id); 76*5113495bSYour Name 77*5113495bSYour Name #endif /* _HAL_LI_API_H_ */ 78