From patchwork Sun Nov 29 04:16:22 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hin-Tak Leung X-Patchwork-Id: 63504 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nAT4GjM9004624 for ; Sun, 29 Nov 2009 04:16:45 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753858AbZK2EQ3 (ORCPT ); Sat, 28 Nov 2009 23:16:29 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753758AbZK2EQ3 (ORCPT ); Sat, 28 Nov 2009 23:16:29 -0500 Received: from mail-ew0-f215.google.com ([209.85.219.215]:42243 "EHLO mail-ew0-f215.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752734AbZK2EQ3 (ORCPT ); Sat, 28 Nov 2009 23:16:29 -0500 Received: by ewy7 with SMTP id 7so3191653ewy.28 for ; Sat, 28 Nov 2009 20:16:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer; bh=oiDcDO7amDmjBAu2LCxLchXYtpKD/PotrvMO/Qk6EkQ=; b=m4bj0Mn5TqIey9UICAO3J3wFPJZMGmizQnnP66AtfO9RIO5txRHbxevOm0FplZGF+9 fpyyr6LUMPLuoSkrMXBCXbD/xLg0V3n8o7Rnv2aR1sCSbpsldLhhjFJmENmscECMNhns 0Ei8kkY8+/niYiB3Jf91HwoNkLVTtgRtEJZkc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; b=HnL9x8nXSCMg+YdA7zfqpT3mQZ07Oii6zClwB7omJDqD3JuYjveg9+03DuNHwJ1hUq +BHj2deR2Ke1+qdHbG3xFHTJMcgtclg1oGWX/hFBFFX4ua44CRBZ/KcBV9fKTHtx5EEo Rst6fphkw6vEfHH/SV8lFdSzRVF0ofO05mH8Q= Received: by 10.213.107.8 with SMTP id z8mr3260479ebo.32.1259468194027; Sat, 28 Nov 2009 20:16:34 -0800 (PST) Received: from localhost.localdomain (cpc2-cmbg5-0-0-cust735.cmbg.cable.ntl.com [81.98.250.224]) by mx.google.com with ESMTPS id 10sm4844404eyd.21.2009.11.28.20.16.32 (version=SSLv3 cipher=RC4-MD5); Sat, 28 Nov 2009 20:16:33 -0800 (PST) From: Hin-Tak Leung To: linux-wireless@vger.kernel.org, lrodriguez@atheros.com Cc: Hin-Tak Leung , Hin-Tak Leung Subject: [PATCH] compat-2.6: split netdev patch to libertas/main.c into two parts Date: Sun, 29 Nov 2009 04:16:22 +0000 Message-Id: <1259468182-25499-1-git-send-email-HinTak.Leung@gmail.com> X-Mailer: git-send-email 1.6.5.2 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org diff --git a/compat/patches/01-netdev.patch b/compat/patches/01-netdev.patch index d66a2f4..8286bb8 100644 --- a/compat/patches/01-netdev.patch +++ b/compat/patches/01-netdev.patch @@ -432,7 +432,37 @@ without creating a headache on maintenance of the pathes. dev->watchdog_timeo = 5 * HZ; dev->ethtool_ops = &lbs_ethtool_ops; #ifdef WIRELESS_EXT -@@ -1405,6 +1416,7 @@ +@@ -1589,11 +1610,13 @@ + lbs_deb_leave(LBS_DEB_MAIN); + } + ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)) + static const struct net_device_ops rtap_netdev_ops = { + .ndo_open = lbs_rtap_open, + .ndo_stop = lbs_rtap_stop, + .ndo_start_xmit = lbs_rtap_hard_start_xmit, + }; ++#endif + + static int lbs_add_rtap(struct lbs_private *priv) + { +@@ -1614,7 +1637,13 @@ + + memcpy(rtap_dev->dev_addr, priv->current_addr, ETH_ALEN); + rtap_dev->type = ARPHRD_IEEE80211_RADIOTAP; ++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)) + rtap_dev->netdev_ops = &rtap_netdev_ops; ++#else ++ rtap_dev->open = lbs_rtap_open; ++ rtap_dev->stop = lbs_rtap_stop; ++ rtap_dev->hard_start_xmit = lbs_rtap_hard_start_xmit; ++#endif + rtap_dev->ml_priv = priv; + SET_NETDEV_DEV(rtap_dev, priv->dev->dev.parent); + +--- a/drivers/net/wireless/libertas/mesh.c 2009-11-02 08:04:43.000000000 -0800 ++++ b/drivers/net/wireless/libertas/mesh.c 2009-11-02 08:04:44.000000000 -0800 +@@ -305,6 +316,7 @@ EXPORT_SYMBOL_GPL(lbs_stop_card); @@ -440,7 +470,7 @@ without creating a headache on maintenance of the pathes. static const struct net_device_ops mesh_netdev_ops = { .ndo_open = lbs_dev_open, .ndo_stop = lbs_mesh_stop, -@@ -1412,6 +1424,7 @@ +@@ -312,6 +324,7 @@ .ndo_set_mac_address = lbs_set_mac_address, .ndo_set_multicast_list = lbs_set_multicast_list, }; @@ -448,7 +478,7 @@ without creating a headache on maintenance of the pathes. /** * @brief This function adds mshX interface -@@ -1435,7 +1448,15 @@ +@@ -335,7 +348,15 @@ mesh_dev->ml_priv = priv; priv->mesh_dev = mesh_dev; @@ -464,34 +494,6 @@ without creating a headache on maintenance of the pathes. mesh_dev->ethtool_ops = &lbs_ethtool_ops; memcpy(mesh_dev->dev_addr, priv->dev->dev_addr, sizeof(priv->dev->dev_addr)); -@@ -1589,11 +1610,13 @@ - lbs_deb_leave(LBS_DEB_MAIN); - } - -+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)) - static const struct net_device_ops rtap_netdev_ops = { - .ndo_open = lbs_rtap_open, - .ndo_stop = lbs_rtap_stop, - .ndo_start_xmit = lbs_rtap_hard_start_xmit, - }; -+#endif - - static int lbs_add_rtap(struct lbs_private *priv) - { -@@ -1614,7 +1637,13 @@ - - memcpy(rtap_dev->dev_addr, priv->current_addr, ETH_ALEN); - rtap_dev->type = ARPHRD_IEEE80211_RADIOTAP; -+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29)) - rtap_dev->netdev_ops = &rtap_netdev_ops; -+#else -+ rtap_dev->open = lbs_rtap_open; -+ rtap_dev->stop = lbs_rtap_stop; -+ rtap_dev->hard_start_xmit = lbs_rtap_hard_start_xmit; -+#endif - rtap_dev->ml_priv = priv; - SET_NETDEV_DEV(rtap_dev, priv->dev->dev.parent); - --- a/drivers/net/wireless/libertas/defs.h 2009-07-08 14:04:29.692256519 -0700 +++ b/drivers/net/wireless/libertas/defs.h 2009-07-08 14:03:26.712279246 -0700 @@ -16,6 +16,14 @@