Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: drivers/net/wireless/iwmc3200wifi/netdev.c net/wireless/scan.c
This commit is contained in:
@@ -346,7 +346,7 @@ void can_restart(unsigned long data)
|
||||
skb = dev_alloc_skb(sizeof(struct can_frame));
|
||||
if (skb == NULL) {
|
||||
err = -ENOMEM;
|
||||
goto out;
|
||||
goto restart;
|
||||
}
|
||||
skb->dev = dev;
|
||||
skb->protocol = htons(ETH_P_CAN);
|
||||
@@ -361,13 +361,13 @@ void can_restart(unsigned long data)
|
||||
stats->rx_packets++;
|
||||
stats->rx_bytes += cf->can_dlc;
|
||||
|
||||
restart:
|
||||
dev_dbg(dev->dev.parent, "restarted\n");
|
||||
priv->can_stats.restarts++;
|
||||
|
||||
/* Now restart the device */
|
||||
err = priv->do_set_mode(dev, CAN_MODE_START);
|
||||
|
||||
out:
|
||||
netif_carrier_on(dev);
|
||||
if (err)
|
||||
dev_err(dev->dev.parent, "Error %d during restart", err);
|
||||
@@ -473,6 +473,10 @@ int open_candev(struct net_device *dev)
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
/* Switch carrier on if device was stopped while in bus-off state */
|
||||
if (!netif_carrier_ok(dev))
|
||||
netif_carrier_on(dev);
|
||||
|
||||
setup_timer(&priv->restart_timer, can_restart, (unsigned long)dev);
|
||||
|
||||
return 0;
|
||||
|
@@ -63,7 +63,6 @@
|
||||
#include <linux/can.h>
|
||||
#include <linux/can/dev.h>
|
||||
#include <linux/can/error.h>
|
||||
#include <linux/can/dev.h>
|
||||
|
||||
#include "sja1000.h"
|
||||
|
||||
|
Reference in New Issue
Block a user