From 9fed3068df3601a722b30a3e780e3e3c19f3d984 Mon Sep 17 00:00:00 2001 From: kimocoder Date: Mon, 19 Dec 2022 23:00:35 +0100 Subject: [PATCH] Fix kernel v5.12 support --- os_dep/linux/recv_linux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/os_dep/linux/recv_linux.c b/os_dep/linux/recv_linux.c index d87c40b..5e7db29 100644 --- a/os_dep/linux/recv_linux.c +++ b/os_dep/linux/recv_linux.c @@ -405,7 +405,7 @@ static int napi_recv(_adapter *padapter, int budget) So, we should prevent cloned SKB go into napi_gro_receive. */ if (pregistrypriv->en_gro && !skb_cloned(pskb)) { -if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0)) +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0)) if (rtw_napi_gro_receive(&padapter->napi, pskb) != GRO_MERGED_FREE) #else if (rtw_napi_gro_receive(&padapter->napi, pskb) != GRO_DROP)