summaryrefslogtreecommitdiff
path: root/drivers/ipoe/ipoe.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ipoe/ipoe.c')
-rw-r--r--drivers/ipoe/ipoe.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/ipoe/ipoe.c b/drivers/ipoe/ipoe.c
index 4951c536..f3acb3f5 100644
--- a/drivers/ipoe/ipoe.c
+++ b/drivers/ipoe/ipoe.c
@@ -784,13 +784,12 @@ static struct ipoe_session *ipoe_lookup_rt6(struct sk_buff *skb, const struct in
if (!dst)
return NULL;
+ *dev = dst->dev;
+
if (dst->error || dst->dev->netdev_ops != &ipoe_netdev_ops) {
dst_release(dst);
return NULL;
}
-
- *dev = dst->dev;
-
ses = netdev_priv(*dev);
atomic_inc(&ses->refs);