From 8bfef12b87f453f01b222e77e88a367983207463 Mon Sep 17 00:00:00 2001 From: Ashish Kumar Dhanotiya Date: Wed, 18 Apr 2018 16:48:27 +0530 Subject: [PATCH] qcacld-3.0: Add logging info for dynamic MAC change Add logging info when the MAC is dynamically changed. Change-Id: If602377f5242ed49a8ead4f71d3d8f1bd989f61a CRs-Fixed: 2215053 --- core/hdd/src/wlan_hdd_hostapd.c | 3 +++ core/hdd/src/wlan_hdd_main.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/core/hdd/src/wlan_hdd_hostapd.c b/core/hdd/src/wlan_hdd_hostapd.c index 73eacdd36a7b..74619a9a34df 100644 --- a/core/hdd/src/wlan_hdd_hostapd.c +++ b/core/hdd/src/wlan_hdd_hostapd.c @@ -704,6 +704,9 @@ static int __hdd_hostapd_set_mac_address(struct net_device *dev, void *addr) return -EINVAL; } + hdd_info("Changing MAC to " MAC_ADDRESS_STR " of interface %s ", + MAC_ADDR_ARRAY(mac_addr.bytes), + dev->name); memcpy(dev->dev_addr, psta_mac_addr->sa_data, ETH_ALEN); hdd_exit(); return 0; diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index c5d06c42a099..657a0ebd922e 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -3276,6 +3276,8 @@ static int __hdd_set_mac_address(struct net_device *dev, void *addr) hdd_err("MAC is Multicast"); return -EINVAL; } + hdd_info("Changing MAC to " MAC_ADDRESS_STR " of the interface %s ", + MAC_ADDR_ARRAY(mac_addr.bytes), dev->name); memcpy(&adapter->mac_addr, psta_mac_addr->sa_data, ETH_ALEN); memcpy(dev->dev_addr, psta_mac_addr->sa_data, ETH_ALEN);