Commit 0e0b46d8 authored by Frank Blaschka's avatar Frank Blaschka Committed by David S. Miller

lcs: convert to net_device_ops

lcs convert to net_device_ops.
Signed-off-by: default avatarFrank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ba270ede
...@@ -2097,6 +2097,20 @@ lcs_register_netdev(struct ccwgroup_device *ccwgdev) ...@@ -2097,6 +2097,20 @@ lcs_register_netdev(struct ccwgroup_device *ccwgdev)
/** /**
* lcs_new_device will be called by setting the group device online. * lcs_new_device will be called by setting the group device online.
*/ */
static const struct net_device_ops lcs_netdev_ops = {
.ndo_open = lcs_open_device,
.ndo_stop = lcs_stop_device,
.ndo_get_stats = lcs_getstats,
.ndo_start_xmit = lcs_start_xmit,
};
static const struct net_device_ops lcs_mc_netdev_ops = {
.ndo_open = lcs_open_device,
.ndo_stop = lcs_stop_device,
.ndo_get_stats = lcs_getstats,
.ndo_start_xmit = lcs_start_xmit,
.ndo_set_multicast_list = lcs_set_multicast_list,
};
static int static int
lcs_new_device(struct ccwgroup_device *ccwgdev) lcs_new_device(struct ccwgroup_device *ccwgdev)
...@@ -2164,14 +2178,11 @@ lcs_new_device(struct ccwgroup_device *ccwgdev) ...@@ -2164,14 +2178,11 @@ lcs_new_device(struct ccwgroup_device *ccwgdev)
goto out; goto out;
card->dev = dev; card->dev = dev;
card->dev->ml_priv = card; card->dev->ml_priv = card;
card->dev->open = lcs_open_device; card->dev->netdev_ops = &lcs_netdev_ops;
card->dev->stop = lcs_stop_device;
card->dev->hard_start_xmit = lcs_start_xmit;
card->dev->get_stats = lcs_getstats;
memcpy(card->dev->dev_addr, card->mac, LCS_MAC_LENGTH); memcpy(card->dev->dev_addr, card->mac, LCS_MAC_LENGTH);
#ifdef CONFIG_IP_MULTICAST #ifdef CONFIG_IP_MULTICAST
if (!lcs_check_multicast_support(card)) if (!lcs_check_multicast_support(card))
card->dev->set_multicast_list = lcs_set_multicast_list; card->dev->netdev_ops = &lcs_mc_netdev_ops;
#endif #endif
netdev_out: netdev_out:
lcs_set_allowed_threads(card,0xffffffff); lcs_set_allowed_threads(card,0xffffffff);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment