From de4b83f92367f90f5bd1bc8b37abdc403a96b77b Mon Sep 17 00:00:00 2001 From: kimocoder Date: Tue, 20 Dec 2022 00:07:35 +0100 Subject: [PATCH] Fixed compiler warnings instead of silencing them --- Makefile | 2 +- core/mesh/rtw_mesh.c | 8 ++++---- hal/hal_hci/hal_usb.c | 2 +- hal/rtl8812a/usb/rtl8812au_xmit.c | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 61e2d47..3353587 100644 --- a/Makefile +++ b/Makefile @@ -6,7 +6,7 @@ EXTRA_CFLAGS += -O1 #EXTRA_CFLAGS += -Werror #EXTRA_CFLAGS += -pedantic #EXTRA_CFLAGS += -Wshadow -Wpointer-arith -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -EXTRA_CFLAGS += -Wno-cast-function-type +#EXTRA_CFLAGS += -Wno-cast-function-type EXTRA_CFLAGS += -Wno-unused-variable EXTRA_CFLAGS += -Wno-implicit-fallthrough #EXTRA_CFLAGS += -Wno-unused-value diff --git a/core/mesh/rtw_mesh.c b/core/mesh/rtw_mesh.c index 25c17cf..1b7c4c1 100644 --- a/core/mesh/rtw_mesh.c +++ b/core/mesh/rtw_mesh.c @@ -3367,24 +3367,24 @@ void rtw_mesh_init_mesh_info(_adapter *adapter) _rtw_memset(minfo, 0, sizeof(struct rtw_mesh_info)); rtw_mesh_plink_ctl_init(adapter); - + minfo->last_preq = rtw_get_current_time(); /* minfo->last_sn_update = rtw_get_current_time(); */ minfo->next_perr = rtw_get_current_time(); - + ATOMIC_SET(&minfo->mpaths, 0); rtw_mesh_pathtbl_init(adapter); _rtw_init_queue(&minfo->mpath_tx_queue); tasklet_init(&minfo->mpath_tx_tasklet - , (void(*)(unsigned long))mpath_tx_tasklet_hdl + , (void(*))mpath_tx_tasklet_hdl , (unsigned long)adapter); rtw_mrc_init(adapter); _rtw_init_listhead(&minfo->preq_queue.list); _rtw_spinlock_init(&minfo->mesh_preq_queue_lock); - + rtw_init_timer(&adapter->mesh_path_timer, adapter, rtw_ieee80211_mesh_path_timer, adapter); rtw_init_timer(&adapter->mesh_path_root_timer, adapter, rtw_ieee80211_mesh_path_root_timer, adapter); rtw_init_timer(&adapter->mesh_atlm_param_req_timer, adapter, rtw_mesh_atlm_param_req_timer, adapter); diff --git a/hal/hal_hci/hal_usb.c b/hal/hal_hci/hal_usb.c index 609616b..053e51c 100644 --- a/hal/hal_hci/hal_usb.c +++ b/hal/hal_hci/hal_usb.c @@ -26,7 +26,7 @@ int usb_init_recv_priv(_adapter *padapter, u16 ini_in_buf_sz) #ifdef PLATFORM_LINUX tasklet_init(&precvpriv->recv_tasklet, - (void(*)(unsigned long))usb_recv_tasklet, + (void(*))usb_recv_tasklet, (unsigned long)padapter); #endif /* PLATFORM_LINUX */ diff --git a/hal/rtl8812a/usb/rtl8812au_xmit.c b/hal/rtl8812a/usb/rtl8812au_xmit.c index 7ec1a84..0059cb0 100644 --- a/hal/rtl8812a/usb/rtl8812au_xmit.c +++ b/hal/rtl8812a/usb/rtl8812au_xmit.c @@ -25,7 +25,7 @@ s32 rtl8812au_init_xmit_priv(_adapter *padapter) #ifdef PLATFORM_LINUX tasklet_init(&pxmitpriv->xmit_tasklet, - (void(*)(unsigned long))rtl8812au_xmit_tasklet, + (void(*))rtl8812au_xmit_tasklet, (unsigned long)padapter); #endif #ifdef CONFIG_TX_EARLY_MODE