<div dir="ltr"><div dir="ltr">Hello Stephen,<br></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Mon, Feb 24, 2025 at 8:25 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"><br>
Please avoid doing assignment in a conditional statement, can be error prone.<br>
Surprised checkpatch doesn't complain about it.<br></blockquote><div><br></div><div>Thanks for the feedback. checkpatch did catch them.</div><div><br></div><div>Here is the new series, <a href="https://inbox.dpdk.org/dev/20250226200841.2342632-3-ariel.otilibili@6wind.com/">https://inbox.dpdk.org/dev/20250226200841.2342632-3-ariel.otilibili@6wind.com/</a></div><div><br></div><div>Regards,</div><div>Ariel<br> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Better as:<br>
desc = reserve_and_fill(txq, mbuf, umem);<br>
if (!desc) {<br>
kick_tx(txq, cq);<br>
desc = reserve_and_fill(txq, mbuf, umem);<br>
if (!desc)<br>
goto out;<br>
</blockquote></div></div>