net: complement wireless handling as ethernet

Change-Id: I13cc4cbfc1e305e17c0630f11a1173afe96e8a03
Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
chao.an
2020-01-06 19:35:50 +08:00
committed by Alan Carvalho de Assis
parent 70fbc14103
commit 97bead5496
5 changed files with 8 additions and 3 deletions
+2 -1
View File
@@ -976,7 +976,8 @@ static int netdev_ifr_ioctl(FAR struct socket *psock, int cmd,
if (dev)
{
#ifdef CONFIG_NET_ETHERNET
if (dev->d_lltype == NET_LL_ETHERNET)
if (dev->d_lltype == NET_LL_ETHERNET ||
dev->d_lltype == NET_LL_IEEE80211)
{
memcpy(dev->d_mac.ether.ether_addr_octet,
req->ifr_hwaddr.sa_data, IFHWADDRLEN);
+1
View File
@@ -121,6 +121,7 @@ int netdev_lladdrsize(FAR struct net_driver_s *dev)
{
#ifdef CONFIG_NET_ETHERNET
case NET_LL_ETHERNET:
case NET_LL_IEEE80211:
{
/* Size of the Ethernet MAC address */