Commit Graph

11 Commits

Author SHA1 Message Date
Kevin Lo
4a1988af0e Closing file descriptors when it's done
Reviewed by:	np
2010-12-08 01:35:19 +00:00
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
Navdeep Parhar
5310975100 Allow cxgbtool to build with WARNS=6
MFC after:	1 week
2010-02-23 23:01:41 +00:00
Ulrich Spörlein
54673381cd Add missing newline in last line of file.
Uncovered via:	fromcvs vs. svn
Approved by:	ed (co-mentor)
2010-02-16 09:10:21 +00:00
Navdeep Parhar
bc62d44240 This adds a new "stdio" mode to cxgbtool - it's an interactive mode
meant primarily for _non_ interactive use.  Scripts that run cxgbtool
repeatedly to perform register r/w or mdio will benefit from this.
Instead of fork/exec'ing a new cxgbtool for every regio/mdio you can
simply open a pair of pipes to/from cxgbtool and run cmds over them.

Approved by:	gnn (mentor)
2009-06-24 22:28:48 +00:00
George V. Neville-Neil
f2d8ff04fe Update the Chelsio driver to the latest bits from Chelsio
Firmware upgraded to 7.1.0 (from 5.0.0).
T3C EEPROM and SRAM added; Code to update eeprom/sram fixed.
fl_empty and rx_fifo_ovfl counters can be observed via sysctl.
Two new cxgbtool commands to get uP logic analyzer info and uP IOQs
Synced up with Chelsio's "common code" (as of 03/03/09)

Submitted by:	 Navdeep Parhar at Chelsio
Reviewed by:	gnn
MFC after:	2 weeks
2009-03-10 19:22:45 +00:00
Kip Macy
bc452c1162 - Fix regression with GETMEM
- Remove gratuitous bswap macros
- check for rev 3 with t3b

Obtained from:	Chelsio Inc.
MFC after:	3 days
2008-09-10 01:10:17 +00:00
Kip Macy
f90e41acf3 Add support for t3c to cxgbtool
Obtained from:	Chelsio Inc.
2008-09-02 22:20:46 +00:00
Kip Macy
4c9839c44e Bring cxgbtool up to date with version 1.5
Obtained from:	Chelsio Inc.
MFC after:	3 days
2008-09-01 07:50:04 +00:00
Kip Macy
e35180e8ed fix include names 2007-03-15 04:09:40 +00:00
Kip Macy
e0499fbd1a Add administration and debugging tool for Chelsio T3 10 Gigabit Ethernet driver 2007-03-14 02:51:57 +00:00