netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@linux-foundation.org>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org
Subject: [patch 2/4] net: make seq_operations const
Date: Mon, 12 Mar 2007 14:08:19 -0700	[thread overview]
Message-ID: <20070312210907.658532320@linux-foundation.org> (raw)
In-Reply-To: 20070312210817.485320783@linux-foundation.org

[-- Attachment #1: net-seq-ops-const.patch --]
[-- Type: text/plain, Size: 6357 bytes --]

The seq_file operations stuff can be marked constant to
get it out of dirty cache.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
---
 net/core/dev.c       |    4 ++--
 net/core/dev_mcast.c |    2 +-
 net/core/neighbour.c |    2 +-
 net/core/sock.c      |    2 +-
 net/core/wireless.c  |    2 +-
 net/ipv4/arp.c       |    2 +-
 net/ipv4/fib_hash.c  |    2 +-
 net/ipv4/fib_trie.c  |    4 ++--
 net/ipv4/igmp.c      |    4 ++--
 net/ipv4/ipmr.c      |    4 ++--
 net/ipv4/raw.c       |    2 +-
 net/ipv4/route.c     |    4 ++--
 12 files changed, 17 insertions(+), 17 deletions(-)

--- net-2.6.22.orig/net/core/dev.c	2007-03-12 12:29:38.000000000 -0700
+++ net-2.6.22/net/core/dev.c	2007-03-12 12:29:39.000000000 -0700
@@ -2177,7 +2177,7 @@
 	return 0;
 }
 
