]> Pileus Git - ~andy/linux/blobdiff - drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
bridge: Add vlan support to static neighbors
[~andy/linux] / drivers / net / ethernet / intel / ixgbe / ixgbe_main.c
index 5989b3fa9fdc7432a8a00f4fa58e148935799e74..1c0efcb7920f18053129c67b9a27998616841401 100644 (file)
@@ -1,7 +1,7 @@
 /*******************************************************************************
 
   Intel 10 Gigabit PCI Express Linux driver
-  Copyright(c) 1999 - 2012 Intel Corporation.
+  Copyright(c) 1999 - 2013 Intel Corporation.
 
   This program is free software; you can redistribute it and/or modify it
   under the terms and conditions of the GNU General Public License,
@@ -66,7 +66,7 @@ static char ixgbe_default_device_descr[] =
 #define DRV_VERSION "3.11.33-k"
 const char ixgbe_driver_version[] = DRV_VERSION;
 static const char ixgbe_copyright[] =
-                               "Copyright (c) 1999-2012 Intel Corporation.";
+                               "Copyright (c) 1999-2013 Intel Corporation.";
 
 static const struct ixgbe_info *ixgbe_info_tbl[] = {
        [board_82598] = &ixgbe_82598_info,
@@ -838,7 +838,7 @@ static bool ixgbe_clean_tx_irq(struct ixgbe_q_vector *q_vector,
                        break;
 
                /* prevent any other reads prior to eop_desc */
-               rmb();
+               read_barrier_depends();
 
                /* if DD is not set pending work has not been completed */
                if (!(eop_desc->wb.status & cpu_to_le32(IXGBE_TXD_STAT_DD)))
