aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/iseries_veth.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/iseries_veth.c')
-rw-r--r--drivers/net/iseries_veth.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/net/iseries_veth.c b/drivers/net/iseries_veth.c
index c46864d626b..c7457f97259 100644
--- a/drivers/net/iseries_veth.c
+++ b/drivers/net/iseries_veth.c
@@ -952,7 +952,7 @@ static int veth_change_mtu(struct net_device *dev, int new_mtu)
static void veth_set_multicast_list(struct net_device *dev)
{
- struct veth_port *port = (struct veth_port *) dev->priv;
+ struct veth_port *port = netdev_priv(dev);
unsigned long flags;
write_lock_irqsave(&port->mcast_gate, flags);
@@ -1044,7 +1044,7 @@ static struct net_device *veth_probe_one(int vlan,
return NULL;
}
- port = (struct veth_port *) dev->priv;
+ port = netdev_priv(dev);
spin_lock_init(&port->queue_lock);
rwlock_init(&port->mcast_gate);
@@ -1102,7 +1102,7 @@ static int veth_transmit_to_one(struct sk_buff *skb, HvLpIndex rlp,
struct net_device *dev)
{
struct veth_lpar_connection *cnx = veth_cnx[rlp];
- struct veth_port *port = (struct veth_port *) dev->priv;
+ struct veth_port *port = netdev_priv(dev);
HvLpEvent_Rc rc;
struct veth_msg *msg = NULL;
unsigned long flags;
@@ -1191,7 +1191,7 @@ static void veth_transmit_to_many(struct sk_buff *skb,
static int veth_start_xmit(struct sk_buff *skb, struct net_device *dev)
{
unsigned char *frame = skb->data;
- struct veth_port *port = (struct veth_port *) dev->priv;
+ struct veth_port *port = netdev_priv(dev);
HvLpIndexMap lpmask;
if (! (frame[0] & 0x01)) {
@@ -1255,7 +1255,7 @@ static void veth_wake_queues(struct veth_lpar_connection *cnx)
if (! dev)
continue;
- port = (struct veth_port *)dev->priv;
+ port = netdev_priv(dev);
if (! (port->lpar_map & (1<<cnx->remote_lp)))
continue;
@@ -1284,7 +1284,7 @@ static void veth_stop_queues(struct veth_lpar_connection *cnx)
if (! dev)
continue;
- port = (struct veth_port *)dev->priv;
+ port = netdev_priv(dev);
/* If this cnx is not on the vlan for this port, continue */
if (! (port->lpar_map & (1 << cnx->remote_lp)))
@@ -1506,7 +1506,7 @@ static void veth_receive(struct veth_lpar_connection *cnx,
continue;
}
- port = (struct veth_port *)dev->priv;
+ port = netdev_priv(dev);
dest = *((u64 *) skb->data) & 0xFFFFFFFFFFFF0000;
if ((vlan > HVMAXARCHITECTEDVIRTUALLANS) || !port) {