From: Nikolay Aleksandrov Date: Tue, 18 Aug 2015 17:28:01 +0000 (+0300) Subject: vrf: drop unnecessary dev refcnt changes X-Git-Tag: v4.14-rc1~4777^2~133^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=17d95f5ee2ba45a9771c97eb1037dfff1d51b064;p=platform%2Fkernel%2Flinux-rpi.git vrf: drop unnecessary dev refcnt changes netdev_master_upper_dev_link/unlink already do a dev_hold/put on the devices being linked, so no need to take another reference. Signed-off-by: Nikolay Aleksandrov Signed-off-by: David S. Miller --- diff --git a/drivers/net/vrf.c b/drivers/net/vrf.c index 95097cb..cd4bc77 100644 --- a/drivers/net/vrf.c +++ b/drivers/net/vrf.c @@ -334,14 +334,12 @@ static struct slave *__vrf_find_slave_dev(struct slave_queue *queue, /* inverse of __vrf_insert_slave */ static void __vrf_remove_slave(struct slave_queue *queue, struct slave *slave) { - dev_put(slave->dev); list_del(&slave->list); queue->num_slaves--; } static void __vrf_insert_slave(struct slave_queue *queue, struct slave *slave) { - dev_hold(slave->dev); list_add(&slave->list, &queue->all_slaves); queue->num_slaves++; }