aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-11-14 02:30:30 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2013-11-14 02:30:30 -0500
commit5e30025a319910695f5010dc0fb53a23299da14d (patch)
tree4292bcf78de221c7de1774ccf5ad0ac5a9315c26 /drivers/net/ethernet
parent7971e23a66c94f1b9bd2d64a3e86dfbfa8c60121 (diff)
parent90d3839b90fe379557dae4a44735a6af78f42885 (diff)
Merge branch 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull core locking changes from Ingo Molnar: "The biggest changes: - add lockdep support for seqcount/seqlocks structures, this unearthed both bugs and required extra annotation. - move the various kernel locking primitives to the new kernel/locking/ directory" * 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (21 commits) block: Use u64_stats_init() to initialize seqcounts locking/lockdep: Mark __lockdep_count_forward_deps() as static lockdep/proc: Fix lock-time avg computation locking/doc: Update references to kernel/mutex.c ipv6: Fix possible ipv6 seqlock deadlock cpuset: Fix potential deadlock w/ set_mems_allowed seqcount: Add lockdep functionality to seqcount/seqlock structures net: Explicitly initialize u64_stats_sync structures for lockdep locking: Move the percpu-rwsem code to kernel/locking/ locking: Move the lglocks code to kernel/locking/ locking: Move the rwsem code to kernel/locking/ locking: Move the rtmutex code to kernel/locking/ locking: Move the semaphore core to kernel/locking/ locking: Move the spinlock code to kernel/locking/ locking: Move the lockdep code to kernel/locking/ locking: Move the mutex code to kernel/locking/ hung_task debugging: Add tracepoint to report the hang x86/locking/kconfig: Update paravirt spinlock Kconfig description lockstat: Report avg wait and hold times lockdep, x86/alternatives: Drop ancient lockdep fixup message ...
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r--drivers/net/ethernet/emulex/benet/be_main.c4
-rw-r--r--drivers/net/ethernet/intel/igb/igb_main.c5
-rw-r--r--drivers/net/ethernet/intel/ixgbe/ixgbe_main.c4
-rw-r--r--drivers/net/ethernet/marvell/mvneta.c3
-rw-r--r--drivers/net/ethernet/marvell/sky2.c3
-rw-r--r--drivers/net/ethernet/neterion/vxge/vxge-main.c4
-rw-r--r--drivers/net/ethernet/nvidia/forcedeth.c2
-rw-r--r--drivers/net/ethernet/realtek/8139too.c3
-rw-r--r--drivers/net/ethernet/tile/tilepro.c2
-rw-r--r--drivers/net/ethernet/via/via-rhine.c3
10 files changed, 33 insertions, 0 deletions
diff --git a/drivers/net/ethernet/emulex/benet/be_main.c b/drivers/net/ethernet/emulex/benet/be_main.c
index cb2bb6fccbc8..eaecaadfa8c5 100644
--- a/drivers/net/ethernet/emulex/benet/be_main.c
+++ b/drivers/net/ethernet/emulex/benet/be_main.c
@@ -2148,6 +2148,9 @@ static int be_tx_qs_create(struct be_adapter *adapter)
2148 if (status) 2148 if (status)
2149 return status; 2149 return status;
2150 2150
2151 u64_stats_init(&txo->stats.sync);
2152 u64_stats_init(&txo->stats.sync_compl);
2153
2151 /* If num_evt_qs is less than num_tx_qs, then more than 2154 /* If num_evt_qs is less than num_tx_qs, then more than
2152 * one txq share an eq 2155 * one txq share an eq
2153 */ 2156 */
@@ -2209,6 +2212,7 @@ static int be_rx_cqs_create(struct be_adapter *adapter)
2209 if (rc) 2212 if (rc)
2210 return rc; 2213 return rc;
2211 2214
2215 u64_stats_init(&rxo->stats.sync);
2212 eq = &adapter->eq_obj[i % adapter->num_evt_qs].q; 2216 eq = &adapter->eq_obj[i % adapter->num_evt_qs].q;
2213 rc = be_cmd_cq_create(adapter, cq, eq, false, 3); 2217 rc = be_cmd_cq_create(adapter, cq, eq, false, 3);
2214 if (rc) 2218 if (rc)
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
index 2ac14bdd5fbb..025e5f4b7481 100644
--- a/drivers/net/ethernet/intel/igb/igb_main.c
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
@@ -1224,6 +1224,9 @@ static int igb_alloc_q_vector(struct igb_adapter *adapter,
1224 ring->count = adapter->tx_ring_count; 1224 ring->count = adapter->tx_ring_count;
1225 ring->queue_index = txr_idx; 1225 ring->queue_index = txr_idx;
1226 1226
1227 u64_stats_init(&ring->tx_syncp);
1228 u64_stats_init(&ring->tx_syncp2);
1229
1227 /* assign ring to adapter */ 1230 /* assign ring to adapter */
1228 adapter->tx_ring[txr_idx] = ring; 1231 adapter->tx_ring[txr_idx] = ring;
1229 1232
@@ -1257,6 +1260,8 @@ static int igb_alloc_q_vector(struct igb_adapter *adapter,
1257 ring->count = adapter->rx_ring_count; 1260 ring->count = adapter->rx_ring_count;
1258 ring->queue_index = rxr_idx; 1261 ring->queue_index = rxr_idx;
1259 1262
1263 u64_stats_init(&ring->rx_syncp);
1264
1260 /* assign ring to adapter */ 1265 /* assign ring to adapter */
1261 adapter->rx_ring[rxr_idx] = ring; 1266 adapter->rx_ring[rxr_idx] = ring;
1262 } 1267 }
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 0066f0aefbfa..0c55079ebee3 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -5085,6 +5085,8 @@ int ixgbe_setup_tx_resources(struct ixgbe_ring *tx_ring)
5085 if (!tx_ring->tx_buffer_info) 5085 if (!tx_ring->tx_buffer_info)
5086 goto err; 5086 goto err;
5087 5087
5088 u64_stats_init(&tx_ring->syncp);
5089
5088 /* round up to nearest 4K */ 5090 /* round up to nearest 4K */
5089 tx_ring->size = tx_ring->count * sizeof(union ixgbe_adv_tx_desc); 5091 tx_ring->size = tx_ring->count * sizeof(union ixgbe_adv_tx_desc);
5090 tx_ring->size = ALIGN(tx_ring->size, 4096); 5092 tx_ring->size = ALIGN(tx_ring->size, 4096);
@@ -5167,6 +5169,8 @@ int ixgbe_setup_rx_resources(struct ixgbe_ring *rx_ring)
5167 if (!rx_ring->rx_buffer_info) 5169 if (!rx_ring->rx_buffer_info)
5168 goto err; 5170 goto err;
5169 5171
5172 u64_stats_init(&rx_ring->syncp);
5173
5170 /* Round up to nearest 4K */ 5174 /* Round up to nearest 4K */
5171 rx_ring->size = rx_ring->count * sizeof(union ixgbe_adv_rx_desc); 5175 rx_ring->size = rx_ring->count * sizeof(union ixgbe_adv_rx_desc);
5172 rx_ring->size = ALIGN(rx_ring->size, 4096); 5176 rx_ring->size = ALIGN(rx_ring->size, 4096);
diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c
index 7d99e695a110..b8e232b4ea2d 100644
--- a/drivers/net/ethernet/marvell/mvneta.c
+++ b/drivers/net/ethernet/marvell/mvneta.c
@@ -2792,6 +2792,9 @@ static int mvneta_probe(struct platform_device *pdev)
2792 2792
2793 pp = netdev_priv(dev); 2793 pp = netdev_priv(dev);
2794 2794
2795 u64_stats_init(&pp->tx_stats.syncp);
2796 u64_stats_init(&pp->rx_stats.syncp);
2797
2795 pp->weight = MVNETA_RX_POLL_WEIGHT; 2798 pp->weight = MVNETA_RX_POLL_WEIGHT;
2796 pp->phy_node = phy_node; 2799 pp->phy_node = phy_node;
2797 pp->phy_interface = phy_mode; 2800 pp->phy_interface = phy_mode;
diff --git a/drivers/net/ethernet/marvell/sky2.c b/drivers/net/ethernet/marvell/sky2.c
index a7df981d2123..43aa7acd84a6 100644
--- a/drivers/net/ethernet/marvell/sky2.c
+++ b/drivers/net/ethernet/marvell/sky2.c
@@ -4763,6 +4763,9 @@ static struct net_device *sky2_init_netdev(struct sky2_hw *hw, unsigned port,
4763 sky2->hw = hw; 4763 sky2->hw = hw;
4764 sky2->msg_enable = netif_msg_init(debug, default_msg); 4764 sky2->msg_enable = netif_msg_init(debug, default_msg);
4765 4765
4766 u64_stats_init(&sky2->tx_stats.syncp);
4767 u64_stats_init(&sky2->rx_stats.syncp);
4768
4766 /* Auto speed and flow control */ 4769 /* Auto speed and flow control */
4767 sky2->flags = SKY2_FLAG_AUTO_SPEED | SKY2_FLAG_AUTO_PAUSE; 4770 sky2->flags = SKY2_FLAG_AUTO_SPEED | SKY2_FLAG_AUTO_PAUSE;
4768 if (hw->chip_id != CHIP_ID_YUKON_XL) 4771 if (hw->chip_id != CHIP_ID_YUKON_XL)
diff --git a/drivers/net/ethernet/neterion/vxge/vxge-main.c b/drivers/net/ethernet/neterion/vxge/vxge-main.c
index 8614eeb7de81..f9876ea8c8bf 100644
--- a/drivers/net/ethernet/neterion/vxge/vxge-main.c
+++ b/drivers/net/ethernet/neterion/vxge/vxge-main.c
@@ -2072,6 +2072,10 @@ static int vxge_open_vpaths(struct vxgedev *vdev)
2072 vdev->config.tx_steering_type; 2072 vdev->config.tx_steering_type;
2073 vpath->fifo.ndev = vdev->ndev; 2073 vpath->fifo.ndev = vdev->ndev;
2074 vpath->fifo.pdev = vdev->pdev; 2074 vpath->fifo.pdev = vdev->pdev;
2075
2076 u64_stats_init(&vpath->fifo.stats.syncp);
2077 u64_stats_init(&vpath->ring.stats.syncp);
2078
2075 if (vdev->config.tx_steering_type) 2079 if (vdev->config.tx_steering_type)
2076 vpath->fifo.txq = 2080 vpath->fifo.txq =
2077 netdev_get_tx_queue(vdev->ndev, i); 2081 netdev_get_tx_queue(vdev->ndev, i);
diff --git a/drivers/net/ethernet/nvidia/forcedeth.c b/drivers/net/ethernet/nvidia/forcedeth.c
index 098b96dad66f..2d045be4b5cf 100644
--- a/drivers/net/ethernet/nvidia/forcedeth.c
+++ b/drivers/net/ethernet/nvidia/forcedeth.c
@@ -5619,6 +5619,8 @@ static int nv_probe(struct pci_dev *pci_dev, const struct pci_device_id *id)
5619 spin_lock_init(&np->lock); 5619 spin_lock_init(&np->lock);
5620 spin_lock_init(&np->hwstats_lock); 5620 spin_lock_init(&np->hwstats_lock);
5621 SET_NETDEV_DEV(dev, &pci_dev->dev); 5621 SET_NETDEV_DEV(dev, &pci_dev->dev);
5622 u64_stats_init(&np->swstats_rx_syncp);
5623 u64_stats_init(&np->swstats_tx_syncp);
5622 5624
5623 init_timer(&np->oom_kick); 5625 init_timer(&np->oom_kick);
5624 np->oom_kick.data = (unsigned long) dev; 5626 np->oom_kick.data = (unsigned long) dev;
diff --git a/drivers/net/ethernet/realtek/8139too.c b/drivers/net/ethernet/realtek/8139too.c
index 50a92104dd0a..da5972eefdd2 100644
--- a/drivers/net/ethernet/realtek/8139too.c
+++ b/drivers/net/ethernet/realtek/8139too.c
@@ -790,6 +790,9 @@ static struct net_device *rtl8139_init_board(struct pci_dev *pdev)
790 790
791 pci_set_master (pdev); 791 pci_set_master (pdev);
792 792
793 u64_stats_init(&tp->rx_stats.syncp);
794 u64_stats_init(&tp->tx_stats.syncp);
795
793retry: 796retry:
794 /* PIO bar register comes first. */ 797 /* PIO bar register comes first. */
795 bar = !use_io; 798 bar = !use_io;
diff --git a/drivers/net/ethernet/tile/tilepro.c b/drivers/net/ethernet/tile/tilepro.c
index 106be47716e7..edb2e12a0fe2 100644
--- a/drivers/net/ethernet/tile/tilepro.c
+++ b/drivers/net/ethernet/tile/tilepro.c
@@ -1008,6 +1008,8 @@ static void tile_net_register(void *dev_ptr)
1008 info->egress_timer.data = (long)info; 1008 info->egress_timer.data = (long)info;
1009 info->egress_timer.function = tile_net_handle_egress_timer; 1009 info->egress_timer.function = tile_net_handle_egress_timer;
1010 1010
1011 u64_stats_init(&info->stats.syncp);
1012
1011 priv->cpu[my_cpu] = info; 1013 priv->cpu[my_cpu] = info;
1012 1014
1013 /* 1015 /*
diff --git a/drivers/net/ethernet/via/via-rhine.c b/drivers/net/ethernet/via/via-rhine.c
index 4a7293ed95e9..cce6c4bc556a 100644
--- a/drivers/net/ethernet/via/via-rhine.c
+++ b/drivers/net/ethernet/via/via-rhine.c
@@ -987,6 +987,9 @@ static int rhine_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
987 987
988 rp->base = ioaddr; 988 rp->base = ioaddr;
989 989
990 u64_stats_init(&rp->tx_stats.syncp);
991 u64_stats_init(&rp->rx_stats.syncp);
992
990 /* Get chip registers into a sane state */ 993 /* Get chip registers into a sane state */
991 rhine_power_init(dev); 994 rhine_power_init(dev);
992 rhine_hw_init(dev, pioaddr); 995 rhine_hw_init(dev, pioaddr);