nRF WiFi
Loading...
Searching...
No Matches
bal_api.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2024 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
12#ifndef __BAL_API_H__
13#define __BAL_API_H__
14
15#include "osal_api.h"
16#include "bal_structs.h"
17
32 enum nrf_wifi_status (*intr_callbk_fn)(void *hal_ctx));
33
34
45
56 void *hal_dev_ctx);
57
65
75
83
92unsigned int nrf_wifi_bal_read_word(void *ctx, unsigned long addr_offset);
93
102 unsigned long addr_offset,
103 unsigned int val);
104
114 void *dest_addr,
115 unsigned long src_addr_offset,
116 size_t len);
117
127 unsigned long dest_addr_offset,
128 const void *src_addr,
129 size_t len);
130
141unsigned long nrf_wifi_bal_dma_map(void *ctx,
142 unsigned long virt_addr,
143 size_t len,
144 enum nrf_wifi_osal_dma_dir dma_dir);
145
154unsigned long nrf_wifi_bal_dma_unmap(void *ctx,
155 unsigned long phy_addr,
156 size_t len,
157 enum nrf_wifi_osal_dma_dir dma_dir);
158
165
172
179
180#if defined(NRF_WIFI_LOW_POWER) || defined(__DOXYGEN__)
187
194
203#endif /* NRF_WIFI_LOW_POWER */
204#endif /* __BAL_API_H__ */
unsigned long nrf_wifi_bal_dma_unmap(void *ctx, unsigned long phy_addr, size_t len, enum nrf_wifi_osal_dma_dir dma_dir)
Unmap a physical address for DMA transfer.
void nrf_wifi_bal_write_block(void *ctx, unsigned long dest_addr_offset, const void *src_addr, size_t len)
Write a block of data to a specific address offset.
enum nrf_wifi_status nrf_wifi_bal_dev_init(struct nrf_wifi_bal_dev_ctx *bal_dev_ctx)
Initialize a device context in the BAL layer.
void nrf_wifi_bal_rpu_ps_sleep(void *ctx)
Put the RPU to sleep.
int nrf_wifi_bal_rpu_ps_status(void *ctx)
Get the power-saving status of the RPU.
struct nrf_wifi_bal_priv * nrf_wifi_bal_init(struct nrf_wifi_bal_cfg_params *cfg_params, enum nrf_wifi_status(*intr_callbk_fn)(void *hal_ctx))
Header containing the API declarations for the Bus Abstraction Layer (BAL) of the Wi-Fi driver.
void nrf_wifi_bal_bus_access_cnt_print(void *ctx)
Print bus access count.
void nrf_wifi_bal_dev_rem(struct nrf_wifi_bal_dev_ctx *bal_dev_ctx)
Remove a device context from the BAL layer.
unsigned int nrf_wifi_bal_read_word(void *ctx, unsigned long addr_offset)
Read a word from a specific address offset.
void nrf_wifi_bal_dev_deinit(struct nrf_wifi_bal_dev_ctx *bal_dev_ctx)
Deinitialize a device context in the BAL layer.
void nrf_wifi_bal_write_word(void *ctx, unsigned long addr_offset, unsigned int val)
Write a word to a specific address offset.
void nrf_wifi_bal_rpu_ps_wake(void *ctx)
Wake up the RPU from sleep.
void nrf_wifi_bal_bus_access_rec_disab(void *ctx)
Disable bus access recording.
unsigned long nrf_wifi_bal_dma_map(void *ctx, unsigned long virt_addr, size_t len, enum nrf_wifi_osal_dma_dir dma_dir)
Map a virtual address to a physical address for DMA transfer.
void nrf_wifi_bal_read_block(void *ctx, void *dest_addr, unsigned long src_addr_offset, size_t len)
Read a block of data from a specific address offset.
struct nrf_wifi_bal_dev_ctx * nrf_wifi_bal_dev_add(struct nrf_wifi_bal_priv *bpriv, void *hal_dev_ctx)
Add a device context to the BAL layer.
void nrf_wifi_bal_bus_access_rec_enab(void *ctx)
Enable bus access recording.
void nrf_wifi_bal_deinit(struct nrf_wifi_bal_priv *bpriv)
Deinitialize the BAL layer.
Header containing the structure declarations for the Bus Abstraction Layer (BAL) of the Wi-Fi driver.
unsigned int len
Definition host_rpu_data_if.h:3
nrf_wifi_status
The status of an operation performed by the RPU driver.
Definition osal_structs.h:39
nrf_wifi_osal_dma_dir
DMA direction for a DMA operation.
Definition osal_structs.h:49
Structure holding configuration parameters for the BAL.
Definition bal_structs.h:23
void * hal_dev_ctx
Definition bal_structs.h:51
struct nrf_wifi_bal_priv * bpriv
Definition bal_structs.h:49
Structure holding the device context for the BAL.
Definition bal_structs.h:47
enum nrf_wifi_status(* intr_callbk_fn)(void *ctx)
Definition bal_structs.h:41
Structure holding context information for the BAL.
Definition bal_structs.h:31