Skip to content

Commit 588fecc

Browse files
krish2718nordicjm
authored andcommitted
[nrf fromtree] drivers: nrf_wifi: Fix NRF71 build
NRF71 doesn't have direct memory access, so, disabled the rpu stats memory variant. Signed-off-by: Chaitanya Tata <[email protected]> (cherry picked from commit 8c5a5ae)
1 parent ee69aaa commit 588fecc

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

drivers/wifi/nrf_wifi/src/wifi_util.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,10 @@
1414
#include "fmac_main.h"
1515
#include "wifi_util.h"
1616

17+
#ifndef CONFIG_NRF71_ON_IPC
1718
#include "rpu_lmac_phy_stats.h"
1819
#include "rpu_umac_stats.h"
20+
#endif
1921

2022
extern struct nrf_wifi_drv_priv_zep rpu_drv_priv_zep;
2123
struct nrf_wifi_ctx_zep *ctx = &rpu_drv_priv_zep.rpu_ctx_zep;
@@ -973,6 +975,7 @@ static int nrf_wifi_util_rpu_recovery_info(const struct shell *sh,
973975
}
974976
#endif /* CONFIG_NRF_WIFI_RPU_RECOVERY */
975977

978+
#ifndef CONFIG_NRF71_ON_IPC
976979
static int nrf_wifi_dump_stats(const struct shell *sh,
977980
struct nrf_wifi_hal_dev_ctx *hal_dev_ctx,
978981
const char *name,
@@ -1010,6 +1013,7 @@ static int nrf_wifi_dump_stats(const struct shell *sh,
10101013
return ret;
10111014
}
10121015

1016+
10131017
static int nrf_wifi_util_dump_rpu_stats_mem(const struct shell *sh,
10141018
size_t argc,
10151019
const char *argv[])
@@ -1095,6 +1099,7 @@ static int nrf_wifi_util_dump_rpu_stats_mem(const struct shell *sh,
10951099
k_mutex_unlock(&ctx->rpu_lock);
10961100
return ret;
10971101
}
1102+
#endif /* !CONFIG_NRF71_ON_IPC */
10981103

10991104
SHELL_STATIC_SUBCMD_SET_CREATE(
11001105
nrf70_util,
@@ -1199,13 +1204,15 @@ SHELL_STATIC_SUBCMD_SET_CREATE(
11991204
1,
12001205
0),
12011206
#endif /* CONFIG_NRF_WIFI_RPU_RECOVERY */
1207+
#ifndef CONFIG_NRF71_ON_IPC
12021208
SHELL_CMD_ARG(rpu_stats_mem,
12031209
NULL,
12041210
"Display RPU stats by reading from memory "
12051211
"Parameters: umac or lmac or or all (default)",
12061212
nrf_wifi_util_dump_rpu_stats_mem,
12071213
1,
12081214
1),
1215+
#endif /* !CONFIG_NRF71_ON_IPC */
12091216
SHELL_SUBCMD_SET_END);
12101217

12111218

drivers/wifi/nrf_wifi/src/wifi_util.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@
1414
#include <zephyr/shell/shell.h>
1515
#include <zephyr/init.h>
1616
#include <ctype.h>
17+
#ifdef CONFIG_NRF71_ON_IPC
18+
#include <nrf71_wifi_ctrl.h>
19+
#else
1720
#include <host_rpu_sys_if.h>
21+
#endif
1822
#include <common/fmac_structs_common.h>
1923
#include <queue.h>
2024

0 commit comments

Comments
 (0)