All of lore.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Geliang Tang <geliang.tang@suse.com>
Cc: mptcp@lists.linux.dev
Subject: Re: [PATCH mptcp-next v7 4/8] mptcp: add sched in mptcp_sock
Date: Mon, 28 Mar 2022 11:51:53 +0200	[thread overview]
Message-ID: <20220328095153.GC18687@breakpoint.cc> (raw)
In-Reply-To: <2812381119c23048dadbf5372293c724ff4b7970.1648459865.git.geliang.tang@suse.com>

Geliang Tang <geliang.tang@suse.com> wrote:
> +void mptcp_release_sched(struct mptcp_sock *msk)
> +{
> +	if (msk->sched && msk->sched->release)
> +		msk->sched->release(msk);
> +	bpf_module_put(msk->sched, msk->sched->owner);
> +	msk->sched = NULL;

Strange.  First line makes sure we don't null deref on msk->sched ==
NULL, but bpf_module_put() passes msk->sched->owner?

Does bpf_module_put need to live in a 
if (msk->sched) { branch or is the null test redundant?

  reply	other threads:[~2022-03-28  9:51 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-28  9:37 [PATCH mptcp-next v7 0/8] BPF packet scheduler Geliang Tang
2022-03-28  9:37 ` [PATCH mptcp-next v7 1/8] mptcp: add struct mptcp_sched_ops Geliang Tang
2022-03-28  9:49   ` Florian Westphal
2022-03-28 13:11     ` Geliang Tang
2022-03-28 13:49       ` Florian Westphal
2022-03-28  9:37 ` [PATCH mptcp-next v7 2/8] mptcp: register default scheduler Geliang Tang
2022-03-28  9:37 ` [PATCH mptcp-next v7 3/8] mptcp: add a new sysctl scheduler Geliang Tang
2022-03-28  9:37 ` [PATCH mptcp-next v7 4/8] mptcp: add sched in mptcp_sock Geliang Tang
2022-03-28  9:51   ` Florian Westphal [this message]
2022-03-28 22:47   ` Mat Martineau
2022-03-28  9:37 ` [PATCH mptcp-next v7 5/8] mptcp: add get_subflow wrapper Geliang Tang
2022-03-28  9:38 ` [PATCH mptcp-next v7 6/8] mptcp: add bpf_mptcp_sched_ops Geliang Tang
2022-03-28  9:38 ` [PATCH mptcp-next v7 7/8] selftests: bpf: add mptcp_bpf_first scheduler Geliang Tang
2022-03-28  9:38 ` [PATCH mptcp-next v7 8/8] selftests: bpf: add mptcp_bpf_first test Geliang Tang
2022-03-28 22:49   ` Mat Martineau
2022-03-30 17:03   ` selftests: bpf: add mptcp_bpf_first test: Build Failure MPTCP CI
2022-03-30 21:10   ` selftests: bpf: add mptcp_bpf_first test: Tests Results MPTCP CI

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=20220328095153.GC18687@breakpoint.cc \
    --to=fw@strlen.de \
    --cc=geliang.tang@suse.com \
    --cc=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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.