diff options
author | Ravikiran G Thirumalai <kiran@scalex86.org> | 2005-09-06 18:17:45 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-09-07 19:57:33 -0400 |
commit | 6c231b7bab0aa6860cd9da2de8a064eddc34c146 (patch) | |
tree | 2a6d9dea348651ec6000b96b99fbf5bd9ccdb228 /arch/i386 | |
parent | 39ed3fdeec1290dd246dcf1da6b278566987a084 (diff) |
[PATCH] Additions to .data.read_mostly section
Mark variables which are usually accessed for reads with __readmostly.
Signed-off-by: Alok N Kataria <alokk@calsoftinc.com>
Signed-off-by: Shai Fultheim <shai@scalex86.org>
Signed-off-by: Ravikiran Thirumalai <kiran@scalex86.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/i386')
-rw-r--r-- | arch/i386/kernel/io_apic.c | 10 | ||||
-rw-r--r-- | arch/i386/kernel/timers/timer_hpet.c | 2 | ||||
-rw-r--r-- | arch/i386/mm/discontig.c | 8 | ||||
-rw-r--r-- | arch/i386/mm/init.c | 2 |
4 files changed, 11 insertions, 11 deletions
diff --git a/arch/i386/kernel/io_apic.c b/arch/i386/kernel/io_apic.c index 4a5940431579..0e727e6da5c9 100644 --- a/arch/i386/kernel/io_apic.c +++ b/arch/i386/kernel/io_apic.c | |||
@@ -78,7 +78,7 @@ static struct irq_pin_list { | |||
78 | int apic, pin, next; | 78 | int apic, pin, next; |
79 | } irq_2_pin[PIN_MAP_SIZE]; | 79 | } irq_2_pin[PIN_MAP_SIZE]; |
80 | 80 | ||
81 | int vector_irq[NR_VECTORS] = { [0 ... NR_VECTORS - 1] = -1}; | 81 | int vector_irq[NR_VECTORS] __read_mostly = { [0 ... NR_VECTORS - 1] = -1}; |
82 | #ifdef CONFIG_PCI_MSI | 82 | #ifdef CONFIG_PCI_MSI |
83 | #define vector_to_irq(vector) \ | 83 | #define vector_to_irq(vector) \ |
84 | (platform_legacy_irq(vector) ? vector : vector_irq[vector]) | 84 | (platform_legacy_irq(vector) ? vector : vector_irq[vector]) |
@@ -1119,7 +1119,7 @@ static inline int IO_APIC_irq_trigger(int irq) | |||
1119 | } | 1119 | } |
1120 | 1120 | ||
1121 | /* irq_vectors is indexed by the sum of all RTEs in all I/O APICs. */ | 1121 | /* irq_vectors is indexed by the sum of all RTEs in all I/O APICs. */ |
1122 | u8 irq_vector[NR_IRQ_VECTORS] = { FIRST_DEVICE_VECTOR , 0 }; | 1122 | u8 irq_vector[NR_IRQ_VECTORS] __read_mostly = { FIRST_DEVICE_VECTOR , 0 }; |
1123 | 1123 | ||
1124 | int assign_irq_vector(int irq) | 1124 | int assign_irq_vector(int irq) |
1125 | { | 1125 | { |
@@ -1990,7 +1990,7 @@ static void set_ioapic_affinity_vector (unsigned int vector, | |||
1990 | * edge-triggered handler, without risking IRQ storms and other ugly | 1990 | * edge-triggered handler, without risking IRQ storms and other ugly |
1991 | * races. | 1991 | * races. |
1992 | */ | 1992 | */ |
1993 | static struct hw_interrupt_type ioapic_edge_type = { | 1993 | static struct hw_interrupt_type ioapic_edge_type __read_mostly = { |
1994 | .typename = "IO-APIC-edge", | 1994 | .typename = "IO-APIC-edge", |
1995 | .startup = startup_edge_ioapic, | 1995 | .startup = startup_edge_ioapic, |
1996 | .shutdown = shutdown_edge_ioapic, | 1996 | .shutdown = shutdown_edge_ioapic, |
@@ -2003,7 +2003,7 @@ static struct hw_interrupt_type ioapic_edge_type = { | |||
2003 | #endif | 2003 | #endif |
2004 | }; | 2004 | }; |
2005 | 2005 | ||
2006 | static struct hw_interrupt_type ioapic_level_type = { | 2006 | static struct hw_interrupt_type ioapic_level_type __read_mostly = { |
2007 | .typename = "IO-APIC-level", | 2007 | .typename = "IO-APIC-level", |
2008 | .startup = startup_level_ioapic, | 2008 | .startup = startup_level_ioapic, |
2009 | .shutdown = shutdown_level_ioapic, | 2009 | .shutdown = shutdown_level_ioapic, |
@@ -2076,7 +2076,7 @@ static void ack_lapic_irq (unsigned int irq) | |||
2076 | 2076 | ||
2077 | static void end_lapic_irq (unsigned int i) { /* nothing */ } | 2077 | static void end_lapic_irq (unsigned int i) { /* nothing */ } |
2078 | 2078 | ||
2079 | static struct hw_interrupt_type lapic_irq_type = { | 2079 | static struct hw_interrupt_type lapic_irq_type __read_mostly = { |
2080 | .typename = "local-APIC-edge", | 2080 | .typename = "local-APIC-edge", |
2081 | .startup = NULL, /* startup_irq() not used for IRQ0 */ | 2081 | .startup = NULL, /* startup_irq() not used for IRQ0 */ |
2082 | .shutdown = NULL, /* shutdown_irq() not used for IRQ0 */ | 2082 | .shutdown = NULL, /* shutdown_irq() not used for IRQ0 */ |
diff --git a/arch/i386/kernel/timers/timer_hpet.c b/arch/i386/kernel/timers/timer_hpet.c index 6dbb29f834e8..d973a8b681fd 100644 --- a/arch/i386/kernel/timers/timer_hpet.c +++ b/arch/i386/kernel/timers/timer_hpet.c | |||
@@ -19,7 +19,7 @@ | |||
19 | #include <asm/hpet.h> | 19 | #include <asm/hpet.h> |
20 | 20 | ||
21 | static unsigned long hpet_usec_quotient __read_mostly; /* convert hpet clks to usec */ | 21 | static unsigned long hpet_usec_quotient __read_mostly; /* convert hpet clks to usec */ |
22 | static unsigned long tsc_hpet_quotient; /* convert tsc to hpet clks */ | 22 | static unsigned long tsc_hpet_quotient __read_mostly; /* convert tsc to hpet clks */ |
23 | static unsigned long hpet_last; /* hpet counter value at last tick*/ | 23 | static unsigned long hpet_last; /* hpet counter value at last tick*/ |
24 | static unsigned long last_tsc_low; /* lsb 32 bits of Time Stamp Counter */ | 24 | static unsigned long last_tsc_low; /* lsb 32 bits of Time Stamp Counter */ |
25 | static unsigned long last_tsc_high; /* msb 32 bits of Time Stamp Counter */ | 25 | static unsigned long last_tsc_high; /* msb 32 bits of Time Stamp Counter */ |
diff --git a/arch/i386/mm/discontig.c b/arch/i386/mm/discontig.c index 6711ce3f6916..244d8ec66be2 100644 --- a/arch/i386/mm/discontig.c +++ b/arch/i386/mm/discontig.c | |||
@@ -37,7 +37,7 @@ | |||
37 | #include <asm/mmzone.h> | 37 | #include <asm/mmzone.h> |
38 | #include <bios_ebda.h> | 38 | #include <bios_ebda.h> |
39 | 39 | ||
40 | struct pglist_data *node_data[MAX_NUMNODES]; | 40 | struct pglist_data *node_data[MAX_NUMNODES] __read_mostly; |
41 | EXPORT_SYMBOL(node_data); | 41 | EXPORT_SYMBOL(node_data); |
42 | bootmem_data_t node0_bdata; | 42 | bootmem_data_t node0_bdata; |
43 | 43 | ||
@@ -49,8 +49,8 @@ bootmem_data_t node0_bdata; | |||
49 | * 2) node_start_pfn - the starting page frame number for a node | 49 | * 2) node_start_pfn - the starting page frame number for a node |
50 | * 3) node_end_pfn - the ending page fram number for a node | 50 | * 3) node_end_pfn - the ending page fram number for a node |
51 | */ | 51 | */ |
52 | unsigned long node_start_pfn[MAX_NUMNODES]; | 52 | unsigned long node_start_pfn[MAX_NUMNODES] __read_mostly; |
53 | unsigned long node_end_pfn[MAX_NUMNODES]; | 53 | unsigned long node_end_pfn[MAX_NUMNODES] __read_mostly; |
54 | 54 | ||
55 | 55 | ||
56 | #ifdef CONFIG_DISCONTIGMEM | 56 | #ifdef CONFIG_DISCONTIGMEM |
@@ -66,7 +66,7 @@ unsigned long node_end_pfn[MAX_NUMNODES]; | |||
66 | * physnode_map[4-7] = 1; | 66 | * physnode_map[4-7] = 1; |
67 | * physnode_map[8- ] = -1; | 67 | * physnode_map[8- ] = -1; |
68 | */ | 68 | */ |
69 | s8 physnode_map[MAX_ELEMENTS] = { [0 ... (MAX_ELEMENTS - 1)] = -1}; | 69 | s8 physnode_map[MAX_ELEMENTS] __read_mostly = { [0 ... (MAX_ELEMENTS - 1)] = -1}; |
70 | EXPORT_SYMBOL(physnode_map); | 70 | EXPORT_SYMBOL(physnode_map); |
71 | 71 | ||
72 | void memory_present(int nid, unsigned long start, unsigned long end) | 72 | void memory_present(int nid, unsigned long start, unsigned long end) |
diff --git a/arch/i386/mm/init.c b/arch/i386/mm/init.c index 9edfc058b894..2ebaf75f732e 100644 --- a/arch/i386/mm/init.c +++ b/arch/i386/mm/init.c | |||
@@ -393,7 +393,7 @@ void zap_low_mappings (void) | |||
393 | } | 393 | } |
394 | 394 | ||
395 | static int disable_nx __initdata = 0; | 395 | static int disable_nx __initdata = 0; |
396 | u64 __supported_pte_mask = ~_PAGE_NX; | 396 | u64 __supported_pte_mask __read_mostly = ~_PAGE_NX; |
397 | 397 | ||
398 | /* | 398 | /* |
399 | * noexec = on|off | 399 | * noexec = on|off |