* [PATCH] netxen: drop redudant spinlock
@ 2007-07-27 17:42 Dhananjay Phadke
2007-07-30 19:52 ` Jeff Garzik
0 siblings, 1 reply; 2+ messages in thread
From: Dhananjay Phadke @ 2007-07-27 17:42 UTC (permalink / raw)
To: netdev; +Cc: jeff
Some leftover code that makes use of adapter->lock in tx_timeout function,
which resets the interface under this lock. In close() when the workqueue
is flushed, prints the warning about sleeping with interrupts disabled
(when spinlock debug is enabled). The lock was required with private netxen
IOCTLs, which were removed a while ago.
Index: netdev-2.6/drivers/net/netxen/netxen_nic_main.c
===================================================================
--- netdev-2.6.orig/drivers/net/netxen/netxen_nic_main.c
+++ netdev-2.6/drivers/net/netxen/netxen_nic_main.c
@@ -335,7 +335,6 @@ netxen_nic_probe(struct pci_dev *pdev, c
adapter->ahw.pdev = pdev;
adapter->ahw.pci_func = pci_func_id;
spin_lock_init(&adapter->tx_lock);
- spin_lock_init(&adapter->lock);
/* remap phys address */
mem_base = pci_resource_start(pdev, 0); /* 0 is for BAR 0 */
@@ -1228,15 +1227,12 @@ static void netxen_tx_timeout_task(struc
{
struct netxen_adapter *adapter =
container_of(work, struct netxen_adapter, tx_timeout_task);
- unsigned long flags;
printk(KERN_ERR "%s %s: transmit timeout, resetting.\n",
netxen_nic_driver_name, adapter->netdev->name);
- spin_lock_irqsave(&adapter->lock, flags);
netxen_nic_close(adapter->netdev);
netxen_nic_open(adapter->netdev);
- spin_unlock_irqrestore(&adapter->lock, flags);
adapter->netdev->trans_start = jiffies;
netif_wake_queue(adapter->netdev);
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] netxen: drop redudant spinlock
2007-07-27 17:42 [PATCH] netxen: drop redudant spinlock Dhananjay Phadke
@ 2007-07-30 19:52 ` Jeff Garzik
0 siblings, 0 replies; 2+ messages in thread
From: Jeff Garzik @ 2007-07-30 19:52 UTC (permalink / raw)
To: Dhananjay Phadke; +Cc: netdev
Dhananjay Phadke wrote:
> Some leftover code that makes use of adapter->lock in tx_timeout function,
> which resets the interface under this lock. In close() when the workqueue
> is flushed, prints the warning about sleeping with interrupts disabled
> (when spinlock debug is enabled). The lock was required with private netxen
> IOCTLs, which were removed a while ago.
applied
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-07-30 19:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-27 17:42 [PATCH] netxen: drop redudant spinlock Dhananjay Phadke
2007-07-30 19:52 ` Jeff Garzik
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.