1
From: Jiri Kosina <jkosina@suse.cz>
2
Subject: Revert module.c and module.h changes from -stable update
5
This reverts two patches from 2.6.32.12 -stable update, as it causes
8
The following two 2.6.32.12 -stable patches are reverted:
10
[169/197] modules: fix incorrect percpu usage
11
[171/197] module: fix __module_ref_addr()
13
They were incorrectly applied to 2.6.32-stable, though they should be applied
14
only to 2.6.33+ stable (on 2.6.32 ia64, static and dynamic percpu areas are
17
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
19
Index: linux-2.6.32-SLE11-SP1/include/linux/module.h
20
===================================================================
21
--- linux-2.6.32-SLE11-SP1.orig/include/linux/module.h
22
+++ linux-2.6.32-SLE11-SP1/include/linux/module.h
23
@@ -459,7 +459,7 @@ void symbol_put_addr(void *addr);
24
static inline local_t *__module_ref_addr(struct module *mod, int cpu)
27
- return (local_t *) per_cpu_ptr(mod->refptr, cpu);
28
+ return (local_t *) (mod->refptr + per_cpu_offset(cpu));
32
Index: linux-2.6.32-SLE11-SP1/kernel/module.c
33
===================================================================
34
--- linux-2.6.32-SLE11-SP1.orig/kernel/module.c
35
+++ linux-2.6.32-SLE11-SP1/kernel/module.c
36
@@ -572,7 +572,7 @@ static void percpu_modcopy(void *pcpudes
39
for_each_possible_cpu(cpu)
40
- memcpy(per_cpu_ptr(pcpudest, cpu), from, size);
41
+ memcpy(pcpudest + per_cpu_offset(cpu), from, size);
44
#else /* ... !CONFIG_SMP */