]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net/smc: introduce statistics for ringbufs usage of net namespace
authorWen Gu <guwen@linux.alibaba.com>
Wed, 14 Aug 2024 13:08:27 +0000 (21:08 +0800)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 20 Aug 2024 09:38:23 +0000 (11:38 +0200)
commite0d103542b06c36240e3887edfe49578464866eb
tree5797d50e999e52c9eb2cac75375b4aefa4bd2d5d
parentd386d59b7c1a39112ca875327339ed519df2b96c
net/smc: introduce statistics for ringbufs usage of net namespace

The buffer size histograms in smc_stats, namely rx/tx_rmbsize, record
the sizes of ringbufs for all connections that have ever appeared in
the net namespace. They are incremental and we cannot know the actual
ringbufs usage from these. So here introduces statistics for current
ringbufs usage of existing smc connections in the net namespace into
smc_stats, it will be incremented when new connection uses a ringbuf
and decremented when the ringbuf is unused.

Signed-off-by: Wen Gu <guwen@linux.alibaba.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
include/uapi/linux/smc.h
net/smc/smc_core.c
net/smc/smc_stats.c
net/smc/smc_stats.h