.. | .. |
---|
23 | 23 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt |
---|
24 | 24 | |
---|
25 | 25 | #define DRV_NAME "3c589_cs" |
---|
26 | | -#define DRV_VERSION "1.162-ac" |
---|
27 | 26 | |
---|
28 | 27 | #include <linux/module.h> |
---|
29 | 28 | #include <linux/kernel.h> |
---|
.. | .. |
---|
173 | 172 | static struct net_device_stats *el3_get_stats(struct net_device *dev); |
---|
174 | 173 | static int el3_rx(struct net_device *dev); |
---|
175 | 174 | static int el3_close(struct net_device *dev); |
---|
176 | | -static void el3_tx_timeout(struct net_device *dev); |
---|
| 175 | +static void el3_tx_timeout(struct net_device *dev, unsigned int txqueue); |
---|
177 | 176 | static void set_rx_mode(struct net_device *dev); |
---|
178 | 177 | static void set_multicast_list(struct net_device *dev); |
---|
179 | 178 | static const struct ethtool_ops netdev_ethtool_ops; |
---|
.. | .. |
---|
196 | 195 | { |
---|
197 | 196 | struct el3_private *lp; |
---|
198 | 197 | struct net_device *dev; |
---|
| 198 | + int ret; |
---|
199 | 199 | |
---|
200 | 200 | dev_dbg(&link->dev, "3c589_attach()\n"); |
---|
201 | 201 | |
---|
.. | .. |
---|
219 | 219 | |
---|
220 | 220 | dev->ethtool_ops = &netdev_ethtool_ops; |
---|
221 | 221 | |
---|
222 | | - return tc589_config(link); |
---|
| 222 | + ret = tc589_config(link); |
---|
| 223 | + if (ret) |
---|
| 224 | + goto err_free_netdev; |
---|
| 225 | + |
---|
| 226 | + return 0; |
---|
| 227 | + |
---|
| 228 | +err_free_netdev: |
---|
| 229 | + free_netdev(dev); |
---|
| 230 | + return ret; |
---|
223 | 231 | } |
---|
224 | 232 | |
---|
225 | 233 | static void tc589_detach(struct pcmcia_device *link) |
---|
.. | .. |
---|
482 | 490 | struct ethtool_drvinfo *info) |
---|
483 | 491 | { |
---|
484 | 492 | strlcpy(info->driver, DRV_NAME, sizeof(info->driver)); |
---|
485 | | - strlcpy(info->version, DRV_VERSION, sizeof(info->version)); |
---|
486 | 493 | snprintf(info->bus_info, sizeof(info->bus_info), |
---|
487 | 494 | "PCMCIA 0x%lx", dev->base_addr); |
---|
488 | 495 | } |
---|
.. | .. |
---|
526 | 533 | return 0; |
---|
527 | 534 | } |
---|
528 | 535 | |
---|
529 | | -static void el3_tx_timeout(struct net_device *dev) |
---|
| 536 | +static void el3_tx_timeout(struct net_device *dev, unsigned int txqueue) |
---|
530 | 537 | { |
---|
531 | 538 | unsigned int ioaddr = dev->base_addr; |
---|
532 | 539 | |
---|