From patchwork Wed Dec 30 13:54:03 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kalle Valo X-Patchwork-Id: 70252 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id nBUDsHgG020224 for ; Wed, 30 Dec 2009 13:54:18 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752896AbZL3NyQ (ORCPT ); Wed, 30 Dec 2009 08:54:16 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752895AbZL3NyQ (ORCPT ); Wed, 30 Dec 2009 08:54:16 -0500 Received: from smtp.nokia.com ([192.100.122.230]:47480 "EHLO mgw-mx03.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752893AbZL3NyQ (ORCPT ); Wed, 30 Dec 2009 08:54:16 -0500 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx03.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nBUDsAXX029614 for ; Wed, 30 Dec 2009 15:54:13 +0200 Received: from vaebh104.NOE.Nokia.com ([10.160.244.30]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Wed, 30 Dec 2009 15:54:09 +0200 Received: from mgw-sa01.ext.nokia.com ([147.243.1.47]) by vaebh104.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Wed, 30 Dec 2009 15:54:09 +0200 Received: from [127.0.1.1] (essapo-nirac25228.europe.nokia.com [10.162.252.28]) by mgw-sa01.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nBUDs5qp032381; Wed, 30 Dec 2009 15:54:05 +0200 Subject: [PATCH] mac80211: fix ieee80211_change_mac() to use struct sockaddr To: linux-wireless@vger.kernel.org From: Kalle Valo Cc: Kalle Valo Date: Wed, 30 Dec 2009 15:54:03 +0200 Message-ID: <20091230135403.30935.72535.stgit@tikku> User-Agent: StGit/0.15 MIME-Version: 1.0 X-OriginalArrivalTime: 30 Dec 2009 13:54:09.0404 (UTC) FILETIME=[8F5F7BC0:01CA8957] X-Nokia-AV: Clean Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c index 00a1f4c..7218966 100644 --- a/net/mac80211/iface.c +++ b/net/mac80211/iface.c @@ -63,15 +63,16 @@ static int ieee80211_change_mtu(struct net_device *dev, int new_mtu) static int ieee80211_change_mac(struct net_device *dev, void *addr) { struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev); + struct sockaddr *sa = addr; int ret; if (ieee80211_sdata_running(sdata)) return -EBUSY; - ret = eth_mac_addr(dev, addr); + ret = eth_mac_addr(dev, sa); if (ret == 0) - memcpy(sdata->vif.addr, addr, ETH_ALEN); + memcpy(sdata->vif.addr, sa->sa_data, ETH_ALEN); return ret; }