On Thu, Mar 03, 2016 at 09:28:27AM -0500, Jamal Hadi Salim wrote: > Phil, there is one thing i noticed in your patch - dont think > it is a big deal but you are doing htons on an int > (instead of u16).
Indeed, I totally overlooked that. Does not look like there's an easy fix though, as all tc_pedit_key fields are u32. OTOH htons() will cast to u16 first, therefore cutting off any higher bits. Looks like the code does the right thing anyway, and the test results fortify that. Do you see a cleaner way to implement this? Otherwise I would vote for leaving it as a little surprise to future readers. ;) Cheers, Phil