Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 135392
b: refs/heads/master
c: 2b023f4
h: refs/heads/master
v: v3
  • Loading branch information
Stephen Hemminger authored and David S. Miller committed Mar 22, 2009
1 parent 6a37b09 commit 5516eaf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0bd11f27ed3b3c04b1a753b6c8bdc79ffc1b8cef
refs/heads/master: 2b023f46cbc6187f6ee88e778ed798745b5b2bfe
11 changes: 7 additions & 4 deletions trunk/drivers/net/irda/sir_dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -865,6 +865,12 @@ static int sirdev_close(struct net_device *ndev)
return 0;
}

static const struct net_device_ops sirdev_ops = {
.ndo_start_xmit = sirdev_hard_xmit,
.ndo_open = sirdev_open,
.ndo_stop = sirdev_close,
.ndo_do_ioctl = sirdev_ioctl,
};
/* ----------------------------------------------------------------------------- */

struct sir_dev * sirdev_get_instance(const struct sir_driver *drv, const char *name)
Expand Down Expand Up @@ -908,10 +914,7 @@ struct sir_dev * sirdev_get_instance(const struct sir_driver *drv, const char *n
dev->netdev = ndev;

/* Override the network functions we need to use */
ndev->hard_start_xmit = sirdev_hard_xmit;
ndev->open = sirdev_open;
ndev->stop = sirdev_close;
ndev->do_ioctl = sirdev_ioctl;
ndev->netdev_ops = &sirdev_ops;

if (register_netdev(ndev)) {
IRDA_ERROR("%s(), register_netdev() failed!\n", __func__);
Expand Down

0 comments on commit 5516eaf

Please sign in to comment.