X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=ofproto%2Fofproto-dpif-mirror.c;h=99172dd55a39722ff397148d8cd858df1b74f25b;hb=4b6ab2b0ae49194e4ff78cc005921286aa9be140;hp=0819b726ea6af8b736a0a75bd2aaf58a1e80547d;hpb=d893c3e0afe2e337d4399bbea20970de1a06cf6b;p=sliver-openvswitch.git diff --git a/ofproto/ofproto-dpif-mirror.c b/ofproto/ofproto-dpif-mirror.c index 0819b726e..99172dd55 100644 --- a/ofproto/ofproto-dpif-mirror.c +++ b/ofproto/ofproto-dpif-mirror.c @@ -75,7 +75,6 @@ static void mbundle_lookup_multiple(const struct mbridge *, struct ofbundle **, size_t n_bundles, struct hmapx *mbundles); static int mirror_scan(struct mbridge *); static void mirror_update_dups(struct mbridge *); -static int mirror_mask_ffs(mirror_mask_t); struct mbridge * mbridge_create(void) @@ -363,7 +362,7 @@ mirror_update_stats(struct mbridge *mbridge, mirror_mask_t mirrors, for (; mirrors; mirrors = zero_rightmost_1bit(mirrors)) { struct mirror *m; - m = mbridge->mirrors[mirror_mask_ffs(mirrors) - 1]; + m = mbridge->mirrors[raw_ctz(mirrors)]; if (!m) { /* In normal circumstances 'm' will not be NULL. However,