In kernels prior to 6.10, dev_base_lock was required to protect the
net_device list traversal. From 6.10 onward the lock was
dropped in favor of RCU.
To preserve previous behavior (i.e. 24.10-nss on kernel 6.6), restore
read_lock()/read_unlock() and wrap into kernel macros check.
Signed-off-by: Sean Khan <datapronix@protonmail.com>