-static struct seq_operations dev_seq_ops = {
+static const struct seq_operations dev_seq_ops = {
 	.start = dev_seq_start,
 	.next  = dev_seq_next,
 	.stop  = dev_seq_stop,
@@ -2197,7 +2197,7 @@
 	.release = seq_release,
 };
 
-static struct seq_operations softnet_seq_ops = {
+static const struct seq_operations softnet_seq_ops = {
 	.start = softnet_seq_start,
 	.next  = softnet_seq_next,
 	.stop  = softnet_seq_stop,
--- net-2.6.22.orig/net/core/dev_mcast.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/core/dev_mcast.c	2007-03-12 12:29:39.000000000 -0700
@@ -264,7 +264,7 @@
 	return 0;
 }
 
-static struct seq_operations dev_mc_seq_ops = {
+static const struct seq_operations dev_mc_seq_ops = {
 	.start = dev_mc_seq_start,
 	.next  = dev_mc_seq_next,
 	.stop  = dev_mc_seq_stop,
--- net-2.6.22.orig/net/core/neighbour.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/core/neighbour.c	2007-03-12 12:29:39.000000000 -0700
@@ -2384,7 +2384,7 @@
 	return 0;
 }
 
-static struct seq_operations neigh_stat_seq_ops = {
+static const struct seq_operations neigh_stat_seq_ops = {
 	.start	= neigh_stat_seq_start,
 	.next	= neigh_stat_seq_next,
 	.stop	= neigh_stat_seq_stop,
--- net-2.6.22.orig/net/core/sock.c	2007-03-12 12:05:58.000000000 -0700
+++ net-2.6.22/net/core/sock.c	2007-03-12 12:29:39.000000000 -0700
@@ -1925,7 +1925,7 @@
 	return 0;
 }
 
-static struct seq_operations proto_seq_ops = {
+static const struct seq_operations proto_seq_ops = {
 	.start  = proto_seq_start,
 	.next   = proto_seq_next,
 	.stop   = proto_seq_stop,
--- net-2.6.22.orig/net/core/wireless.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/core/wireless.c	2007-03-12 12:29:39.000000000 -0700
@@ -660,7 +660,7 @@
 	return 0;
 }
 
-static struct seq_operations wireless_seq_ops = {
+static const struct seq_operations wireless_seq_ops = {
 	.start = dev_seq_start,
 	.next  = dev_seq_next,
 	.stop  = dev_seq_stop,
--- net-2.6.22.orig/net/ipv4/arp.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/ipv4/arp.c	2007-03-12 12:29:39.000000000 -0700
@@ -1360,7 +1360,7 @@
 
 /* ------------------------------------------------------------------------ */
 
-static struct seq_operations arp_seq_ops = {
+static const struct seq_operations arp_seq_ops = {
 	.start  = arp_seq_start,
 	.next   = neigh_seq_next,
 	.stop   = neigh_seq_stop,
--- net-2.6.22.orig/net/ipv4/fib_hash.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/ipv4/fib_hash.c	2007-03-12 12:29:39.000000000 -0700
@@ -1027,7 +1027,7 @@
 	return 0;
 }
 
-static struct seq_operations fib_seq_ops = {
+static const struct seq_operations fib_seq_ops = {
 	.start  = fib_seq_start,
 	.next   = fib_seq_next,
 	.stop   = fib_seq_stop,
--- net-2.6.22.orig/net/ipv4/fib_trie.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/ipv4/fib_trie.c	2007-03-12 12:29:39.000000000 -0700
@@ -2332,7 +2332,7 @@
 	return 0;
 }
 
-static struct seq_operations fib_trie_seq_ops = {
+static const struct seq_operations fib_trie_seq_ops = {
 	.start  = fib_trie_seq_start,
 	.next   = fib_trie_seq_next,
 	.stop   = fib_trie_seq_stop,
@@ -2453,7 +2453,7 @@
 	return 0;
 }
 
-static struct seq_operations fib_route_seq_ops = {
+static const struct seq_operations fib_route_seq_ops = {
 	.start  = fib_trie_seq_start,
 	.next   = fib_trie_seq_next,
 	.stop   = fib_trie_seq_stop,
--- net-2.6.22.orig/net/ipv4/igmp.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/ipv4/igmp.c	2007-03-12 12:29:39.000000000 -0700
@@ -2397,7 +2397,7 @@
 	return 0;
 }
 
-static struct seq_operations igmp_mc_seq_ops = {
+static const struct seq_operations igmp_mc_seq_ops = {
 	.start	=	igmp_mc_seq_start,
 	.next	=	igmp_mc_seq_next,
 	.stop	=	igmp_mc_seq_stop,
@@ -2571,7 +2571,7 @@
 	return 0;
 }
 
-static struct seq_operations igmp_mcf_seq_ops = {
+static const struct seq_operations igmp_mcf_seq_ops = {
 	.start	=	igmp_mcf_seq_start,
 	.next	=	igmp_mcf_seq_next,
 	.stop	=	igmp_mcf_seq_stop,
--- net-2.6.22.orig/net/ipv4/ipmr.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/ipv4/ipmr.c	2007-03-12 12:29:39.000000000 -0700
@@ -1677,7 +1677,7 @@
 	return 0;
 }
 
-static struct seq_operations ipmr_vif_seq_ops = {
+static const struct seq_operations ipmr_vif_seq_ops = {
 	.start = ipmr_vif_seq_start,
 	.next  = ipmr_vif_seq_next,
 	.stop  = ipmr_vif_seq_stop,
@@ -1840,7 +1840,7 @@
 	return 0;
 }
 
-static struct seq_operations ipmr_mfc_seq_ops = {
+static const struct seq_operations ipmr_mfc_seq_ops = {
 	.start = ipmr_mfc_seq_start,
 	.next  = ipmr_mfc_seq_next,
 	.stop  = ipmr_mfc_seq_stop,
--- net-2.6.22.orig/net/ipv4/raw.c	2007-03-12 12:05:34.000000000 -0700
+++ net-2.6.22/net/ipv4/raw.c	2007-03-12 12:29:39.000000000 -0700
@@ -887,7 +887,7 @@
 	return 0;
 }
 
-static struct seq_operations raw_seq_ops = {
+static const struct seq_operations raw_seq_ops = {
 	.start = raw_seq_start,
 	.next  = raw_seq_next,
 	.stop  = raw_seq_stop,
--- net-2.6.22.orig/net/ipv4/route.c	2007-03-12 12:05:58.000000000 -0700
+++ net-2.6.22/net/ipv4/route.c	2007-03-12 12:29:39.000000000 -0700
@@ -364,7 +364,7 @@
 	return 0;
 }
 
-static struct seq_operations rt_cache_seq_ops = {
+static const struct seq_operations rt_cache_seq_ops = {
 	.start  = rt_cache_seq_start,
 	.next   = rt_cache_seq_next,
 	.stop   = rt_cache_seq_stop,
@@ -470,7 +470,7 @@
 	return 0;
 }
 
-static struct seq_operations rt_cpu_seq_ops = {
+static const struct seq_operations rt_cpu_seq_ops = {
 	.start  = rt_cpu_seq_start,
 	.next   = rt_cpu_seq_next,
 	.stop   = rt_cpu_seq_stop,

--
Stephen Hemminger <shemminger@linux-foundation.org>


  parent reply	other threads:[~2007-03-12 21:09 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-12 21:08 [patch 0/4] more stuff for 2.6.22 Stephen Hemminger
2007-03-12 21:08 ` [patch 1/4] network dev read_mostly Stephen Hemminger
2007-03-12 21:34   ` David Miller
2007-03-13  5:37   ` Eric Dumazet
2007-03-13 21:26     ` [RFC] Get rid of netdev_nit Stephen Hemminger
2007-04-21  0:02       ` David Miller
2007-03-15  2:18   ` [patch 1/4] network dev read_mostly Benjamin LaHaise
2007-03-15  4:54     ` David Miller
2007-03-15  6:28     ` Eric Dumazet
2007-03-15  7:25       ` David Miller
2007-03-15  7:42         ` Eric Dumazet
2007-03-15 13:17         ` Benjamin LaHaise
2007-03-16 17:03           ` Stephen Hemminger
2007-03-15 15:10     ` Andi Kleen
2007-03-12 21:08 ` Stephen Hemminger [this message]
2007-03-12 21:34   ` [patch 2/4] net: make seq_operations const David Miller
2007-03-12 21:08 ` [patch 3/4] net: show bound packet types Stephen Hemminger
2007-03-12 21:35   ` David Miller
2007-03-12 21:08 ` [patch 4/4] tcp: statistics not read_mostly Stephen Hemminger
2007-03-12 21:15   ` David Miller
2007-03-12 21:26     ` Stephen Hemminger
2007-03-12 21:33       ` David Miller
2007-03-13 20:09       ` Andi Kleen

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=20070312210907.658532320@linux-foundation.org \
    --to=shemminger@linux-foundation.org \
    --cc=davem@davemloft.net \
    --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).