diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2023-02-06 09:25:56 -0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2023-02-06 09:25:56 -0300 |
commit | ab809efaeba0cca20cfcda23852b0ee958f6ea69 (patch) | |
tree | 36b168deb9908cba8605bb8fa026bdacc26560db /net/ipv4/metrics.c | |
parent | 17f248aa8664ff5b3643491136283e73b5c18166 (diff) | |
parent | d2d11f342b179f1894a901f143ec7c008caba43e (diff) | |
download | linux-stable-ab809efaeba0cca20cfcda23852b0ee958f6ea69.tar.gz linux-stable-ab809efaeba0cca20cfcda23852b0ee958f6ea69.tar.bz2 linux-stable-ab809efaeba0cca20cfcda23852b0ee958f6ea69.zip |
Merge remote-tracking branch 'torvalds/master' into perf/core
To sync with libbpf, etc.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'net/ipv4/metrics.c')
-rw-r--r-- | net/ipv4/metrics.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/ipv4/metrics.c b/net/ipv4/metrics.c index 7fcfdfd8f9de..0e3ee1532848 100644 --- a/net/ipv4/metrics.c +++ b/net/ipv4/metrics.c @@ -1,5 +1,6 @@ // SPDX-License-Identifier: GPL-2.0-only #include <linux/netlink.h> +#include <linux/nospec.h> #include <linux/rtnetlink.h> #include <linux/types.h> #include <net/ip.h> @@ -25,6 +26,7 @@ static int ip_metrics_convert(struct net *net, struct nlattr *fc_mx, return -EINVAL; } + type = array_index_nospec(type, RTAX_MAX + 1); if (type == RTAX_CC_ALGO) { char tmp[TCP_CA_NAME_MAX]; |