From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f194.google.com ([209.85.192.194]:36360 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965813AbeCAE2S (ORCPT ); Wed, 28 Feb 2018 23:28:18 -0500 Received: by mail-pf0-f194.google.com with SMTP id 68so1972848pfx.3 for ; Wed, 28 Feb 2018 20:28:18 -0800 (PST) Message-ID: <1519878495.11536.4.camel@gmail.com> Subject: Re: [PATCH] inet: add bound ports statistic From: Eric Dumazet To: David Miller Cc: stephen@networkplumber.org, netdev@vger.kernel.org, sthemmin@microsoft.com Date: Wed, 28 Feb 2018 20:28:15 -0800 In-Reply-To: <20180228.223217.1178910703084049513.davem@davemloft.net> References: <20180301020101.3975-1-sthemmin@microsoft.com> <1519871282.11536.2.camel@gmail.com> <20180228.223217.1178910703084049513.davem@davemloft.net> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: netdev-owner@vger.kernel.org List-ID: On Wed, 2018-02-28 at 22:32 -0500, David Miller wrote: > From: Eric Dumazet > Date: Wed, 28 Feb 2018 18:28:02 -0800 > > > How useful it is to report this information ? > > > > Given REUSEADDR and REUSEPORT, I really wonder what can be derived from > > this counter. > > > > It seems its semantic is weak. > > To me none of this really matters. > > What matters is that iproute2 reported this via slabinfo for longer > than a decade. > > It broke recently when SLAB started merging caches just like SLUB > always did. Linus himself removed some info that was much more useful in commit a5ad88ce8c7fae7d ("mm: get rid of 'vmalloc_info' from /proc/meminfo") # egrep "VmallocUsed|VmallocChunk" /proc/meminfo VmallocUsed:           0 kB VmallocChunk:          0 kB So I vote for not re-adding another loop in the kernel with no preemption point. Simply taking spinlocks like Stephen did is going to slow down the other threads, lets face it. This implementation has a high cost, and provides something that made no sense in the first place.