diff --git a/bcmwl/src/wl/sys/wl_linux.c b/bcmwl/src/wl/sys/wl_linux.c index 860b935..8823363 100644 --- a/bcmwl/src/wl/sys/wl_linux.c +++ b/bcmwl/src/wl/sys/wl_linux.c @@ -1635,8 +1635,13 @@ wl_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) goto done2; } +#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 9, 0)) if (segment_eq(get_fs(), KERNEL_DS)) buf = ioc.buf; +#else + if (uaccess_kernel()) + buf = ioc.buf; +#endif else if (ioc.buf) { if (!(buf = (void *) MALLOC(wl->osh, MAX(ioc.len, WLC_IOCTL_MAXLEN)))) {