@@ -1399,6 +1399,7 @@ static void ixgbe_set_rsc_gso_size(struct ixgbe_ring *ring,
        /* set gso_size to avoid messing up TCP MSS */
        skb_shinfo(skb)->gso_size = DIV_ROUND_UP((skb->len - hdr_len),
                                                 IXGBE_CB(skb)->append_cnt);
+       skb_shinfo(skb)->gso_type = SKB_GSO_TCPV4;
 }
 
 static void ixgbe_update_rsc_stats(struct ixgbe_ring *rx_ring,
@@ -2178,10 +2179,10 @@ static void ixgbe_check_overtemp_subtask(struct ixgbe_adapter *adapter)
                        return;
 
                if (!(eicr & IXGBE_EICR_LSC) && hw->mac.ops.check_link) {
-                       u32 autoneg;
+                       u32 speed;
                        bool link_up = false;
 
-                       hw->mac.ops.check_link(hw, &autoneg, &link_up, false);
+                       hw->mac.ops.check_link(hw, &speed, &link_up, false);
 
                        if (link_up)
                                return;
@@ -3994,25 +3995,25 @@ static void ixgbe_sfp_link_config(struct ixgbe_adapter *adapter)
  **/
 static int ixgbe_non_sfp_link_config(struct ixgbe_hw *hw)
 {
-       u32 autoneg;
-       bool negotiation, link_up = false;
+       u32 speed;
+       bool autoneg, link_up = false;
        u32 ret = IXGBE_ERR_LINK_SETUP;
 
        if (hw->mac.ops.check_link)
-               ret = hw->mac.ops.check_link(hw, &autoneg, &link_up, false);
+               ret = hw->mac.ops.check_link(hw, &speed, &link_up, false);
 
        if (ret)
                goto link_cfg_out;
 
-       autoneg = hw->phy.autoneg_advertised;
-       if ((!autoneg) && (hw->mac.ops.get_link_capabilities))
-               ret = hw->mac.ops.get_link_capabilities(hw, &autoneg,
-                                                       &negotiation);
+       speed = hw->phy.autoneg_advertised;
+       if ((!speed) && (hw->mac.ops.get_link_capabilities))
+               ret = hw->mac.ops.get_link_capabilities(hw, &speed,
+                                                       &autoneg);
        if (ret)
                goto link_cfg_out;
 
        if (hw->mac.ops.setup_link)
-               ret = hw->mac.ops.setup_link(hw, autoneg, negotiation, link_up);
+               ret = hw->mac.ops.setup_link(hw, speed, link_up);
 link_cfg_out:
        return ret;
 }
@@ -4869,7 +4870,7 @@ static int ixgbe_change_mtu(struct net_device *netdev, int new_mtu)
         */
        if ((adapter->flags & IXGBE_FLAG_SRIOV_ENABLED) &&
            (adapter->hw.mac.type == ixgbe_mac_82599EB) &&
-           (max_frame > MAXIMUM_ETHERNET_VLAN_SIZE))
+           (max_frame > (ETH_FRAME_LEN + ETH_FCS_LEN)))
                e_warn(probe, "Setting MTU > 1500 will disable legacy VFs\n");
 
        e_info(probe, "changing MTU from %d to %d\n", netdev->mtu, new_mtu);
@@ -5739,8 +5740,8 @@ sfp_out:
 static void ixgbe_sfp_link_config_subtask(struct ixgbe_adapter *adapter)
 {
        struct ixgbe_hw *hw = &adapter->hw;
-       u32 autoneg;
-       bool negotiation;
+       u32 speed;
+       bool autoneg = false;
 
        if (!(adapter->flags & IXGBE_FLAG_NEED_LINK_CONFIG))
                return;
@@ -5751,11 +5752,11 @@ static void ixgbe_sfp_link_config_subtask(struct ixgbe_adapter *adapter)
 
        adapter->flags &= ~IXGBE_FLAG_NEED_LINK_CONFIG;
 
-       autoneg = hw->phy.autoneg_advertised;
-       if ((!autoneg) && (hw->mac.ops.get_link_capabilities))
-               hw->mac.ops.get_link_capabilities(hw, &autoneg, &negotiation);
+       speed = hw->phy.autoneg_advertised;
+       if ((!speed) && (hw->mac.ops.get_link_capabilities))
+               hw->mac.ops.get_link_capabilities(hw, &speed, &autoneg);
        if (hw->mac.ops.setup_link)
-               hw->mac.ops.setup_link(hw, autoneg, negotiation, true);
+               hw->mac.ops.setup_link(hw, speed, true);
 
        adapter->flags |= IXGBE_FLAG_NEED_LINK_UPDATE;
        adapter->link_check_timeout = jiffies;
@@ -7001,7 +7002,7 @@ static int ixgbe_ndo_fdb_add(struct ndmsg *ndm, struct nlattr *tb[],
        return err;
 }
 
-static int ixgbe_ndo_fdb_del(struct ndmsg *ndm,
+static int ixgbe_ndo_fdb_del(struct ndmsg *ndm, struct nlattr *tb[],
                             struct net_device *dev,
                             const unsigned char *addr)
 {
@@ -7078,7 +7079,8 @@ static int ixgbe_ndo_bridge_setlink(struct net_device *dev,
 }
 
 static int ixgbe_ndo_bridge_getlink(struct sk_buff *skb, u32 pid, u32 seq,
-                                   struct net_device *dev)
+                                   struct net_device *dev,
+                                   u32 filter_mask)
 {
        struct ixgbe_adapter *adapter = netdev_priv(dev);
        u16 mode;
@@ -7758,6 +7760,8 @@ static pci_ers_result_t ixgbe_io_error_detected(struct pci_dev *pdev,
                if (vfdev) {
                        e_dev_err("Issuing VFLR to VF %d\n", vf);
                        pci_write_config_dword(vfdev, 0xA8, 0x00008000);
+                       /* Free device reference count */
+                       pci_dev_put(vfdev);
                }
 
                pci_cleanup_aer_uncorrect_error_status(pdev);