Navdeep Parhar d6da836201 Add support for hardware filters to cxgb(4). The T3 chip can inspect
L2/3/4 headers and can drop or steer packets as instructed.  Filtering
based on src ip, dst ip, src port, dst port, 802.1q, udp/tcp, and mac
addr is possible.  Add support in cxgbtool to program these filters.
Some simple examples:

Drop all tcp/80 traffic coming from the subnet specified.
# cxgbtool cxgb2 filter 0 sip 192.168.1.0/24 dport 80 type tcp action drop

Steer all incoming UDP traffic to qset 0.
# cxgbtool cxgb2 filter 1 type udp queue 0 action pass

Steer all tcp traffic from 192.168.1.1 to qset 1.
# cxgbtool cxgb2 filter 2 sip 192.168.1.1 type tcp queue 1 action pass

Drop fragments.
# cxgbtool cxgb2 filter 3 type frag action drop

List all filters.
# cxgbtool cxgb2 filter list
index         SIP                DIP     sport dport VLAN PRI P/MAC type Q
    0     192.168.1.0/24         0.0.0.0     *    80    0 0/1 */*    tcp -
    1         0.0.0.0/0          0.0.0.0     *     *    0 0/1 */*    udp 0
    2     192.168.1.1/32         0.0.0.0     *     *    0 0/1 */*    tcp 1
    3         0.0.0.0/0          0.0.0.0     *     *    0 0/1 */*   frag -
16367         0.0.0.0/0          0.0.0.0     *     *    0 0/1 */*      * *

MFC after:	2 weeks
2010-05-05 00:41:40 +00:00
..
2010-04-28 22:25:27 +00:00
2009-05-13 22:31:25 +00:00
2009-09-14 21:33:00 +00:00
2010-01-28 08:41:30 +00:00
2010-04-30 08:37:00 +00:00
2010-04-30 02:35:46 +00:00
2010-01-03 23:28:32 +00:00
2010-04-27 15:50:25 +00:00
2010-01-03 23:26:29 +00:00
2009-12-16 12:25:27 +00:00
2010-01-24 10:50:20 +00:00
2010-01-08 20:40:28 +00:00
2010-01-08 15:57:56 +00:00
2010-02-17 17:03:04 +00:00
2010-01-01 22:47:53 +00:00
2010-01-28 08:41:30 +00:00
2010-04-15 14:26:52 +00:00
2010-01-03 23:31:58 +00:00
2010-03-11 15:25:47 +00:00
2009-09-06 10:27:45 +00:00
2009-05-25 22:50:11 +00:00
2009-08-23 08:04:40 +00:00
2010-01-28 08:41:30 +00:00
2010-01-28 08:41:30 +00:00
2009-12-25 00:23:47 +00:00
2010-01-03 23:29:49 +00:00