All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: "Christoph Böhmwalder" <christoph.boehmwalder@linbit.com>
Cc: Philipp Reisner <philipp.reisner@linbit.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
	Alok Tiwari <alok.a.tiwari@oracle.com>,
	Kees Cook <kees@kernel.org>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH] genetlink: add multi-version family support for protocol negotiation
Date: Mon, 16 Mar 2026 11:37:36 -0700	[thread overview]
Message-ID: <20260316113736.1085a124@kernel.org> (raw)
In-Reply-To: <20260316151507.3958299-2-christoph.boehmwalder@linbit.com>

On Mon, 16 Mar 2026 16:15:06 +0100 Christoph Böhmwalder wrote:
> Extend the genetlink infrastructure to allow families to advertise a
> range of supported protocol versions [min_version, max_version]. This
> enables a single kernel module to serve both old and new userspace by
> letting userspace discover the maximum version via CTRL_ATTR_MAX_VERSION
> and select the desired protocol dialect in genlmsghdr.version.
> 
> Rename genl_family.version to .min_version across all families (pure
> rename, no behavioral change). This avoids updating all callers.
> 
> Add genl_family.max_version. When 0 (default) the family behaves
> exactly as before. When > min_version, the controller advertises
> CTRL_ATTR_MAX_VERSION in CTRL_CMD_GETFAMILY replies.
> 
> When sending a reply, echo the request's genlmsghdr.version, so
> userspace receives responses in the protocol version it spoke.
> Notifications (where info->nlhdr is NULL) continue to use min_version.
> 
> Add genlmsg_put_ver() for families that need to stamp a specific
> version on notifications.
> 
> The immediate motivation is upstreaming DRBD 9 (genl family v1)
> while keeping unmodified DRBD 8 userspace (family v2) working. The
> DRBD family would register with min_version=1, max_version=2 and
> handle both protocol dialects.

What's the delta between the families? Do you have any examples of 
the the version ends up being used?

  reply	other threads:[~2026-03-16 18:37 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-16 15:15 [RFC PATCH] genetlink: add multi-version family support for protocol negotiation Christoph Böhmwalder
2026-03-16 18:37 ` Jakub Kicinski [this message]
2026-03-17 15:47   ` Christoph Böhmwalder
2026-03-17 22:17     ` Jakub Kicinski
2026-03-18 14:54       ` Christoph Böhmwalder
2026-03-18 22:27         ` Jakub Kicinski

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=20260316113736.1085a124@kernel.org \
    --to=kuba@kernel.org \
    --cc=alok.a.tiwari@oracle.com \
    --cc=christoph.boehmwalder@linbit.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kees@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=philipp.reisner@linbit.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 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.