···3163static void bcm43xx_periodic_work_handler(void *d)3164{3165 struct bcm43xx_private *bcm = d;03166 unsigned long flags;3167 u32 savedirqs = 0;3168 int badness;031693170 mutex_lock(&bcm->mutex);3171 badness = estimate_periodic_work_badness(bcm->periodic_state);···3175 /* Periodic work will take a long time, so we want it to3176 * be preemtible.3177 */3178- netif_tx_disable(bcm->net_dev);000000000003179 spin_lock_irqsave(&bcm->irq_lock, flags);3180 bcm43xx_mac_suspend(bcm);3181 if (bcm43xx_using_pio(bcm))···3211 bcm43xx_pio_thaw_txqueues(bcm);3212 bcm43xx_mac_enable(bcm);3213 netif_wake_queue(bcm->net_dev);03214 }3215 mmiowb();3216 spin_unlock_irqrestore(&bcm->irq_lock, flags);
···3163static void bcm43xx_periodic_work_handler(void *d)3164{3165 struct bcm43xx_private *bcm = d;3166+ struct net_device *net_dev = bcm->net_dev;3167 unsigned long flags;3168 u32 savedirqs = 0;3169 int badness;3170+ unsigned long orig_trans_start = 0;31713172 mutex_lock(&bcm->mutex);3173 badness = estimate_periodic_work_badness(bcm->periodic_state);···3173 /* Periodic work will take a long time, so we want it to3174 * be preemtible.3175 */3176+3177+ netif_tx_lock_bh(net_dev);3178+ /* We must fake a started transmission here, as we are going to3179+ * disable TX. If we wouldn't fake a TX, it would be possible to3180+ * trigger the netdev watchdog, if the last real TX is already3181+ * some time on the past (slightly less than 5secs)3182+ */3183+ orig_trans_start = net_dev->trans_start;3184+ net_dev->trans_start = jiffies;3185+ netif_stop_queue(net_dev);3186+ netif_tx_unlock_bh(net_dev);3187+3188 spin_lock_irqsave(&bcm->irq_lock, flags);3189 bcm43xx_mac_suspend(bcm);3190 if (bcm43xx_using_pio(bcm))···3198 bcm43xx_pio_thaw_txqueues(bcm);3199 bcm43xx_mac_enable(bcm);3200 netif_wake_queue(bcm->net_dev);3201+ net_dev->trans_start = orig_trans_start;3202 }3203 mmiowb();3204 spin_unlock_irqrestore(&bcm->irq_lock, flags);