diff options
-rw-r--r-- | init/dyn_array.c | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/init/dyn_array.c b/init/dyn_array.c index 778d9d508158..c8d5e2a18588 100644 --- a/init/dyn_array.c +++ b/init/dyn_array.c | |||
@@ -17,10 +17,9 @@ void __init pre_alloc_dyn_array(void) | |||
17 | for (daa = __dyn_array_start ; daa < __dyn_array_end; daa++) { | 17 | for (daa = __dyn_array_start ; daa < __dyn_array_end; daa++) { |
18 | struct dyn_array *da = *daa; | 18 | struct dyn_array *da = *daa; |
19 | 19 | ||
20 | printk(KERN_DEBUG "dyn_array %pF size:%#lx nr:%d align:%#lx\n", | ||
21 | da->name, da->size, *da->nr, da->align); | ||
20 | size = da->size * (*da->nr); | 22 | size = da->size * (*da->nr); |
21 | print_fn_descriptor_symbol("dyn_array %s ", da->name); | ||
22 | printk(KERN_CONT "size:%#lx nr:%d align:%#lx\n", | ||
23 | da->size, *da->nr, da->align); | ||
24 | total_size += roundup(size, da->align); | 23 | total_size += roundup(size, da->align); |
25 | if (da->align > max_align) | 24 | if (da->align > max_align) |
26 | max_align = da->align; | 25 | max_align = da->align; |
@@ -40,11 +39,10 @@ void __init pre_alloc_dyn_array(void) | |||
40 | struct dyn_array *da = *daa; | 39 | struct dyn_array *da = *daa; |
41 | 40 | ||
42 | size = da->size * (*da->nr); | 41 | size = da->size * (*da->nr); |
43 | print_fn_descriptor_symbol("dyn_array %s ", da->name); | ||
44 | |||
45 | phys = roundup(phys, da->align); | 42 | phys = roundup(phys, da->align); |
43 | printk(KERN_DEBUG "dyn_array %pF ==> [%#lx - %#lx]\n", | ||
44 | da->name, phys, phys + size); | ||
46 | *da->name = phys_to_virt(phys); | 45 | *da->name = phys_to_virt(phys); |
47 | printk(KERN_CONT " ==> [%#lx - %#lx]\n", phys, phys + size); | ||
48 | 46 | ||
49 | phys += size; | 47 | phys += size; |
50 | 48 | ||
@@ -72,10 +70,9 @@ unsigned long __init per_cpu_dyn_array_size(unsigned long *align) | |||
72 | for (daa = __per_cpu_dyn_array_start ; daa < __per_cpu_dyn_array_end; daa++) { | 70 | for (daa = __per_cpu_dyn_array_start ; daa < __per_cpu_dyn_array_end; daa++) { |
73 | struct dyn_array *da = *daa; | 71 | struct dyn_array *da = *daa; |
74 | 72 | ||
73 | printk(KERN_DEBUG "per_cpu_dyn_array %pF size:%#lx nr:%d align:%#lx\n", | ||
74 | da->name, da->size, *da->nr, da->align); | ||
75 | size = da->size * (*da->nr); | 75 | size = da->size * (*da->nr); |
76 | print_fn_descriptor_symbol("per_cpu_dyn_array %s ", da->name); | ||
77 | printk(KERN_CONT "size:%#lx nr:%d align:%#lx\n", | ||
78 | da->size, *da->nr, da->align); | ||
79 | total_size += roundup(size, da->align); | 76 | total_size += roundup(size, da->align); |
80 | if (da->align > max_align) | 77 | if (da->align > max_align) |
81 | max_align = da->align; | 78 | max_align = da->align; |
@@ -103,15 +100,15 @@ void __init per_cpu_alloc_dyn_array(int cpu, char *ptr) | |||
103 | struct dyn_array *da = *daa; | 100 | struct dyn_array *da = *daa; |
104 | 101 | ||
105 | size = da->size * (*da->nr); | 102 | size = da->size * (*da->nr); |
106 | print_fn_descriptor_symbol("per_cpu_dyn_array %s ", da->name); | ||
107 | |||
108 | phys = roundup(phys, da->align); | 103 | phys = roundup(phys, da->align); |
104 | printk(KERN_DEBUG "per_cpu_dyn_array %pF ==> [%#lx - %#lx]\n", | ||
105 | da->name, phys, phys + size); | ||
106 | |||
109 | addr = (unsigned long)da->name; | 107 | addr = (unsigned long)da->name; |
110 | addr += per_cpu_offset(cpu); | 108 | addr += per_cpu_offset(cpu); |
111 | array = (void **)addr; | 109 | array = (void **)addr; |
112 | *array = phys_to_virt(phys); | 110 | *array = phys_to_virt(phys); |
113 | *da->name = *array; /* so init_work could use it directly */ | 111 | *da->name = *array; /* so init_work could use it directly */ |
114 | printk(KERN_CONT " ==> [%#lx - %#lx]\n", phys, phys + size); | ||
115 | 112 | ||
116 | phys += size; | 113 | phys += size; |
117 | 114 | ||