Adding Flow Director sysctls to ixgbe(4) (was: netmap: traffic distribution)

Takuya ASADA syuu at dokukino.com
Fri Oct 25 21:38:10 UTC 2013


2013/10/24 hiren panchasara <hiren.panchasara at gmail.com>

> On Mon, Oct 7, 2013 at 5:49 PM, hiren panchasara
> <hiren.panchasara at gmail.com> wrote:
> > On Mon, Oct 7, 2013 at 12:01 AM, Takuya ASADA <syuu at dokukino.com> wrote:
> >> Hi,
> >>
> >> This is updated version of "ixgbetool" patch.
> > I will try to give this a try tomorrow.
>
> Alright, sorry for the delay. I now have bandwidth/setup to test this.
> >
> > Cheers,
> > Hiren
> >> Here's improved feature list:
> >> - signature filter list feature available
> >> - user-defined filter can be use with an ATR.
>
> How does this work? You identify user-defined flows and apply ATR on
> the rest of the flows?
>

I made a hash table for user-defined filters, insert a filter entry into a
hash table when it added.
And when ixgbe driver try to change queue assignment by ATR, lookup a hash
table and prevent changing if the entry is on a hash table.

>> To enable it, add "hw.ixgbe.cooperative_atr=1" on /boot/loader.conf
> >>
> >> Usage is as follows:
> >> ixgbetool <ifname> [operation]
> >>     add_sig_filter <proto> <src_ip> <src_port> <dst_ip> <dst_port>
> >> <que_index>
> >>     show_sig_filter
> >>     del_sig_filter <id>
>
> I believe, I can somehow test whether the signature filter works or
> not by generating custom traffic, creating matching filter, directing
> the traffic to a specific queue and watch that queue.
>
> But how do I test/see ATR (application targeted receive) in action?
> Traffic for a specific application should follow the application on
> different cpus, right? Any guidance on how to do that would be great.
>

To do it specifically, we should add debug printf on ixgbe_rxeof, printout
hash value and queue number.
Actually, if test flow is only one, you can see which queue is processing
the flow by using "top -P".
If ATR is working properly, ixgbe will changes queue assign every few
moments (unless communicating process is pinned by cpuset command).
But I don't see such behavior when I using ATR, even my patch is not
applied.
I'm guessing ixgbe_atr() function is failing to detect current CPU of
communicating process.

Could be it required extra kernel parameter configuration to enable ATR,
but I haven't find any informations for it.


More information about the freebsd-net mailing list