From: David Miller <davem@davemloft.net>
To: xiyou.wangcong@gmail.com
Cc: xiangxia.m.yue@gmail.com, netdev@vger.kernel.org
Subject: Re: [PATCH v7 2/3] sock: Move the socket inuse to namespace.
Date: Mon, 18 Dec 2017 22:22:11 -0500 (EST) [thread overview]
Message-ID: <20171218.222211.1453774388722002269.davem@davemloft.net> (raw)
In-Reply-To: <CAM_iQpXhuQ03LB+DsVU4z=m5BCOWKTP1j1oUnBX7-rWC=z_oSA@mail.gmail.com>
From: Cong Wang <xiyou.wangcong@gmail.com>
Date: Mon, 18 Dec 2017 13:38:39 -0800
> On Mon, Dec 18, 2017 at 11:30 AM, David Miller <davem@davemloft.net> wrote:
>> From: Tonghao Zhang <xiangxia.m.yue@gmail.com>
>> Date: Thu, 14 Dec 2017 05:51:58 -0800
>>
>>> In some case, we want to know how many sockets are in use in
>>> different _net_ namespaces. It's a key resource metric.
>>
>> Useful or not, you're not exporting this value.
>>
>> All this patch series does is convert the existing export of the
>> global tally to add up the per-net values.
>>
>> So if you're not exporting the per-net value on it's own in any way,
>> this patch series isn't achieving the stated goal.
>>
>> I'm not applying this series, sorry.
>
>
> This value is already exported via procfs:
> sockstat_seq_show() -> socket_seq_show().
>
> And the proc file itself should already be per-net:
>
> static int sockstat_seq_open(struct inode *inode, struct file *file)
> {
> return single_open_net(inode, file, sockstat_seq_show);
> }
>
>
> This patch just makes that value to be per-net too.
You're right, my bad.
I'll keep reviewing this.
next prev parent reply other threads:[~2017-12-19 3:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-14 13:51 [PATCH v7 1/3] sock: Change the netns_core member name Tonghao Zhang
2017-12-14 13:51 ` [PATCH v7 2/3] sock: Move the socket inuse to namespace Tonghao Zhang
2017-12-18 19:30 ` David Miller
2017-12-18 21:38 ` Cong Wang
2017-12-19 3:22 ` David Miller [this message]
2017-12-19 15:19 ` David Miller
2017-12-14 13:51 ` [PATCH v7 3/3] sock: Hide unused variable when !CONFIG_PROC_FS Tonghao Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20171218.222211.1453774388722002269.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=xiangxia.m.yue@gmail.com \
--cc=xiyou.wangcong@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox