From owner-svn-src-all@FreeBSD.ORG Tue May 5 06:46:00 2015 Return-Path: Delivered-To: svn-src-all@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 A758D755; Tue, 5 May 2015 06:46:00 +0000 (UTC) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.69.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "cell.glebius.int.ru", Issuer "cell.glebius.int.ru" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 32A7E125A; Tue, 5 May 2015 06:45:59 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.9/8.14.9) with ESMTP id t456juU7047165 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 5 May 2015 09:45:56 +0300 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.9/8.14.9/Submit) id t456juL0047164; Tue, 5 May 2015 09:45:56 +0300 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Tue, 5 May 2015 09:45:56 +0300 From: Gleb Smirnoff To: John Baldwin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r282280 - in head/sys/dev: e1000 ixgbe ixl Message-ID: <20150505064556.GM34544@FreeBSD.org> References: <201504301823.t3UINd74073186@svn.freebsd.org> <26088556.xbkUe5VAyp@ralph.baldwin.cx> <20150504185125.GL34544@FreeBSD.org> <2463555.FfYUgqxYi8@ralph.baldwin.cx> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2463555.FfYUgqxYi8@ralph.baldwin.cx> User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 May 2015 06:46:00 -0000 John, On Mon, May 04, 2015 at 04:01:28PM -0400, John Baldwin wrote: J> > Your answer seems quite orthogonal to my question. I reread it couple of times, J> > but still can't figure out how exactly do you prefet to fetch per-queue stats. J> > Can you please explain in more detail? J> J> struct if_queue { J> struct ifnet *ifq_parent; J> void (*ifq_get_counter)(struct if_queue *, ift_counter); J> ... J> }; J> J> (Pretend that if_queue is a new object type and that each RX or TX queue on a J> NIC has one.) This looks like a driver with 1024 queues would carry extra 1024 function pointers per ifnet. Is it really worth? Could it be that queue #0 differs from queue #1? Even, if a rare case when queue #N differs from queue #M do exist, they still can share the pointer and the differentiating logic would be in the function itself. Right now, in the projects/ifnet branch, I'm developing in quite opposite direction - many instances of the same driver share the set of interface options. This is done to shrink struct ifnet. What's wrong with KPI when the queue number is parameter to an ifop? This KPI would also hide the queue pointers from the stack, which are quite driver specific. -- Totus tuus, Glebius.