Skip to content
Commit e05176a3 authored by Wenyu Zhang's avatar Wenyu Zhang Committed by David S. Miller
Browse files

openvswitch: Make 100 percents packets sampled when sampling rate is 1.



When sampling rate is 1, the sampling probability is UINT32_MAX. The packet
should be sampled even the prandom32() generate the number of UINT32_MAX.
And none packet need be sampled when the probability is 0.

Signed-off-by: default avatarWenyu Zhang <wenyuz@vmware.com>
Acked-by: default avatarPravin B Shelar <pshelar@nicira.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent da8b43c0
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment