From owner-freebsd-current@FreeBSD.ORG Wed Nov 19 20:46:06 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C8C1AE79; Wed, 19 Nov 2014 20:46:06 +0000 (UTC) Received: from mail-yh0-x22d.google.com (mail-yh0-x22d.google.com [IPv6:2607:f8b0:4002:c01::22d]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 845F9114; Wed, 19 Nov 2014 20:46:06 +0000 (UTC) Received: by mail-yh0-f45.google.com with SMTP id f10so672612yha.18 for ; Wed, 19 Nov 2014 12:46:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=a/iAXKmlGTLh/JiiXwu+Z8r34jh/tVzuTgXRuw0en5U=; b=1EzRYx1bXNz709nZdLNwXO50StetdD35k6RDKrCL1BKpIu80TJrPGsuwg319SlMzK9 Zvq24PPt5qVkWl3p3kcVYoEY395JT+f8uAWABcBigT+ElInitFD5biEOh2N2KJgxXnzl oHYttjPc23P0C/Aed4sG3WwsQ6pUI1tgk55bdRdNKTRgvN1CeNI6AHmHd8XQCYXjstU2 kcvgiJlbQPru9ZBr8N0LWjWEPKuaekSaqVFfZQjfD7qCW193q1D8w7R1ZYDXEkDJfiIe ar82J8B0mg1CpqvCaRkRL82Zxt0QS60VAlMvfoduuVe+LCCyLA6JthXx+2cfMtQSl37A /9pg== MIME-Version: 1.0 X-Received: by 10.170.164.87 with SMTP id g84mr6511861ykd.10.1416429965730; Wed, 19 Nov 2014 12:46:05 -0800 (PST) Sender: kmacybsd@gmail.com Received: by 10.170.82.197 with HTTP; Wed, 19 Nov 2014 12:46:05 -0800 (PST) In-Reply-To: <546CE948.2070105@selasky.org> References: <546CE948.2070105@selasky.org> Date: Wed, 19 Nov 2014 12:46:05 -0800 X-Google-Sender-Auth: EHptYr0sw7MAE2hBzb5NKdY83Cs Message-ID: Subject: Re: [RFC] Removal of M_FLOWID flag from m_flags [WAS: Add support for hardware transmit rate limiting queues] From: "K. Macy" To: Hans Petter Selasky Content-Type: text/plain; charset=UTF-8 Cc: Lawrence Stewart , Adrian Chadd , FreeBSD Current , Luigi Rizzo , Navdeep Parhar 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 20:46:07 -0000 Hi Hans, It mostly looks fine, but it's a large change and there are some places in the patch where it isn't clear that the right thing is being done by looking at the patch alone. Please give us some time to review. Thanks. -K On Wed, Nov 19, 2014 at 11:02 AM, Hans Petter Selasky wrote: > Hi, > > 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. > > Background: > =========== > > 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. > > 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. > > > Patch is available from here: > ============================= > http://home.selasky.org:8192/m_flowid_removal.diff > > > Comments are appreciated! > > > --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"