xdp-project / xdp-tools

Utilities and example programs for use with XDP

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

is a formula error in comment of xsk_prod_nb_free

ZENOTME opened this issue · comments

formula in comment here seems inconsistent with the code.

* free_entries = r->cached_prod - r->cached_cons + r->size.

__u32 free_entries = r->cached_cons - r->cached_prod;

Is this formula should be free_entries = r->cached_cons - r->cached_prod + r->size?

You are correct. Thanks for spotting! Please submit a patch.