From dced21add6ffb5e20594bb430fd65d4d60694d35 Mon Sep 17 00:00:00 2001 From: Simon Horman Date: Thu, 25 Sep 2014 11:57:53 +0000 Subject: [PATCH] ofproto-dpif-rid: remove unused return value of rid_pool_add() The return value of rid_pool_add() is never used so the code may be slightly simplified by removing it. Signed-off-by: Simon Horman Signed-off-by: Andy Zhou --- ofproto/ofproto-dpif-rid.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ofproto/ofproto-dpif-rid.c b/ofproto/ofproto-dpif-rid.c index 1326eae33..236de4d7f 100644 --- a/ofproto/ofproto-dpif-rid.c +++ b/ofproto/ofproto-dpif-rid.c @@ -47,7 +47,7 @@ static void rid_pool_uninit(struct rid_pool *pool); static uint32_t rid_pool_alloc_id(struct rid_pool *pool); static void rid_pool_free_id(struct rid_pool *rids, uint32_t rid); static struct rid_node *rid_pool_find(struct rid_pool *rids, uint32_t id); -static struct rid_node *rid_pool_add(struct rid_pool *rids, uint32_t id); +static void rid_pool_add(struct rid_pool *rids, uint32_t id); struct recirc_id_pool * recirc_id_pool_create(void) @@ -126,7 +126,7 @@ rid_pool_find(struct rid_pool *rids, uint32_t id) return NULL; } -static struct rid_node * +static void rid_pool_add(struct rid_pool *rids, uint32_t id) { struct rid_node *rid = xmalloc(sizeof *rid); @@ -135,7 +135,6 @@ rid_pool_add(struct rid_pool *rids, uint32_t id) rid->recirc_id = id; hash = hash_int(id, 0); hmap_insert(&rids->map, &rid->node, hash); - return rid; } static uint32_t -- 2.20.1