rtl8821ce icon indicating copy to clipboard operation
rtl8821ce copied to clipboard

how to use with openthinclient ?

Open YeyeX64 opened this issue 1 year ago • 1 comments

hello,

i'm looking for a solution to use this driver on openthinclient (light client, pxe or localboot on debian 10).

i think i must include it in the kernel used by pxe or localboot, but i can't do it. Someone have a similar problem ?

best regards

Best regards

YeyeX64 avatar Sep 08 '23 14:09 YeyeX64

this patch seems to work for me

diff --git a/core/rtw_rf.c b/core/rtw_rf.c
index c916c9f..bde8267 100644
--- a/core/rtw_rf.c
+++ b/core/rtw_rf.c
@@ -727,7 +727,11 @@ void rtw_regd_exc_list_free(struct rf_ctl_t *rfctl)
 		ent = LIST_CONTAINOR(cur, struct regd_exc_ent, list);
 		cur = get_next(cur);
 		rtw_list_delete(&ent->list);
-		rtw_mfree((u8 *)ent, sizeof(struct regd_exc_ent) + strlen(ent->regd_name) + 1);
+		#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 5, 1))
+			rtw_mfree((u8 *)ent, sizeof(struct regd_exc_ent));
+		#else
+			rtw_mfree((u8 *)ent, sizeof(struct regd_exc_ent) + strlen(ent->regd_name) + 1);
+		#endif
 	}
 	rfctl->regd_exc_num = 0;
 
@@ -1182,7 +1186,11 @@ void rtw_txpwr_lmt_list_free(struct rf_ctl_t *rfctl)
 		if (ent->regd_name == rfctl->regd_name)
 			rfctl->regd_name = regd_str(TXPWR_LMT_NONE);
 		rtw_list_delete(&ent->list);
-		rtw_vmfree((u8 *)ent, sizeof(struct txpwr_lmt_ent) + strlen(ent->regd_name) + 1);
+		#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 5, 1))
+			rtw_vmfree((u8 *)ent, sizeof(struct txpwr_lmt_ent));
+		#else
+			rtw_vmfree((u8 *)ent, sizeof(struct txpwr_lmt_ent) + strlen(ent->regd_name) + 1);
+		#endif
 	}
 	rfctl->txpwr_regd_num = 0;

nbrondeau avatar Sep 23 '23 06:09 nbrondeau