From: Mat Martineau <mathew.j.martineau at linux.intel.com>
To: mptcp at lists.01.org
Subject: [MPTCP] Re: [MPTCP][PATCH mptcp-next 4/5] mptcp: add the mibs for MP_PRIO
Date: Fri, 20 Nov 2020 17:19:52 -0800 [thread overview]
Message-ID: <2fa7b62a-fe25-4fa4-1ef3-d2838da9a5f2@linux.intel.com> (raw)
In-Reply-To: 7d895c955dbde5094f6bfc18b17779a75baa5861.1605855783.git.geliangtang@gmail.com
[-- Attachment #1: Type: text/plain, Size: 2403 bytes --]
On Fri, 20 Nov 2020, Geliang Tang wrote:
> This patch added the mibs for MP_PRIO, MPTCP_MIB_MPPRIOTX for transmitting
> of the MP_PRIO suboption, and MPTCP_MIB_MPPRIORX for receiving of it.
>
> Signed-off-by: Geliang Tang <geliangtang(a)gmail.com>
> ---
> net/mptcp/mib.c | 2 ++
> net/mptcp/mib.h | 2 ++
> net/mptcp/options.c | 1 +
> net/mptcp/pm_netlink.c | 1 +
> 4 files changed, 6 insertions(+)
>
> diff --git a/net/mptcp/mib.c b/net/mptcp/mib.c
> index 5e8f7827cfe0..49fb978aeb7e 100644
> --- a/net/mptcp/mib.c
> +++ b/net/mptcp/mib.c
> @@ -35,6 +35,8 @@ static const struct snmp_mib mptcp_snmp_list[] = {
> SNMP_MIB_ITEM("PortAckRx", MPTCP_MIB_PORTACKRX),
> SNMP_MIB_ITEM("RmAddr", MPTCP_MIB_RMADDR),
> SNMP_MIB_ITEM("RmSubflow", MPTCP_MIB_RMSUBFLOW),
> + SNMP_MIB_ITEM("MPPrioTx", MPTCP_MIB_MPPRIOTX),
Thanks for adding the Tx MIB. Patch looks good to me.
> + SNMP_MIB_ITEM("MPPrioRx", MPTCP_MIB_MPPRIORX),
> SNMP_MIB_SENTINEL
> };
>
> diff --git a/net/mptcp/mib.h b/net/mptcp/mib.h
> index b762941d492f..e023d8435d18 100644
> --- a/net/mptcp/mib.h
> +++ b/net/mptcp/mib.h
> @@ -28,6 +28,8 @@ enum linux_mptcp_mib_field {
> MPTCP_MIB_PORTACKRX, /* Received an ACK + MP_JOIN with port */
> MPTCP_MIB_RMADDR, /* Received RM_ADDR */
> MPTCP_MIB_RMSUBFLOW, /* Remove a subflow */
> + MPTCP_MIB_MPPRIOTX, /* Transmit a MP_PRIO */
> + MPTCP_MIB_MPPRIORX, /* Received a MP_PRIO */
> __MPTCP_MIB_MAX
> };
>
> diff --git a/net/mptcp/options.c b/net/mptcp/options.c
> index b1cb43c76be8..3171b620cab1 100644
> --- a/net/mptcp/options.c
> +++ b/net/mptcp/options.c
> @@ -1011,6 +1011,7 @@ void mptcp_incoming_options(struct sock *sk, struct sk_buff *skb)
>
> if (mp_opt.mp_prio) {
> mptcp_pm_mp_prio_received(sk, mp_opt.backup);
> + MPTCP_INC_STATS(sock_net(sk), MPTCP_MIB_MPPRIORX);
> mp_opt.mp_prio = 0;
> }
>
> diff --git a/net/mptcp/pm_netlink.c b/net/mptcp/pm_netlink.c
> index 58960e1cdc32..90943138da7e 100644
> --- a/net/mptcp/pm_netlink.c
> +++ b/net/mptcp/pm_netlink.c
> @@ -545,6 +545,7 @@ void mptcp_pm_nl_mp_prio_send_ack(struct mptcp_sock *msk,
>
> subflow->send_mp_prio = 1;
> subflow->request_bkup = bkup;
> + __MPTCP_INC_STATS(sock_net(sk), MPTCP_MIB_MPPRIOTX);
>
> spin_unlock_bh(&msk->pm.lock);
> pr_debug("send ack for mp_prio");
> --
> 2.26.2
--
Mat Martineau
Intel
reply other threads:[~2020-11-21 1:19 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=2fa7b62a-fe25-4fa4-1ef3-d2838da9a5f2@linux.intel.com \
--to=mptcp@lists.linux.dev \
/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