Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d55b53ff authored by Jeff Kirsher's avatar Jeff Kirsher Committed by David S. Miller
Browse files

igb/ixgbe/e1000e: resolve tx multiqueue bug



With the recent changes to tx mutiqueue, igb/ixgbe/e1000e was not calling
netif_tx_start_all_queues() before calling netif_tx_wake_all_queues().
This causes an issue during loading of the driver.

In addition, updated e1000e to use the updated tx mutliqueue api.

Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b6fcbdb4
Loading
Loading
Loading
Loading
+6 −4
Original line number Original line Diff line number Diff line
@@ -2513,7 +2513,7 @@ void e1000e_down(struct e1000_adapter *adapter)
	ew32(RCTL, rctl & ~E1000_RCTL_EN);
	ew32(RCTL, rctl & ~E1000_RCTL_EN);
	/* flush and sleep below */
	/* flush and sleep below */


	netif_stop_queue(netdev);
	netif_tx_stop_all_queues(netdev);


	/* disable transmits in the hardware */
	/* disable transmits in the hardware */
	tctl = er32(TCTL);
	tctl = er32(TCTL);
@@ -2663,6 +2663,8 @@ static int e1000_open(struct net_device *netdev)


	e1000_irq_enable(adapter);
	e1000_irq_enable(adapter);


	netif_tx_start_all_queues(netdev);

	/* fire a link status change interrupt to start the watchdog */
	/* fire a link status change interrupt to start the watchdog */
	ew32(ICS, E1000_ICS_LSC);
	ew32(ICS, E1000_ICS_LSC);


@@ -3118,7 +3120,7 @@ static void e1000_watchdog_task(struct work_struct *work)
			ew32(TCTL, tctl);
			ew32(TCTL, tctl);


			netif_carrier_on(netdev);
			netif_carrier_on(netdev);
			netif_wake_queue(netdev);
			netif_tx_wake_all_queues(netdev);


			if (!test_bit(__E1000_DOWN, &adapter->state))
			if (!test_bit(__E1000_DOWN, &adapter->state))
				mod_timer(&adapter->phy_info_timer,
				mod_timer(&adapter->phy_info_timer,
@@ -3130,7 +3132,7 @@ static void e1000_watchdog_task(struct work_struct *work)
			adapter->link_duplex = 0;
			adapter->link_duplex = 0;
			ndev_info(netdev, "Link is Down\n");
			ndev_info(netdev, "Link is Down\n");
			netif_carrier_off(netdev);
			netif_carrier_off(netdev);
			netif_stop_queue(netdev);
			netif_tx_stop_all_queues(netdev);
			if (!test_bit(__E1000_DOWN, &adapter->state))
			if (!test_bit(__E1000_DOWN, &adapter->state))
				mod_timer(&adapter->phy_info_timer,
				mod_timer(&adapter->phy_info_timer,
					  round_jiffies(jiffies + 2 * HZ));
					  round_jiffies(jiffies + 2 * HZ));
@@ -4504,7 +4506,7 @@ static int __devinit e1000_probe(struct pci_dev *pdev,


	/* tell the stack to leave us alone until e1000_open() is called */
	/* tell the stack to leave us alone until e1000_open() is called */
	netif_carrier_off(netdev);
	netif_carrier_off(netdev);
	netif_stop_queue(netdev);
	netif_tx_stop_all_queues(netdev);


	strcpy(netdev->name, "eth%d");
	strcpy(netdev->name, "eth%d");
	err = register_netdev(netdev);
	err = register_netdev(netdev);
+2 −0
Original line number Original line Diff line number Diff line
@@ -1493,6 +1493,8 @@ static int igb_open(struct net_device *netdev)


	igb_irq_enable(adapter);
	igb_irq_enable(adapter);


	netif_tx_start_all_queues(netdev);

	/* Fire a link status change interrupt to start the watchdog. */
	/* Fire a link status change interrupt to start the watchdog. */
	wr32(E1000_ICS, E1000_ICS_LSC);
	wr32(E1000_ICS, E1000_ICS_LSC);


+2 −0
Original line number Original line Diff line number Diff line
@@ -2765,6 +2765,8 @@ static int ixgbe_open(struct net_device *netdev)
	if (err)
	if (err)
		goto err_up;
		goto err_up;


	netif_tx_start_all_queues(netdev);

	return 0;
	return 0;


err_up:
err_up: