Article View: linux.kernel.netdev
Article #14831Re: [PATCH net-next v7 1/2] netlink: specs: add ovs_flow del and set operations
From: netdev-bot+sashiko
Date: Thu, 12 Nov 2026 02:02
Date: Thu, 12 Nov 2026 02:02
134 lines
12920 bytes
12920 bytes
Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.
Low priority / nit picks for your consideration:
- [Low] The new OVS_FLOW_ATTR_UFID doc in
include/uapi/linux/openvswitch.h (lines 669-671) and in…
- [Low] The patch changes the docs for key, actions, stats, tcp-flags and
used from 'present in notifications' to 'present in replies and…
--
netlink: specs: add ovs_flow del and set operations
This commit adds the del and set operations to the ovs_flow YNL spec and
gives dump its own request list. It also changes probe to a flag and adds
used and tcp-flags to the get reply. The attribute docs are reworded in
both the spec and include/uapi/linux/openvswitch.h.
> diff --git a/Documentation/netlink/specs/ovs_flow.yaml b/Documentation/netlink/specs/ovs_flow.yaml
> index 951837b72e1d2..d7aeeeb5a3cc5 100644
> --- a/Documentation/netlink/specs/ovs_flow.yaml
> +++ b/Documentation/netlink/specs/ovs_flow.yaml
[ ... ]
> @@ -438,18 +447,22 @@ attribute-sets:
[ ... ]
> -
> name: ufid
> type: binary
> + checks:
> + min-len: 1
> doc: |
> A value between 1-16 octets specifying a unique identifier for the
> flow. Causes the flow to be indexed by this value rather than the
> - value of the OVS_FLOW_ATTR_KEY attribute. Optional for all
> - requests. Present in notifications if the flow was created with this
> - attribute.
> + value of the OVS_FLOW_ATTR_KEY attribute. A value longer than 16
> + octets is treated as if the attribute were absent, so a new flow is
> + indexed by its key. A zero-length value is rejected with -ERANGE.
> + Optional for all requests. Present in notifications if the flow was
> + created with this attribute. A dump does not read it.
[Severity: Low]
Is "A dump does not read it" accurate when it sits next to the -ERANGE
sentence? The commit message goes further:
"A dump does not read the attribute at all."
ovs_flow_cmd_dump() still parses every attribute against flow_policy:
net/openvswitch/datapath.c:ovs_flow_cmd_dump() {
...
err = genlmsg_parse_deprecated(cb->nlh, &dp_flow_genl_family, a,
OVS_FLOW_ATTR_MAX, flow_policy, NULL);
if (err)
return err;
...
}
and flow_policy has:
[OVS_FLOW_ATTR_UFID] = { .type = NLA_UNSPEC, .len = 1 },
In validate_nla(), the NLA_UNSPEC length check fails with -ERANGE, so a dump
request that carries a zero-length OVS_FLOW_ATTR_UFID is rejected the same
way a do request is. The dump never uses the ufid value, but it does
validate the attribute.
Could the wording say that a dump ignores the value but still rejects a
zero-length ufid? The same sentence is in the OVS_FLOW_ATTR_UFID kernel-doc
in include/uapi/linux/openvswitch.h.
[ ... ]
> diff --git a/include/uapi/linux/openvswitch.h b/include/uapi/linux/openvswitch.h
> index 440825e658371..3f18f59e91dc2 100644
> --- a/include/uapi/linux/openvswitch.h
> +++ b/include/uapi/linux/openvswitch.h
[ ... ]
> @@ -655,9 +664,11 @@ struct ovs_nsh_key_md1 {
> * should be suppressed.
> * @OVS_FLOW_ATTR_UFID: A value between 1-16 octets specifying a unique
> * identifier for the flow. Causes the flow to be indexed by this value rather
> - * than the value of the %OVS_FLOW_ATTR_KEY attribute. Optional for all
> + * than the value of the %OVS_FLOW_ATTR_KEY attribute. A value longer than 16
> + * octets is treated as if the attribute were absent, so a new flow is indexed
> + * by its key. A zero-length value is rejected with -ERANGE. Optional for all
> * requests. Present in notifications if the flow was created with this
> - * attribute.
> + * attribute. A dump does not read it.
[Severity: Low]
This patch changes key, actions, stats, tcp-flags and used from "present in
notifications" to "present in replies and notifications". This paragraph is
edited too, but it keeps "Present in notifications if the flow was created
with this attribute". Should it also say replies?
ovs_flow_cmd_fill_info() calls ovs_nla_put_identifier() unconditionally:
net/openvswitch/datapath.c:ovs_flow_cmd_fill_info() {
...
err = ovs_nla_put_identifier(flow, skb);
if (err)
goto error;
...
}
and for a flow identified by a ufid, that emits OVS_FLOW_ATTR_UFID:
net/openvswitch/flow_netlink.c:ovs_nla_put_identifier() {
if (ovs_identifier_is_ufid(&flow->id))
return nla_put(skb, OVS_FLOW_ATTR_UFID, flow->id.ufid_len,
flow->id.ufid);
...
}
fill_info() builds get replies and every dump entry, so the ufid shows up in
those replies as well as in notifications.
The spec now also disagrees with itself: the &flow-get-reply list includes
ufid, but the ufid doc in ovs_flow.yaml has the same notification-only
sentence.
--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261110174751.973464-1-houminxi%40gmail.com
Technical Details
Message-ID:
<179444894546.2199510.2728310247051508293@kernel.org>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!nntp.comgw.net!eternal-september.org!feeder.eternal-september.org!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-361450-linux-kernel-netdev=dewy.ruReferences:
<20261110174751.973464-2-houminxi@gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!nntp.comgw.net!eternal-september.org!feeder.eternal-september.org!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-361450-linux-kernel-netdev=dewy.ru From: netdev-bot+sashiko@kernel.org Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net-next v7 1/2] netlink: specs: add ovs_flow del and set operations Date: Thu, 12 Nov 2026 02:02:25 +0000 Organization: Usenet Network Message-ID: <179444894546.2199510.2728310247051508293@kernel.org> References: <20261110174751.973464-2-houminxi@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="986542"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:M1vp/SfJn7+mTufhXD1drYk0Z1Q= sha256:chV9ulyaNXQ+quCU+AkCvxY/ALTN6TyAgbw210VxHJk= sha1:06aV5xx+w2sodg0o3n9XdFaBLtM= sha256:HlSN1sya3eU2+m4Fze+DOnaSNRQycZkHqMiH31yYzQM= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id E8A8E1140C0; Thu, 12 Nov 2026 05:04:22 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.501 X-Spam-Status: No, score=-3.501 tagged_above=-9999 required=6.31 tests=[DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id UHEqNBqXp5Mv; Thu, 12 Nov 2026 05:04:17 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.232.135.74; helo=sto.lore.kernel.org; envelope-from=netdev+bounces-361450-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74]) by mail.dewy.ru (Postfix) with ESMTPS id 3C84F113FC3; Thu, 12 Nov 2026 05:04:07 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sto.lore.kernel.org (Postfix) with ESMTP id 983AE61A920; Thu, 12 Nov 2026 02:02:37 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1794448948; b=IkWzfxfFAq4t68H/cfFc5Bv+rrMSgpANrDwDIqQJ052CblY5ouAjJKdCklWPEhElRE1I OIYnKfqehfpQi9GVbiPsrrpntX2NeJSxVT2JExfi+Y/ArDsyJyX4OFtAW4Ns1NYtrKrDr IMr8QbnKsw6KbrdOLR/BZZjPvHih00ZjH0GjEahFBogQG0CQGJVfweG4lmaCu97+JTY50 c2ri798rnJjSF1rMcTpfSRVE962jEy0joqdKHS9h4uVtlKVezgOMQ5m7rDc/f+eXf5/2L VqFJGYWpzrcjJMyamhYJylAWCVIR7587U7Xtz76fSREwJuenzaHHLA8HwHYY4mJyjmQ== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794448948; h=X-Original-To:Received:Received:DKIM-Signature:Subject:From:To:Cc: Date:Message-ID:In-Reply-To:References:X-sashiko-severity: Content-Type:Content-Transfer-Encoding:X-Mailing-List:List-Id: List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner: Precedence:MIME-Version; bh=HriGiWi+UQ8QPL/8QwkOWDz4Mb2kWePdRLKQHkPJXMI=; b=JdGytN6t3H2Jl7xQ26BRDm008EOiAlgoy18Z7Tw9t3Apc72PeXnb6/Fu9X6lz91YcMR6 KuxqvTxl5SAIdUEtPhEFtfRJQ3q+LGIMaP1heI+FzYOQBMtvk8+NaDPyKh96nnlSXpw3c cjTqZAl2ieYYGO2LaycBXdYPX2NV6SjpGk8AvrfoRundOgaA02wlU6gQ0K+31Jzk6vRNo 50p3vbpSeLZard4O/2t6NMlD7H1Z8MI50cev/RJOUTv2jJUrqfsD9dgjZ8CngURT1Xvrf cvCpS+kdunDCyIHvzsk5FrAmQyzIyyZzKShE7kZnC835nZrmDOpUhq02E7dSSJvIrQw== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=WWhT9UPX; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E4DB6606A33D; Thu, 12 Nov 2026 02:02:27 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=WWhT9UPX X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794448947; b=1xDAYoadD6RKu9Mh33t7IJDuXllqvqzP/CDO5Tpd8zr31VjpvDucmQYqUoR/tS2iZngP JqoPRP404x2XW4lZlqVcOObE+mljUQT9z1buvXANrflbajU21tLXFzu6M4pRh5sOMgf/v iRXYsTGVxLoMy6P8RFeFcupSyDaf0u6lo4eSpRS+T2iwNn1X148552f82n89V+xLy0GNM YCoA/lbMYWOWXROgMNTtuDdgTakPf/rWf0Xk/Q56aEw8Ouog/CAuLgwTZpnmDam2xy2md RE5yy+XxQNHDbEYv5O4dSfoUuHbJvpMwDun99XGvIzDykgzNFbHCE3LC8WD4bLuG/QQ== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794448947; h=Received:DKIM-Signature:Subject:From:To:Cc:Date:Message-ID: In-Reply-To:References:X-sashiko-severity:Content-Type: Content-Transfer-Encoding:MIME-Version; bh=HriGiWi+UQ8QPL/8QwkOWDz4Mb2kWePdRLKQHkPJXMI=; b=FHVkfGc61rFNP0KJ7Ux9n1QKrS1LYS8H78izDy8B6fiXiJI5l2n7p+5sn3/Vo+75eYse pFYaEmxcCvzasrXrbnXtCnIfHlhqxnUbTZupJ+9NuIYodbW8tyDJO6+VqFa8yeORluwhG UYwWES1rEyDVeMeahE/+n4344vQrXfxyOGx3x0Co6LIQCYPfk9btQm+Q5coN3AWnJx5Ty m++awrnwVZkDGHuJvAkIOD+kus3n8fzAsnA0tejce1v9amdfxBQ1s7/uCT7lmJaOeXJK1 gnumGtuJCbtTTipHWwVgbFwXyYMT+3d+sz2k5nRUnysoGSJlTbyprLnk+4YAs5NXPiw== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=WWhT9UPX; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0D7BD606A337 for <netdev@vger.kernel.org>; Thu, 12 Nov 2026 02:02:26 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id E4AA61F00A06; Thu, 12 Nov 2026 02:02:25 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1794448946; bh=HriGiWi+UQ8QPL/8QwkOWDz4Mb2kWePdRLKQHkPJXMI=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=WWhT9UPXr0myRopcw5u0oW/MMCb3oOkApSaqHzPxBZxrKs50GY7bhTW8hzQcTcYPl 1+Grsajj+fI5uHHWIbqWAQsLem0ChlZVaDI9lKzD3MdgT+HGktCoZLs362xHto7YZz a3SwCdTjCozx8DwBnWUMr5VMCeBiraUbgkraWa9Sjpt8lbohj9eqsY4ANESzgUhShE P0RpRvESMdL1QX6zG5Bl1Cu1zvE/i82CVhQIv3wMhL0WsdC2muikCaFazwtjf7C6s2 vJF/W8eaC1HDuTi+WB/ZnfvtkUx18zDukmf2Dn1I7viQx52hKiiG3l+mguS36Qsf3X nAxAaE/njcJjA== X-Cc: netdev@vger.kernel.org, donald.hunter@gmail.com, kuba@kernel.org, davem@davemloft.net, edumazet@kernel.org, pabeni@redhat.com, horms@kernel.org, aconole@redhat.com, echaudro@redhat.com, i.maximets@ovn.org, dev@openvswitch.org X-In-Reply-To: <20261110174751.973464-2-houminxi@gmail.com> X-sashiko-severity: Low X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list