diff --git a/src/shared/linux_osl.c b/src/shared/linux_osl.c index 711b771..5a2636a 100644 --- a/src/shared/linux_osl.c +++ b/src/shared/linux_osl.c @@ -1105,7 +1105,7 @@ osl_os_get_image_block(char *buf, int len, void *image) if (!image) return 0; - rdlen = kernel_read(fp, fp->f_pos, buf, len); + rdlen = kernel_read(fp, (void *)fp->f_pos, (size_t)len, (loff_t *)buf); if (rdlen > 0) fp->f_pos += rdlen; diff --git a/src/wl/sys/wl_cfg80211_hybrid.c b/src/wl/sys/wl_cfg80211_hybrid.c index 2b3c290..093dce6 100644 --- a/src/wl/sys/wl_cfg80211_hybrid.c +++ b/src/wl/sys/wl_cfg80211_hybrid.c @@ -790,6 +790,7 @@ wl_set_auth_type(struct net_device *dev, struct cfg80211_connect_params *sme) break; case NL80211_AUTHTYPE_NETWORK_EAP: WL_DBG(("network eap\n")); + break; default: val = 2; WL_ERR(("invalid auth type (%d)\n", sme->auth_type)); @@ -2347,26 +2348,24 @@ wl_bss_roaming_done(struct wl_cfg80211_priv *wl, struct net_device *ndev, const wl_event_msg_t *e, void *data) { struct wl_cfg80211_connect_info *conn_info = wl_to_conn(wl); + s32 err = 0; #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0) struct cfg80211_bss *bss; struct wlc_ssid *ssid; + struct cfg80211_roam_info roam_info; ssid = &wl->profile->ssid; bss = cfg80211_get_bss(wl_to_wiphy(wl), NULL, (s8 *)&wl->bssid, ssid->SSID, ssid->SSID_len, WLAN_CAPABILITY_ESS, WLAN_CAPABILITY_ESS); - struct cfg80211_roam_info roam_info = { // Rel. commit "cfg80211: Indicate MLO connection info in connect and roam callbacks" (Veerendranath Jakkam, Wed Jun 8) #if LINUX_VERSION_CODE < KERNEL_VERSION(6, 0, 0) - .bss = bss, + roam_info.bss = bss; #else - .links[0].bss = bss, + roam_info.links[0].bss = bss; #endif - .req_ie = conn_info->req_ie, - .req_ie_len = conn_info->req_ie_len, - .resp_ie = conn_info->resp_ie, - .resp_ie_len = conn_info->resp_ie_len, - }; + roam_info.req_ie = conn_info->req_ie; + roam_info.req_ie_len = conn_info->req_ie_len; + roam_info.resp_ie = conn_info->resp_ie; #endif - s32 err = 0; wl_get_assoc_ies(wl); memcpy(wl->profile->bssid, &e->addr, ETHER_ADDR_LEN); diff --git a/src/wl/sys/wl_iw.h b/src/wl/sys/wl_iw.h index 3ab084f..471d11f 100644 --- a/src/wl/sys/wl_iw.h +++ b/src/wl/sys/wl_iw.h @@ -70,7 +70,6 @@ struct cntry_locales_custom { #define WL_IW_RSSI_EXCELLENT -57 #define WL_IW_RSSI_INVALID 0 #define MAX_WX_STRING 80 -#define isprint(c) bcm_isprint(c) #define WL_IW_SET_ACTIVE_SCAN (SIOCIWFIRSTPRIV+1) #define WL_IW_GET_RSSI (SIOCIWFIRSTPRIV+3) #define WL_IW_SET_PASSIVE_SCAN (SIOCIWFIRSTPRIV+5) diff --git a/src/wl/sys/wl_linux.c b/src/wl/sys/wl_linux.c index d13fb98..97ae2a6 100644 --- a/src/wl/sys/wl_linux.c +++ b/src/wl/sys/wl_linux.c @@ -797,14 +797,15 @@ wl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) pci_read_config_dword(pdev, 0x40, &val); if ((val & 0x0000ff00) != 0) pci_write_config_dword(pdev, 0x40, val & 0xffff00ff); - bar1_size = pci_resource_len(pdev, 2); - #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) - bar1_addr = (uchar *)ioremap(pci_resource_start(pdev, 2), - bar1_size); - #else - bar1_addr = (uchar *)ioremap_nocache(pci_resource_start(pdev, 2), - bar1_size); - #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) */ + + bar1_size = pci_resource_len(pdev, 2); + #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) + bar1_addr = (uchar *)ioremap(pci_resource_start(pdev, 2), + bar1_size); + #else + bar1_addr = (uchar *)ioremap_nocache(pci_resource_start(pdev, 2), + bar1_size); + #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) */ wl = wl_attach(pdev->vendor, pdev->device, pci_resource_start(pdev, 0), PCI_BUS, pdev, pdev->irq, bar1_addr, bar1_size);