From owner-freebsd-hackers@FreeBSD.ORG Sun Nov 16 15:09:01 2008 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 753D31065678 for ; Sun, 16 Nov 2008 15:09:01 +0000 (UTC) (envelope-from max@love2party.net) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) by mx1.freebsd.org (Postfix) with ESMTP id 096A08FC1F for ; Sun, 16 Nov 2008 15:09:00 +0000 (UTC) (envelope-from max@love2party.net) Received: from vampire.homelinux.org (dslb-088-066-022-110.pools.arcor-ip.net [88.66.22.110]) by mrelayeu.kundenserver.de (node=mrelayeu7) with ESMTP (Nemesis) id 0ML2xA-1L1jFA31JY-0003zw; Sun, 16 Nov 2008 16:08:59 +0100 Received: (qmail 60970 invoked from network); 16 Nov 2008 15:08:52 -0000 Received: from fbsd8.laiers.local (192.168.4.151) by laiers.local with SMTP; 16 Nov 2008 15:08:52 -0000 From: Max Laier Organization: FreeBSD To: freebsd-hackers@freebsd.org Date: Sun, 16 Nov 2008 16:08:51 +0100 User-Agent: KMail/1.10.1 (FreeBSD/8.0-CURRENT; KDE/4.1.1; i386; ; ) References: <20def4870811160610l5289267erfd7abafb9916b706@mail.gmail.com> In-Reply-To: <20def4870811160610l5289267erfd7abafb9916b706@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200811161608.51813.max@love2party.net> X-Provags-ID: V01U2FsdGVkX18dplM7+4N2nIgrA6+cRPcj7LHF9bKZS+4Vph6 1NKuDS3jqtmedQJ7aScFpJDAmrM2Y9fTEzq4zccInUswDxOUnk 1oqlOifZ+i/xMg5dRs7Pw== Cc: Yehonatan Yossef , Yony Yossef Subject: Re: VLAN offloads on FreeBSD 6.3 & 7.0 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Nov 2008 15:09:01 -0000 On Sunday 16 November 2008 15:10:19 Yony Yossef wrote: > Hi All, > > I'm working on an Ethernet driver for FreeBSD, currently implementing > VLAN offloads. > I have two problems, one is enabling TSO over the VLAN interface and > the second is enabling the VLAN filtering offload. > > About the TSO problem, I'm currently suffering a hugh performance > penalty since I have no TSO enabled over my vlan interfaces. > When I create a VLAN interface it does not inherit the features of > it's mother-interface, e.g. IFCAP_TSO. > Can it be done on FreeBSD 6.3 / 7.0 ? > > Second, my NIC is capable of holding a vlan table on HW, filtering > vlans on it's own, now I need to find a way to update that HW table > with added/deleted VLANs in order to use that VLAN filtering offload. > One way is to recieve a ioctl from the OS of it's vlan table events > (add, remove). I can't find such ioctl. > > Second way is to have direct access from the driver to the OS vlan > table. I'm not familiar with the interface though (something parallel > to vlan_group_get_device on linux) or if it's possible at all, can > anyone help on this one? See http://svn.freebsd.org/viewvc/base?view=revision&revision=180510 for the VLAN tag issue. Simply EVENTHANDLER_REGISTER a function in your driver to update the hw-table on config/unconfig events. I hope this helps. -- /"\ Best regards, | mlaier@freebsd.org \ / Max Laier | ICQ #67774661 X http://pf4freebsd.love2party.net/ | mlaier@EFnet / \ ASCII Ribbon Campaign | Against HTML Mail and News