From: Eric Dumazet <eric.dumazet@gmail.com>
To: "David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>
Cc: netdev <netdev@vger.kernel.org>,
Eric Dumazet <edumazet@google.com>,
Eric Dumazet <eric.dumazet@gmail.com>
Subject: [PATCH net-next 3/9] ipv4: convert fib_notify_on_flag_change sysctl to u8
Date: Wed, 31 Mar 2021 10:52:07 -0700 [thread overview]
Message-ID: <20210331175213.691460-4-eric.dumazet@gmail.com> (raw)
In-Reply-To: <20210331175213.691460-1-eric.dumazet@gmail.com>
From: Eric Dumazet <edumazet@google.com>
Reduce footprint of sysctls.
Signed-off-by: Eric Dumazet <edumazet@google.com>
---
include/net/netns/ipv4.h | 2 +-
net/ipv4/sysctl_net_ipv4.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/include/net/netns/ipv4.h b/include/net/netns/ipv4.h
index 538ed69919dc4d51acfd43c7d6d1fca611fcb003..b187ac597b8ce33376070bcd42c8c935b9c287eb 100644
--- a/include/net/netns/ipv4.h
+++ b/include/net/netns/ipv4.h
@@ -191,7 +191,7 @@ struct netns_ipv4 {
int sysctl_udp_wmem_min;
int sysctl_udp_rmem_min;
- int sysctl_fib_notify_on_flag_change;
+ u8 sysctl_fib_notify_on_flag_change;
#ifdef CONFIG_NET_L3_MASTER_DEV
int sysctl_udp_l3mdev_accept;
diff --git a/net/ipv4/sysctl_net_ipv4.c b/net/ipv4/sysctl_net_ipv4.c
index 9199f507a005efc3f57ca0225d3898bfa5d01c53..a2352d8d88cc9956ac0ddcaf351cbc996fa10add 100644
--- a/net/ipv4/sysctl_net_ipv4.c
+++ b/net/ipv4/sysctl_net_ipv4.c
@@ -1364,9 +1364,9 @@ static struct ctl_table ipv4_net_table[] = {
{
.procname = "fib_notify_on_flag_change",
.data = &init_net.ipv4.sysctl_fib_notify_on_flag_change,
- .maxlen = sizeof(int),
+ .maxlen = sizeof(u8),
.mode = 0644,
- .proc_handler = proc_dointvec_minmax,
+ .proc_handler = proc_dou8vec_minmax,
.extra1 = SYSCTL_ZERO,
.extra2 = &two,
},
--
2.31.0.291.g576ba9dcdaf-goog
next prev parent reply other threads:[~2021-03-31 17:53 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-31 17:52 [PATCH net-next 0/9] inet: shrink netns_ipv{4|6} Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 1/9] inet: shrink inet_timewait_death_row by 48 bytes Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 2/9] inet: shrink netns_ipv4 by another cache line Eric Dumazet
2021-03-31 17:52 ` Eric Dumazet [this message]
2021-03-31 17:52 ` [PATCH net-next 4/9] ipv4: convert udp_l3mdev_accept sysctl to u8 Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 5/9] ipv4: convert fib_multipath_{use_neigh|hash_policy} sysctls " Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 6/9] ipv4: convert igmp_link_local_mcast_reports sysctl " Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 7/9] tcp: convert tcp_comp_sack_nr " Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 8/9] ipv6: convert elligible sysctls " Eric Dumazet
2021-03-31 17:52 ` [PATCH net-next 9/9] ipv6: move ip6_dst_ops first in netns_ipv6 Eric Dumazet
2021-03-31 22:20 ` [PATCH net-next 0/9] inet: shrink netns_ipv{4|6} patchwork-bot+netdevbpf
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=20210331175213.691460-4-eric.dumazet@gmail.com \
--to=eric.dumazet@gmail.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).