summaryrefslogtreecommitdiff
path: root/ofproto/pinsched.c
diff options
context:
space:
mode:
authorEthan Jackson <ethan@nicira.com>2013-06-22 10:33:27 -0700
committerEthan Jackson <ethan@nicira.com>2013-06-24 14:15:50 -0700
commitf9c0c3eccdb8e14dc8fbf572e515dbef1eb7b2ee (patch)
tree620c68eed5586228e8aea554e812d3152ad39fe8 /ofproto/pinsched.c
parent7894e7daad4bc780dc3386bf2c28cafdc0692016 (diff)
downloadopenvswitch-f9c0c3eccdb8e14dc8fbf572e515dbef1eb7b2ee.tar.gz
flow: New function hash_ofp_port() and hash_ofp_port().
These functions are used so often, that having an easy to read helper is worth it. Signed-off-by: Ethan Jackson <ethan@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'ofproto/pinsched.c')
-rw-r--r--ofproto/pinsched.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ofproto/pinsched.c b/ofproto/pinsched.c
index 4c5f3e836..91e9c411c 100644
--- a/ofproto/pinsched.c
+++ b/ofproto/pinsched.c
@@ -104,7 +104,7 @@ pinqueue_destroy(struct pinsched *ps, struct pinqueue *q)
static struct pinqueue *
pinqueue_get(struct pinsched *ps, ofp_port_t port_no)
{
- uint32_t hash = hash_int(ofp_to_u16(port_no), 0);
+ uint32_t hash = hash_ofp_port(port_no);
struct pinqueue *q;
HMAP_FOR_EACH_IN_BUCKET (q, node, hash, &ps->queues) {