From owner-freebsd-current@FreeBSD.ORG Wed Nov 19 19:30:27 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id BDCCC918; Wed, 19 Nov 2014 19:30:27 +0000 (UTC) Received: from mail-n.franken.de (drew.ipv6.franken.de [IPv6:2001:638:a02:a001:20e:cff:fe4a:feaa]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mail-n.franken.de", Issuer "Thawte DV SSL CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7F3AF842; Wed, 19 Nov 2014 19:30:27 +0000 (UTC) Received: from [192.168.1.200] (p508F059E.dip0.t-ipconnect.de [80.143.5.158]) (Authenticated sender: macmic) by mail-n.franken.de (Postfix) with ESMTP id 42B3D1C104FC7; Wed, 19 Nov 2014 20:30:24 +0100 (CET) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: [RFC] Removal of M_FLOWID flag from m_flags [WAS: Add support for hardware transmit rate limiting queues] From: Michael Tuexen In-Reply-To: <546CE948.2070105@selasky.org> Date: Wed, 19 Nov 2014 20:30:21 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: References: <546CE948.2070105@selasky.org> To: Hans Petter Selasky X-Mailer: Apple Mail (2.1878.6) Cc: Lawrence Stewart , Adrian Chadd , FreeBSD Current , Luigi Rizzo , np@freebsd.org X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Nov 2014 19:30:27 -0000 On 19 Nov 2014, at 20:02, Hans Petter Selasky wrote: > Hi, >=20 > The M_FLOWID flag is marked as deprecated in the FreeBSD kernel code = and the patch below completely removes it. I suggest we will now be = using the "m_pkthdr.rsstype" also known as "M_HASHTYPE" to decide if the = flowid value is valid or not. When the "rsstype" is set to = "M_HASHTYPE_NONE" the "m_pkthdr.flowid" field is not valid. Else this = field contains valid data for both TX and RX direction. >=20 > Background: > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >=20 > The network drivers today use the "rsstype" field only when receiving = traffic. After my patch it is also used when sending traffic, and = probably we should rename it. >=20 > The reason for using the rsstype field for transmit, is to avoid = introducing another field in the MBUF's packet header in order to steer = outgoing traffic into special multiple purpose hardware FIFOs. This new = feature should coexist with the existing flowid mechanism, and this is = achieved by introducing a new hash type which I've named = "M_HASHTYPE_HWRING" in my patch. This type can be selected by upper = layers when generating traffic for lower layers, to indicate that the = traffic is of a special kind and should have special treatment by the = hardware, like rate-limiting. Hardware which doesn't support = M_HASHTYPE_HWRING will send out the packets like usual. >=20 >=20 > Patch is available from here: > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D > http://home.selasky.org:8192/m_flowid_removal.diff >=20 >=20 > Comments are appreciated! Before finally committing this, drop me a note. All the SCTP changes = need to be ported upstream. Depending on the time and if it is OK for you, I would try to integrate = this upstream and push it down to FreeBSD. Then you can commit the rest. This is simpler for me = than reintegrating your changes upstream... Best regards Michael >=20 >=20 > --HPS > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to = "freebsd-current-unsubscribe@freebsd.org" >=20