<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Wed, Jan 1, 2025 at 10:51 PM Stephen Hemminger <<a href="mailto:stephen@networkplumber.org">stephen@networkplumber.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Wed,  1 Jan 2025 15:07:35 +0530<br>
Kumara Parameshwaran <<a href="mailto:kumaraparamesh92@gmail.com" target="_blank">kumaraparamesh92@gmail.com</a>> wrote:<br>
<br>
> From: Kumara Parameshwaran <<a href="mailto:kumaraparamesh92@gmail.com" target="_blank">kumaraparamesh92@gmail.com</a>><br>
> To: <a href="mailto:hujiayu.hu@foxmail.com" target="_blank">hujiayu.hu@foxmail.com</a><br>
> Cc: <a href="mailto:dev@dpdk.org" target="_blank">dev@dpdk.org</a>,  Kumara Parameshwaran <<a href="mailto:kumaraparamesh92@gmail.com" target="_blank">kumaraparamesh92@gmail.com</a>><br>
> Subject: [PATCH] lib/gro: use hash function for flow lookup<br>
> Date: Wed,  1 Jan 2025 15:07:35 +0530<br>
> X-Mailer: git-send-email 2.47.1<br>
> <br>
> optimize the GRO lookup using hash based<br>
> implementation<br>
> <br>
> Signed-off-by: Kumara Parameshwaran <<a href="mailto:kumaraparamesh92@gmail.com" target="_blank">kumaraparamesh92@gmail.com</a>><br>
<br>
Rather than open coding a hash table with collision chains, please use the<br>
existing DPDK cuckoo hash which is faster and you can also prevent hash<br>
DoS chain attacks.<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><a href="http://dpdk.org/patch/158636">http://dpdk.org/patch/158636</a> <a class="gmail_plusreply" id="plusReplyChip-0" href="mailto:stephen@networkplumber.org" tabindex="-1">@Stephen Hemminger</a>  - Please find the link to the patch. This is sample implementation with test. Please let me know if it looks fine, would add more test cases. </blockquote>
<br>
Alternatively, use a better hash function such as siphash which is resistent<br>
to DoS attacks.<br>
</blockquote></div></div>