diff options
Diffstat (limited to 'net/core/netpoll.c')
| -rw-r--r-- | net/core/netpoll.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/net/core/netpoll.c b/net/core/netpoll.c index 2d7d6d473781..adf84dd8c7b5 100644 --- a/net/core/netpoll.c +++ b/net/core/netpoll.c | |||
| @@ -177,7 +177,7 @@ static void service_arp_queue(struct netpoll_info *npi) | |||
| 177 | } | 177 | } |
| 178 | } | 178 | } |
| 179 | 179 | ||
| 180 | void netpoll_poll_dev(struct net_device *dev) | 180 | static void netpoll_poll_dev(struct net_device *dev) |
| 181 | { | 181 | { |
| 182 | const struct net_device_ops *ops; | 182 | const struct net_device_ops *ops; |
| 183 | 183 | ||
| @@ -208,13 +208,6 @@ void netpoll_poll_dev(struct net_device *dev) | |||
| 208 | 208 | ||
| 209 | zap_completion_queue(); | 209 | zap_completion_queue(); |
| 210 | } | 210 | } |
| 211 | EXPORT_SYMBOL(netpoll_poll_dev); | ||
| 212 | |||
| 213 | void netpoll_poll(struct netpoll *np) | ||
| 214 | { | ||
| 215 | netpoll_poll_dev(np->dev); | ||
| 216 | } | ||
| 217 | EXPORT_SYMBOL(netpoll_poll); | ||
| 218 | 211 | ||
| 219 | static void refill_skbs(void) | 212 | static void refill_skbs(void) |
| 220 | { | 213 | { |
| @@ -275,7 +268,7 @@ repeat: | |||
| 275 | 268 | ||
| 276 | if (!skb) { | 269 | if (!skb) { |
| 277 | if (++count < 10) { | 270 | if (++count < 10) { |
| 278 | netpoll_poll(np); | 271 | netpoll_poll_dev(np->dev); |
| 279 | goto repeat; | 272 | goto repeat; |
| 280 | } | 273 | } |
| 281 | return NULL; | 274 | return NULL; |
| @@ -336,7 +329,7 @@ void netpoll_send_skb_on_dev(struct netpoll *np, struct sk_buff *skb, | |||
| 336 | } | 329 | } |
| 337 | 330 | ||
| 338 | /* tickle device maybe there is some cleanup */ | 331 | /* tickle device maybe there is some cleanup */ |
| 339 | netpoll_poll(np); | 332 | netpoll_poll_dev(np->dev); |
| 340 | 333 | ||
| 341 | udelay(USEC_PER_POLL); | 334 | udelay(USEC_PER_POLL); |
| 342 | } | 335 | } |
| @@ -792,6 +785,13 @@ int netpoll_setup(struct netpoll *np) | |||
| 792 | return -ENODEV; | 785 | return -ENODEV; |
| 793 | } | 786 | } |
| 794 | 787 | ||
| 788 | if (ndev->master) { | ||
| 789 | printk(KERN_ERR "%s: %s is a slave device, aborting.\n", | ||
| 790 | np->name, np->dev_name); | ||
| 791 | err = -EBUSY; | ||
| 792 | goto put; | ||
| 793 | } | ||
| 794 | |||
| 795 | if (!netif_running(ndev)) { | 795 | if (!netif_running(ndev)) { |
| 796 | unsigned long atmost, atleast; | 796 | unsigned long atmost, atleast; |
| 797 | 797 | ||
