diff options
author | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-08-06 13:42:33 -0400 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-08-06 13:42:33 -0400 |
commit | 00dd7b7d26a3bf3780cfcebfdde2b86126b3a082 (patch) | |
tree | 5129fd1abc99d0c58a520938f28bf330ae94ef30 /arch | |
parent | 58b3ac07fed31ffc1349380b78305af6522fe1f4 (diff) | |
parent | 6e1e63259b1e01f047796e7985d960ca040993e6 (diff) |
Merge ../linux-2.6
Conflicts:
arch/ia64/hp/sim/simscsi.c
Stylistic differences in two separate fixes for buffer->request_buffer
problem.
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'arch')
127 files changed, 1184 insertions, 727 deletions
diff --git a/arch/alpha/kernel/err_ev7.c b/arch/alpha/kernel/err_ev7.c index bf52ba691957..fed6b3d1b803 100644 --- a/arch/alpha/kernel/err_ev7.c +++ b/arch/alpha/kernel/err_ev7.c | |||
@@ -274,16 +274,14 @@ ev7_process_pal_subpacket(struct el_subpacket *header) | |||
274 | struct el_subpacket_handler ev7_pal_subpacket_handler = | 274 | struct el_subpacket_handler ev7_pal_subpacket_handler = |
275 | SUBPACKET_HANDLER_INIT(EL_CLASS__PAL, ev7_process_pal_subpacket); | 275 | SUBPACKET_HANDLER_INIT(EL_CLASS__PAL, ev7_process_pal_subpacket); |
276 | 276 | ||
277 | void | 277 | void |
278 | ev7_register_error_handlers(void) | 278 | ev7_register_error_handlers(void) |
279 | { | 279 | { |
280 | int i; | 280 | int i; |
281 | 281 | ||
282 | for(i = 0; | 282 | for (i = 0; i < ARRAY_SIZE(el_ev7_pal_annotations); i++) |
283 | i<sizeof(el_ev7_pal_annotations)/sizeof(el_ev7_pal_annotations[1]); | ||
284 | i++) { | ||
285 | cdl_register_subpacket_annotation(&el_ev7_pal_annotations[i]); | 283 | cdl_register_subpacket_annotation(&el_ev7_pal_annotations[i]); |
286 | } | 284 | |
287 | cdl_register_subpacket_handler(&ev7_pal_subpacket_handler); | 285 | cdl_register_subpacket_handler(&ev7_pal_subpacket_handler); |
288 | } | 286 | } |
289 | 287 | ||
diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index e15dcf4f3dcd..73c7622b5297 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c | |||
@@ -623,12 +623,12 @@ osf_sysinfo(int command, char __user *buf, long count) | |||
623 | long len, err = -EINVAL; | 623 | long len, err = -EINVAL; |
624 | 624 | ||
625 | offset = command-1; | 625 | offset = command-1; |
626 | if (offset >= sizeof(sysinfo_table)/sizeof(char *)) { | 626 | if (offset >= ARRAY_SIZE(sysinfo_table)) { |
627 | /* Digital UNIX has a few unpublished interfaces here */ | 627 | /* Digital UNIX has a few unpublished interfaces here */ |
628 | printk("sysinfo(%d)", command); | 628 | printk("sysinfo(%d)", command); |
629 | goto out; | 629 | goto out; |
630 | } | 630 | } |
631 | 631 | ||
632 | down_read(&uts_sem); | 632 | down_read(&uts_sem); |
633 | res = sysinfo_table[offset]; | 633 | res = sysinfo_table[offset]; |
634 | len = strlen(res)+1; | 634 | len = strlen(res)+1; |
diff --git a/arch/alpha/kernel/setup.c b/arch/alpha/kernel/setup.c index 2cb9c4380113..fd4a8fa0c93d 100644 --- a/arch/alpha/kernel/setup.c +++ b/arch/alpha/kernel/setup.c | |||
@@ -114,8 +114,6 @@ struct alpha_machine_vector alpha_mv; | |||
114 | int alpha_using_srm; | 114 | int alpha_using_srm; |
115 | #endif | 115 | #endif |
116 | 116 | ||
117 | #define N(a) (sizeof(a)/sizeof(a[0])) | ||
118 | |||
119 | static struct alpha_machine_vector *get_sysvec(unsigned long, unsigned long, | 117 | static struct alpha_machine_vector *get_sysvec(unsigned long, unsigned long, |
120 | unsigned long); | 118 | unsigned long); |
121 | static struct alpha_machine_vector *get_sysvec_byname(const char *); | 119 | static struct alpha_machine_vector *get_sysvec_byname(const char *); |
@@ -240,7 +238,7 @@ reserve_std_resources(void) | |||
240 | standard_io_resources[0].start = RTC_PORT(0); | 238 | standard_io_resources[0].start = RTC_PORT(0); |
241 | standard_io_resources[0].end = RTC_PORT(0) + 0x10; | 239 | standard_io_resources[0].end = RTC_PORT(0) + 0x10; |
242 | 240 | ||
243 | for (i = 0; i < N(standard_io_resources); ++i) | 241 | for (i = 0; i < ARRAY_SIZE(standard_io_resources); ++i) |
244 | request_resource(io, standard_io_resources+i); | 242 | request_resource(io, standard_io_resources+i); |
245 | } | 243 | } |
246 | 244 | ||
@@ -918,13 +916,13 @@ get_sysvec(unsigned long type, unsigned long variation, unsigned long cpu) | |||
918 | 916 | ||
919 | /* Search the system tables first... */ | 917 | /* Search the system tables first... */ |
920 | vec = NULL; | 918 | vec = NULL; |
921 | if (type < N(systype_vecs)) { | 919 | if (type < ARRAY_SIZE(systype_vecs)) { |
922 | vec = systype_vecs[type]; | 920 | vec = systype_vecs[type]; |
923 | } else if ((type > ST_API_BIAS) && | 921 | } else if ((type > ST_API_BIAS) && |
924 | (type - ST_API_BIAS) < N(api_vecs)) { | 922 | (type - ST_API_BIAS) < ARRAY_SIZE(api_vecs)) { |
925 | vec = api_vecs[type - ST_API_BIAS]; | 923 | vec = api_vecs[type - ST_API_BIAS]; |
926 | } else if ((type > ST_UNOFFICIAL_BIAS) && | 924 | } else if ((type > ST_UNOFFICIAL_BIAS) && |
927 | (type - ST_UNOFFICIAL_BIAS) < N(unofficial_vecs)) { | 925 | (type - ST_UNOFFICIAL_BIAS) < ARRAY_SIZE(unofficial_vecs)) { |
928 | vec = unofficial_vecs[type - ST_UNOFFICIAL_BIAS]; | 926 | vec = unofficial_vecs[type - ST_UNOFFICIAL_BIAS]; |
929 | } | 927 | } |
930 | 928 | ||
@@ -938,11 +936,11 @@ get_sysvec(unsigned long type, unsigned long variation, unsigned long cpu) | |||
938 | 936 | ||
939 | switch (type) { | 937 | switch (type) { |
940 | case ST_DEC_ALCOR: | 938 | case ST_DEC_ALCOR: |
941 | if (member < N(alcor_indices)) | 939 | if (member < ARRAY_SIZE(alcor_indices)) |
942 | vec = alcor_vecs[alcor_indices[member]]; | 940 | vec = alcor_vecs[alcor_indices[member]]; |
943 | break; | 941 | break; |
944 | case ST_DEC_EB164: | 942 | case ST_DEC_EB164: |
945 | if (member < N(eb164_indices)) | 943 | if (member < ARRAY_SIZE(eb164_indices)) |
946 | vec = eb164_vecs[eb164_indices[member]]; | 944 | vec = eb164_vecs[eb164_indices[member]]; |
947 | /* PC164 may show as EB164 variation with EV56 CPU, | 945 | /* PC164 may show as EB164 variation with EV56 CPU, |
948 | but, since no true EB164 had anything but EV5... */ | 946 | but, since no true EB164 had anything but EV5... */ |
@@ -950,24 +948,24 @@ get_sysvec(unsigned long type, unsigned long variation, unsigned long cpu) | |||
950 | vec = &pc164_mv; | 948 | vec = &pc164_mv; |
951 | break; | 949 | break; |
952 | case ST_DEC_EB64P: | 950 | case ST_DEC_EB64P: |
953 | if (member < N(eb64p_indices)) | 951 | if (member < ARRAY_SIZE(eb64p_indices)) |
954 | vec = eb64p_vecs[eb64p_indices[member]]; | 952 | vec = eb64p_vecs[eb64p_indices[member]]; |
955 | break; | 953 | break; |
956 | case ST_DEC_EB66: | 954 | case ST_DEC_EB66: |
957 | if (member < N(eb66_indices)) | 955 | if (member < ARRAY_SIZE(eb66_indices)) |
958 | vec = eb66_vecs[eb66_indices[member]]; | 956 | vec = eb66_vecs[eb66_indices[member]]; |
959 | break; | 957 | break; |
960 | case ST_DEC_MARVEL: | 958 | case ST_DEC_MARVEL: |
961 | if (member < N(marvel_indices)) | 959 | if (member < ARRAY_SIZE(marvel_indices)) |
962 | vec = marvel_vecs[marvel_indices[member]]; | 960 | vec = marvel_vecs[marvel_indices[member]]; |
963 | break; | 961 | break; |
964 | case ST_DEC_TITAN: | 962 | case ST_DEC_TITAN: |
965 | vec = titan_vecs[0]; /* default */ | 963 | vec = titan_vecs[0]; /* default */ |
966 | if (member < N(titan_indices)) | 964 | if (member < ARRAY_SIZE(titan_indices)) |
967 | vec = titan_vecs[titan_indices[member]]; | 965 | vec = titan_vecs[titan_indices[member]]; |
968 | break; | 966 | break; |
969 | case ST_DEC_TSUNAMI: | 967 | case ST_DEC_TSUNAMI: |
970 | if (member < N(tsunami_indices)) | 968 | if (member < ARRAY_SIZE(tsunami_indices)) |
971 | vec = tsunami_vecs[tsunami_indices[member]]; | 969 | vec = tsunami_vecs[tsunami_indices[member]]; |
972 | break; | 970 | break; |
973 | case ST_DEC_1000: | 971 | case ST_DEC_1000: |
@@ -1039,7 +1037,7 @@ get_sysvec_byname(const char *name) | |||
1039 | 1037 | ||
1040 | size_t i; | 1038 | size_t i; |
1041 | 1039 | ||
1042 | for (i = 0; i < N(all_vecs); ++i) { | 1040 | for (i = 0; i < ARRAY_SIZE(all_vecs); ++i) { |
1043 | struct alpha_machine_vector *mv = all_vecs[i]; | 1041 | struct alpha_machine_vector *mv = all_vecs[i]; |
1044 | if (strcasecmp(mv->vector_name, name) == 0) | 1042 | if (strcasecmp(mv->vector_name, name) == 0) |
1045 | return mv; | 1043 | return mv; |
@@ -1055,13 +1053,13 @@ get_sysnames(unsigned long type, unsigned long variation, unsigned long cpu, | |||
1055 | 1053 | ||
1056 | /* If not in the tables, make it UNKNOWN, | 1054 | /* If not in the tables, make it UNKNOWN, |
1057 | else set type name to family */ | 1055 | else set type name to family */ |
1058 | if (type < N(systype_names)) { | 1056 | if (type < ARRAY_SIZE(systype_names)) { |
1059 | *type_name = systype_names[type]; | 1057 | *type_name = systype_names[type]; |
1060 | } else if ((type > ST_API_BIAS) && | 1058 | } else if ((type > ST_API_BIAS) && |
1061 | (type - ST_API_BIAS) < N(api_names)) { | 1059 | (type - ST_API_BIAS) < ARRAY_SIZE(api_names)) { |
1062 | *type_name = api_names[type - ST_API_BIAS]; | 1060 | *type_name = api_names[type - ST_API_BIAS]; |
1063 | } else if ((type > ST_UNOFFICIAL_BIAS) && | 1061 | } else if ((type > ST_UNOFFICIAL_BIAS) && |
1064 | (type - ST_UNOFFICIAL_BIAS) < N(unofficial_names)) { | 1062 | (type - ST_UNOFFICIAL_BIAS) < ARRAY_SIZE(unofficial_names)) { |
1065 | *type_name = unofficial_names[type - ST_UNOFFICIAL_BIAS]; | 1063 | *type_name = unofficial_names[type - ST_UNOFFICIAL_BIAS]; |
1066 | } else { | 1064 | } else { |
1067 | *type_name = sys_unknown; | 1065 | *type_name = sys_unknown; |
@@ -1083,7 +1081,7 @@ get_sysnames(unsigned long type, unsigned long variation, unsigned long cpu, | |||
1083 | default: /* default to variation "0" for now */ | 1081 | default: /* default to variation "0" for now */ |
1084 | break; | 1082 | break; |
1085 | case ST_DEC_EB164: | 1083 | case ST_DEC_EB164: |
1086 | if (member < N(eb164_indices)) | 1084 | if (member < ARRAY_SIZE(eb164_indices)) |
1087 | *variation_name = eb164_names[eb164_indices[member]]; | 1085 | *variation_name = eb164_names[eb164_indices[member]]; |
1088 | /* PC164 may show as EB164 variation, but with EV56 CPU, | 1086 | /* PC164 may show as EB164 variation, but with EV56 CPU, |
1089 | so, since no true EB164 had anything but EV5... */ | 1087 | so, since no true EB164 had anything but EV5... */ |
@@ -1091,32 +1089,32 @@ get_sysnames(unsigned long type, unsigned long variation, unsigned long cpu, | |||
1091 | *variation_name = eb164_names[1]; /* make it PC164 */ | 1089 | *variation_name = eb164_names[1]; /* make it PC164 */ |
1092 | break; | 1090 | break; |
1093 | case ST_DEC_ALCOR: | 1091 | case ST_DEC_ALCOR: |
1094 | if (member < N(alcor_indices)) | 1092 | if (member < ARRAY_SIZE(alcor_indices)) |
1095 | *variation_name = alcor_names[alcor_indices[member]]; | 1093 | *variation_name = alcor_names[alcor_indices[member]]; |
1096 | break; | 1094 | break; |
1097 | case ST_DEC_EB64P: | 1095 | case ST_DEC_EB64P: |
1098 | if (member < N(eb64p_indices)) | 1096 | if (member < ARRAY_SIZE(eb64p_indices)) |
1099 | *variation_name = eb64p_names[eb64p_indices[member]]; | 1097 | *variation_name = eb64p_names[eb64p_indices[member]]; |
1100 | break; | 1098 | break; |
1101 | case ST_DEC_EB66: | 1099 | case ST_DEC_EB66: |
1102 | if (member < N(eb66_indices)) | 1100 | if (member < ARRAY_SIZE(eb66_indices)) |
1103 | *variation_name = eb66_names[eb66_indices[member]]; | 1101 | *variation_name = eb66_names[eb66_indices[member]]; |
1104 | break; | 1102 | break; |
1105 | case ST_DEC_MARVEL: | 1103 | case ST_DEC_MARVEL: |
1106 | if (member < N(marvel_indices)) | 1104 | if (member < ARRAY_SIZE(marvel_indices)) |
1107 | *variation_name = marvel_names[marvel_indices[member]]; | 1105 | *variation_name = marvel_names[marvel_indices[member]]; |
1108 | break; | 1106 | break; |
1109 | case ST_DEC_RAWHIDE: | 1107 | case ST_DEC_RAWHIDE: |
1110 | if (member < N(rawhide_indices)) | 1108 | if (member < ARRAY_SIZE(rawhide_indices)) |
1111 | *variation_name = rawhide_names[rawhide_indices[member]]; | 1109 | *variation_name = rawhide_names[rawhide_indices[member]]; |
1112 | break; | 1110 | break; |
1113 | case ST_DEC_TITAN: | 1111 | case ST_DEC_TITAN: |
1114 | *variation_name = titan_names[0]; /* default */ | 1112 | *variation_name = titan_names[0]; /* default */ |
1115 | if (member < N(titan_indices)) | 1113 | if (member < ARRAY_SIZE(titan_indices)) |
1116 | *variation_name = titan_names[titan_indices[member]]; | 1114 | *variation_name = titan_names[titan_indices[member]]; |
1117 | break; | 1115 | break; |
1118 | case ST_DEC_TSUNAMI: | 1116 | case ST_DEC_TSUNAMI: |
1119 | if (member < N(tsunami_indices)) | 1117 | if (member < ARRAY_SIZE(tsunami_indices)) |
1120 | *variation_name = tsunami_names[tsunami_indices[member]]; | 1118 | *variation_name = tsunami_names[tsunami_indices[member]]; |
1121 | break; | 1119 | break; |
1122 | } | 1120 | } |
@@ -1211,7 +1209,7 @@ show_cpuinfo(struct seq_file *f, void *slot) | |||
1211 | 1209 | ||
1212 | cpu_index = (unsigned) (cpu->type - 1); | 1210 | cpu_index = (unsigned) (cpu->type - 1); |
1213 | cpu_name = "Unknown"; | 1211 | cpu_name = "Unknown"; |
1214 | if (cpu_index < N(cpu_names)) | 1212 | if (cpu_index < ARRAY_SIZE(cpu_names)) |
1215 | cpu_name = cpu_names[cpu_index]; | 1213 | cpu_name = cpu_names[cpu_index]; |
1216 | 1214 | ||
1217 | get_sysnames(hwrpb->sys_type, hwrpb->sys_variation, | 1215 | get_sysnames(hwrpb->sys_type, hwrpb->sys_variation, |
diff --git a/arch/alpha/kernel/sys_ruffian.c b/arch/alpha/kernel/sys_ruffian.c index 78c30decf3ff..5b99cf3cd69c 100644 --- a/arch/alpha/kernel/sys_ruffian.c +++ b/arch/alpha/kernel/sys_ruffian.c | |||
@@ -182,16 +182,16 @@ static unsigned long __init | |||
182 | ruffian_get_bank_size(unsigned long offset) | 182 | ruffian_get_bank_size(unsigned long offset) |
183 | { | 183 | { |
184 | unsigned long bank_addr, bank, ret = 0; | 184 | unsigned long bank_addr, bank, ret = 0; |
185 | 185 | ||
186 | /* Valid offsets are: 0x800, 0x840 and 0x880 | 186 | /* Valid offsets are: 0x800, 0x840 and 0x880 |
187 | since Ruffian only uses three banks. */ | 187 | since Ruffian only uses three banks. */ |
188 | bank_addr = (unsigned long)PYXIS_MCR + offset; | 188 | bank_addr = (unsigned long)PYXIS_MCR + offset; |
189 | bank = *(vulp)bank_addr; | 189 | bank = *(vulp)bank_addr; |
190 | 190 | ||
191 | /* Check BANK_ENABLE */ | 191 | /* Check BANK_ENABLE */ |
192 | if (bank & 0x01) { | 192 | if (bank & 0x01) { |
193 | static unsigned long size[] __initdata = { | 193 | static unsigned long size[] __initdata = { |
194 | 0x40000000UL, /* 0x00, 1G */ | 194 | 0x40000000UL, /* 0x00, 1G */ |
195 | 0x20000000UL, /* 0x02, 512M */ | 195 | 0x20000000UL, /* 0x02, 512M */ |
196 | 0x10000000UL, /* 0x04, 256M */ | 196 | 0x10000000UL, /* 0x04, 256M */ |
197 | 0x08000000UL, /* 0x06, 128M */ | 197 | 0x08000000UL, /* 0x06, 128M */ |
@@ -203,7 +203,7 @@ ruffian_get_bank_size(unsigned long offset) | |||
203 | }; | 203 | }; |
204 | 204 | ||
205 | bank = (bank & 0x1e) >> 1; | 205 | bank = (bank & 0x1e) >> 1; |
206 | if (bank < sizeof(size)/sizeof(*size)) | 206 | if (bank < ARRAY_SIZE(size)) |
207 | ret = size[bank]; | 207 | ret = size[bank]; |
208 | } | 208 | } |
209 | 209 | ||
diff --git a/arch/alpha/kernel/time.c b/arch/alpha/kernel/time.c index 50eccde2dcd8..b191cc759737 100644 --- a/arch/alpha/kernel/time.c +++ b/arch/alpha/kernel/time.c | |||
@@ -233,7 +233,7 @@ validate_cc_value(unsigned long cc) | |||
233 | index = cpu->type & 0xffffffff; | 233 | index = cpu->type & 0xffffffff; |
234 | 234 | ||
235 | /* If index out of bounds, no way to validate. */ | 235 | /* If index out of bounds, no way to validate. */ |
236 | if (index >= sizeof(cpu_hz)/sizeof(cpu_hz[0])) | 236 | if (index >= ARRAY_SIZE(cpu_hz)) |
237 | return cc; | 237 | return cc; |
238 | 238 | ||
239 | /* If index contains no data, no way to validate. */ | 239 | /* If index contains no data, no way to validate. */ |
diff --git a/arch/arm/common/gic.c b/arch/arm/common/gic.c index f3c1ebfdd0aa..f3e020f2227f 100644 --- a/arch/arm/common/gic.c +++ b/arch/arm/common/gic.c | |||
@@ -95,7 +95,8 @@ static void gic_set_cpu(unsigned int irq, cpumask_t mask_val) | |||
95 | } | 95 | } |
96 | #endif | 96 | #endif |
97 | 97 | ||
98 | static struct irqchip gic_chip = { | 98 | static struct irq_chip gic_chip = { |
99 | .name = "GIC", | ||
99 | .ack = gic_ack_irq, | 100 | .ack = gic_ack_irq, |
100 | .mask = gic_mask_irq, | 101 | .mask = gic_mask_irq, |
101 | .unmask = gic_unmask_irq, | 102 | .unmask = gic_unmask_irq, |
diff --git a/arch/arm/common/locomo.c b/arch/arm/common/locomo.c index 04de83f4f008..4e0dcaef6eb2 100644 --- a/arch/arm/common/locomo.c +++ b/arch/arm/common/locomo.c | |||
@@ -204,7 +204,8 @@ static void locomo_unmask_irq(unsigned int irq) | |||
204 | locomo_writel(r, mapbase + LOCOMO_ICR); | 204 | locomo_writel(r, mapbase + LOCOMO_ICR); |
205 | } | 205 | } |
206 | 206 | ||
207 | static struct irqchip locomo_chip = { | 207 | static struct irq_chip locomo_chip = { |
208 | .name = "LOCOMO", | ||
208 | .ack = locomo_ack_irq, | 209 | .ack = locomo_ack_irq, |
209 | .mask = locomo_mask_irq, | 210 | .mask = locomo_mask_irq, |
210 | .unmask = locomo_unmask_irq, | 211 | .unmask = locomo_unmask_irq, |
@@ -249,7 +250,8 @@ static void locomo_key_unmask_irq(unsigned int irq) | |||
249 | locomo_writel(r, mapbase + LOCOMO_KEYBOARD + LOCOMO_KIC); | 250 | locomo_writel(r, mapbase + LOCOMO_KEYBOARD + LOCOMO_KIC); |
250 | } | 251 | } |
251 | 252 | ||
252 | static struct irqchip locomo_key_chip = { | 253 | static struct irq_chip locomo_key_chip = { |
254 | .name = "LOCOMO-key", | ||
253 | .ack = locomo_key_ack_irq, | 255 | .ack = locomo_key_ack_irq, |
254 | .mask = locomo_key_mask_irq, | 256 | .mask = locomo_key_mask_irq, |
255 | .unmask = locomo_key_unmask_irq, | 257 | .unmask = locomo_key_unmask_irq, |
@@ -312,7 +314,8 @@ static void locomo_gpio_unmask_irq(unsigned int irq) | |||
312 | locomo_writel(r, mapbase + LOCOMO_GIE); | 314 | locomo_writel(r, mapbase + LOCOMO_GIE); |
313 | } | 315 | } |
314 | 316 | ||
315 | static struct irqchip locomo_gpio_chip = { | 317 | static struct irq_chip locomo_gpio_chip = { |
318 | .name = "LOCOMO-gpio", | ||
316 | .ack = locomo_gpio_ack_irq, | 319 | .ack = locomo_gpio_ack_irq, |
317 | .mask = locomo_gpio_mask_irq, | 320 | .mask = locomo_gpio_mask_irq, |
318 | .unmask = locomo_gpio_unmask_irq, | 321 | .unmask = locomo_gpio_unmask_irq, |
@@ -357,7 +360,8 @@ static void locomo_lt_unmask_irq(unsigned int irq) | |||
357 | locomo_writel(r, mapbase + LOCOMO_LTINT); | 360 | locomo_writel(r, mapbase + LOCOMO_LTINT); |
358 | } | 361 | } |
359 | 362 | ||
360 | static struct irqchip locomo_lt_chip = { | 363 | static struct irq_chip locomo_lt_chip = { |
364 | .name = "LOCOMO-lt", | ||
361 | .ack = locomo_lt_ack_irq, | 365 | .ack = locomo_lt_ack_irq, |
362 | .mask = locomo_lt_mask_irq, | 366 | .mask = locomo_lt_mask_irq, |
363 | .unmask = locomo_lt_unmask_irq, | 367 | .unmask = locomo_lt_unmask_irq, |
@@ -418,7 +422,8 @@ static void locomo_spi_unmask_irq(unsigned int irq) | |||
418 | locomo_writel(r, mapbase + LOCOMO_SPIIE); | 422 | locomo_writel(r, mapbase + LOCOMO_SPIIE); |
419 | } | 423 | } |
420 | 424 | ||
421 | static struct irqchip locomo_spi_chip = { | 425 | static struct irq_chip locomo_spi_chip = { |
426 | .name = "LOCOMO-spi", | ||
422 | .ack = locomo_spi_ack_irq, | 427 | .ack = locomo_spi_ack_irq, |
423 | .mask = locomo_spi_mask_irq, | 428 | .mask = locomo_spi_mask_irq, |
424 | .unmask = locomo_spi_unmask_irq, | 429 | .unmask = locomo_spi_unmask_irq, |
diff --git a/arch/arm/common/sa1111.c b/arch/arm/common/sa1111.c index 1cdb26a47e1f..a331c12cead9 100644 --- a/arch/arm/common/sa1111.c +++ b/arch/arm/common/sa1111.c | |||
@@ -272,7 +272,8 @@ static int sa1111_wake_lowirq(unsigned int irq, unsigned int on) | |||
272 | return 0; | 272 | return 0; |
273 | } | 273 | } |
274 | 274 | ||
275 | static struct irqchip sa1111_low_chip = { | 275 | static struct irq_chip sa1111_low_chip = { |
276 | .name = "SA1111-l", | ||
276 | .ack = sa1111_ack_irq, | 277 | .ack = sa1111_ack_irq, |
277 | .mask = sa1111_mask_lowirq, | 278 | .mask = sa1111_mask_lowirq, |
278 | .unmask = sa1111_unmask_lowirq, | 279 | .unmask = sa1111_unmask_lowirq, |
@@ -368,7 +369,8 @@ static int sa1111_wake_highirq(unsigned int irq, unsigned int on) | |||
368 | return 0; | 369 | return 0; |
369 | } | 370 | } |
370 | 371 | ||
371 | static struct irqchip sa1111_high_chip = { | 372 | static struct irq_chip sa1111_high_chip = { |
373 | .name = "SA1111-h", | ||
372 | .ack = sa1111_ack_irq, | 374 | .ack = sa1111_ack_irq, |
373 | .mask = sa1111_mask_highirq, | 375 | .mask = sa1111_mask_highirq, |
374 | .unmask = sa1111_unmask_highirq, | 376 | .unmask = sa1111_unmask_highirq, |
diff --git a/arch/arm/common/vic.c b/arch/arm/common/vic.c index a19bc4a6196d..43d278134521 100644 --- a/arch/arm/common/vic.c +++ b/arch/arm/common/vic.c | |||
@@ -39,7 +39,8 @@ static void vic_unmask_irq(unsigned int irq) | |||
39 | writel(1 << irq, base + VIC_INT_ENABLE); | 39 | writel(1 << irq, base + VIC_INT_ENABLE); |
40 | } | 40 | } |
41 | 41 | ||
42 | static struct irqchip vic_chip = { | 42 | static struct irq_chip vic_chip = { |
43 | .name = "VIC", | ||
43 | .ack = vic_mask_irq, | 44 | .ack = vic_mask_irq, |
44 | .mask = vic_mask_irq, | 45 | .mask = vic_mask_irq, |
45 | .unmask = vic_unmask_irq, | 46 | .unmask = vic_unmask_irq, |
diff --git a/arch/arm/configs/ep93xx_defconfig b/arch/arm/configs/ep93xx_defconfig index c0de6fcd488a..2948b4589a8b 100644 --- a/arch/arm/configs/ep93xx_defconfig +++ b/arch/arm/configs/ep93xx_defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.18-rc1 | 3 | # Linux kernel version: 2.6.18-rc1-git9 |
4 | # Sun Jul 9 15:21:30 2006 | 4 | # Sat Jul 15 15:08:10 2006 |
5 | # | 5 | # |
6 | CONFIG_ARM=y | 6 | CONFIG_ARM=y |
7 | CONFIG_MMU=y | 7 | CONFIG_MMU=y |
@@ -30,6 +30,7 @@ CONFIG_SWAP=y | |||
30 | CONFIG_SYSVIPC=y | 30 | CONFIG_SYSVIPC=y |
31 | # CONFIG_POSIX_MQUEUE is not set | 31 | # CONFIG_POSIX_MQUEUE is not set |
32 | # CONFIG_BSD_PROCESS_ACCT is not set | 32 | # CONFIG_BSD_PROCESS_ACCT is not set |
33 | # CONFIG_TASKSTATS is not set | ||
33 | CONFIG_SYSCTL=y | 34 | CONFIG_SYSCTL=y |
34 | # CONFIG_AUDIT is not set | 35 | # CONFIG_AUDIT is not set |
35 | CONFIG_IKCONFIG=y | 36 | CONFIG_IKCONFIG=y |
@@ -749,7 +750,7 @@ CONFIG_VIDEO_V4L2=y | |||
749 | # USB support | 750 | # USB support |
750 | # | 751 | # |
751 | CONFIG_USB_ARCH_HAS_HCD=y | 752 | CONFIG_USB_ARCH_HAS_HCD=y |
752 | # CONFIG_USB_ARCH_HAS_OHCI is not set | 753 | CONFIG_USB_ARCH_HAS_OHCI=y |
753 | # CONFIG_USB_ARCH_HAS_EHCI is not set | 754 | # CONFIG_USB_ARCH_HAS_EHCI is not set |
754 | CONFIG_USB=y | 755 | CONFIG_USB=y |
755 | CONFIG_USB_DEBUG=y | 756 | CONFIG_USB_DEBUG=y |
@@ -766,6 +767,9 @@ CONFIG_USB_DYNAMIC_MINORS=y | |||
766 | # USB Host Controller Drivers | 767 | # USB Host Controller Drivers |
767 | # | 768 | # |
768 | # CONFIG_USB_ISP116X_HCD is not set | 769 | # CONFIG_USB_ISP116X_HCD is not set |
770 | CONFIG_USB_OHCI_HCD=y | ||
771 | # CONFIG_USB_OHCI_BIG_ENDIAN is not set | ||
772 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y | ||
769 | # CONFIG_USB_SL811_HCD is not set | 773 | # CONFIG_USB_SL811_HCD is not set |
770 | 774 | ||
771 | # | 775 | # |
@@ -855,6 +859,7 @@ CONFIG_USB_SERIAL_CONSOLE=y | |||
855 | CONFIG_USB_SERIAL_PL2303=y | 859 | CONFIG_USB_SERIAL_PL2303=y |
856 | # CONFIG_USB_SERIAL_HP4X is not set | 860 | # CONFIG_USB_SERIAL_HP4X is not set |
857 | # CONFIG_USB_SERIAL_SAFE is not set | 861 | # CONFIG_USB_SERIAL_SAFE is not set |
862 | # CONFIG_USB_SERIAL_SIERRAWIRELESS is not set | ||
858 | # CONFIG_USB_SERIAL_TI is not set | 863 | # CONFIG_USB_SERIAL_TI is not set |
859 | # CONFIG_USB_SERIAL_CYBERJACK is not set | 864 | # CONFIG_USB_SERIAL_CYBERJACK is not set |
860 | # CONFIG_USB_SERIAL_XIRCOM is not set | 865 | # CONFIG_USB_SERIAL_XIRCOM is not set |
@@ -871,7 +876,7 @@ CONFIG_USB_SERIAL_PL2303=y | |||
871 | # CONFIG_USB_LEGOTOWER is not set | 876 | # CONFIG_USB_LEGOTOWER is not set |
872 | # CONFIG_USB_LCD is not set | 877 | # CONFIG_USB_LCD is not set |
873 | # CONFIG_USB_LED is not set | 878 | # CONFIG_USB_LED is not set |
874 | # CONFIG_USB_CY7C63 is not set | 879 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
875 | # CONFIG_USB_CYTHERM is not set | 880 | # CONFIG_USB_CYTHERM is not set |
876 | # CONFIG_USB_PHIDGETKIT is not set | 881 | # CONFIG_USB_PHIDGETKIT is not set |
877 | # CONFIG_USB_PHIDGETSERVO is not set | 882 | # CONFIG_USB_PHIDGETSERVO is not set |
@@ -916,6 +921,7 @@ CONFIG_RTC_INTF_DEV=y | |||
916 | # CONFIG_RTC_DRV_X1205 is not set | 921 | # CONFIG_RTC_DRV_X1205 is not set |
917 | # CONFIG_RTC_DRV_DS1307 is not set | 922 | # CONFIG_RTC_DRV_DS1307 is not set |
918 | # CONFIG_RTC_DRV_DS1553 is not set | 923 | # CONFIG_RTC_DRV_DS1553 is not set |
924 | # CONFIG_RTC_DRV_ISL1208 is not set | ||
919 | # CONFIG_RTC_DRV_DS1672 is not set | 925 | # CONFIG_RTC_DRV_DS1672 is not set |
920 | # CONFIG_RTC_DRV_DS1742 is not set | 926 | # CONFIG_RTC_DRV_DS1742 is not set |
921 | # CONFIG_RTC_DRV_PCF8563 is not set | 927 | # CONFIG_RTC_DRV_PCF8563 is not set |
@@ -1023,7 +1029,6 @@ CONFIG_SUNRPC=y | |||
1023 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1029 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
1024 | # CONFIG_SMB_FS is not set | 1030 | # CONFIG_SMB_FS is not set |
1025 | # CONFIG_CIFS is not set | 1031 | # CONFIG_CIFS is not set |
1026 | # CONFIG_CIFS_DEBUG2 is not set | ||
1027 | # CONFIG_NCP_FS is not set | 1032 | # CONFIG_NCP_FS is not set |
1028 | # CONFIG_CODA_FS is not set | 1033 | # CONFIG_CODA_FS is not set |
1029 | # CONFIG_AFS_FS is not set | 1034 | # CONFIG_AFS_FS is not set |
diff --git a/arch/arm/kernel/ecard.c b/arch/arm/kernel/ecard.c index b9a74a741d00..eca248d9eba4 100644 --- a/arch/arm/kernel/ecard.c +++ b/arch/arm/kernel/ecard.c | |||
@@ -470,7 +470,8 @@ static void ecard_irq_mask(unsigned int irqnr) | |||
470 | } | 470 | } |
471 | } | 471 | } |
472 | 472 | ||
473 | static struct irqchip ecard_chip = { | 473 | static struct irq_chip ecard_chip = { |
474 | .name = "ECARD", | ||
474 | .ack = ecard_irq_mask, | 475 | .ack = ecard_irq_mask, |
475 | .mask = ecard_irq_mask, | 476 | .mask = ecard_irq_mask, |
476 | .unmask = ecard_irq_unmask, | 477 | .unmask = ecard_irq_unmask, |
diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S index 2242f5f7cb7d..4fe386eea4b4 100644 --- a/arch/arm/kernel/head.S +++ b/arch/arm/kernel/head.S | |||
@@ -114,9 +114,9 @@ ENTRY(secondary_startup) | |||
114 | * Use the page tables supplied from __cpu_up. | 114 | * Use the page tables supplied from __cpu_up. |
115 | */ | 115 | */ |
116 | adr r4, __secondary_data | 116 | adr r4, __secondary_data |
117 | ldmia r4, {r5, r6, r13} @ address to jump to after | 117 | ldmia r4, {r5, r7, r13} @ address to jump to after |
118 | sub r4, r4, r5 @ mmu has been enabled | 118 | sub r4, r4, r5 @ mmu has been enabled |
119 | ldr r4, [r6, r4] @ get secondary_data.pgdir | 119 | ldr r4, [r7, r4] @ get secondary_data.pgdir |
120 | adr lr, __enable_mmu @ return address | 120 | adr lr, __enable_mmu @ return address |
121 | add pc, r10, #12 @ initialise processor | 121 | add pc, r10, #12 @ initialise processor |
122 | @ (return control reg) | 122 | @ (return control reg) |
@@ -125,7 +125,7 @@ ENTRY(secondary_startup) | |||
125 | * r6 = &secondary_data | 125 | * r6 = &secondary_data |
126 | */ | 126 | */ |
127 | ENTRY(__secondary_switched) | 127 | ENTRY(__secondary_switched) |
128 | ldr sp, [r6, #4] @ get secondary_data.stack | 128 | ldr sp, [r7, #4] @ get secondary_data.stack |
129 | mov fp, #0 | 129 | mov fp, #0 |
130 | b secondary_start_kernel | 130 | b secondary_start_kernel |
131 | 131 | ||
diff --git a/arch/arm/kernel/irq.c b/arch/arm/kernel/irq.c index 626feeec0ade..2e1bf830fe11 100644 --- a/arch/arm/kernel/irq.c +++ b/arch/arm/kernel/irq.c | |||
@@ -77,6 +77,7 @@ int show_interrupts(struct seq_file *p, void *v) | |||
77 | seq_printf(p, "%3d: ", i); | 77 | seq_printf(p, "%3d: ", i); |
78 | for_each_present_cpu(cpu) | 78 | for_each_present_cpu(cpu) |
79 | seq_printf(p, "%10u ", kstat_cpu(cpu).irqs[i]); | 79 | seq_printf(p, "%10u ", kstat_cpu(cpu).irqs[i]); |
80 | seq_printf(p, " %10s", irq_desc[i].chip->name ? : "-"); | ||
80 | seq_printf(p, " %s", action->name); | 81 | seq_printf(p, " %s", action->name); |
81 | for (action = action->next; action; action = action->next) | 82 | for (action = action->next; action; action = action->next) |
82 | seq_printf(p, ", %s", action->name); | 83 | seq_printf(p, ", %s", action->name); |
diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c index 35a052fc177a..4e29dd03e582 100644 --- a/arch/arm/kernel/traps.c +++ b/arch/arm/kernel/traps.c | |||
@@ -232,11 +232,8 @@ NORET_TYPE void die(const char *str, struct pt_regs *regs, int err) | |||
232 | bust_spinlocks(0); | 232 | bust_spinlocks(0); |
233 | spin_unlock_irq(&die_lock); | 233 | spin_unlock_irq(&die_lock); |
234 | 234 | ||
235 | if (panic_on_oops) { | 235 | if (panic_on_oops) |
236 | printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); | 236 | panic("Fatal exception: panic_on_oops"); |
237 | ssleep(5); | ||
238 | panic("Fatal exception"); | ||
239 | } | ||
240 | 237 | ||
241 | do_exit(SIGSEGV); | 238 | do_exit(SIGSEGV); |
242 | } | 239 | } |
diff --git a/arch/arm/mach-at91rm9200/gpio.c b/arch/arm/mach-at91rm9200/gpio.c index 5783c282ae7b..cec199fd6721 100644 --- a/arch/arm/mach-at91rm9200/gpio.c +++ b/arch/arm/mach-at91rm9200/gpio.c | |||
@@ -327,7 +327,8 @@ static int gpio_irq_type(unsigned pin, unsigned type) | |||
327 | return (type == IRQT_BOTHEDGE) ? 0 : -EINVAL; | 327 | return (type == IRQT_BOTHEDGE) ? 0 : -EINVAL; |
328 | } | 328 | } |
329 | 329 | ||
330 | static struct irqchip gpio_irqchip = { | 330 | static struct irq_chip gpio_irqchip = { |
331 | .name = "GPIO", | ||
331 | .mask = gpio_irq_mask, | 332 | .mask = gpio_irq_mask, |
332 | .unmask = gpio_irq_unmask, | 333 | .unmask = gpio_irq_unmask, |
333 | .set_type = gpio_irq_type, | 334 | .set_type = gpio_irq_type, |
diff --git a/arch/arm/mach-at91rm9200/irq.c b/arch/arm/mach-at91rm9200/irq.c index 9b0911320417..c3a5e777f9f8 100644 --- a/arch/arm/mach-at91rm9200/irq.c +++ b/arch/arm/mach-at91rm9200/irq.c | |||
@@ -114,7 +114,8 @@ void at91_irq_resume(void) | |||
114 | #define at91_aic_set_wake NULL | 114 | #define at91_aic_set_wake NULL |
115 | #endif | 115 | #endif |
116 | 116 | ||
117 | static struct irqchip at91_aic_chip = { | 117 | static struct irq_chip at91_aic_chip = { |
118 | .name = "AIC", | ||
118 | .ack = at91_aic_mask_irq, | 119 | .ack = at91_aic_mask_irq, |
119 | .mask = at91_aic_mask_irq, | 120 | .mask = at91_aic_mask_irq, |
120 | .unmask = at91_aic_unmask_irq, | 121 | .unmask = at91_aic_unmask_irq, |
diff --git a/arch/arm/mach-footbridge/cats-hw.c b/arch/arm/mach-footbridge/cats-hw.c index 5b64d5c5b967..ef6ccc8993e9 100644 --- a/arch/arm/mach-footbridge/cats-hw.c +++ b/arch/arm/mach-footbridge/cats-hw.c | |||
@@ -8,7 +8,7 @@ | |||
8 | #include <linux/ioport.h> | 8 | #include <linux/ioport.h> |
9 | #include <linux/kernel.h> | 9 | #include <linux/kernel.h> |
10 | #include <linux/init.h> | 10 | #include <linux/init.h> |
11 | #include <linux/tty.h> | 11 | #include <linux/screen_info.h> |
12 | 12 | ||
13 | #include <asm/hardware/dec21285.h> | 13 | #include <asm/hardware/dec21285.h> |
14 | #include <asm/io.h> | 14 | #include <asm/io.h> |
diff --git a/arch/arm/mach-imx/irq.c b/arch/arm/mach-imx/irq.c index a5de5f1da9f2..2688bd82c2a2 100644 --- a/arch/arm/mach-imx/irq.c +++ b/arch/arm/mach-imx/irq.c | |||
@@ -204,13 +204,15 @@ imx_gpiod_demux_handler(unsigned int irq_unused, struct irqdesc *desc, | |||
204 | imx_gpio_handler(mask, irq, desc, regs); | 204 | imx_gpio_handler(mask, irq, desc, regs); |
205 | } | 205 | } |
206 | 206 | ||
207 | static struct irqchip imx_internal_chip = { | 207 | static struct irq_chip imx_internal_chip = { |
208 | .name = "MPU", | ||
208 | .ack = imx_mask_irq, | 209 | .ack = imx_mask_irq, |
209 | .mask = imx_mask_irq, | 210 | .mask = imx_mask_irq, |
210 | .unmask = imx_unmask_irq, | 211 | .unmask = imx_unmask_irq, |
211 | }; | 212 | }; |
212 | 213 | ||
213 | static struct irqchip imx_gpio_chip = { | 214 | static struct irq_chip imx_gpio_chip = { |
215 | .name = "GPIO", | ||
214 | .ack = imx_gpio_ack_irq, | 216 | .ack = imx_gpio_ack_irq, |
215 | .mask = imx_gpio_mask_irq, | 217 | .mask = imx_gpio_mask_irq, |
216 | .unmask = imx_gpio_unmask_irq, | 218 | .unmask = imx_gpio_unmask_irq, |
diff --git a/arch/arm/mach-integrator/integrator_ap.c b/arch/arm/mach-integrator/integrator_ap.c index 6d65c96ebfd2..191c57a3b997 100644 --- a/arch/arm/mach-integrator/integrator_ap.c +++ b/arch/arm/mach-integrator/integrator_ap.c | |||
@@ -161,7 +161,8 @@ static void sc_unmask_irq(unsigned int irq) | |||
161 | writel(1 << irq, VA_IC_BASE + IRQ_ENABLE_SET); | 161 | writel(1 << irq, VA_IC_BASE + IRQ_ENABLE_SET); |
162 | } | 162 | } |
163 | 163 | ||
164 | static struct irqchip sc_chip = { | 164 | static struct irq_chip sc_chip = { |
165 | .name = "SC", | ||
165 | .ack = sc_mask_irq, | 166 | .ack = sc_mask_irq, |
166 | .mask = sc_mask_irq, | 167 | .mask = sc_mask_irq, |
167 | .unmask = sc_unmask_irq, | 168 | .unmask = sc_unmask_irq, |
diff --git a/arch/arm/mach-integrator/integrator_cp.c b/arch/arm/mach-integrator/integrator_cp.c index 9f55f5ae1044..678b6ba2b463 100644 --- a/arch/arm/mach-integrator/integrator_cp.c +++ b/arch/arm/mach-integrator/integrator_cp.c | |||
@@ -156,7 +156,8 @@ static void cic_unmask_irq(unsigned int irq) | |||
156 | cic_writel(1 << irq, INTCP_VA_CIC_BASE + IRQ_ENABLE_SET); | 156 | cic_writel(1 << irq, INTCP_VA_CIC_BASE + IRQ_ENABLE_SET); |
157 | } | 157 | } |
158 | 158 | ||
159 | static struct irqchip cic_chip = { | 159 | static struct irq_chip cic_chip = { |
160 | .name = "CIC", | ||
160 | .ack = cic_mask_irq, | 161 | .ack = cic_mask_irq, |
161 | .mask = cic_mask_irq, | 162 | .mask = cic_mask_irq, |
162 | .unmask = cic_unmask_irq, | 163 | .unmask = cic_unmask_irq, |
@@ -174,7 +175,8 @@ static void pic_unmask_irq(unsigned int irq) | |||
174 | pic_writel(1 << irq, INTCP_VA_PIC_BASE + IRQ_ENABLE_SET); | 175 | pic_writel(1 << irq, INTCP_VA_PIC_BASE + IRQ_ENABLE_SET); |
175 | } | 176 | } |
176 | 177 | ||
177 | static struct irqchip pic_chip = { | 178 | static struct irq_chip pic_chip = { |
179 | .name = "PIC", | ||
178 | .ack = pic_mask_irq, | 180 | .ack = pic_mask_irq, |
179 | .mask = pic_mask_irq, | 181 | .mask = pic_mask_irq, |
180 | .unmask = pic_unmask_irq, | 182 | .unmask = pic_unmask_irq, |
@@ -192,7 +194,8 @@ static void sic_unmask_irq(unsigned int irq) | |||
192 | sic_writel(1 << irq, INTCP_VA_SIC_BASE + IRQ_ENABLE_SET); | 194 | sic_writel(1 << irq, INTCP_VA_SIC_BASE + IRQ_ENABLE_SET); |
193 | } | 195 | } |
194 | 196 | ||
195 | static struct irqchip sic_chip = { | 197 | static struct irq_chip sic_chip = { |
198 | .name = "SIC", | ||
196 | .ack = sic_mask_irq, | 199 | .ack = sic_mask_irq, |
197 | .mask = sic_mask_irq, | 200 | .mask = sic_mask_irq, |
198 | .unmask = sic_unmask_irq, | 201 | .unmask = sic_unmask_irq, |
diff --git a/arch/arm/mach-iop3xx/iop321-irq.c b/arch/arm/mach-iop3xx/iop321-irq.c index d42aae6aef03..88ac333472c8 100644 --- a/arch/arm/mach-iop3xx/iop321-irq.c +++ b/arch/arm/mach-iop3xx/iop321-irq.c | |||
@@ -52,7 +52,8 @@ iop321_irq_unmask (unsigned int irq) | |||
52 | intctl_write(iop321_mask); | 52 | intctl_write(iop321_mask); |
53 | } | 53 | } |
54 | 54 | ||
55 | struct irqchip ext_chip = { | 55 | struct irq_chip ext_chip = { |
56 | .name = "IOP", | ||
56 | .ack = iop321_irq_mask, | 57 | .ack = iop321_irq_mask, |
57 | .mask = iop321_irq_mask, | 58 | .mask = iop321_irq_mask, |
58 | .unmask = iop321_irq_unmask, | 59 | .unmask = iop321_irq_unmask, |
diff --git a/arch/arm/mach-iop3xx/iop331-irq.c b/arch/arm/mach-iop3xx/iop331-irq.c index f4d4321737a4..cab11722ced2 100644 --- a/arch/arm/mach-iop3xx/iop331-irq.c +++ b/arch/arm/mach-iop3xx/iop331-irq.c | |||
@@ -77,13 +77,15 @@ iop331_irq_unmask2(unsigned int irq) | |||
77 | intctl_write1(iop331_mask1); | 77 | intctl_write1(iop331_mask1); |
78 | } | 78 | } |
79 | 79 | ||
80 | struct irqchip iop331_irqchip1 = { | 80 | struct irq_chip iop331_irqchip1 = { |
81 | .name = "IOP-1", | ||
81 | .ack = iop331_irq_mask1, | 82 | .ack = iop331_irq_mask1, |
82 | .mask = iop331_irq_mask1, | 83 | .mask = iop331_irq_mask1, |
83 | .unmask = iop331_irq_unmask1, | 84 | .unmask = iop331_irq_unmask1, |
84 | }; | 85 | }; |
85 | 86 | ||
86 | struct irqchip iop331_irqchip2 = { | 87 | struct irq_chip iop331_irqchip2 = { |
88 | .name = "IOP-2", | ||
87 | .ack = iop331_irq_mask2, | 89 | .ack = iop331_irq_mask2, |
88 | .mask = iop331_irq_mask2, | 90 | .mask = iop331_irq_mask2, |
89 | .unmask = iop331_irq_unmask2, | 91 | .unmask = iop331_irq_unmask2, |
diff --git a/arch/arm/mach-lh7a40x/arch-kev7a400.c b/arch/arm/mach-lh7a40x/arch-kev7a400.c index 2cccc27c62e4..4f2ab48800a5 100644 --- a/arch/arm/mach-lh7a40x/arch-kev7a400.c +++ b/arch/arm/mach-lh7a40x/arch-kev7a400.c | |||
@@ -63,7 +63,8 @@ static void kev7a400_unmask_cpld_irq (u32 irq) | |||
63 | CPLD_WR_PB_INT_MASK = CPLD_IRQ_mask; | 63 | CPLD_WR_PB_INT_MASK = CPLD_IRQ_mask; |
64 | } | 64 | } |
65 | 65 | ||
66 | static struct irqchip kev7a400_cpld_chip = { | 66 | static struct irq_chip kev7a400_cpld_chip = { |
67 | .name = "CPLD", | ||
67 | .ack = kev7a400_ack_cpld_irq, | 68 | .ack = kev7a400_ack_cpld_irq, |
68 | .mask = kev7a400_mask_cpld_irq, | 69 | .mask = kev7a400_mask_cpld_irq, |
69 | .unmask = kev7a400_unmask_cpld_irq, | 70 | .unmask = kev7a400_unmask_cpld_irq, |
diff --git a/arch/arm/mach-lh7a40x/arch-lpd7a40x.c b/arch/arm/mach-lh7a40x/arch-lpd7a40x.c index 35c3606a2079..a6910114b24c 100644 --- a/arch/arm/mach-lh7a40x/arch-lpd7a40x.c +++ b/arch/arm/mach-lh7a40x/arch-lpd7a40x.c | |||
@@ -200,7 +200,8 @@ static void lh7a40x_unmask_cpld_irq (u32 irq) | |||
200 | } | 200 | } |
201 | } | 201 | } |
202 | 202 | ||
203 | static struct irqchip lpd7a40x_cpld_chip = { | 203 | static struct irq_chip lpd7a40x_cpld_chip = { |
204 | .name = "CPLD", | ||
204 | .ack = lh7a40x_ack_cpld_irq, | 205 | .ack = lh7a40x_ack_cpld_irq, |
205 | .mask = lh7a40x_mask_cpld_irq, | 206 | .mask = lh7a40x_mask_cpld_irq, |
206 | .unmask = lh7a40x_unmask_cpld_irq, | 207 | .unmask = lh7a40x_unmask_cpld_irq, |
diff --git a/arch/arm/mach-lh7a40x/irq-kev7a400.c b/arch/arm/mach-lh7a40x/irq-kev7a400.c index 8535764d89ca..f9b3fe9174a5 100644 --- a/arch/arm/mach-lh7a40x/irq-kev7a400.c +++ b/arch/arm/mach-lh7a40x/irq-kev7a400.c | |||
@@ -43,7 +43,8 @@ lh7a400_unmask_cpld_irq (u32 irq) | |||
43 | } | 43 | } |
44 | 44 | ||
45 | static struct | 45 | static struct |
46 | irqchip lh7a400_cpld_chip = { | 46 | irq_chip lh7a400_cpld_chip = { |
47 | .name = "CPLD", | ||
47 | .ack = lh7a400_ack_cpld_irq, | 48 | .ack = lh7a400_ack_cpld_irq, |
48 | .mask = lh7a400_mask_cpld_irq, | 49 | .mask = lh7a400_mask_cpld_irq, |
49 | .unmask = lh7a400_unmask_cpld_irq, | 50 | .unmask = lh7a400_unmask_cpld_irq, |
diff --git a/arch/arm/mach-lh7a40x/irq-lh7a400.c b/arch/arm/mach-lh7a40x/irq-lh7a400.c index f9fdefef6d6f..091b2dc58d25 100644 --- a/arch/arm/mach-lh7a40x/irq-lh7a400.c +++ b/arch/arm/mach-lh7a40x/irq-lh7a400.c | |||
@@ -38,13 +38,15 @@ static void lh7a400_ack_gpio_irq (u32 irq) | |||
38 | INTC_INTENC = (1 << irq); | 38 | INTC_INTENC = (1 << irq); |
39 | } | 39 | } |
40 | 40 | ||
41 | static struct irqchip lh7a400_internal_chip = { | 41 | static struct irq_chip lh7a400_internal_chip = { |
42 | .name = "MPU", | ||
42 | .ack = lh7a400_mask_irq, /* Level triggering -> mask is ack */ | 43 | .ack = lh7a400_mask_irq, /* Level triggering -> mask is ack */ |
43 | .mask = lh7a400_mask_irq, | 44 | .mask = lh7a400_mask_irq, |
44 | .unmask = lh7a400_unmask_irq, | 45 | .unmask = lh7a400_unmask_irq, |
45 | }; | 46 | }; |
46 | 47 | ||
47 | static struct irqchip lh7a400_gpio_chip = { | 48 | static struct irq_chip lh7a400_gpio_chip = { |
49 | .name = "GPIO", | ||
48 | .ack = lh7a400_ack_gpio_irq, | 50 | .ack = lh7a400_ack_gpio_irq, |
49 | .mask = lh7a400_mask_irq, | 51 | .mask = lh7a400_mask_irq, |
50 | .unmask = lh7a400_unmask_irq, | 52 | .unmask = lh7a400_unmask_irq, |
diff --git a/arch/arm/mach-lh7a40x/irq-lh7a404.c b/arch/arm/mach-lh7a40x/irq-lh7a404.c index 2685a81454d2..7059b983724f 100644 --- a/arch/arm/mach-lh7a40x/irq-lh7a404.c +++ b/arch/arm/mach-lh7a40x/irq-lh7a404.c | |||
@@ -76,25 +76,29 @@ static void lh7a404_vic2_ack_gpio_irq (u32 irq) | |||
76 | VIC2_INTENCLR = (1 << irq); | 76 | VIC2_INTENCLR = (1 << irq); |
77 | } | 77 | } |
78 | 78 | ||
79 | static struct irqchip lh7a404_vic1_chip = { | 79 | static struct irq_chip lh7a404_vic1_chip = { |
80 | .name = "VIC1", | ||
80 | .ack = lh7a404_vic1_mask_irq, /* Because level-triggered */ | 81 | .ack = lh7a404_vic1_mask_irq, /* Because level-triggered */ |
81 | .mask = lh7a404_vic1_mask_irq, | 82 | .mask = lh7a404_vic1_mask_irq, |
82 | .unmask = lh7a404_vic1_unmask_irq, | 83 | .unmask = lh7a404_vic1_unmask_irq, |
83 | }; | 84 | }; |
84 | 85 | ||
85 | static struct irqchip lh7a404_vic2_chip = { | 86 | static struct irq_chip lh7a404_vic2_chip = { |
87 | .name = "VIC2", | ||
86 | .ack = lh7a404_vic2_mask_irq, /* Because level-triggered */ | 88 | .ack = lh7a404_vic2_mask_irq, /* Because level-triggered */ |
87 | .mask = lh7a404_vic2_mask_irq, | 89 | .mask = lh7a404_vic2_mask_irq, |
88 | .unmask = lh7a404_vic2_unmask_irq, | 90 | .unmask = lh7a404_vic2_unmask_irq, |
89 | }; | 91 | }; |
90 | 92 | ||
91 | static struct irqchip lh7a404_gpio_vic1_chip = { | 93 | static struct irq_chip lh7a404_gpio_vic1_chip = { |
94 | .name = "GPIO-VIC1", | ||
92 | .ack = lh7a404_vic1_ack_gpio_irq, | 95 | .ack = lh7a404_vic1_ack_gpio_irq, |
93 | .mask = lh7a404_vic1_mask_irq, | 96 | .mask = lh7a404_vic1_mask_irq, |
94 | .unmask = lh7a404_vic1_unmask_irq, | 97 | .unmask = lh7a404_vic1_unmask_irq, |
95 | }; | 98 | }; |
96 | 99 | ||
97 | static struct irqchip lh7a404_gpio_vic2_chip = { | 100 | static struct irq_chip lh7a404_gpio_vic2_chip = { |
101 | .name = "GPIO-VIC2", | ||
98 | .ack = lh7a404_vic2_ack_gpio_irq, | 102 | .ack = lh7a404_vic2_ack_gpio_irq, |
99 | .mask = lh7a404_vic2_mask_irq, | 103 | .mask = lh7a404_vic2_mask_irq, |
100 | .unmask = lh7a404_vic2_unmask_irq, | 104 | .unmask = lh7a404_vic2_unmask_irq, |
diff --git a/arch/arm/mach-lh7a40x/irq-lpd7a40x.c b/arch/arm/mach-lh7a40x/irq-lpd7a40x.c index dcb4e17b9419..d6055dde6468 100644 --- a/arch/arm/mach-lh7a40x/irq-lpd7a40x.c +++ b/arch/arm/mach-lh7a40x/irq-lpd7a40x.c | |||
@@ -50,7 +50,8 @@ static void lh7a40x_unmask_cpld_irq (u32 irq) | |||
50 | } | 50 | } |
51 | } | 51 | } |
52 | 52 | ||
53 | static struct irqchip lh7a40x_cpld_chip = { | 53 | static struct irq_chip lh7a40x_cpld_chip = { |
54 | .name = "CPLD", | ||
54 | .ack = lh7a40x_ack_cpld_irq, | 55 | .ack = lh7a40x_ack_cpld_irq, |
55 | .mask = lh7a40x_mask_cpld_irq, | 56 | .mask = lh7a40x_mask_cpld_irq, |
56 | .unmask = lh7a40x_unmask_cpld_irq, | 57 | .unmask = lh7a40x_unmask_cpld_irq, |
diff --git a/arch/arm/mach-omap1/fpga.c b/arch/arm/mach-omap1/fpga.c index 34eb79ee6e61..efe9bfc6e55f 100644 --- a/arch/arm/mach-omap1/fpga.c +++ b/arch/arm/mach-omap1/fpga.c | |||
@@ -106,14 +106,16 @@ void innovator_fpga_IRQ_demux(unsigned int irq, struct irqdesc *desc, | |||
106 | } | 106 | } |
107 | } | 107 | } |
108 | 108 | ||
109 | static struct irqchip omap_fpga_irq_ack = { | 109 | static struct irq_chip omap_fpga_irq_ack = { |
110 | .name = "FPGA-ack", | ||
110 | .ack = fpga_mask_ack_irq, | 111 | .ack = fpga_mask_ack_irq, |
111 | .mask = fpga_mask_irq, | 112 | .mask = fpga_mask_irq, |
112 | .unmask = fpga_unmask_irq, | 113 | .unmask = fpga_unmask_irq, |
113 | }; | 114 | }; |
114 | 115 | ||
115 | 116 | ||
116 | static struct irqchip omap_fpga_irq = { | 117 | static struct irq_chip omap_fpga_irq = { |
118 | .name = "FPGA", | ||
117 | .ack = fpga_ack_irq, | 119 | .ack = fpga_ack_irq, |
118 | .mask = fpga_mask_irq, | 120 | .mask = fpga_mask_irq, |
119 | .unmask = fpga_unmask_irq, | 121 | .unmask = fpga_unmask_irq, |
diff --git a/arch/arm/mach-omap1/irq.c b/arch/arm/mach-omap1/irq.c index 9e039845b50e..3ea140bb9eba 100644 --- a/arch/arm/mach-omap1/irq.c +++ b/arch/arm/mach-omap1/irq.c | |||
@@ -168,7 +168,8 @@ static struct omap_irq_bank omap1610_irq_banks[] = { | |||
168 | }; | 168 | }; |
169 | #endif | 169 | #endif |
170 | 170 | ||
171 | static struct irqchip omap_irq_chip = { | 171 | static struct irq_chip omap_irq_chip = { |
172 | .name = "MPU", | ||
172 | .ack = omap_mask_ack_irq, | 173 | .ack = omap_mask_ack_irq, |
173 | .mask = omap_mask_irq, | 174 | .mask = omap_mask_irq, |
174 | .unmask = omap_unmask_irq, | 175 | .unmask = omap_unmask_irq, |
diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c index 3eed6a737bf8..dfc3b35cc1ff 100644 --- a/arch/arm/mach-omap2/irq.c +++ b/arch/arm/mach-omap2/irq.c | |||
@@ -94,7 +94,8 @@ static void omap_mask_ack_irq(unsigned int irq) | |||
94 | omap_ack_irq(irq); | 94 | omap_ack_irq(irq); |
95 | } | 95 | } |
96 | 96 | ||
97 | static struct irqchip omap_irq_chip = { | 97 | static struct irq_chip omap_irq_chip = { |
98 | .name = "INTC", | ||
98 | .ack = omap_mask_ack_irq, | 99 | .ack = omap_mask_ack_irq, |
99 | .mask = omap_mask_irq, | 100 | .mask = omap_mask_irq, |
100 | .unmask = omap_unmask_irq, | 101 | .unmask = omap_unmask_irq, |
diff --git a/arch/arm/mach-pxa/irq.c b/arch/arm/mach-pxa/irq.c index d9635ff4b10c..12141e2a50cc 100644 --- a/arch/arm/mach-pxa/irq.c +++ b/arch/arm/mach-pxa/irq.c | |||
@@ -39,7 +39,8 @@ static void pxa_unmask_low_irq(unsigned int irq) | |||
39 | ICMR |= (1 << (irq + PXA_IRQ_SKIP)); | 39 | ICMR |= (1 << (irq + PXA_IRQ_SKIP)); |
40 | } | 40 | } |
41 | 41 | ||
42 | static struct irqchip pxa_internal_chip_low = { | 42 | static struct irq_chip pxa_internal_chip_low = { |
43 | .name = "SC", | ||
43 | .ack = pxa_mask_low_irq, | 44 | .ack = pxa_mask_low_irq, |
44 | .mask = pxa_mask_low_irq, | 45 | .mask = pxa_mask_low_irq, |
45 | .unmask = pxa_unmask_low_irq, | 46 | .unmask = pxa_unmask_low_irq, |
@@ -61,7 +62,8 @@ static void pxa_unmask_high_irq(unsigned int irq) | |||
61 | ICMR2 |= (1 << (irq - 32 + PXA_IRQ_SKIP)); | 62 | ICMR2 |= (1 << (irq - 32 + PXA_IRQ_SKIP)); |
62 | } | 63 | } |
63 | 64 | ||
64 | static struct irqchip pxa_internal_chip_high = { | 65 | static struct irq_chip pxa_internal_chip_high = { |
66 | .name = "SC-hi", | ||
65 | .ack = pxa_mask_high_irq, | 67 | .ack = pxa_mask_high_irq, |
66 | .mask = pxa_mask_high_irq, | 68 | .mask = pxa_mask_high_irq, |
67 | .unmask = pxa_unmask_high_irq, | 69 | .unmask = pxa_unmask_high_irq, |
@@ -129,7 +131,8 @@ static void pxa_ack_low_gpio(unsigned int irq) | |||
129 | GEDR0 = (1 << (irq - IRQ_GPIO0)); | 131 | GEDR0 = (1 << (irq - IRQ_GPIO0)); |
130 | } | 132 | } |
131 | 133 | ||
132 | static struct irqchip pxa_low_gpio_chip = { | 134 | static struct irq_chip pxa_low_gpio_chip = { |
135 | .name = "GPIO-l", | ||
133 | .ack = pxa_ack_low_gpio, | 136 | .ack = pxa_ack_low_gpio, |
134 | .mask = pxa_mask_low_irq, | 137 | .mask = pxa_mask_low_irq, |
135 | .unmask = pxa_unmask_low_irq, | 138 | .unmask = pxa_unmask_low_irq, |
@@ -237,7 +240,8 @@ static void pxa_unmask_muxed_gpio(unsigned int irq) | |||
237 | GFER(gpio) = GPIO_IRQ_falling_edge[idx] & GPIO_IRQ_mask[idx]; | 240 | GFER(gpio) = GPIO_IRQ_falling_edge[idx] & GPIO_IRQ_mask[idx]; |
238 | } | 241 | } |
239 | 242 | ||
240 | static struct irqchip pxa_muxed_gpio_chip = { | 243 | static struct irq_chip pxa_muxed_gpio_chip = { |
244 | .name = "GPIO", | ||
241 | .ack = pxa_ack_muxed_gpio, | 245 | .ack = pxa_ack_muxed_gpio, |
242 | .mask = pxa_mask_muxed_gpio, | 246 | .mask = pxa_mask_muxed_gpio, |
243 | .unmask = pxa_unmask_muxed_gpio, | 247 | .unmask = pxa_unmask_muxed_gpio, |
diff --git a/arch/arm/mach-pxa/lpd270.c b/arch/arm/mach-pxa/lpd270.c index 1a5f5c21481e..12479ae26db2 100644 --- a/arch/arm/mach-pxa/lpd270.c +++ b/arch/arm/mach-pxa/lpd270.c | |||
@@ -68,7 +68,8 @@ static void lpd270_unmask_irq(unsigned int irq) | |||
68 | __raw_writew(lpd270_irq_enabled, LPD270_INT_MASK); | 68 | __raw_writew(lpd270_irq_enabled, LPD270_INT_MASK); |
69 | } | 69 | } |
70 | 70 | ||
71 | static struct irqchip lpd270_irq_chip = { | 71 | static struct irq_chip lpd270_irq_chip = { |
72 | .name = "CPLD", | ||
72 | .ack = lpd270_mask_irq, | 73 | .ack = lpd270_mask_irq, |
73 | .mask = lpd270_mask_irq, | 74 | .mask = lpd270_mask_irq, |
74 | .unmask = lpd270_unmask_irq, | 75 | .unmask = lpd270_unmask_irq, |
diff --git a/arch/arm/mach-pxa/lubbock.c b/arch/arm/mach-pxa/lubbock.c index 6a9a669d60de..83ff5cee64d9 100644 --- a/arch/arm/mach-pxa/lubbock.c +++ b/arch/arm/mach-pxa/lubbock.c | |||
@@ -78,7 +78,8 @@ static void lubbock_unmask_irq(unsigned int irq) | |||
78 | LUB_IRQ_MASK_EN = (lubbock_irq_enabled |= (1 << lubbock_irq)); | 78 | LUB_IRQ_MASK_EN = (lubbock_irq_enabled |= (1 << lubbock_irq)); |
79 | } | 79 | } |
80 | 80 | ||
81 | static struct irqchip lubbock_irq_chip = { | 81 | static struct irq_chip lubbock_irq_chip = { |
82 | .name = "FPGA", | ||
82 | .ack = lubbock_mask_irq, | 83 | .ack = lubbock_mask_irq, |
83 | .mask = lubbock_mask_irq, | 84 | .mask = lubbock_mask_irq, |
84 | .unmask = lubbock_unmask_irq, | 85 | .unmask = lubbock_unmask_irq, |
diff --git a/arch/arm/mach-pxa/mainstone.c b/arch/arm/mach-pxa/mainstone.c index 21ddf3de2f6e..a7e9b96f258a 100644 --- a/arch/arm/mach-pxa/mainstone.c +++ b/arch/arm/mach-pxa/mainstone.c | |||
@@ -64,7 +64,8 @@ static void mainstone_unmask_irq(unsigned int irq) | |||
64 | MST_INTMSKENA = (mainstone_irq_enabled |= (1 << mainstone_irq)); | 64 | MST_INTMSKENA = (mainstone_irq_enabled |= (1 << mainstone_irq)); |
65 | } | 65 | } |
66 | 66 | ||
67 | static struct irqchip mainstone_irq_chip = { | 67 | static struct irq_chip mainstone_irq_chip = { |
68 | .name = "FPGA", | ||
68 | .ack = mainstone_mask_irq, | 69 | .ack = mainstone_mask_irq, |
69 | .mask = mainstone_mask_irq, | 70 | .mask = mainstone_mask_irq, |
70 | .unmask = mainstone_unmask_irq, | 71 | .unmask = mainstone_unmask_irq, |
diff --git a/arch/arm/mach-s3c2410/mach-anubis.c b/arch/arm/mach-s3c2410/mach-anubis.c index 4a92d6f92d6b..60641d452db3 100644 --- a/arch/arm/mach-s3c2410/mach-anubis.c +++ b/arch/arm/mach-s3c2410/mach-anubis.c | |||
@@ -60,11 +60,12 @@ static struct map_desc anubis_iodesc[] __initdata = { | |||
60 | .virtual = (u32)S3C24XX_VA_ISA_BYTE, | 60 | .virtual = (u32)S3C24XX_VA_ISA_BYTE, |
61 | .pfn = __phys_to_pfn(0x0), | 61 | .pfn = __phys_to_pfn(0x0), |
62 | .length = SZ_4M, | 62 | .length = SZ_4M, |
63 | .type = MT_DEVICE | 63 | .type = MT_DEVICE, |
64 | }, { | 64 | }, { |
65 | .virtual = (u32)S3C24XX_VA_ISA_WORD, | 65 | .virtual = (u32)S3C24XX_VA_ISA_WORD, |
66 | .pfn = __phys_to_pfn(0x0), | 66 | .pfn = __phys_to_pfn(0x0), |
67 | .length = SZ_4M, MT_DEVICE | 67 | .length = SZ_4M, |
68 | .type = MT_DEVICE, | ||
68 | }, | 69 | }, |
69 | 70 | ||
70 | /* we could possibly compress the next set down into a set of smaller tables | 71 | /* we could possibly compress the next set down into a set of smaller tables |
@@ -78,36 +79,12 @@ static struct map_desc anubis_iodesc[] __initdata = { | |||
78 | .virtual = (u32)ANUBIS_VA_CTRL1, | 79 | .virtual = (u32)ANUBIS_VA_CTRL1, |
79 | .pfn = __phys_to_pfn(ANUBIS_PA_CTRL1), | 80 | .pfn = __phys_to_pfn(ANUBIS_PA_CTRL1), |
80 | .length = SZ_4K, | 81 | .length = SZ_4K, |
81 | .type = MT_DEVICE | 82 | .type = MT_DEVICE, |
82 | }, { | 83 | }, { |
83 | .virtual = (u32)ANUBIS_VA_CTRL2, | 84 | .virtual = (u32)ANUBIS_VA_CTRL2, |
84 | .pfn = __phys_to_pfn(ANUBIS_PA_CTRL2), | 85 | .pfn = __phys_to_pfn(ANUBIS_PA_CTRL2), |
85 | .length = SZ_4K, | 86 | .length = SZ_4K, |
86 | .type =MT_DEVICE | 87 | .type = MT_DEVICE, |
87 | }, | ||
88 | |||
89 | /* IDE drives */ | ||
90 | |||
91 | { | ||
92 | .virtual = (u32)ANUBIS_IDEPRI, | ||
93 | .pfn = __phys_to_pfn(S3C2410_CS3), | ||
94 | .length = SZ_1M, | ||
95 | .type = MT_DEVICE | ||
96 | }, { | ||
97 | .virtual = (u32)ANUBIS_IDEPRIAUX, | ||
98 | .pfn = __phys_to_pfn(S3C2410_CS3+(1<<26)), | ||
99 | .length = SZ_1M, | ||
100 | .type = MT_DEVICE | ||
101 | }, { | ||
102 | .virtual = (u32)ANUBIS_IDESEC, | ||
103 | .pfn = __phys_to_pfn(S3C2410_CS4), | ||
104 | .length = SZ_1M, | ||
105 | .type = MT_DEVICE | ||
106 | }, { | ||
107 | .virtual = (u32)ANUBIS_IDESECAUX, | ||
108 | .pfn = __phys_to_pfn(S3C2410_CS4+(1<<26)), | ||
109 | .length = SZ_1M, | ||
110 | .type = MT_DEVICE | ||
111 | }, | 88 | }, |
112 | }; | 89 | }; |
113 | 90 | ||
@@ -126,7 +103,7 @@ static struct s3c24xx_uart_clksrc anubis_serial_clocks[] = { | |||
126 | .name = "pclk", | 103 | .name = "pclk", |
127 | .divisor = 1, | 104 | .divisor = 1, |
128 | .min_baud = 0, | 105 | .min_baud = 0, |
129 | .max_baud = 0. | 106 | .max_baud = 0, |
130 | } | 107 | } |
131 | }; | 108 | }; |
132 | 109 | ||
@@ -139,7 +116,7 @@ static struct s3c2410_uartcfg anubis_uartcfgs[] __initdata = { | |||
139 | .ulcon = ULCON, | 116 | .ulcon = ULCON, |
140 | .ufcon = UFCON, | 117 | .ufcon = UFCON, |
141 | .clocks = anubis_serial_clocks, | 118 | .clocks = anubis_serial_clocks, |
142 | .clocks_size = ARRAY_SIZE(anubis_serial_clocks) | 119 | .clocks_size = ARRAY_SIZE(anubis_serial_clocks), |
143 | }, | 120 | }, |
144 | [1] = { | 121 | [1] = { |
145 | .hwport = 2, | 122 | .hwport = 2, |
@@ -148,7 +125,7 @@ static struct s3c2410_uartcfg anubis_uartcfgs[] __initdata = { | |||
148 | .ulcon = ULCON, | 125 | .ulcon = ULCON, |
149 | .ufcon = UFCON, | 126 | .ufcon = UFCON, |
150 | .clocks = anubis_serial_clocks, | 127 | .clocks = anubis_serial_clocks, |
151 | .clocks_size = ARRAY_SIZE(anubis_serial_clocks) | 128 | .clocks_size = ARRAY_SIZE(anubis_serial_clocks), |
152 | }, | 129 | }, |
153 | }; | 130 | }; |
154 | 131 | ||
@@ -162,7 +139,7 @@ static struct mtd_partition anubis_default_nand_part[] = { | |||
162 | [0] = { | 139 | [0] = { |
163 | .name = "Boot Agent", | 140 | .name = "Boot Agent", |
164 | .size = SZ_16K, | 141 | .size = SZ_16K, |
165 | .offset = 0 | 142 | .offset = 0, |
166 | }, | 143 | }, |
167 | [1] = { | 144 | [1] = { |
168 | .name = "/boot", | 145 | .name = "/boot", |
@@ -194,21 +171,21 @@ static struct s3c2410_nand_set anubis_nand_sets[] = { | |||
194 | .nr_chips = 1, | 171 | .nr_chips = 1, |
195 | .nr_map = external_map, | 172 | .nr_map = external_map, |
196 | .nr_partitions = ARRAY_SIZE(anubis_default_nand_part), | 173 | .nr_partitions = ARRAY_SIZE(anubis_default_nand_part), |
197 | .partitions = anubis_default_nand_part | 174 | .partitions = anubis_default_nand_part, |
198 | }, | 175 | }, |
199 | [0] = { | 176 | [0] = { |
200 | .name = "chip0", | 177 | .name = "chip0", |
201 | .nr_chips = 1, | 178 | .nr_chips = 1, |
202 | .nr_map = chip0_map, | 179 | .nr_map = chip0_map, |
203 | .nr_partitions = ARRAY_SIZE(anubis_default_nand_part), | 180 | .nr_partitions = ARRAY_SIZE(anubis_default_nand_part), |
204 | .partitions = anubis_default_nand_part | 181 | .partitions = anubis_default_nand_part, |
205 | }, | 182 | }, |
206 | [2] = { | 183 | [2] = { |
207 | .name = "chip1", | 184 | .name = "chip1", |
208 | .nr_chips = 1, | 185 | .nr_chips = 1, |
209 | .nr_map = chip1_map, | 186 | .nr_map = chip1_map, |
210 | .nr_partitions = ARRAY_SIZE(anubis_default_nand_part), | 187 | .nr_partitions = ARRAY_SIZE(anubis_default_nand_part), |
211 | .partitions = anubis_default_nand_part | 188 | .partitions = anubis_default_nand_part, |
212 | }, | 189 | }, |
213 | }; | 190 | }; |
214 | 191 | ||
@@ -313,7 +290,7 @@ static struct s3c24xx_board anubis_board __initdata = { | |||
313 | .devices = anubis_devices, | 290 | .devices = anubis_devices, |
314 | .devices_count = ARRAY_SIZE(anubis_devices), | 291 | .devices_count = ARRAY_SIZE(anubis_devices), |
315 | .clocks = anubis_clocks, | 292 | .clocks = anubis_clocks, |
316 | .clocks_count = ARRAY_SIZE(anubis_clocks) | 293 | .clocks_count = ARRAY_SIZE(anubis_clocks), |
317 | }; | 294 | }; |
318 | 295 | ||
319 | static void __init anubis_map_io(void) | 296 | static void __init anubis_map_io(void) |
diff --git a/arch/arm/mach-s3c2410/mach-osiris.c b/arch/arm/mach-s3c2410/mach-osiris.c index 858fd03c6bc5..e193ba69e652 100644 --- a/arch/arm/mach-s3c2410/mach-osiris.c +++ b/arch/arm/mach-s3c2410/mach-osiris.c | |||
@@ -67,12 +67,12 @@ static struct map_desc osiris_iodesc[] __initdata = { | |||
67 | .virtual = (u32)OSIRIS_VA_CTRL1, | 67 | .virtual = (u32)OSIRIS_VA_CTRL1, |
68 | .pfn = __phys_to_pfn(OSIRIS_PA_CTRL1), | 68 | .pfn = __phys_to_pfn(OSIRIS_PA_CTRL1), |
69 | .length = SZ_16K, | 69 | .length = SZ_16K, |
70 | .type = MT_DEVICE | 70 | .type = MT_DEVICE, |
71 | }, { | 71 | }, { |
72 | .virtual = (u32)OSIRIS_VA_CTRL2, | 72 | .virtual = (u32)OSIRIS_VA_CTRL2, |
73 | .pfn = __phys_to_pfn(OSIRIS_PA_CTRL2), | 73 | .pfn = __phys_to_pfn(OSIRIS_PA_CTRL2), |
74 | .length = SZ_16K, | 74 | .length = SZ_16K, |
75 | .type = MT_DEVICE | 75 | .type = MT_DEVICE, |
76 | }, | 76 | }, |
77 | }; | 77 | }; |
78 | 78 | ||
@@ -91,7 +91,7 @@ static struct s3c24xx_uart_clksrc osiris_serial_clocks[] = { | |||
91 | .name = "pclk", | 91 | .name = "pclk", |
92 | .divisor = 1, | 92 | .divisor = 1, |
93 | .min_baud = 0, | 93 | .min_baud = 0, |
94 | .max_baud = 0. | 94 | .max_baud = 0, |
95 | } | 95 | } |
96 | }; | 96 | }; |
97 | 97 | ||
@@ -103,7 +103,7 @@ static struct s3c2410_uartcfg osiris_uartcfgs[] __initdata = { | |||
103 | .ulcon = ULCON, | 103 | .ulcon = ULCON, |
104 | .ufcon = UFCON, | 104 | .ufcon = UFCON, |
105 | .clocks = osiris_serial_clocks, | 105 | .clocks = osiris_serial_clocks, |
106 | .clocks_size = ARRAY_SIZE(osiris_serial_clocks) | 106 | .clocks_size = ARRAY_SIZE(osiris_serial_clocks), |
107 | }, | 107 | }, |
108 | [1] = { | 108 | [1] = { |
109 | .hwport = 1, | 109 | .hwport = 1, |
@@ -112,7 +112,7 @@ static struct s3c2410_uartcfg osiris_uartcfgs[] __initdata = { | |||
112 | .ulcon = ULCON, | 112 | .ulcon = ULCON, |
113 | .ufcon = UFCON, | 113 | .ufcon = UFCON, |
114 | .clocks = osiris_serial_clocks, | 114 | .clocks = osiris_serial_clocks, |
115 | .clocks_size = ARRAY_SIZE(osiris_serial_clocks) | 115 | .clocks_size = ARRAY_SIZE(osiris_serial_clocks), |
116 | }, | 116 | }, |
117 | }; | 117 | }; |
118 | 118 | ||
@@ -126,7 +126,7 @@ static struct mtd_partition osiris_default_nand_part[] = { | |||
126 | [0] = { | 126 | [0] = { |
127 | .name = "Boot Agent", | 127 | .name = "Boot Agent", |
128 | .size = SZ_16K, | 128 | .size = SZ_16K, |
129 | .offset = 0 | 129 | .offset = 0, |
130 | }, | 130 | }, |
131 | [1] = { | 131 | [1] = { |
132 | .name = "/boot", | 132 | .name = "/boot", |
@@ -158,21 +158,21 @@ static struct s3c2410_nand_set osiris_nand_sets[] = { | |||
158 | .nr_chips = 1, | 158 | .nr_chips = 1, |
159 | .nr_map = external_map, | 159 | .nr_map = external_map, |
160 | .nr_partitions = ARRAY_SIZE(osiris_default_nand_part), | 160 | .nr_partitions = ARRAY_SIZE(osiris_default_nand_part), |
161 | .partitions = osiris_default_nand_part | 161 | .partitions = osiris_default_nand_part, |
162 | }, | 162 | }, |
163 | [0] = { | 163 | [0] = { |
164 | .name = "chip0", | 164 | .name = "chip0", |
165 | .nr_chips = 1, | 165 | .nr_chips = 1, |
166 | .nr_map = chip0_map, | 166 | .nr_map = chip0_map, |
167 | .nr_partitions = ARRAY_SIZE(osiris_default_nand_part), | 167 | .nr_partitions = ARRAY_SIZE(osiris_default_nand_part), |
168 | .partitions = osiris_default_nand_part | 168 | .partitions = osiris_default_nand_part, |
169 | }, | 169 | }, |
170 | [2] = { | 170 | [2] = { |
171 | .name = "chip1", | 171 | .name = "chip1", |
172 | .nr_chips = 1, | 172 | .nr_chips = 1, |
173 | .nr_map = chip1_map, | 173 | .nr_map = chip1_map, |
174 | .nr_partitions = ARRAY_SIZE(osiris_default_nand_part), | 174 | .nr_partitions = ARRAY_SIZE(osiris_default_nand_part), |
175 | .partitions = osiris_default_nand_part | 175 | .partitions = osiris_default_nand_part, |
176 | }, | 176 | }, |
177 | }; | 177 | }; |
178 | 178 | ||
@@ -245,7 +245,7 @@ static struct s3c24xx_board osiris_board __initdata = { | |||
245 | .devices = osiris_devices, | 245 | .devices = osiris_devices, |
246 | .devices_count = ARRAY_SIZE(osiris_devices), | 246 | .devices_count = ARRAY_SIZE(osiris_devices), |
247 | .clocks = osiris_clocks, | 247 | .clocks = osiris_clocks, |
248 | .clocks_count = ARRAY_SIZE(osiris_clocks) | 248 | .clocks_count = ARRAY_SIZE(osiris_clocks), |
249 | }; | 249 | }; |
250 | 250 | ||
251 | static void __init osiris_map_io(void) | 251 | static void __init osiris_map_io(void) |
diff --git a/arch/arm/mach-sa1100/irq.c b/arch/arm/mach-sa1100/irq.c index 2891b8ca86dd..b55b90a2e8fe 100644 --- a/arch/arm/mach-sa1100/irq.c +++ b/arch/arm/mach-sa1100/irq.c | |||
@@ -95,7 +95,8 @@ static int sa1100_low_gpio_wake(unsigned int irq, unsigned int on) | |||
95 | return 0; | 95 | return 0; |
96 | } | 96 | } |
97 | 97 | ||
98 | static struct irqchip sa1100_low_gpio_chip = { | 98 | static struct irq_chip sa1100_low_gpio_chip = { |
99 | .name = "GPIO-l", | ||
99 | .ack = sa1100_low_gpio_ack, | 100 | .ack = sa1100_low_gpio_ack, |
100 | .mask = sa1100_low_gpio_mask, | 101 | .mask = sa1100_low_gpio_mask, |
101 | .unmask = sa1100_low_gpio_unmask, | 102 | .unmask = sa1100_low_gpio_unmask, |
@@ -178,7 +179,8 @@ static int sa1100_high_gpio_wake(unsigned int irq, unsigned int on) | |||
178 | return 0; | 179 | return 0; |
179 | } | 180 | } |
180 | 181 | ||
181 | static struct irqchip sa1100_high_gpio_chip = { | 182 | static struct irq_chip sa1100_high_gpio_chip = { |
183 | .name = "GPIO-h", | ||
182 | .ack = sa1100_high_gpio_ack, | 184 | .ack = sa1100_high_gpio_ack, |
183 | .mask = sa1100_high_gpio_mask, | 185 | .mask = sa1100_high_gpio_mask, |
184 | .unmask = sa1100_high_gpio_unmask, | 186 | .unmask = sa1100_high_gpio_unmask, |
@@ -215,7 +217,8 @@ static int sa1100_set_wake(unsigned int irq, unsigned int on) | |||
215 | return -EINVAL; | 217 | return -EINVAL; |
216 | } | 218 | } |
217 | 219 | ||
218 | static struct irqchip sa1100_normal_chip = { | 220 | static struct irq_chip sa1100_normal_chip = { |
221 | .name = "SC", | ||
219 | .ack = sa1100_mask_irq, | 222 | .ack = sa1100_mask_irq, |
220 | .mask = sa1100_mask_irq, | 223 | .mask = sa1100_mask_irq, |
221 | .unmask = sa1100_unmask_irq, | 224 | .unmask = sa1100_unmask_irq, |
diff --git a/arch/arm/mach-shark/irq.c b/arch/arm/mach-shark/irq.c index 6cb67bd3dfd3..b227052296cf 100644 --- a/arch/arm/mach-shark/irq.c +++ b/arch/arm/mach-shark/irq.c | |||
@@ -69,7 +69,8 @@ static irqreturn_t bogus_int(int irq, void *dev_id, struct pt_regs *regs) | |||
69 | 69 | ||
70 | static struct irqaction cascade; | 70 | static struct irqaction cascade; |
71 | 71 | ||
72 | static struct irqchip fb_chip = { | 72 | static struct irq_chip fb_chip = { |
73 | .name = "XT-PIC", | ||
73 | .ack = shark_ack_8259A_irq, | 74 | .ack = shark_ack_8259A_irq, |
74 | .mask = shark_disable_8259A_irq, | 75 | .mask = shark_disable_8259A_irq, |
75 | .unmask = shark_enable_8259A_irq, | 76 | .unmask = shark_enable_8259A_irq, |
diff --git a/arch/arm/mach-versatile/core.c b/arch/arm/mach-versatile/core.c index 864377176015..c4e3f8c68479 100644 --- a/arch/arm/mach-versatile/core.c +++ b/arch/arm/mach-versatile/core.c | |||
@@ -69,7 +69,8 @@ static void sic_unmask_irq(unsigned int irq) | |||
69 | writel(1 << irq, VA_SIC_BASE + SIC_IRQ_ENABLE_SET); | 69 | writel(1 << irq, VA_SIC_BASE + SIC_IRQ_ENABLE_SET); |
70 | } | 70 | } |
71 | 71 | ||
72 | static struct irqchip sic_chip = { | 72 | static struct irq_chip sic_chip = { |
73 | .name = "SIC", | ||
73 | .ack = sic_mask_irq, | 74 | .ack = sic_mask_irq, |
74 | .mask = sic_mask_irq, | 75 | .mask = sic_mask_irq, |
75 | .unmask = sic_unmask_irq, | 76 | .unmask = sic_unmask_irq, |
diff --git a/arch/arm/mm/ioremap.c b/arch/arm/mm/ioremap.c index dba7dddfe57d..88a999df0ab3 100644 --- a/arch/arm/mm/ioremap.c +++ b/arch/arm/mm/ioremap.c | |||
@@ -363,7 +363,9 @@ EXPORT_SYMBOL(__ioremap); | |||
363 | 363 | ||
364 | void __iounmap(void __iomem *addr) | 364 | void __iounmap(void __iomem *addr) |
365 | { | 365 | { |
366 | #ifndef CONFIG_SMP | ||
366 | struct vm_struct **p, *tmp; | 367 | struct vm_struct **p, *tmp; |
368 | #endif | ||
367 | unsigned int section_mapping = 0; | 369 | unsigned int section_mapping = 0; |
368 | 370 | ||
369 | addr = (void __iomem *)(PAGE_MASK & (unsigned long)addr); | 371 | addr = (void __iomem *)(PAGE_MASK & (unsigned long)addr); |
diff --git a/arch/arm/mm/proc-syms.c b/arch/arm/mm/proc-syms.c index 6c5f0fe578a5..ab143557e688 100644 --- a/arch/arm/mm/proc-syms.c +++ b/arch/arm/mm/proc-syms.c | |||
@@ -13,6 +13,7 @@ | |||
13 | #include <asm/cacheflush.h> | 13 | #include <asm/cacheflush.h> |
14 | #include <asm/proc-fns.h> | 14 | #include <asm/proc-fns.h> |
15 | #include <asm/tlbflush.h> | 15 | #include <asm/tlbflush.h> |
16 | #include <asm/page.h> | ||
16 | 17 | ||
17 | #ifndef MULTI_CPU | 18 | #ifndef MULTI_CPU |
18 | EXPORT_SYMBOL(cpu_dcache_clean_area); | 19 | EXPORT_SYMBOL(cpu_dcache_clean_area); |
@@ -30,6 +31,13 @@ EXPORT_SYMBOL(__cpuc_coherent_kern_range); | |||
30 | EXPORT_SYMBOL(cpu_cache); | 31 | EXPORT_SYMBOL(cpu_cache); |
31 | #endif | 32 | #endif |
32 | 33 | ||
34 | #ifndef MULTI_USER | ||
35 | EXPORT_SYMBOL(__cpu_clear_user_page); | ||
36 | EXPORT_SYMBOL(__cpu_copy_user_page); | ||
37 | #else | ||
38 | EXPORT_SYMBOL(cpu_user); | ||
39 | #endif | ||
40 | |||
33 | /* | 41 | /* |
34 | * No module should need to touch the TLB (and currently | 42 | * No module should need to touch the TLB (and currently |
35 | * no modules do. We export this for "loadkernel" support | 43 | * no modules do. We export this for "loadkernel" support |
diff --git a/arch/arm/mm/proc-xscale.S b/arch/arm/mm/proc-xscale.S index 521538671f4c..561bff73a036 100644 --- a/arch/arm/mm/proc-xscale.S +++ b/arch/arm/mm/proc-xscale.S | |||
@@ -536,6 +536,11 @@ cpu_80200_name: | |||
536 | .asciz "XScale-80200" | 536 | .asciz "XScale-80200" |
537 | .size cpu_80200_name, . - cpu_80200_name | 537 | .size cpu_80200_name, . - cpu_80200_name |
538 | 538 | ||
539 | .type cpu_80219_name, #object | ||
540 | cpu_80219_name: | ||
541 | .asciz "XScale-80219" | ||
542 | .size cpu_80219_name, . - cpu_80219_name | ||
543 | |||
539 | .type cpu_8032x_name, #object | 544 | .type cpu_8032x_name, #object |
540 | cpu_8032x_name: | 545 | cpu_8032x_name: |
541 | .asciz "XScale-IOP8032x Family" | 546 | .asciz "XScale-IOP8032x Family" |
@@ -613,10 +618,33 @@ __80200_proc_info: | |||
613 | .long xscale_cache_fns | 618 | .long xscale_cache_fns |
614 | .size __80200_proc_info, . - __80200_proc_info | 619 | .size __80200_proc_info, . - __80200_proc_info |
615 | 620 | ||
621 | .type __80219_proc_info,#object | ||
622 | __80219_proc_info: | ||
623 | .long 0x69052e20 | ||
624 | .long 0xffffffe0 | ||
625 | .long PMD_TYPE_SECT | \ | ||
626 | PMD_SECT_BUFFERABLE | \ | ||
627 | PMD_SECT_CACHEABLE | \ | ||
628 | PMD_SECT_AP_WRITE | \ | ||
629 | PMD_SECT_AP_READ | ||
630 | .long PMD_TYPE_SECT | \ | ||
631 | PMD_SECT_AP_WRITE | \ | ||
632 | PMD_SECT_AP_READ | ||
633 | b __xscale_setup | ||
634 | .long cpu_arch_name | ||
635 | .long cpu_elf_name | ||
636 | .long HWCAP_SWP|HWCAP_HALF|HWCAP_THUMB|HWCAP_FAST_MULT|HWCAP_EDSP | ||
637 | .long cpu_80219_name | ||
638 | .long xscale_processor_functions | ||
639 | .long v4wbi_tlb_fns | ||
640 | .long xscale_mc_user_fns | ||
641 | .long xscale_cache_fns | ||
642 | .size __80219_proc_info, . - __80219_proc_info | ||
643 | |||
616 | .type __8032x_proc_info,#object | 644 | .type __8032x_proc_info,#object |
617 | __8032x_proc_info: | 645 | __8032x_proc_info: |
618 | .long 0x69052420 | 646 | .long 0x69052420 |
619 | .long 0xfffff5e0 @ mask should accomodate IOP80219 also | 647 | .long 0xffffffe0 |
620 | .long PMD_TYPE_SECT | \ | 648 | .long PMD_TYPE_SECT | \ |
621 | PMD_SECT_BUFFERABLE | \ | 649 | PMD_SECT_BUFFERABLE | \ |
622 | PMD_SECT_CACHEABLE | \ | 650 | PMD_SECT_CACHEABLE | \ |
diff --git a/arch/arm/plat-omap/gpio.c b/arch/arm/plat-omap/gpio.c index fec7970e564d..cd7f973fb286 100644 --- a/arch/arm/plat-omap/gpio.c +++ b/arch/arm/plat-omap/gpio.c | |||
@@ -944,7 +944,8 @@ static void mpuio_unmask_irq(unsigned int irq) | |||
944 | _set_gpio_irqenable(bank, gpio, 1); | 944 | _set_gpio_irqenable(bank, gpio, 1); |
945 | } | 945 | } |
946 | 946 | ||
947 | static struct irqchip gpio_irq_chip = { | 947 | static struct irq_chip gpio_irq_chip = { |
948 | .name = "GPIO", | ||
948 | .ack = gpio_ack_irq, | 949 | .ack = gpio_ack_irq, |
949 | .mask = gpio_mask_irq, | 950 | .mask = gpio_mask_irq, |
950 | .unmask = gpio_unmask_irq, | 951 | .unmask = gpio_unmask_irq, |
@@ -952,10 +953,11 @@ static struct irqchip gpio_irq_chip = { | |||
952 | .set_wake = gpio_wake_enable, | 953 | .set_wake = gpio_wake_enable, |
953 | }; | 954 | }; |
954 | 955 | ||
955 | static struct irqchip mpuio_irq_chip = { | 956 | static struct irq_chip mpuio_irq_chip = { |
957 | .name = "MPUIO", | ||
956 | .ack = mpuio_ack_irq, | 958 | .ack = mpuio_ack_irq, |
957 | .mask = mpuio_mask_irq, | 959 | .mask = mpuio_mask_irq, |
958 | .unmask = mpuio_unmask_irq | 960 | .unmask = mpuio_unmask_irq |
959 | }; | 961 | }; |
960 | 962 | ||
961 | static int initialized; | 963 | static int initialized; |
diff --git a/arch/i386/Kconfig b/arch/i386/Kconfig index daa75ce4b777..f71fb4a029cb 100644 --- a/arch/i386/Kconfig +++ b/arch/i386/Kconfig | |||
@@ -672,7 +672,7 @@ config MTRR | |||
672 | See <file:Documentation/mtrr.txt> for more information. | 672 | See <file:Documentation/mtrr.txt> for more information. |
673 | 673 | ||
674 | config EFI | 674 | config EFI |
675 | bool "Boot from EFI support (EXPERIMENTAL)" | 675 | bool "Boot from EFI support" |
676 | depends on ACPI | 676 | depends on ACPI |
677 | default n | 677 | default n |
678 | ---help--- | 678 | ---help--- |
diff --git a/arch/i386/kernel/Makefile b/arch/i386/kernel/Makefile index 1b452a1665c4..ab98fc21a541 100644 --- a/arch/i386/kernel/Makefile +++ b/arch/i386/kernel/Makefile | |||
@@ -59,7 +59,8 @@ quiet_cmd_syscall = SYSCALL $@ | |||
59 | 59 | ||
60 | export CPPFLAGS_vsyscall.lds += -P -C -U$(ARCH) | 60 | export CPPFLAGS_vsyscall.lds += -P -C -U$(ARCH) |
61 | 61 | ||
62 | vsyscall-flags = -shared -s -Wl,-soname=linux-gate.so.1 | 62 | vsyscall-flags = -shared -s -Wl,-soname=linux-gate.so.1 \ |
63 | $(call ld-option, -Wl$(comma)--hash-style=sysv) | ||
63 | SYSCFLAGS_vsyscall-sysenter.so = $(vsyscall-flags) | 64 | SYSCFLAGS_vsyscall-sysenter.so = $(vsyscall-flags) |
64 | SYSCFLAGS_vsyscall-int80.so = $(vsyscall-flags) | 65 | SYSCFLAGS_vsyscall-int80.so = $(vsyscall-flags) |
65 | 66 | ||
diff --git a/arch/i386/kernel/cpu/cpufreq/Kconfig b/arch/i386/kernel/cpu/cpufreq/Kconfig index e44a4c6a4fe5..ccc1edff5c97 100644 --- a/arch/i386/kernel/cpu/cpufreq/Kconfig +++ b/arch/i386/kernel/cpu/cpufreq/Kconfig | |||
@@ -96,6 +96,7 @@ config X86_POWERNOW_K8_ACPI | |||
96 | 96 | ||
97 | config X86_GX_SUSPMOD | 97 | config X86_GX_SUSPMOD |
98 | tristate "Cyrix MediaGX/NatSemi Geode Suspend Modulation" | 98 | tristate "Cyrix MediaGX/NatSemi Geode Suspend Modulation" |
99 | depends on PCI | ||
99 | help | 100 | help |
100 | This add the CPUFreq driver for NatSemi Geode processors which | 101 | This add the CPUFreq driver for NatSemi Geode processors which |
101 | support suspend modulation. | 102 | support suspend modulation. |
@@ -202,7 +203,7 @@ config X86_LONGRUN | |||
202 | config X86_LONGHAUL | 203 | config X86_LONGHAUL |
203 | tristate "VIA Cyrix III Longhaul" | 204 | tristate "VIA Cyrix III Longhaul" |
204 | select CPU_FREQ_TABLE | 205 | select CPU_FREQ_TABLE |
205 | depends on BROKEN | 206 | depends on ACPI_PROCESSOR |
206 | help | 207 | help |
207 | This adds the CPUFreq driver for VIA Samuel/CyrixIII, | 208 | This adds the CPUFreq driver for VIA Samuel/CyrixIII, |
208 | VIA Cyrix Samuel/C3, VIA Cyrix Ezra and VIA Cyrix Ezra-T | 209 | VIA Cyrix Samuel/C3, VIA Cyrix Ezra and VIA Cyrix Ezra-T |
diff --git a/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c b/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c index 567b39bea07e..efb41e81351c 100644 --- a/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c +++ b/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c | |||
@@ -384,8 +384,7 @@ static int acpi_cpufreq_early_init_acpi(void) | |||
384 | } | 384 | } |
385 | 385 | ||
386 | /* Do initialization in ACPI core */ | 386 | /* Do initialization in ACPI core */ |
387 | acpi_processor_preregister_performance(acpi_perf_data); | 387 | return acpi_processor_preregister_performance(acpi_perf_data); |
388 | return 0; | ||
389 | } | 388 | } |
390 | 389 | ||
391 | static int | 390 | static int |
diff --git a/arch/i386/kernel/cpu/cpufreq/longhaul.c b/arch/i386/kernel/cpu/cpufreq/longhaul.c index 146f607e9c44..4f2c3aeef724 100644 --- a/arch/i386/kernel/cpu/cpufreq/longhaul.c +++ b/arch/i386/kernel/cpu/cpufreq/longhaul.c | |||
@@ -29,11 +29,13 @@ | |||
29 | #include <linux/cpufreq.h> | 29 | #include <linux/cpufreq.h> |
30 | #include <linux/slab.h> | 30 | #include <linux/slab.h> |
31 | #include <linux/string.h> | 31 | #include <linux/string.h> |
32 | #include <linux/pci.h> | ||
33 | 32 | ||
34 | #include <asm/msr.h> | 33 | #include <asm/msr.h> |
35 | #include <asm/timex.h> | 34 | #include <asm/timex.h> |
36 | #include <asm/io.h> | 35 | #include <asm/io.h> |
36 | #include <asm/acpi.h> | ||
37 | #include <linux/acpi.h> | ||
38 | #include <acpi/processor.h> | ||
37 | 39 | ||
38 | #include "longhaul.h" | 40 | #include "longhaul.h" |
39 | 41 | ||
@@ -56,6 +58,8 @@ static int minvid, maxvid; | |||
56 | static unsigned int minmult, maxmult; | 58 | static unsigned int minmult, maxmult; |
57 | static int can_scale_voltage; | 59 | static int can_scale_voltage; |
58 | static int vrmrev; | 60 | static int vrmrev; |
61 | static struct acpi_processor *pr = NULL; | ||
62 | static struct acpi_processor_cx *cx = NULL; | ||
59 | 63 | ||
60 | /* Module parameters */ | 64 | /* Module parameters */ |
61 | static int dont_scale_voltage; | 65 | static int dont_scale_voltage; |
@@ -118,84 +122,65 @@ static int longhaul_get_cpu_mult(void) | |||
118 | return eblcr_table[invalue]; | 122 | return eblcr_table[invalue]; |
119 | } | 123 | } |
120 | 124 | ||
125 | /* For processor with BCR2 MSR */ | ||
121 | 126 | ||
122 | static void do_powersaver(union msr_longhaul *longhaul, | 127 | static void do_longhaul1(int cx_address, unsigned int clock_ratio_index) |
123 | unsigned int clock_ratio_index) | ||
124 | { | 128 | { |
125 | struct pci_dev *dev; | 129 | union msr_bcr2 bcr2; |
126 | unsigned long flags; | 130 | u32 t; |
127 | unsigned int tmp_mask; | ||
128 | int version; | ||
129 | int i; | ||
130 | u16 pci_cmd; | ||
131 | u16 cmd_state[64]; | ||
132 | 131 | ||
133 | switch (cpu_model) { | 132 | rdmsrl(MSR_VIA_BCR2, bcr2.val); |
134 | case CPU_EZRA_T: | 133 | /* Enable software clock multiplier */ |
135 | version = 3; | 134 | bcr2.bits.ESOFTBF = 1; |
136 | break; | 135 | bcr2.bits.CLOCKMUL = clock_ratio_index; |
137 | case CPU_NEHEMIAH: | ||
138 | version = 0xf; | ||
139 | break; | ||
140 | default: | ||
141 | return; | ||
142 | } | ||
143 | 136 | ||
144 | rdmsrl(MSR_VIA_LONGHAUL, longhaul->val); | 137 | /* Sync to timer tick */ |
145 | longhaul->bits.SoftBusRatio = clock_ratio_index & 0xf; | 138 | safe_halt(); |
146 | longhaul->bits.SoftBusRatio4 = (clock_ratio_index & 0x10) >> 4; | 139 | ACPI_FLUSH_CPU_CACHE(); |
147 | longhaul->bits.EnableSoftBusRatio = 1; | 140 | /* Change frequency on next halt or sleep */ |
148 | longhaul->bits.RevisionKey = 0; | 141 | wrmsrl(MSR_VIA_BCR2, bcr2.val); |
142 | /* Invoke C3 */ | ||
143 | inb(cx_address); | ||
144 | /* Dummy op - must do something useless after P_LVL3 read */ | ||
145 | t = inl(acpi_fadt.xpm_tmr_blk.address); | ||
146 | |||
147 | /* Disable software clock multiplier */ | ||
148 | local_irq_disable(); | ||
149 | rdmsrl(MSR_VIA_BCR2, bcr2.val); | ||
150 | bcr2.bits.ESOFTBF = 0; | ||
151 | wrmsrl(MSR_VIA_BCR2, bcr2.val); | ||
152 | } | ||
149 | 153 | ||
150 | preempt_disable(); | 154 | /* For processor with Longhaul MSR */ |
151 | local_irq_save(flags); | ||
152 | 155 | ||
153 | /* | 156 | static void do_powersaver(int cx_address, unsigned int clock_ratio_index) |
154 | * get current pci bus master state for all devices | 157 | { |
155 | * and clear bus master bit | 158 | union msr_longhaul longhaul; |
156 | */ | 159 | u32 t; |
157 | dev = NULL; | ||
158 | i = 0; | ||
159 | do { | ||
160 | dev = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, dev); | ||
161 | if (dev != NULL) { | ||
162 | pci_read_config_word(dev, PCI_COMMAND, &pci_cmd); | ||
163 | cmd_state[i++] = pci_cmd; | ||
164 | pci_cmd &= ~PCI_COMMAND_MASTER; | ||
165 | pci_write_config_word(dev, PCI_COMMAND, pci_cmd); | ||
166 | } | ||
167 | } while (dev != NULL); | ||
168 | 160 | ||
169 | tmp_mask=inb(0x21); /* works on C3. save mask. */ | 161 | rdmsrl(MSR_VIA_LONGHAUL, longhaul.val); |
170 | outb(0xFE,0x21); /* TMR0 only */ | 162 | longhaul.bits.RevisionKey = longhaul.bits.RevisionID; |
171 | outb(0xFF,0x80); /* delay */ | 163 | longhaul.bits.SoftBusRatio = clock_ratio_index & 0xf; |
164 | longhaul.bits.SoftBusRatio4 = (clock_ratio_index & 0x10) >> 4; | ||
165 | longhaul.bits.EnableSoftBusRatio = 1; | ||
172 | 166 | ||
167 | /* Sync to timer tick */ | ||
173 | safe_halt(); | 168 | safe_halt(); |
174 | wrmsrl(MSR_VIA_LONGHAUL, longhaul->val); | 169 | ACPI_FLUSH_CPU_CACHE(); |
175 | halt(); | 170 | /* Change frequency on next halt or sleep */ |
176 | 171 | wrmsrl(MSR_VIA_LONGHAUL, longhaul.val); | |
172 | /* Invoke C3 */ | ||
173 | inb(cx_address); | ||
174 | /* Dummy op - must do something useless after P_LVL3 read */ | ||
175 | t = inl(acpi_fadt.xpm_tmr_blk.address); | ||
176 | |||
177 | /* Disable bus ratio bit */ | ||
177 | local_irq_disable(); | 178 | local_irq_disable(); |
178 | 179 | longhaul.bits.RevisionKey = longhaul.bits.RevisionID; | |
179 | outb(tmp_mask,0x21); /* restore mask */ | 180 | longhaul.bits.EnableSoftBusRatio = 0; |
180 | 181 | longhaul.bits.EnableSoftBSEL = 0; | |
181 | /* restore pci bus master state for all devices */ | 182 | longhaul.bits.EnableSoftVID = 0; |
182 | dev = NULL; | 183 | wrmsrl(MSR_VIA_LONGHAUL, longhaul.val); |
183 | i = 0; | ||
184 | do { | ||
185 | dev = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, dev); | ||
186 | if (dev != NULL) { | ||
187 | pci_cmd = cmd_state[i++]; | ||
188 | pci_write_config_byte(dev, PCI_COMMAND, pci_cmd); | ||
189 | } | ||
190 | } while (dev != NULL); | ||
191 | local_irq_restore(flags); | ||
192 | preempt_enable(); | ||
193 | |||
194 | /* disable bus ratio bit */ | ||
195 | rdmsrl(MSR_VIA_LONGHAUL, longhaul->val); | ||
196 | longhaul->bits.EnableSoftBusRatio = 0; | ||
197 | longhaul->bits.RevisionKey = version; | ||
198 | wrmsrl(MSR_VIA_LONGHAUL, longhaul->val); | ||
199 | } | 184 | } |
200 | 185 | ||
201 | /** | 186 | /** |
@@ -209,9 +194,9 @@ static void longhaul_setstate(unsigned int clock_ratio_index) | |||
209 | { | 194 | { |
210 | int speed, mult; | 195 | int speed, mult; |
211 | struct cpufreq_freqs freqs; | 196 | struct cpufreq_freqs freqs; |
212 | union msr_longhaul longhaul; | ||
213 | union msr_bcr2 bcr2; | ||
214 | static unsigned int old_ratio=-1; | 197 | static unsigned int old_ratio=-1; |
198 | unsigned long flags; | ||
199 | unsigned int pic1_mask, pic2_mask; | ||
215 | 200 | ||
216 | if (old_ratio == clock_ratio_index) | 201 | if (old_ratio == clock_ratio_index) |
217 | return; | 202 | return; |
@@ -234,6 +219,20 @@ static void longhaul_setstate(unsigned int clock_ratio_index) | |||
234 | dprintk ("Setting to FSB:%dMHz Mult:%d.%dx (%s)\n", | 219 | dprintk ("Setting to FSB:%dMHz Mult:%d.%dx (%s)\n", |
235 | fsb, mult/10, mult%10, print_speed(speed/1000)); | 220 | fsb, mult/10, mult%10, print_speed(speed/1000)); |
236 | 221 | ||
222 | preempt_disable(); | ||
223 | local_irq_save(flags); | ||
224 | |||
225 | pic2_mask = inb(0xA1); | ||
226 | pic1_mask = inb(0x21); /* works on C3. save mask. */ | ||
227 | outb(0xFF,0xA1); /* Overkill */ | ||
228 | outb(0xFE,0x21); /* TMR0 only */ | ||
229 | |||
230 | /* Disable bus master arbitration */ | ||
231 | if (pr->flags.bm_check) { | ||
232 | acpi_set_register(ACPI_BITREG_ARB_DISABLE, 1, | ||
233 | ACPI_MTX_DO_NOT_LOCK); | ||
234 | } | ||
235 | |||
237 | switch (longhaul_version) { | 236 | switch (longhaul_version) { |
238 | 237 | ||
239 | /* | 238 | /* |
@@ -245,20 +244,7 @@ static void longhaul_setstate(unsigned int clock_ratio_index) | |||
245 | */ | 244 | */ |
246 | case TYPE_LONGHAUL_V1: | 245 | case TYPE_LONGHAUL_V1: |
247 | case TYPE_LONGHAUL_V2: | 246 | case TYPE_LONGHAUL_V2: |
248 | rdmsrl (MSR_VIA_BCR2, bcr2.val); | 247 | do_longhaul1(cx->address, clock_ratio_index); |
249 | /* Enable software clock multiplier */ | ||
250 | bcr2.bits.ESOFTBF = 1; | ||
251 | bcr2.bits.CLOCKMUL = clock_ratio_index; | ||
252 | local_irq_disable(); | ||
253 | wrmsrl (MSR_VIA_BCR2, bcr2.val); | ||
254 | safe_halt(); | ||
255 | |||
256 | /* Disable software clock multiplier */ | ||
257 | rdmsrl (MSR_VIA_BCR2, bcr2.val); | ||
258 | bcr2.bits.ESOFTBF = 0; | ||
259 | local_irq_disable(); | ||
260 | wrmsrl (MSR_VIA_BCR2, bcr2.val); | ||
261 | local_irq_enable(); | ||
262 | break; | 248 | break; |
263 | 249 | ||
264 | /* | 250 | /* |
@@ -273,10 +259,22 @@ static void longhaul_setstate(unsigned int clock_ratio_index) | |||
273 | * to work in practice. | 259 | * to work in practice. |
274 | */ | 260 | */ |
275 | case TYPE_POWERSAVER: | 261 | case TYPE_POWERSAVER: |
276 | do_powersaver(&longhaul, clock_ratio_index); | 262 | do_powersaver(cx->address, clock_ratio_index); |
277 | break; | 263 | break; |
278 | } | 264 | } |
279 | 265 | ||
266 | /* Enable bus master arbitration */ | ||
267 | if (pr->flags.bm_check) { | ||
268 | acpi_set_register(ACPI_BITREG_ARB_DISABLE, 0, | ||
269 | ACPI_MTX_DO_NOT_LOCK); | ||
270 | } | ||
271 | |||
272 | outb(pic2_mask,0xA1); /* restore mask */ | ||
273 | outb(pic1_mask,0x21); | ||
274 | |||
275 | local_irq_restore(flags); | ||
276 | preempt_enable(); | ||
277 | |||
280 | cpufreq_notify_transition(&freqs, CPUFREQ_POSTCHANGE); | 278 | cpufreq_notify_transition(&freqs, CPUFREQ_POSTCHANGE); |
281 | } | 279 | } |
282 | 280 | ||
@@ -324,9 +322,11 @@ static int guess_fsb(void) | |||
324 | static int __init longhaul_get_ranges(void) | 322 | static int __init longhaul_get_ranges(void) |
325 | { | 323 | { |
326 | unsigned long invalue; | 324 | unsigned long invalue; |
327 | unsigned int multipliers[32]= { | 325 | unsigned int ezra_t_multipliers[32]= { |
328 | 50,30,40,100,55,35,45,95,90,70,80,60,120,75,85,65, | 326 | 90, 30, 40, 100, 55, 35, 45, 95, |
329 | -1,110,120,-1,135,115,125,105,130,150,160,140,-1,155,-1,145 }; | 327 | 50, 70, 80, 60, 120, 75, 85, 65, |
328 | -1, 110, 120, -1, 135, 115, 125, 105, | ||
329 | 130, 150, 160, 140, -1, 155, -1, 145 }; | ||
330 | unsigned int j, k = 0; | 330 | unsigned int j, k = 0; |
331 | union msr_longhaul longhaul; | 331 | union msr_longhaul longhaul; |
332 | unsigned long lo, hi; | 332 | unsigned long lo, hi; |
@@ -355,13 +355,13 @@ static int __init longhaul_get_ranges(void) | |||
355 | invalue = longhaul.bits.MaxMHzBR; | 355 | invalue = longhaul.bits.MaxMHzBR; |
356 | if (longhaul.bits.MaxMHzBR4) | 356 | if (longhaul.bits.MaxMHzBR4) |
357 | invalue += 16; | 357 | invalue += 16; |
358 | maxmult=multipliers[invalue]; | 358 | maxmult=ezra_t_multipliers[invalue]; |
359 | 359 | ||
360 | invalue = longhaul.bits.MinMHzBR; | 360 | invalue = longhaul.bits.MinMHzBR; |
361 | if (longhaul.bits.MinMHzBR4 == 1) | 361 | if (longhaul.bits.MinMHzBR4 == 1) |
362 | minmult = 30; | 362 | minmult = 30; |
363 | else | 363 | else |
364 | minmult = multipliers[invalue]; | 364 | minmult = ezra_t_multipliers[invalue]; |
365 | fsb = eblcr_fsb_table_v2[longhaul.bits.MaxMHzFSB]; | 365 | fsb = eblcr_fsb_table_v2[longhaul.bits.MaxMHzFSB]; |
366 | break; | 366 | break; |
367 | } | 367 | } |
@@ -527,6 +527,18 @@ static unsigned int longhaul_get(unsigned int cpu) | |||
527 | return calc_speed(longhaul_get_cpu_mult()); | 527 | return calc_speed(longhaul_get_cpu_mult()); |
528 | } | 528 | } |
529 | 529 | ||
530 | static acpi_status longhaul_walk_callback(acpi_handle obj_handle, | ||
531 | u32 nesting_level, | ||
532 | void *context, void **return_value) | ||
533 | { | ||
534 | struct acpi_device *d; | ||
535 | |||
536 | if ( acpi_bus_get_device(obj_handle, &d) ) { | ||
537 | return 0; | ||
538 | } | ||
539 | *return_value = (void *)acpi_driver_data(d); | ||
540 | return 1; | ||
541 | } | ||
530 | 542 | ||
531 | static int __init longhaul_cpu_init(struct cpufreq_policy *policy) | 543 | static int __init longhaul_cpu_init(struct cpufreq_policy *policy) |
532 | { | 544 | { |
@@ -534,6 +546,15 @@ static int __init longhaul_cpu_init(struct cpufreq_policy *policy) | |||
534 | char *cpuname=NULL; | 546 | char *cpuname=NULL; |
535 | int ret; | 547 | int ret; |
536 | 548 | ||
549 | /* Check ACPI support for C3 state */ | ||
550 | acpi_walk_namespace(ACPI_TYPE_PROCESSOR, ACPI_ROOT_OBJECT, ACPI_UINT32_MAX, | ||
551 | &longhaul_walk_callback, NULL, (void *)&pr); | ||
552 | if (pr == NULL) goto err_acpi; | ||
553 | |||
554 | cx = &pr->power.states[ACPI_STATE_C3]; | ||
555 | if (cx->address == 0 || cx->latency > 1000) goto err_acpi; | ||
556 | |||
557 | /* Now check what we have on this motherboard */ | ||
537 | switch (c->x86_model) { | 558 | switch (c->x86_model) { |
538 | case 6: | 559 | case 6: |
539 | cpu_model = CPU_SAMUEL; | 560 | cpu_model = CPU_SAMUEL; |
@@ -634,6 +655,10 @@ static int __init longhaul_cpu_init(struct cpufreq_policy *policy) | |||
634 | cpufreq_frequency_table_get_attr(longhaul_table, policy->cpu); | 655 | cpufreq_frequency_table_get_attr(longhaul_table, policy->cpu); |
635 | 656 | ||
636 | return 0; | 657 | return 0; |
658 | |||
659 | err_acpi: | ||
660 | printk(KERN_ERR PFX "No ACPI support for CPU frequency changes.\n"); | ||
661 | return -ENODEV; | ||
637 | } | 662 | } |
638 | 663 | ||
639 | static int __devexit longhaul_cpu_exit(struct cpufreq_policy *policy) | 664 | static int __devexit longhaul_cpu_exit(struct cpufreq_policy *policy) |
@@ -666,6 +691,18 @@ static int __init longhaul_init(void) | |||
666 | if (c->x86_vendor != X86_VENDOR_CENTAUR || c->x86 != 6) | 691 | if (c->x86_vendor != X86_VENDOR_CENTAUR || c->x86 != 6) |
667 | return -ENODEV; | 692 | return -ENODEV; |
668 | 693 | ||
694 | #ifdef CONFIG_SMP | ||
695 | if (num_online_cpus() > 1) { | ||
696 | return -ENODEV; | ||
697 | printk(KERN_ERR PFX "More than 1 CPU detected, longhaul disabled.\n"); | ||
698 | } | ||
699 | #endif | ||
700 | #ifdef CONFIG_X86_IO_APIC | ||
701 | if (cpu_has_apic) { | ||
702 | printk(KERN_ERR PFX "APIC detected. Longhaul is currently broken in this configuration.\n"); | ||
703 | return -ENODEV; | ||
704 | } | ||
705 | #endif | ||
669 | switch (c->x86_model) { | 706 | switch (c->x86_model) { |
670 | case 6 ... 9: | 707 | case 6 ... 9: |
671 | return cpufreq_register_driver(&longhaul_driver); | 708 | return cpufreq_register_driver(&longhaul_driver); |
@@ -699,6 +736,6 @@ MODULE_AUTHOR ("Dave Jones <davej@codemonkey.org.uk>"); | |||
699 | MODULE_DESCRIPTION ("Longhaul driver for VIA Cyrix processors."); | 736 | MODULE_DESCRIPTION ("Longhaul driver for VIA Cyrix processors."); |
700 | MODULE_LICENSE ("GPL"); | 737 | MODULE_LICENSE ("GPL"); |
701 | 738 | ||
702 | module_init(longhaul_init); | 739 | late_initcall(longhaul_init); |
703 | module_exit(longhaul_exit); | 740 | module_exit(longhaul_exit); |
704 | 741 | ||
diff --git a/arch/i386/kernel/cpu/intel_cacheinfo.c b/arch/i386/kernel/cpu/intel_cacheinfo.c index e9f0b928b0a9..5c43be47587f 100644 --- a/arch/i386/kernel/cpu/intel_cacheinfo.c +++ b/arch/i386/kernel/cpu/intel_cacheinfo.c | |||
@@ -759,7 +759,7 @@ static int __cpuinit cache_sysfs_init(void) | |||
759 | if (num_cache_leaves == 0) | 759 | if (num_cache_leaves == 0) |
760 | return 0; | 760 | return 0; |
761 | 761 | ||
762 | register_cpu_notifier(&cacheinfo_cpu_notifier); | 762 | register_hotcpu_notifier(&cacheinfo_cpu_notifier); |
763 | 763 | ||
764 | for_each_online_cpu(i) { | 764 | for_each_online_cpu(i) { |
765 | cacheinfo_cpu_callback(&cacheinfo_cpu_notifier, CPU_ONLINE, | 765 | cacheinfo_cpu_callback(&cacheinfo_cpu_notifier, CPU_ONLINE, |
diff --git a/arch/i386/kernel/cpu/mcheck/mce.h b/arch/i386/kernel/cpu/mcheck/mce.h index dc2416dfef15..84fd4cf7d0fb 100644 --- a/arch/i386/kernel/cpu/mcheck/mce.h +++ b/arch/i386/kernel/cpu/mcheck/mce.h | |||
@@ -9,6 +9,6 @@ void winchip_mcheck_init(struct cpuinfo_x86 *c); | |||
9 | /* Call the installed machine check handler for this CPU setup. */ | 9 | /* Call the installed machine check handler for this CPU setup. */ |
10 | extern fastcall void (*machine_check_vector)(struct pt_regs *, long error_code); | 10 | extern fastcall void (*machine_check_vector)(struct pt_regs *, long error_code); |
11 | 11 | ||
12 | extern int mce_disabled __initdata; | 12 | extern int mce_disabled; |
13 | extern int nr_mce_banks; | 13 | extern int nr_mce_banks; |
14 | 14 | ||
diff --git a/arch/i386/kernel/entry.S b/arch/i386/kernel/entry.S index d9a260f2efb4..37a7d2eaf4a0 100644 --- a/arch/i386/kernel/entry.S +++ b/arch/i386/kernel/entry.S | |||
@@ -204,7 +204,7 @@ VM_MASK = 0x00020000 | |||
204 | ENTRY(ret_from_fork) | 204 | ENTRY(ret_from_fork) |
205 | CFI_STARTPROC | 205 | CFI_STARTPROC |
206 | pushl %eax | 206 | pushl %eax |
207 | CFI_ADJUST_CFA_OFFSET -4 | 207 | CFI_ADJUST_CFA_OFFSET 4 |
208 | call schedule_tail | 208 | call schedule_tail |
209 | GET_THREAD_INFO(%ebp) | 209 | GET_THREAD_INFO(%ebp) |
210 | popl %eax | 210 | popl %eax |
diff --git a/arch/i386/kernel/kprobes.c b/arch/i386/kernel/kprobes.c index de2e16e561c0..afe6505ca0b3 100644 --- a/arch/i386/kernel/kprobes.c +++ b/arch/i386/kernel/kprobes.c | |||
@@ -256,11 +256,6 @@ static int __kprobes kprobe_handler(struct pt_regs *regs) | |||
256 | int ret = 0; | 256 | int ret = 0; |
257 | kprobe_opcode_t *addr; | 257 | kprobe_opcode_t *addr; |
258 | struct kprobe_ctlblk *kcb; | 258 | struct kprobe_ctlblk *kcb; |
259 | #ifdef CONFIG_PREEMPT | ||
260 | unsigned pre_preempt_count = preempt_count(); | ||
261 | #else | ||
262 | unsigned pre_preempt_count = 1; | ||
263 | #endif | ||
264 | 259 | ||
265 | addr = (kprobe_opcode_t *)(regs->eip - sizeof(kprobe_opcode_t)); | 260 | addr = (kprobe_opcode_t *)(regs->eip - sizeof(kprobe_opcode_t)); |
266 | 261 | ||
@@ -338,13 +333,15 @@ static int __kprobes kprobe_handler(struct pt_regs *regs) | |||
338 | return 1; | 333 | return 1; |
339 | 334 | ||
340 | ss_probe: | 335 | ss_probe: |
341 | if (pre_preempt_count && p->ainsn.boostable == 1 && !p->post_handler){ | 336 | #ifndef CONFIG_PREEMPT |
337 | if (p->ainsn.boostable == 1 && !p->post_handler){ | ||
342 | /* Boost up -- we can execute copied instructions directly */ | 338 | /* Boost up -- we can execute copied instructions directly */ |
343 | reset_current_kprobe(); | 339 | reset_current_kprobe(); |
344 | regs->eip = (unsigned long)p->ainsn.insn; | 340 | regs->eip = (unsigned long)p->ainsn.insn; |
345 | preempt_enable_no_resched(); | 341 | preempt_enable_no_resched(); |
346 | return 1; | 342 | return 1; |
347 | } | 343 | } |
344 | #endif | ||
348 | prepare_singlestep(p, regs); | 345 | prepare_singlestep(p, regs); |
349 | kcb->kprobe_status = KPROBE_HIT_SS; | 346 | kcb->kprobe_status = KPROBE_HIT_SS; |
350 | return 1; | 347 | return 1; |
diff --git a/arch/i386/kernel/machine_kexec.c b/arch/i386/kernel/machine_kexec.c index 511abe52a94e..6b1ae6ba76f0 100644 --- a/arch/i386/kernel/machine_kexec.c +++ b/arch/i386/kernel/machine_kexec.c | |||
@@ -189,14 +189,11 @@ NORET_TYPE void machine_kexec(struct kimage *image) | |||
189 | memcpy((void *)reboot_code_buffer, relocate_new_kernel, | 189 | memcpy((void *)reboot_code_buffer, relocate_new_kernel, |
190 | relocate_new_kernel_size); | 190 | relocate_new_kernel_size); |
191 | 191 | ||
192 | /* The segment registers are funny things, they are | 192 | /* The segment registers are funny things, they have both a |
193 | * automatically loaded from a table, in memory wherever you | 193 | * visible and an invisible part. Whenever the visible part is |
194 | * set them to a specific selector, but this table is never | 194 | * set to a specific selector, the invisible part is loaded |
195 | * accessed again you set the segment to a different selector. | 195 | * with from a table in memory. At no other time is the |
196 | * | 196 | * descriptor table in memory accessed. |
197 | * The more common model is are caches where the behide | ||
198 | * the scenes work is done, but is also dropped at arbitrary | ||
199 | * times. | ||
200 | * | 197 | * |
201 | * I take advantage of this here by force loading the | 198 | * I take advantage of this here by force loading the |
202 | * segments, before I zap the gdt with an invalid value. | 199 | * segments, before I zap the gdt with an invalid value. |
diff --git a/arch/i386/kernel/nmi.c b/arch/i386/kernel/nmi.c index 2dd928a84645..acb351478e42 100644 --- a/arch/i386/kernel/nmi.c +++ b/arch/i386/kernel/nmi.c | |||
@@ -575,6 +575,7 @@ void touch_nmi_watchdog (void) | |||
575 | */ | 575 | */ |
576 | touch_softlockup_watchdog(); | 576 | touch_softlockup_watchdog(); |
577 | } | 577 | } |
578 | EXPORT_SYMBOL(touch_nmi_watchdog); | ||
578 | 579 | ||
579 | extern void die_nmi(struct pt_regs *, const char *msg); | 580 | extern void die_nmi(struct pt_regs *, const char *msg); |
580 | 581 | ||
diff --git a/arch/i386/kernel/process.c b/arch/i386/kernel/process.c index 923bb292f47f..8657c739656a 100644 --- a/arch/i386/kernel/process.c +++ b/arch/i386/kernel/process.c | |||
@@ -690,8 +690,8 @@ struct task_struct fastcall * __switch_to(struct task_struct *prev_p, struct tas | |||
690 | /* | 690 | /* |
691 | * Now maybe handle debug registers and/or IO bitmaps | 691 | * Now maybe handle debug registers and/or IO bitmaps |
692 | */ | 692 | */ |
693 | if (unlikely((task_thread_info(next_p)->flags & _TIF_WORK_CTXSW)) | 693 | if (unlikely((task_thread_info(next_p)->flags & _TIF_WORK_CTXSW) |
694 | || test_tsk_thread_flag(prev_p, TIF_IO_BITMAP)) | 694 | || test_tsk_thread_flag(prev_p, TIF_IO_BITMAP))) |
695 | __switch_to_xtra(next_p, tss); | 695 | __switch_to_xtra(next_p, tss); |
696 | 696 | ||
697 | disable_tsc(prev_p, next_p); | 697 | disable_tsc(prev_p, next_p); |
diff --git a/arch/i386/kernel/smpboot.c b/arch/i386/kernel/smpboot.c index 6f5fea05f1d7..f948419c888a 100644 --- a/arch/i386/kernel/smpboot.c +++ b/arch/i386/kernel/smpboot.c | |||
@@ -212,14 +212,20 @@ valid_k7: | |||
212 | * then we print a warning if not, and always resync. | 212 | * then we print a warning if not, and always resync. |
213 | */ | 213 | */ |
214 | 214 | ||
215 | static atomic_t tsc_start_flag = ATOMIC_INIT(0); | 215 | static struct { |
216 | static atomic_t tsc_count_start = ATOMIC_INIT(0); | 216 | atomic_t start_flag; |
217 | static atomic_t tsc_count_stop = ATOMIC_INIT(0); | 217 | atomic_t count_start; |
218 | static unsigned long long tsc_values[NR_CPUS]; | 218 | atomic_t count_stop; |
219 | unsigned long long values[NR_CPUS]; | ||
220 | } tsc __initdata = { | ||
221 | .start_flag = ATOMIC_INIT(0), | ||
222 | .count_start = ATOMIC_INIT(0), | ||
223 | .count_stop = ATOMIC_INIT(0), | ||
224 | }; | ||
219 | 225 | ||
220 | #define NR_LOOPS 5 | 226 | #define NR_LOOPS 5 |
221 | 227 | ||
222 | static void __init synchronize_tsc_bp (void) | 228 | static void __init synchronize_tsc_bp(void) |
223 | { | 229 | { |
224 | int i; | 230 | int i; |
225 | unsigned long long t0; | 231 | unsigned long long t0; |
@@ -233,7 +239,7 @@ static void __init synchronize_tsc_bp (void) | |||
233 | /* convert from kcyc/sec to cyc/usec */ | 239 | /* convert from kcyc/sec to cyc/usec */ |
234 | one_usec = cpu_khz / 1000; | 240 | one_usec = cpu_khz / 1000; |
235 | 241 | ||
236 | atomic_set(&tsc_start_flag, 1); | 242 | atomic_set(&tsc.start_flag, 1); |
237 | wmb(); | 243 | wmb(); |
238 | 244 | ||
239 | /* | 245 | /* |
@@ -250,16 +256,16 @@ static void __init synchronize_tsc_bp (void) | |||
250 | /* | 256 | /* |
251 | * all APs synchronize but they loop on '== num_cpus' | 257 | * all APs synchronize but they loop on '== num_cpus' |
252 | */ | 258 | */ |
253 | while (atomic_read(&tsc_count_start) != num_booting_cpus()-1) | 259 | while (atomic_read(&tsc.count_start) != num_booting_cpus()-1) |
254 | cpu_relax(); | 260 | cpu_relax(); |
255 | atomic_set(&tsc_count_stop, 0); | 261 | atomic_set(&tsc.count_stop, 0); |
256 | wmb(); | 262 | wmb(); |
257 | /* | 263 | /* |
258 | * this lets the APs save their current TSC: | 264 | * this lets the APs save their current TSC: |
259 | */ | 265 | */ |
260 | atomic_inc(&tsc_count_start); | 266 | atomic_inc(&tsc.count_start); |
261 | 267 | ||
262 | rdtscll(tsc_values[smp_processor_id()]); | 268 | rdtscll(tsc.values[smp_processor_id()]); |
263 | /* | 269 | /* |
264 | * We clear the TSC in the last loop: | 270 | * We clear the TSC in the last loop: |
265 | */ | 271 | */ |
@@ -269,56 +275,54 @@ static void __init synchronize_tsc_bp (void) | |||
269 | /* | 275 | /* |
270 | * Wait for all APs to leave the synchronization point: | 276 | * Wait for all APs to leave the synchronization point: |
271 | */ | 277 | */ |
272 | while (atomic_read(&tsc_count_stop) != num_booting_cpus()-1) | 278 | while (atomic_read(&tsc.count_stop) != num_booting_cpus()-1) |
273 | cpu_relax(); | 279 | cpu_relax(); |
274 | atomic_set(&tsc_count_start, 0); | 280 | atomic_set(&tsc.count_start, 0); |
275 | wmb(); | 281 | wmb(); |
276 | atomic_inc(&tsc_count_stop); | 282 | atomic_inc(&tsc.count_stop); |
277 | } | 283 | } |
278 | 284 | ||
279 | sum = 0; | 285 | sum = 0; |
280 | for (i = 0; i < NR_CPUS; i++) { | 286 | for (i = 0; i < NR_CPUS; i++) { |
281 | if (cpu_isset(i, cpu_callout_map)) { | 287 | if (cpu_isset(i, cpu_callout_map)) { |
282 | t0 = tsc_values[i]; | 288 | t0 = tsc.values[i]; |
283 | sum += t0; | 289 | sum += t0; |
284 | } | 290 | } |
285 | } | 291 | } |
286 | avg = sum; | 292 | avg = sum; |
287 | do_div(avg, num_booting_cpus()); | 293 | do_div(avg, num_booting_cpus()); |
288 | 294 | ||
289 | sum = 0; | ||
290 | for (i = 0; i < NR_CPUS; i++) { | 295 | for (i = 0; i < NR_CPUS; i++) { |
291 | if (!cpu_isset(i, cpu_callout_map)) | 296 | if (!cpu_isset(i, cpu_callout_map)) |
292 | continue; | 297 | continue; |
293 | delta = tsc_values[i] - avg; | 298 | delta = tsc.values[i] - avg; |
294 | if (delta < 0) | 299 | if (delta < 0) |
295 | delta = -delta; | 300 | delta = -delta; |
296 | /* | 301 | /* |
297 | * We report bigger than 2 microseconds clock differences. | 302 | * We report bigger than 2 microseconds clock differences. |
298 | */ | 303 | */ |
299 | if (delta > 2*one_usec) { | 304 | if (delta > 2*one_usec) { |
300 | long realdelta; | 305 | long long realdelta; |
306 | |||
301 | if (!buggy) { | 307 | if (!buggy) { |
302 | buggy = 1; | 308 | buggy = 1; |
303 | printk("\n"); | 309 | printk("\n"); |
304 | } | 310 | } |
305 | realdelta = delta; | 311 | realdelta = delta; |
306 | do_div(realdelta, one_usec); | 312 | do_div(realdelta, one_usec); |
307 | if (tsc_values[i] < avg) | 313 | if (tsc.values[i] < avg) |
308 | realdelta = -realdelta; | 314 | realdelta = -realdelta; |
309 | 315 | ||
310 | if (realdelta > 0) | 316 | if (realdelta) |
311 | printk(KERN_INFO "CPU#%d had %ld usecs TSC " | 317 | printk(KERN_INFO "CPU#%d had %Ld usecs TSC " |
312 | "skew, fixed it up.\n", i, realdelta); | 318 | "skew, fixed it up.\n", i, realdelta); |
313 | } | 319 | } |
314 | |||
315 | sum += delta; | ||
316 | } | 320 | } |
317 | if (!buggy) | 321 | if (!buggy) |
318 | printk("passed.\n"); | 322 | printk("passed.\n"); |
319 | } | 323 | } |
320 | 324 | ||
321 | static void __init synchronize_tsc_ap (void) | 325 | static void __init synchronize_tsc_ap(void) |
322 | { | 326 | { |
323 | int i; | 327 | int i; |
324 | 328 | ||
@@ -327,20 +331,20 @@ static void __init synchronize_tsc_ap (void) | |||
327 | * this gets called, so we first wait for the BP to | 331 | * this gets called, so we first wait for the BP to |
328 | * finish SMP initialization: | 332 | * finish SMP initialization: |
329 | */ | 333 | */ |
330 | while (!atomic_read(&tsc_start_flag)) | 334 | while (!atomic_read(&tsc.start_flag)) |
331 | cpu_relax(); | 335 | cpu_relax(); |
332 | 336 | ||
333 | for (i = 0; i < NR_LOOPS; i++) { | 337 | for (i = 0; i < NR_LOOPS; i++) { |
334 | atomic_inc(&tsc_count_start); | 338 | atomic_inc(&tsc.count_start); |
335 | while (atomic_read(&tsc_count_start) != num_booting_cpus()) | 339 | while (atomic_read(&tsc.count_start) != num_booting_cpus()) |
336 | cpu_relax(); | 340 | cpu_relax(); |
337 | 341 | ||
338 | rdtscll(tsc_values[smp_processor_id()]); | 342 | rdtscll(tsc.values[smp_processor_id()]); |
339 | if (i == NR_LOOPS-1) | 343 | if (i == NR_LOOPS-1) |
340 | write_tsc(0, 0); | 344 | write_tsc(0, 0); |
341 | 345 | ||
342 | atomic_inc(&tsc_count_stop); | 346 | atomic_inc(&tsc.count_stop); |
343 | while (atomic_read(&tsc_count_stop) != num_booting_cpus()) | 347 | while (atomic_read(&tsc.count_stop) != num_booting_cpus()) |
344 | cpu_relax(); | 348 | cpu_relax(); |
345 | } | 349 | } |
346 | } | 350 | } |
diff --git a/arch/i386/kernel/time.c b/arch/i386/kernel/time.c index 8705c0f05788..edd00f6cee37 100644 --- a/arch/i386/kernel/time.c +++ b/arch/i386/kernel/time.c | |||
@@ -135,7 +135,7 @@ unsigned long profile_pc(struct pt_regs *regs) | |||
135 | { | 135 | { |
136 | unsigned long pc = instruction_pointer(regs); | 136 | unsigned long pc = instruction_pointer(regs); |
137 | 137 | ||
138 | if (in_lock_functions(pc)) | 138 | if (!user_mode_vm(regs) && in_lock_functions(pc)) |
139 | return *(unsigned long *)(regs->ebp + 4); | 139 | return *(unsigned long *)(regs->ebp + 4); |
140 | 140 | ||
141 | return pc; | 141 | return pc; |
diff --git a/arch/i386/kernel/traps.c b/arch/i386/kernel/traps.c index 313ac1f7dc5a..0d4005dc06c5 100644 --- a/arch/i386/kernel/traps.c +++ b/arch/i386/kernel/traps.c | |||
@@ -187,10 +187,21 @@ static void show_trace_log_lvl(struct task_struct *task, struct pt_regs *regs, | |||
187 | if (unwind_init_blocked(&info, task) == 0) | 187 | if (unwind_init_blocked(&info, task) == 0) |
188 | unw_ret = show_trace_unwind(&info, log_lvl); | 188 | unw_ret = show_trace_unwind(&info, log_lvl); |
189 | } | 189 | } |
190 | if (unw_ret > 0) { | 190 | if (unw_ret > 0 && !arch_unw_user_mode(&info)) { |
191 | if (call_trace > 0) | 191 | #ifdef CONFIG_STACK_UNWIND |
192 | print_symbol("DWARF2 unwinder stuck at %s\n", | ||
193 | UNW_PC(&info)); | ||
194 | if (call_trace == 1) { | ||
195 | printk("Leftover inexact backtrace:\n"); | ||
196 | if (UNW_SP(&info)) | ||
197 | stack = (void *)UNW_SP(&info); | ||
198 | } else if (call_trace > 1) | ||
192 | return; | 199 | return; |
193 | printk("%sLegacy call trace:\n", log_lvl); | 200 | else |
201 | printk("Full inexact backtrace again:\n"); | ||
202 | #else | ||
203 | printk("Inexact backtrace:\n"); | ||
204 | #endif | ||
194 | } | 205 | } |
195 | } | 206 | } |
196 | 207 | ||
@@ -442,11 +453,9 @@ void die(const char * str, struct pt_regs * regs, long err) | |||
442 | if (in_interrupt()) | 453 | if (in_interrupt()) |
443 | panic("Fatal exception in interrupt"); | 454 | panic("Fatal exception in interrupt"); |
444 | 455 | ||
445 | if (panic_on_oops) { | 456 | if (panic_on_oops) |
446 | printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); | 457 | panic("Fatal exception: panic_on_oops"); |
447 | ssleep(5); | 458 | |
448 | panic("Fatal exception"); | ||
449 | } | ||
450 | oops_exit(); | 459 | oops_exit(); |
451 | do_exit(SIGSEGV); | 460 | do_exit(SIGSEGV); |
452 | } | 461 | } |
@@ -1238,8 +1247,10 @@ static int __init call_trace_setup(char *s) | |||
1238 | call_trace = -1; | 1247 | call_trace = -1; |
1239 | else if (strcmp(s, "both") == 0) | 1248 | else if (strcmp(s, "both") == 0) |
1240 | call_trace = 0; | 1249 | call_trace = 0; |
1241 | else if (strcmp(s, "new") == 0) | 1250 | else if (strcmp(s, "newfallback") == 0) |
1242 | call_trace = 1; | 1251 | call_trace = 1; |
1252 | else if (strcmp(s, "new") == 2) | ||
1253 | call_trace = 2; | ||
1243 | return 1; | 1254 | return 1; |
1244 | } | 1255 | } |
1245 | __setup("call_trace=", call_trace_setup); | 1256 | __setup("call_trace=", call_trace_setup); |
diff --git a/arch/i386/kernel/vsyscall.lds.S b/arch/i386/kernel/vsyscall.lds.S index e26975fc68b6..f66cd11adb72 100644 --- a/arch/i386/kernel/vsyscall.lds.S +++ b/arch/i386/kernel/vsyscall.lds.S | |||
@@ -10,6 +10,7 @@ SECTIONS | |||
10 | . = VDSO_PRELINK + SIZEOF_HEADERS; | 10 | . = VDSO_PRELINK + SIZEOF_HEADERS; |
11 | 11 | ||
12 | .hash : { *(.hash) } :text | 12 | .hash : { *(.hash) } :text |
13 | .gnu.hash : { *(.gnu.hash) } | ||
13 | .dynsym : { *(.dynsym) } | 14 | .dynsym : { *(.dynsym) } |
14 | .dynstr : { *(.dynstr) } | 15 | .dynstr : { *(.dynstr) } |
15 | .gnu.version : { *(.gnu.version) } | 16 | .gnu.version : { *(.gnu.version) } |
diff --git a/arch/ia64/configs/sn2_defconfig b/arch/ia64/configs/sn2_defconfig index 9ea35398e10d..0f14a82b856e 100644 --- a/arch/ia64/configs/sn2_defconfig +++ b/arch/ia64/configs/sn2_defconfig | |||
@@ -363,7 +363,7 @@ CONFIG_BLK_DEV_IDECD=y | |||
363 | # | 363 | # |
364 | CONFIG_IDE_GENERIC=y | 364 | CONFIG_IDE_GENERIC=y |
365 | CONFIG_BLK_DEV_IDEPCI=y | 365 | CONFIG_BLK_DEV_IDEPCI=y |
366 | # CONFIG_IDEPCI_SHARE_IRQ is not set | 366 | CONFIG_IDEPCI_SHARE_IRQ=y |
367 | # CONFIG_BLK_DEV_OFFBOARD is not set | 367 | # CONFIG_BLK_DEV_OFFBOARD is not set |
368 | # CONFIG_BLK_DEV_GENERIC is not set | 368 | # CONFIG_BLK_DEV_GENERIC is not set |
369 | # CONFIG_BLK_DEV_OPTI621 is not set | 369 | # CONFIG_BLK_DEV_OPTI621 is not set |
diff --git a/arch/ia64/defconfig b/arch/ia64/defconfig index 6cba55da572a..9001b3fbaa32 100644 --- a/arch/ia64/defconfig +++ b/arch/ia64/defconfig | |||
@@ -366,7 +366,7 @@ CONFIG_BLK_DEV_IDESCSI=m | |||
366 | # CONFIG_IDE_GENERIC is not set | 366 | # CONFIG_IDE_GENERIC is not set |
367 | # CONFIG_BLK_DEV_IDEPNP is not set | 367 | # CONFIG_BLK_DEV_IDEPNP is not set |
368 | CONFIG_BLK_DEV_IDEPCI=y | 368 | CONFIG_BLK_DEV_IDEPCI=y |
369 | # CONFIG_IDEPCI_SHARE_IRQ is not set | 369 | CONFIG_IDEPCI_SHARE_IRQ=y |
370 | # CONFIG_BLK_DEV_OFFBOARD is not set | 370 | # CONFIG_BLK_DEV_OFFBOARD is not set |
371 | CONFIG_BLK_DEV_GENERIC=y | 371 | CONFIG_BLK_DEV_GENERIC=y |
372 | # CONFIG_BLK_DEV_OPTI621 is not set | 372 | # CONFIG_BLK_DEV_OPTI621 is not set |
diff --git a/arch/ia64/kernel/Makefile b/arch/ia64/kernel/Makefile index 0e4553f320bf..ad8215a3c586 100644 --- a/arch/ia64/kernel/Makefile +++ b/arch/ia64/kernel/Makefile | |||
@@ -45,7 +45,8 @@ CPPFLAGS_gate.lds := -P -C -U$(ARCH) | |||
45 | quiet_cmd_gate = GATE $@ | 45 | quiet_cmd_gate = GATE $@ |
46 | cmd_gate = $(CC) -nostdlib $(GATECFLAGS_$(@F)) -Wl,-T,$(filter-out FORCE,$^) -o $@ | 46 | cmd_gate = $(CC) -nostdlib $(GATECFLAGS_$(@F)) -Wl,-T,$(filter-out FORCE,$^) -o $@ |
47 | 47 | ||
48 | GATECFLAGS_gate.so = -shared -s -Wl,-soname=linux-gate.so.1 | 48 | GATECFLAGS_gate.so = -shared -s -Wl,-soname=linux-gate.so.1 \ |
49 | $(call ld-option, -Wl$(comma)--hash-style=sysv) | ||
49 | $(obj)/gate.so: $(obj)/gate.lds $(obj)/gate.o FORCE | 50 | $(obj)/gate.so: $(obj)/gate.lds $(obj)/gate.o FORCE |
50 | $(call if_changed,gate) | 51 | $(call if_changed,gate) |
51 | 52 | ||
diff --git a/arch/ia64/kernel/efi.c b/arch/ia64/kernel/efi.c index e4bfa9dafbce..bb8770a177b5 100644 --- a/arch/ia64/kernel/efi.c +++ b/arch/ia64/kernel/efi.c | |||
@@ -632,7 +632,7 @@ kern_memory_descriptor (unsigned long phys_addr) | |||
632 | if (phys_addr - md->start < (md->num_pages << EFI_PAGE_SHIFT)) | 632 | if (phys_addr - md->start < (md->num_pages << EFI_PAGE_SHIFT)) |
633 | return md; | 633 | return md; |
634 | } | 634 | } |
635 | return 0; | 635 | return NULL; |
636 | } | 636 | } |
637 | 637 | ||
638 | static efi_memory_desc_t * | 638 | static efi_memory_desc_t * |
@@ -652,7 +652,7 @@ efi_memory_descriptor (unsigned long phys_addr) | |||
652 | if (phys_addr - md->phys_addr < (md->num_pages << EFI_PAGE_SHIFT)) | 652 | if (phys_addr - md->phys_addr < (md->num_pages << EFI_PAGE_SHIFT)) |
653 | return md; | 653 | return md; |
654 | } | 654 | } |
655 | return 0; | 655 | return NULL; |
656 | } | 656 | } |
657 | 657 | ||
658 | u32 | 658 | u32 |
@@ -923,7 +923,7 @@ find_memmap_space (void) | |||
923 | void | 923 | void |
924 | efi_memmap_init(unsigned long *s, unsigned long *e) | 924 | efi_memmap_init(unsigned long *s, unsigned long *e) |
925 | { | 925 | { |
926 | struct kern_memdesc *k, *prev = 0; | 926 | struct kern_memdesc *k, *prev = NULL; |
927 | u64 contig_low=0, contig_high=0; | 927 | u64 contig_low=0, contig_high=0; |
928 | u64 as, ae, lim; | 928 | u64 as, ae, lim; |
929 | void *efi_map_start, *efi_map_end, *p, *q; | 929 | void *efi_map_start, *efi_map_end, *p, *q; |
diff --git a/arch/ia64/kernel/gate.lds.S b/arch/ia64/kernel/gate.lds.S index cc35cddfd4cf..6d198339bf85 100644 --- a/arch/ia64/kernel/gate.lds.S +++ b/arch/ia64/kernel/gate.lds.S | |||
@@ -12,6 +12,7 @@ SECTIONS | |||
12 | . = GATE_ADDR + SIZEOF_HEADERS; | 12 | . = GATE_ADDR + SIZEOF_HEADERS; |
13 | 13 | ||
14 | .hash : { *(.hash) } :readable | 14 | .hash : { *(.hash) } :readable |
15 | .gnu.hash : { *(.gnu.hash) } | ||
15 | .dynsym : { *(.dynsym) } | 16 | .dynsym : { *(.dynsym) } |
16 | .dynstr : { *(.dynstr) } | 17 | .dynstr : { *(.dynstr) } |
17 | .gnu.version : { *(.gnu.version) } | 18 | .gnu.version : { *(.gnu.version) } |
diff --git a/arch/ia64/kernel/head.S b/arch/ia64/kernel/head.S index 561b8f1d3bc7..29236f0c62b5 100644 --- a/arch/ia64/kernel/head.S +++ b/arch/ia64/kernel/head.S | |||
@@ -853,7 +853,6 @@ END(__ia64_init_fpu) | |||
853 | */ | 853 | */ |
854 | GLOBAL_ENTRY(ia64_switch_mode_phys) | 854 | GLOBAL_ENTRY(ia64_switch_mode_phys) |
855 | { | 855 | { |
856 | alloc r2=ar.pfs,0,0,0,0 | ||
857 | rsm psr.i | psr.ic // disable interrupts and interrupt collection | 856 | rsm psr.i | psr.ic // disable interrupts and interrupt collection |
858 | mov r15=ip | 857 | mov r15=ip |
859 | } | 858 | } |
@@ -902,7 +901,6 @@ END(ia64_switch_mode_phys) | |||
902 | */ | 901 | */ |
903 | GLOBAL_ENTRY(ia64_switch_mode_virt) | 902 | GLOBAL_ENTRY(ia64_switch_mode_virt) |
904 | { | 903 | { |
905 | alloc r2=ar.pfs,0,0,0,0 | ||
906 | rsm psr.i | psr.ic // disable interrupts and interrupt collection | 904 | rsm psr.i | psr.ic // disable interrupts and interrupt collection |
907 | mov r15=ip | 905 | mov r15=ip |
908 | } | 906 | } |
diff --git a/arch/ia64/kernel/ia64_ksyms.c b/arch/ia64/kernel/ia64_ksyms.c index b7cf651ceb14..3ead20fb6f4b 100644 --- a/arch/ia64/kernel/ia64_ksyms.c +++ b/arch/ia64/kernel/ia64_ksyms.c | |||
@@ -62,7 +62,7 @@ EXPORT_SYMBOL(__udivdi3); | |||
62 | EXPORT_SYMBOL(__moddi3); | 62 | EXPORT_SYMBOL(__moddi3); |
63 | EXPORT_SYMBOL(__umoddi3); | 63 | EXPORT_SYMBOL(__umoddi3); |
64 | 64 | ||
65 | #if defined(CONFIG_MD_RAID5) || defined(CONFIG_MD_RAID5_MODULE) | 65 | #if defined(CONFIG_MD_RAID456) || defined(CONFIG_MD_RAID456_MODULE) |
66 | extern void xor_ia64_2(void); | 66 | extern void xor_ia64_2(void); |
67 | extern void xor_ia64_3(void); | 67 | extern void xor_ia64_3(void); |
68 | extern void xor_ia64_4(void); | 68 | extern void xor_ia64_4(void); |
diff --git a/arch/ia64/kernel/kprobes.c b/arch/ia64/kernel/kprobes.c index 00d9c83b8020..781960f80b6f 100644 --- a/arch/ia64/kernel/kprobes.c +++ b/arch/ia64/kernel/kprobes.c | |||
@@ -448,11 +448,20 @@ int __kprobes arch_prepare_kprobe(struct kprobe *p) | |||
448 | return 0; | 448 | return 0; |
449 | } | 449 | } |
450 | 450 | ||
451 | void __kprobes flush_insn_slot(struct kprobe *p) | ||
452 | { | ||
453 | unsigned long arm_addr; | ||
454 | |||
455 | arm_addr = ((unsigned long)&p->opcode.bundle) & ~0xFULL; | ||
456 | flush_icache_range(arm_addr, arm_addr + sizeof(bundle_t)); | ||
457 | } | ||
458 | |||
451 | void __kprobes arch_arm_kprobe(struct kprobe *p) | 459 | void __kprobes arch_arm_kprobe(struct kprobe *p) |
452 | { | 460 | { |
453 | unsigned long addr = (unsigned long)p->addr; | 461 | unsigned long addr = (unsigned long)p->addr; |
454 | unsigned long arm_addr = addr & ~0xFULL; | 462 | unsigned long arm_addr = addr & ~0xFULL; |
455 | 463 | ||
464 | flush_insn_slot(p); | ||
456 | memcpy((char *)arm_addr, &p->ainsn.insn.bundle, sizeof(bundle_t)); | 465 | memcpy((char *)arm_addr, &p->ainsn.insn.bundle, sizeof(bundle_t)); |
457 | flush_icache_range(arm_addr, arm_addr + sizeof(bundle_t)); | 466 | flush_icache_range(arm_addr, arm_addr + sizeof(bundle_t)); |
458 | } | 467 | } |
diff --git a/arch/ia64/kernel/pal.S b/arch/ia64/kernel/pal.S index 5018c7f2e7a8..ebaf1e685f5e 100644 --- a/arch/ia64/kernel/pal.S +++ b/arch/ia64/kernel/pal.S | |||
@@ -217,12 +217,7 @@ GLOBAL_ENTRY(ia64_pal_call_phys_stacked) | |||
217 | .body | 217 | .body |
218 | ;; | 218 | ;; |
219 | ld8 loc2 = [loc2] // loc2 <- entry point | 219 | ld8 loc2 = [loc2] // loc2 <- entry point |
220 | mov out0 = in0 // first argument | 220 | mov loc3 = psr // save psr |
221 | mov out1 = in1 // copy arg2 | ||
222 | mov out2 = in2 // copy arg3 | ||
223 | mov out3 = in3 // copy arg3 | ||
224 | ;; | ||
225 | mov loc3 = psr // save psr | ||
226 | ;; | 221 | ;; |
227 | mov loc4=ar.rsc // save RSE configuration | 222 | mov loc4=ar.rsc // save RSE configuration |
228 | dep.z loc2=loc2,0,61 // convert pal entry point to physical | 223 | dep.z loc2=loc2,0,61 // convert pal entry point to physical |
@@ -236,18 +231,23 @@ GLOBAL_ENTRY(ia64_pal_call_phys_stacked) | |||
236 | ;; | 231 | ;; |
237 | andcm r16=loc3,r16 // removes bits to clear from psr | 232 | andcm r16=loc3,r16 // removes bits to clear from psr |
238 | br.call.sptk.many rp=ia64_switch_mode_phys | 233 | br.call.sptk.many rp=ia64_switch_mode_phys |
239 | .ret6: | 234 | |
235 | mov out0 = in0 // first argument | ||
236 | mov out1 = in1 // copy arg2 | ||
237 | mov out2 = in2 // copy arg3 | ||
238 | mov out3 = in3 // copy arg3 | ||
240 | mov loc5 = r19 | 239 | mov loc5 = r19 |
241 | mov loc6 = r20 | 240 | mov loc6 = r20 |
241 | |||
242 | br.call.sptk.many rp=b7 // now make the call | 242 | br.call.sptk.many rp=b7 // now make the call |
243 | .ret7: | 243 | |
244 | mov ar.rsc=0 // put RSE in enforced lazy, LE mode | 244 | mov ar.rsc=0 // put RSE in enforced lazy, LE mode |
245 | mov r16=loc3 // r16= original psr | 245 | mov r16=loc3 // r16= original psr |
246 | mov r19=loc5 | 246 | mov r19=loc5 |
247 | mov r20=loc6 | 247 | mov r20=loc6 |
248 | br.call.sptk.many rp=ia64_switch_mode_virt // return to virtual mode | 248 | br.call.sptk.many rp=ia64_switch_mode_virt // return to virtual mode |
249 | 249 | ||
250 | .ret8: mov psr.l = loc3 // restore init PSR | 250 | mov psr.l = loc3 // restore init PSR |
251 | mov ar.pfs = loc1 | 251 | mov ar.pfs = loc1 |
252 | mov rp = loc0 | 252 | mov rp = loc0 |
253 | ;; | 253 | ;; |
diff --git a/arch/ia64/kernel/palinfo.c b/arch/ia64/kernel/palinfo.c index 3f5bac59209a..0b546e2b36ac 100644 --- a/arch/ia64/kernel/palinfo.c +++ b/arch/ia64/kernel/palinfo.c | |||
@@ -566,29 +566,23 @@ version_info(char *page) | |||
566 | pal_version_u_t min_ver, cur_ver; | 566 | pal_version_u_t min_ver, cur_ver; |
567 | char *p = page; | 567 | char *p = page; |
568 | 568 | ||
569 | /* The PAL_VERSION call is advertised as being able to support | 569 | if (ia64_pal_version(&min_ver, &cur_ver) != 0) |
570 | * both physical and virtual mode calls. This seems to be a documentation | 570 | return 0; |
571 | * bug rather than firmware bug. In fact, it does only support physical mode. | ||
572 | * So now the code reflects this fact and the pal_version() has been updated | ||
573 | * accordingly. | ||
574 | */ | ||
575 | if (ia64_pal_version(&min_ver, &cur_ver) != 0) return 0; | ||
576 | 571 | ||
577 | p += sprintf(p, | 572 | p += sprintf(p, |
578 | "PAL_vendor : 0x%02x (min=0x%02x)\n" | 573 | "PAL_vendor : 0x%02x (min=0x%02x)\n" |
579 | "PAL_A : %x.%x.%x (min=%x.%x.%x)\n" | 574 | "PAL_A : %02x.%02x (min=%02x.%02x)\n" |
580 | "PAL_B : %x.%x.%x (min=%x.%x.%x)\n", | 575 | "PAL_B : %02x.%02x (min=%02x.%02x)\n", |
581 | cur_ver.pal_version_s.pv_pal_vendor, min_ver.pal_version_s.pv_pal_vendor, | 576 | cur_ver.pal_version_s.pv_pal_vendor, |
582 | 577 | min_ver.pal_version_s.pv_pal_vendor, | |
583 | cur_ver.pal_version_s.pv_pal_a_model>>4, | 578 | cur_ver.pal_version_s.pv_pal_a_model, |
584 | cur_ver.pal_version_s.pv_pal_a_model&0xf, cur_ver.pal_version_s.pv_pal_a_rev, | 579 | cur_ver.pal_version_s.pv_pal_a_rev, |
585 | min_ver.pal_version_s.pv_pal_a_model>>4, | 580 | min_ver.pal_version_s.pv_pal_a_model, |
586 | min_ver.pal_version_s.pv_pal_a_model&0xf, min_ver.pal_version_s.pv_pal_a_rev, | 581 | min_ver.pal_version_s.pv_pal_a_rev, |
587 | 582 | cur_ver.pal_version_s.pv_pal_b_model, | |
588 | cur_ver.pal_version_s.pv_pal_b_model>>4, | 583 | cur_ver.pal_version_s.pv_pal_b_rev, |
589 | cur_ver.pal_version_s.pv_pal_b_model&0xf, cur_ver.pal_version_s.pv_pal_b_rev, | 584 | min_ver.pal_version_s.pv_pal_b_model, |
590 | min_ver.pal_version_s.pv_pal_b_model>>4, | 585 | min_ver.pal_version_s.pv_pal_b_rev); |
591 | min_ver.pal_version_s.pv_pal_b_model&0xf, min_ver.pal_version_s.pv_pal_b_rev); | ||
592 | return p - page; | 586 | return p - page; |
593 | } | 587 | } |
594 | 588 | ||
@@ -958,9 +952,9 @@ remove_palinfo_proc_entries(unsigned int hcpu) | |||
958 | } | 952 | } |
959 | } | 953 | } |
960 | 954 | ||
961 | static int __cpuinit palinfo_cpu_callback(struct notifier_block *nfb, | 955 | #ifdef CONFIG_HOTPLUG_CPU |
962 | unsigned long action, | 956 | static int palinfo_cpu_callback(struct notifier_block *nfb, |
963 | void *hcpu) | 957 | unsigned long action, void *hcpu) |
964 | { | 958 | { |
965 | unsigned int hotcpu = (unsigned long)hcpu; | 959 | unsigned int hotcpu = (unsigned long)hcpu; |
966 | 960 | ||
@@ -968,20 +962,19 @@ static int __cpuinit palinfo_cpu_callback(struct notifier_block *nfb, | |||
968 | case CPU_ONLINE: | 962 | case CPU_ONLINE: |
969 | create_palinfo_proc_entries(hotcpu); | 963 | create_palinfo_proc_entries(hotcpu); |
970 | break; | 964 | break; |
971 | #ifdef CONFIG_HOTPLUG_CPU | ||
972 | case CPU_DEAD: | 965 | case CPU_DEAD: |
973 | remove_palinfo_proc_entries(hotcpu); | 966 | remove_palinfo_proc_entries(hotcpu); |
974 | break; | 967 | break; |
975 | #endif | ||
976 | } | 968 | } |
977 | return NOTIFY_OK; | 969 | return NOTIFY_OK; |
978 | } | 970 | } |
979 | 971 | ||
980 | static struct notifier_block __cpuinitdata palinfo_cpu_notifier = | 972 | static struct notifier_block palinfo_cpu_notifier = |
981 | { | 973 | { |
982 | .notifier_call = palinfo_cpu_callback, | 974 | .notifier_call = palinfo_cpu_callback, |
983 | .priority = 0, | 975 | .priority = 0, |
984 | }; | 976 | }; |
977 | #endif | ||
985 | 978 | ||
986 | static int __init | 979 | static int __init |
987 | palinfo_init(void) | 980 | palinfo_init(void) |
@@ -1020,7 +1013,7 @@ palinfo_exit(void) | |||
1020 | /* | 1013 | /* |
1021 | * Unregister from cpu notifier callbacks | 1014 | * Unregister from cpu notifier callbacks |
1022 | */ | 1015 | */ |
1023 | unregister_cpu_notifier(&palinfo_cpu_notifier); | 1016 | unregister_hotcpu_notifier(&palinfo_cpu_notifier); |
1024 | } | 1017 | } |
1025 | 1018 | ||
1026 | module_init(palinfo_init); | 1019 | module_init(palinfo_init); |
diff --git a/arch/ia64/kernel/topology.c b/arch/ia64/kernel/topology.c index b146f1cfad31..d24fa393b182 100644 --- a/arch/ia64/kernel/topology.c +++ b/arch/ia64/kernel/topology.c | |||
@@ -435,7 +435,7 @@ static int __cpuinit cache_sysfs_init(void) | |||
435 | (void *)(long)i); | 435 | (void *)(long)i); |
436 | } | 436 | } |
437 | 437 | ||
438 | register_cpu_notifier(&cache_cpu_notifier); | 438 | register_hotcpu_notifier(&cache_cpu_notifier); |
439 | 439 | ||
440 | return 0; | 440 | return 0; |
441 | } | 441 | } |
diff --git a/arch/ia64/kernel/traps.c b/arch/ia64/kernel/traps.c index e7bbb0f40aa2..5a0420464c6c 100644 --- a/arch/ia64/kernel/traps.c +++ b/arch/ia64/kernel/traps.c | |||
@@ -117,11 +117,8 @@ die (const char *str, struct pt_regs *regs, long err) | |||
117 | die.lock_owner = -1; | 117 | die.lock_owner = -1; |
118 | spin_unlock_irq(&die.lock); | 118 | spin_unlock_irq(&die.lock); |
119 | 119 | ||
120 | if (panic_on_oops) { | 120 | if (panic_on_oops) |
121 | printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); | 121 | panic("Fatal exception: panic_on_oops"); |
122 | ssleep(5); | ||
123 | panic("Fatal exception"); | ||
124 | } | ||
125 | 122 | ||
126 | do_exit(SIGSEGV); | 123 | do_exit(SIGSEGV); |
127 | } | 124 | } |
diff --git a/arch/ia64/kernel/uncached.c b/arch/ia64/kernel/uncached.c index 5f03b9e524dd..4c73a6763669 100644 --- a/arch/ia64/kernel/uncached.c +++ b/arch/ia64/kernel/uncached.c | |||
@@ -32,32 +32,38 @@ | |||
32 | 32 | ||
33 | extern void __init efi_memmap_walk_uc(efi_freemem_callback_t, void *); | 33 | extern void __init efi_memmap_walk_uc(efi_freemem_callback_t, void *); |
34 | 34 | ||
35 | #define MAX_UNCACHED_GRANULES 5 | 35 | struct uncached_pool { |
36 | static int allocated_granules; | 36 | struct gen_pool *pool; |
37 | struct mutex add_chunk_mutex; /* serialize adding a converted chunk */ | ||
38 | int nchunks_added; /* #of converted chunks added to pool */ | ||
39 | atomic_t status; /* smp called function's return status*/ | ||
40 | }; | ||
41 | |||
42 | #define MAX_CONVERTED_CHUNKS_PER_NODE 2 | ||
37 | 43 | ||
38 | struct gen_pool *uncached_pool[MAX_NUMNODES]; | 44 | struct uncached_pool uncached_pools[MAX_NUMNODES]; |
39 | 45 | ||
40 | 46 | ||
41 | static void uncached_ipi_visibility(void *data) | 47 | static void uncached_ipi_visibility(void *data) |
42 | { | 48 | { |
43 | int status; | 49 | int status; |
50 | struct uncached_pool *uc_pool = (struct uncached_pool *)data; | ||
44 | 51 | ||
45 | status = ia64_pal_prefetch_visibility(PAL_VISIBILITY_PHYSICAL); | 52 | status = ia64_pal_prefetch_visibility(PAL_VISIBILITY_PHYSICAL); |
46 | if ((status != PAL_VISIBILITY_OK) && | 53 | if ((status != PAL_VISIBILITY_OK) && |
47 | (status != PAL_VISIBILITY_OK_REMOTE_NEEDED)) | 54 | (status != PAL_VISIBILITY_OK_REMOTE_NEEDED)) |
48 | printk(KERN_DEBUG "pal_prefetch_visibility() returns %i on " | 55 | atomic_inc(&uc_pool->status); |
49 | "CPU %i\n", status, raw_smp_processor_id()); | ||
50 | } | 56 | } |
51 | 57 | ||
52 | 58 | ||
53 | static void uncached_ipi_mc_drain(void *data) | 59 | static void uncached_ipi_mc_drain(void *data) |
54 | { | 60 | { |
55 | int status; | 61 | int status; |
62 | struct uncached_pool *uc_pool = (struct uncached_pool *)data; | ||
56 | 63 | ||
57 | status = ia64_pal_mc_drain(); | 64 | status = ia64_pal_mc_drain(); |
58 | if (status) | 65 | if (status != PAL_STATUS_SUCCESS) |
59 | printk(KERN_WARNING "ia64_pal_mc_drain() failed with %i on " | 66 | atomic_inc(&uc_pool->status); |
60 | "CPU %i\n", status, raw_smp_processor_id()); | ||
61 | } | 67 | } |
62 | 68 | ||
63 | 69 | ||
@@ -70,21 +76,34 @@ static void uncached_ipi_mc_drain(void *data) | |||
70 | * This is accomplished by first allocating a granule of cached memory pages | 76 | * This is accomplished by first allocating a granule of cached memory pages |
71 | * and then converting them to uncached memory pages. | 77 | * and then converting them to uncached memory pages. |
72 | */ | 78 | */ |
73 | static int uncached_add_chunk(struct gen_pool *pool, int nid) | 79 | static int uncached_add_chunk(struct uncached_pool *uc_pool, int nid) |
74 | { | 80 | { |
75 | struct page *page; | 81 | struct page *page; |
76 | int status, i; | 82 | int status, i, nchunks_added = uc_pool->nchunks_added; |
77 | unsigned long c_addr, uc_addr; | 83 | unsigned long c_addr, uc_addr; |
78 | 84 | ||
79 | if (allocated_granules >= MAX_UNCACHED_GRANULES) | 85 | if (mutex_lock_interruptible(&uc_pool->add_chunk_mutex) != 0) |
86 | return -1; /* interrupted by a signal */ | ||
87 | |||
88 | if (uc_pool->nchunks_added > nchunks_added) { | ||
89 | /* someone added a new chunk while we were waiting */ | ||
90 | mutex_unlock(&uc_pool->add_chunk_mutex); | ||
91 | return 0; | ||
92 | } | ||
93 | |||
94 | if (uc_pool->nchunks_added >= MAX_CONVERTED_CHUNKS_PER_NODE) { | ||
95 | mutex_unlock(&uc_pool->add_chunk_mutex); | ||
80 | return -1; | 96 | return -1; |
97 | } | ||
81 | 98 | ||
82 | /* attempt to allocate a granule's worth of cached memory pages */ | 99 | /* attempt to allocate a granule's worth of cached memory pages */ |
83 | 100 | ||
84 | page = alloc_pages_node(nid, GFP_KERNEL | __GFP_ZERO, | 101 | page = alloc_pages_node(nid, GFP_KERNEL | __GFP_ZERO, |
85 | IA64_GRANULE_SHIFT-PAGE_SHIFT); | 102 | IA64_GRANULE_SHIFT-PAGE_SHIFT); |
86 | if (!page) | 103 | if (!page) { |
104 | mutex_unlock(&uc_pool->add_chunk_mutex); | ||
87 | return -1; | 105 | return -1; |
106 | } | ||
88 | 107 | ||
89 | /* convert the memory pages from cached to uncached */ | 108 | /* convert the memory pages from cached to uncached */ |
90 | 109 | ||
@@ -102,11 +121,14 @@ static int uncached_add_chunk(struct gen_pool *pool, int nid) | |||
102 | flush_tlb_kernel_range(uc_addr, uc_adddr + IA64_GRANULE_SIZE); | 121 | flush_tlb_kernel_range(uc_addr, uc_adddr + IA64_GRANULE_SIZE); |
103 | 122 | ||
104 | status = ia64_pal_prefetch_visibility(PAL_VISIBILITY_PHYSICAL); | 123 | status = ia64_pal_prefetch_visibility(PAL_VISIBILITY_PHYSICAL); |
105 | if (!status) { | 124 | if (status == PAL_VISIBILITY_OK_REMOTE_NEEDED) { |
106 | status = smp_call_function(uncached_ipi_visibility, NULL, 0, 1); | 125 | atomic_set(&uc_pool->status, 0); |
107 | if (status) | 126 | status = smp_call_function(uncached_ipi_visibility, uc_pool, |
127 | 0, 1); | ||
128 | if (status || atomic_read(&uc_pool->status)) | ||
108 | goto failed; | 129 | goto failed; |
109 | } | 130 | } else if (status != PAL_VISIBILITY_OK) |
131 | goto failed; | ||
110 | 132 | ||
111 | preempt_disable(); | 133 | preempt_disable(); |
112 | 134 | ||
@@ -120,20 +142,24 @@ static int uncached_add_chunk(struct gen_pool *pool, int nid) | |||
120 | 142 | ||
121 | preempt_enable(); | 143 | preempt_enable(); |
122 | 144 | ||
123 | ia64_pal_mc_drain(); | 145 | status = ia64_pal_mc_drain(); |
124 | status = smp_call_function(uncached_ipi_mc_drain, NULL, 0, 1); | 146 | if (status != PAL_STATUS_SUCCESS) |
125 | if (status) | 147 | goto failed; |
148 | atomic_set(&uc_pool->status, 0); | ||
149 | status = smp_call_function(uncached_ipi_mc_drain, uc_pool, 0, 1); | ||
150 | if (status || atomic_read(&uc_pool->status)) | ||
126 | goto failed; | 151 | goto failed; |
127 | 152 | ||
128 | /* | 153 | /* |
129 | * The chunk of memory pages has been converted to uncached so now we | 154 | * The chunk of memory pages has been converted to uncached so now we |
130 | * can add it to the pool. | 155 | * can add it to the pool. |
131 | */ | 156 | */ |
132 | status = gen_pool_add(pool, uc_addr, IA64_GRANULE_SIZE, nid); | 157 | status = gen_pool_add(uc_pool->pool, uc_addr, IA64_GRANULE_SIZE, nid); |
133 | if (status) | 158 | if (status) |
134 | goto failed; | 159 | goto failed; |
135 | 160 | ||
136 | allocated_granules++; | 161 | uc_pool->nchunks_added++; |
162 | mutex_unlock(&uc_pool->add_chunk_mutex); | ||
137 | return 0; | 163 | return 0; |
138 | 164 | ||
139 | /* failed to convert or add the chunk so give it back to the kernel */ | 165 | /* failed to convert or add the chunk so give it back to the kernel */ |
@@ -142,6 +168,7 @@ failed: | |||
142 | ClearPageUncached(&page[i]); | 168 | ClearPageUncached(&page[i]); |
143 | 169 | ||
144 | free_pages(c_addr, IA64_GRANULE_SHIFT-PAGE_SHIFT); | 170 | free_pages(c_addr, IA64_GRANULE_SHIFT-PAGE_SHIFT); |
171 | mutex_unlock(&uc_pool->add_chunk_mutex); | ||
145 | return -1; | 172 | return -1; |
146 | } | 173 | } |
147 | 174 | ||
@@ -158,7 +185,7 @@ failed: | |||
158 | unsigned long uncached_alloc_page(int starting_nid) | 185 | unsigned long uncached_alloc_page(int starting_nid) |
159 | { | 186 | { |
160 | unsigned long uc_addr; | 187 | unsigned long uc_addr; |
161 | struct gen_pool *pool; | 188 | struct uncached_pool *uc_pool; |
162 | int nid; | 189 | int nid; |
163 | 190 | ||
164 | if (unlikely(starting_nid >= MAX_NUMNODES)) | 191 | if (unlikely(starting_nid >= MAX_NUMNODES)) |
@@ -171,14 +198,14 @@ unsigned long uncached_alloc_page(int starting_nid) | |||
171 | do { | 198 | do { |
172 | if (!node_online(nid)) | 199 | if (!node_online(nid)) |
173 | continue; | 200 | continue; |
174 | pool = uncached_pool[nid]; | 201 | uc_pool = &uncached_pools[nid]; |
175 | if (pool == NULL) | 202 | if (uc_pool->pool == NULL) |
176 | continue; | 203 | continue; |
177 | do { | 204 | do { |
178 | uc_addr = gen_pool_alloc(pool, PAGE_SIZE); | 205 | uc_addr = gen_pool_alloc(uc_pool->pool, PAGE_SIZE); |
179 | if (uc_addr != 0) | 206 | if (uc_addr != 0) |
180 | return uc_addr; | 207 | return uc_addr; |
181 | } while (uncached_add_chunk(pool, nid) == 0); | 208 | } while (uncached_add_chunk(uc_pool, nid) == 0); |
182 | 209 | ||
183 | } while ((nid = (nid + 1) % MAX_NUMNODES) != starting_nid); | 210 | } while ((nid = (nid + 1) % MAX_NUMNODES) != starting_nid); |
184 | 211 | ||
@@ -197,7 +224,7 @@ EXPORT_SYMBOL(uncached_alloc_page); | |||
197 | void uncached_free_page(unsigned long uc_addr) | 224 | void uncached_free_page(unsigned long uc_addr) |
198 | { | 225 | { |
199 | int nid = paddr_to_nid(uc_addr - __IA64_UNCACHED_OFFSET); | 226 | int nid = paddr_to_nid(uc_addr - __IA64_UNCACHED_OFFSET); |
200 | struct gen_pool *pool = uncached_pool[nid]; | 227 | struct gen_pool *pool = uncached_pools[nid].pool; |
201 | 228 | ||
202 | if (unlikely(pool == NULL)) | 229 | if (unlikely(pool == NULL)) |
203 | return; | 230 | return; |
@@ -224,7 +251,7 @@ static int __init uncached_build_memmap(unsigned long uc_start, | |||
224 | unsigned long uc_end, void *arg) | 251 | unsigned long uc_end, void *arg) |
225 | { | 252 | { |
226 | int nid = paddr_to_nid(uc_start - __IA64_UNCACHED_OFFSET); | 253 | int nid = paddr_to_nid(uc_start - __IA64_UNCACHED_OFFSET); |
227 | struct gen_pool *pool = uncached_pool[nid]; | 254 | struct gen_pool *pool = uncached_pools[nid].pool; |
228 | size_t size = uc_end - uc_start; | 255 | size_t size = uc_end - uc_start; |
229 | 256 | ||
230 | touch_softlockup_watchdog(); | 257 | touch_softlockup_watchdog(); |
@@ -242,7 +269,8 @@ static int __init uncached_init(void) | |||
242 | int nid; | 269 | int nid; |
243 | 270 | ||
244 | for_each_online_node(nid) { | 271 | for_each_online_node(nid) { |
245 | uncached_pool[nid] = gen_pool_create(PAGE_SHIFT, nid); | 272 | uncached_pools[nid].pool = gen_pool_create(PAGE_SHIFT, nid); |
273 | mutex_init(&uncached_pools[nid].add_chunk_mutex); | ||
246 | } | 274 | } |
247 | 275 | ||
248 | efi_memmap_walk_uc(uncached_build_memmap, NULL); | 276 | efi_memmap_walk_uc(uncached_build_memmap, NULL); |
diff --git a/arch/ia64/lib/Makefile b/arch/ia64/lib/Makefile index d8536a2c22a9..38fa6e49e791 100644 --- a/arch/ia64/lib/Makefile +++ b/arch/ia64/lib/Makefile | |||
@@ -14,7 +14,7 @@ lib-y := __divsi3.o __udivsi3.o __modsi3.o __umodsi3.o \ | |||
14 | lib-$(CONFIG_ITANIUM) += copy_page.o copy_user.o memcpy.o | 14 | lib-$(CONFIG_ITANIUM) += copy_page.o copy_user.o memcpy.o |
15 | lib-$(CONFIG_MCKINLEY) += copy_page_mck.o memcpy_mck.o | 15 | lib-$(CONFIG_MCKINLEY) += copy_page_mck.o memcpy_mck.o |
16 | lib-$(CONFIG_PERFMON) += carta_random.o | 16 | lib-$(CONFIG_PERFMON) += carta_random.o |
17 | lib-$(CONFIG_MD_RAID5) += xor.o | 17 | lib-$(CONFIG_MD_RAID456) += xor.o |
18 | 18 | ||
19 | AFLAGS___divdi3.o = | 19 | AFLAGS___divdi3.o = |
20 | AFLAGS___udivdi3.o = -DUNSIGNED | 20 | AFLAGS___udivdi3.o = -DUNSIGNED |
diff --git a/arch/ia64/mm/contig.c b/arch/ia64/mm/contig.c index 2a88cdd6d924..e004143ba86b 100644 --- a/arch/ia64/mm/contig.c +++ b/arch/ia64/mm/contig.c | |||
@@ -27,6 +27,7 @@ | |||
27 | 27 | ||
28 | #ifdef CONFIG_VIRTUAL_MEM_MAP | 28 | #ifdef CONFIG_VIRTUAL_MEM_MAP |
29 | static unsigned long num_dma_physpages; | 29 | static unsigned long num_dma_physpages; |
30 | static unsigned long max_gap; | ||
30 | #endif | 31 | #endif |
31 | 32 | ||
32 | /** | 33 | /** |
@@ -45,9 +46,15 @@ show_mem (void) | |||
45 | 46 | ||
46 | printk("Free swap: %6ldkB\n", nr_swap_pages<<(PAGE_SHIFT-10)); | 47 | printk("Free swap: %6ldkB\n", nr_swap_pages<<(PAGE_SHIFT-10)); |
47 | i = max_mapnr; | 48 | i = max_mapnr; |
48 | while (i-- > 0) { | 49 | for (i = 0; i < max_mapnr; i++) { |
49 | if (!pfn_valid(i)) | 50 | if (!pfn_valid(i)) { |
51 | #ifdef CONFIG_VIRTUAL_MEM_MAP | ||
52 | if (max_gap < LARGE_GAP) | ||
53 | continue; | ||
54 | i = vmemmap_find_next_valid_pfn(0, i) - 1; | ||
55 | #endif | ||
50 | continue; | 56 | continue; |
57 | } | ||
51 | total++; | 58 | total++; |
52 | if (PageReserved(mem_map+i)) | 59 | if (PageReserved(mem_map+i)) |
53 | reserved++; | 60 | reserved++; |
@@ -234,7 +241,6 @@ paging_init (void) | |||
234 | unsigned long zones_size[MAX_NR_ZONES]; | 241 | unsigned long zones_size[MAX_NR_ZONES]; |
235 | #ifdef CONFIG_VIRTUAL_MEM_MAP | 242 | #ifdef CONFIG_VIRTUAL_MEM_MAP |
236 | unsigned long zholes_size[MAX_NR_ZONES]; | 243 | unsigned long zholes_size[MAX_NR_ZONES]; |
237 | unsigned long max_gap; | ||
238 | #endif | 244 | #endif |
239 | 245 | ||
240 | /* initialize mem_map[] */ | 246 | /* initialize mem_map[] */ |
@@ -266,7 +272,6 @@ paging_init (void) | |||
266 | } | 272 | } |
267 | } | 273 | } |
268 | 274 | ||
269 | max_gap = 0; | ||
270 | efi_memmap_walk(find_largest_hole, (u64 *)&max_gap); | 275 | efi_memmap_walk(find_largest_hole, (u64 *)&max_gap); |
271 | if (max_gap < LARGE_GAP) { | 276 | if (max_gap < LARGE_GAP) { |
272 | vmem_map = (struct page *) 0; | 277 | vmem_map = (struct page *) 0; |
@@ -277,7 +282,8 @@ paging_init (void) | |||
277 | 282 | ||
278 | /* allocate virtual_mem_map */ | 283 | /* allocate virtual_mem_map */ |
279 | 284 | ||
280 | map_size = PAGE_ALIGN(max_low_pfn * sizeof(struct page)); | 285 | map_size = PAGE_ALIGN(ALIGN(max_low_pfn, MAX_ORDER_NR_PAGES) * |
286 | sizeof(struct page)); | ||
281 | vmalloc_end -= map_size; | 287 | vmalloc_end -= map_size; |
282 | vmem_map = (struct page *) vmalloc_end; | 288 | vmem_map = (struct page *) vmalloc_end; |
283 | efi_memmap_walk(create_mem_map_page_table, NULL); | 289 | efi_memmap_walk(create_mem_map_page_table, NULL); |
diff --git a/arch/ia64/mm/discontig.c b/arch/ia64/mm/discontig.c index 99bd9e30db96..d260bffa01ab 100644 --- a/arch/ia64/mm/discontig.c +++ b/arch/ia64/mm/discontig.c | |||
@@ -534,68 +534,6 @@ void __cpuinit *per_cpu_init(void) | |||
534 | } | 534 | } |
535 | #endif /* CONFIG_SMP */ | 535 | #endif /* CONFIG_SMP */ |
536 | 536 | ||
537 | #ifdef CONFIG_VIRTUAL_MEM_MAP | ||
538 | static inline int find_next_valid_pfn_for_pgdat(pg_data_t *pgdat, int i) | ||
539 | { | ||
540 | unsigned long end_address, hole_next_pfn; | ||
541 | unsigned long stop_address; | ||
542 | |||
543 | end_address = (unsigned long) &vmem_map[pgdat->node_start_pfn + i]; | ||
544 | end_address = PAGE_ALIGN(end_address); | ||
545 | |||
546 | stop_address = (unsigned long) &vmem_map[ | ||
547 | pgdat->node_start_pfn + pgdat->node_spanned_pages]; | ||
548 | |||
549 | do { | ||
550 | pgd_t *pgd; | ||
551 | pud_t *pud; | ||
552 | pmd_t *pmd; | ||
553 | pte_t *pte; | ||
554 | |||
555 | pgd = pgd_offset_k(end_address); | ||
556 | if (pgd_none(*pgd)) { | ||
557 | end_address += PGDIR_SIZE; | ||
558 | continue; | ||
559 | } | ||
560 | |||
561 | pud = pud_offset(pgd, end_address); | ||
562 | if (pud_none(*pud)) { | ||
563 | end_address += PUD_SIZE; | ||
564 | continue; | ||
565 | } | ||
566 | |||
567 | pmd = pmd_offset(pud, end_address); | ||
568 | if (pmd_none(*pmd)) { | ||
569 | end_address += PMD_SIZE; | ||
570 | continue; | ||
571 | } | ||
572 | |||
573 | pte = pte_offset_kernel(pmd, end_address); | ||
574 | retry_pte: | ||
575 | if (pte_none(*pte)) { | ||
576 | end_address += PAGE_SIZE; | ||
577 | pte++; | ||
578 | if ((end_address < stop_address) && | ||
579 | (end_address != ALIGN(end_address, 1UL << PMD_SHIFT))) | ||
580 | goto retry_pte; | ||
581 | continue; | ||
582 | } | ||
583 | /* Found next valid vmem_map page */ | ||
584 | break; | ||
585 | } while (end_address < stop_address); | ||
586 | |||
587 | end_address = min(end_address, stop_address); | ||
588 | end_address = end_address - (unsigned long) vmem_map + sizeof(struct page) - 1; | ||
589 | hole_next_pfn = end_address / sizeof(struct page); | ||
590 | return hole_next_pfn - pgdat->node_start_pfn; | ||
591 | } | ||
592 | #else | ||
593 | static inline int find_next_valid_pfn_for_pgdat(pg_data_t *pgdat, int i) | ||
594 | { | ||
595 | return i + 1; | ||
596 | } | ||
597 | #endif | ||
598 | |||
599 | /** | 537 | /** |
600 | * show_mem - give short summary of memory stats | 538 | * show_mem - give short summary of memory stats |
601 | * | 539 | * |
@@ -625,7 +563,8 @@ void show_mem(void) | |||
625 | if (pfn_valid(pgdat->node_start_pfn + i)) | 563 | if (pfn_valid(pgdat->node_start_pfn + i)) |
626 | page = pfn_to_page(pgdat->node_start_pfn + i); | 564 | page = pfn_to_page(pgdat->node_start_pfn + i); |
627 | else { | 565 | else { |
628 | i = find_next_valid_pfn_for_pgdat(pgdat, i) - 1; | 566 | i = vmemmap_find_next_valid_pfn(pgdat->node_id, |
567 | i) - 1; | ||
629 | continue; | 568 | continue; |
630 | } | 569 | } |
631 | if (PageReserved(page)) | 570 | if (PageReserved(page)) |
@@ -751,7 +690,8 @@ void __init paging_init(void) | |||
751 | efi_memmap_walk(filter_rsvd_memory, count_node_pages); | 690 | efi_memmap_walk(filter_rsvd_memory, count_node_pages); |
752 | 691 | ||
753 | #ifdef CONFIG_VIRTUAL_MEM_MAP | 692 | #ifdef CONFIG_VIRTUAL_MEM_MAP |
754 | vmalloc_end -= PAGE_ALIGN(max_low_pfn * sizeof(struct page)); | 693 | vmalloc_end -= PAGE_ALIGN(ALIGN(max_low_pfn, MAX_ORDER_NR_PAGES) * |
694 | sizeof(struct page)); | ||
755 | vmem_map = (struct page *) vmalloc_end; | 695 | vmem_map = (struct page *) vmalloc_end; |
756 | efi_memmap_walk(create_mem_map_page_table, NULL); | 696 | efi_memmap_walk(create_mem_map_page_table, NULL); |
757 | printk("Virtual mem_map starts at 0x%p\n", vmem_map); | 697 | printk("Virtual mem_map starts at 0x%p\n", vmem_map); |
diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c index 2f50c064513c..30617ccb4f7e 100644 --- a/arch/ia64/mm/init.c +++ b/arch/ia64/mm/init.c | |||
@@ -415,6 +415,61 @@ ia64_mmu_init (void *my_cpu_data) | |||
415 | } | 415 | } |
416 | 416 | ||
417 | #ifdef CONFIG_VIRTUAL_MEM_MAP | 417 | #ifdef CONFIG_VIRTUAL_MEM_MAP |
418 | int vmemmap_find_next_valid_pfn(int node, int i) | ||
419 | { | ||
420 | unsigned long end_address, hole_next_pfn; | ||
421 | unsigned long stop_address; | ||
422 | pg_data_t *pgdat = NODE_DATA(node); | ||
423 | |||
424 | end_address = (unsigned long) &vmem_map[pgdat->node_start_pfn + i]; | ||
425 | end_address = PAGE_ALIGN(end_address); | ||
426 | |||
427 | stop_address = (unsigned long) &vmem_map[ | ||
428 | pgdat->node_start_pfn + pgdat->node_spanned_pages]; | ||
429 | |||
430 | do { | ||
431 | pgd_t *pgd; | ||
432 | pud_t *pud; | ||
433 | pmd_t *pmd; | ||
434 | pte_t *pte; | ||
435 | |||
436 | pgd = pgd_offset_k(end_address); | ||
437 | if (pgd_none(*pgd)) { | ||
438 | end_address += PGDIR_SIZE; | ||
439 | continue; | ||
440 | } | ||
441 | |||
442 | pud = pud_offset(pgd, end_address); | ||
443 | if (pud_none(*pud)) { | ||
444 | end_address += PUD_SIZE; | ||
445 | continue; | ||
446 | } | ||
447 | |||
448 | pmd = pmd_offset(pud, end_address); | ||
449 | if (pmd_none(*pmd)) { | ||
450 | end_address += PMD_SIZE; | ||
451 | continue; | ||
452 | } | ||
453 | |||
454 | pte = pte_offset_kernel(pmd, end_address); | ||
455 | retry_pte: | ||
456 | if (pte_none(*pte)) { | ||
457 | end_address += PAGE_SIZE; | ||
458 | pte++; | ||
459 | if ((end_address < stop_address) && | ||
460 | (end_address != ALIGN(end_address, 1UL << PMD_SHIFT))) | ||
461 | goto retry_pte; | ||
462 | continue; | ||
463 | } | ||
464 | /* Found next valid vmem_map page */ | ||
465 | break; | ||
466 | } while (end_address < stop_address); | ||
467 | |||
468 | end_address = min(end_address, stop_address); | ||
469 | end_address = end_address - (unsigned long) vmem_map + sizeof(struct page) - 1; | ||
470 | hole_next_pfn = end_address / sizeof(struct page); | ||
471 | return hole_next_pfn - pgdat->node_start_pfn; | ||
472 | } | ||
418 | 473 | ||
419 | int __init | 474 | int __init |
420 | create_mem_map_page_table (u64 start, u64 end, void *arg) | 475 | create_mem_map_page_table (u64 start, u64 end, void *arg) |
diff --git a/arch/ia64/mm/ioremap.c b/arch/ia64/mm/ioremap.c index 07bd02b6c372..4280c074d64e 100644 --- a/arch/ia64/mm/ioremap.c +++ b/arch/ia64/mm/ioremap.c | |||
@@ -32,7 +32,7 @@ ioremap (unsigned long offset, unsigned long size) | |||
32 | */ | 32 | */ |
33 | attr = kern_mem_attribute(offset, size); | 33 | attr = kern_mem_attribute(offset, size); |
34 | if (attr & EFI_MEMORY_WB) | 34 | if (attr & EFI_MEMORY_WB) |
35 | return phys_to_virt(offset); | 35 | return (void __iomem *) phys_to_virt(offset); |
36 | else if (attr & EFI_MEMORY_UC) | 36 | else if (attr & EFI_MEMORY_UC) |
37 | return __ioremap(offset, size); | 37 | return __ioremap(offset, size); |
38 | 38 | ||
@@ -43,7 +43,7 @@ ioremap (unsigned long offset, unsigned long size) | |||
43 | gran_base = GRANULEROUNDDOWN(offset); | 43 | gran_base = GRANULEROUNDDOWN(offset); |
44 | gran_size = GRANULEROUNDUP(offset + size) - gran_base; | 44 | gran_size = GRANULEROUNDUP(offset + size) - gran_base; |
45 | if (efi_mem_attribute(gran_base, gran_size) & EFI_MEMORY_WB) | 45 | if (efi_mem_attribute(gran_base, gran_size) & EFI_MEMORY_WB) |
46 | return phys_to_virt(offset); | 46 | return (void __iomem *) phys_to_virt(offset); |
47 | 47 | ||
48 | return __ioremap(offset, size); | 48 | return __ioremap(offset, size); |
49 | } | 49 | } |
@@ -53,7 +53,7 @@ void __iomem * | |||
53 | ioremap_nocache (unsigned long offset, unsigned long size) | 53 | ioremap_nocache (unsigned long offset, unsigned long size) |
54 | { | 54 | { |
55 | if (kern_mem_attribute(offset, size) & EFI_MEMORY_WB) | 55 | if (kern_mem_attribute(offset, size) & EFI_MEMORY_WB) |
56 | return 0; | 56 | return NULL; |
57 | 57 | ||
58 | return __ioremap(offset, size); | 58 | return __ioremap(offset, size); |
59 | } | 59 | } |
diff --git a/arch/ia64/sn/kernel/xpc_main.c b/arch/ia64/sn/kernel/xpc_main.c index 99b123a6421a..5e8e59efb347 100644 --- a/arch/ia64/sn/kernel/xpc_main.c +++ b/arch/ia64/sn/kernel/xpc_main.c | |||
@@ -480,7 +480,7 @@ xpc_activating(void *__partid) | |||
480 | partid_t partid = (u64) __partid; | 480 | partid_t partid = (u64) __partid; |
481 | struct xpc_partition *part = &xpc_partitions[partid]; | 481 | struct xpc_partition *part = &xpc_partitions[partid]; |
482 | unsigned long irq_flags; | 482 | unsigned long irq_flags; |
483 | struct sched_param param = { sched_priority: MAX_RT_PRIO - 1 }; | 483 | struct sched_param param = { .sched_priority = MAX_RT_PRIO - 1 }; |
484 | int ret; | 484 | int ret; |
485 | 485 | ||
486 | 486 | ||
diff --git a/arch/ia64/sn/pci/tioce_provider.c b/arch/ia64/sn/pci/tioce_provider.c index 17cd34284886..af7171adcd2c 100644 --- a/arch/ia64/sn/pci/tioce_provider.c +++ b/arch/ia64/sn/pci/tioce_provider.c | |||
@@ -74,7 +74,7 @@ tioce_mmr_war_pre(struct tioce_kernel *kern, void *mmr_addr) | |||
74 | else | 74 | else |
75 | mmr_war_offset = 0x158; | 75 | mmr_war_offset = 0x158; |
76 | 76 | ||
77 | readq_relaxed((void *)(mmr_base + mmr_war_offset)); | 77 | readq_relaxed((void __iomem *)(mmr_base + mmr_war_offset)); |
78 | } | 78 | } |
79 | } | 79 | } |
80 | 80 | ||
@@ -92,8 +92,8 @@ tioce_mmr_war_post(struct tioce_kernel *kern, void *mmr_addr) | |||
92 | 92 | ||
93 | if (mmr_offset < 0x45000) { | 93 | if (mmr_offset < 0x45000) { |
94 | if (mmr_offset == 0x100) | 94 | if (mmr_offset == 0x100) |
95 | readq_relaxed((void *)(mmr_base + 0x38)); | 95 | readq_relaxed((void __iomem *)(mmr_base + 0x38)); |
96 | readq_relaxed((void *)(mmr_base + 0xb050)); | 96 | readq_relaxed((void __iomem *)(mmr_base + 0xb050)); |
97 | } | 97 | } |
98 | } | 98 | } |
99 | 99 | ||
diff --git a/arch/parisc/kernel/vmlinux.lds.S b/arch/parisc/kernel/vmlinux.lds.S index 9989495a51dd..b3677fc8eef5 100644 --- a/arch/parisc/kernel/vmlinux.lds.S +++ b/arch/parisc/kernel/vmlinux.lds.S | |||
@@ -204,6 +204,7 @@ SECTIONS | |||
204 | *(.dynstr) | 204 | *(.dynstr) |
205 | *(.dynamic) | 205 | *(.dynamic) |
206 | *(.hash) | 206 | *(.hash) |
207 | *(.gnu.hash) | ||
207 | #endif | 208 | #endif |
208 | } | 209 | } |
209 | 210 | ||
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 2643dbc3f289..13e583f16ede 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig | |||
@@ -504,7 +504,7 @@ config CPU_FREQ_PMAC | |||
504 | 504 | ||
505 | config CPU_FREQ_PMAC64 | 505 | config CPU_FREQ_PMAC64 |
506 | bool "Support for some Apple G5s" | 506 | bool "Support for some Apple G5s" |
507 | depends on CPU_FREQ && PMAC_SMU && PPC64 | 507 | depends on CPU_FREQ && PPC64 |
508 | select CPU_FREQ_TABLE | 508 | select CPU_FREQ_TABLE |
509 | help | 509 | help |
510 | This adds support for frequency switching on Apple iMac G5, | 510 | This adds support for frequency switching on Apple iMac G5, |
diff --git a/arch/powerpc/configs/pmac32_defconfig b/arch/powerpc/configs/pmac32_defconfig index addc79381c3b..3545af9896af 100644 --- a/arch/powerpc/configs/pmac32_defconfig +++ b/arch/powerpc/configs/pmac32_defconfig | |||
@@ -1,16 +1,18 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.17-rc5 | 3 | # Linux kernel version: 2.6.17 |
4 | # Mon May 29 14:47:49 2006 | 4 | # Mon Jul 3 14:20:49 2006 |
5 | # | 5 | # |
6 | # CONFIG_PPC64 is not set | 6 | # CONFIG_PPC64 is not set |
7 | CONFIG_PPC32=y | 7 | CONFIG_PPC32=y |
8 | CONFIG_PPC_MERGE=y | 8 | CONFIG_PPC_MERGE=y |
9 | CONFIG_MMU=y | 9 | CONFIG_MMU=y |
10 | CONFIG_GENERIC_HARDIRQS=y | 10 | CONFIG_GENERIC_HARDIRQS=y |
11 | CONFIG_IRQ_PER_CPU=y | ||
11 | CONFIG_RWSEM_XCHGADD_ALGORITHM=y | 12 | CONFIG_RWSEM_XCHGADD_ALGORITHM=y |
12 | CONFIG_GENERIC_HWEIGHT=y | 13 | CONFIG_GENERIC_HWEIGHT=y |
13 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 14 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
15 | CONFIG_GENERIC_FIND_NEXT_BIT=y | ||
14 | CONFIG_PPC=y | 16 | CONFIG_PPC=y |
15 | CONFIG_EARLY_PRINTK=y | 17 | CONFIG_EARLY_PRINTK=y |
16 | CONFIG_GENERIC_NVRAM=y | 18 | CONFIG_GENERIC_NVRAM=y |
@@ -29,6 +31,7 @@ CONFIG_CLASSIC32=y | |||
29 | # CONFIG_PPC_82xx is not set | 31 | # CONFIG_PPC_82xx is not set |
30 | # CONFIG_PPC_83xx is not set | 32 | # CONFIG_PPC_83xx is not set |
31 | # CONFIG_PPC_85xx is not set | 33 | # CONFIG_PPC_85xx is not set |
34 | # CONFIG_PPC_86xx is not set | ||
32 | # CONFIG_40x is not set | 35 | # CONFIG_40x is not set |
33 | # CONFIG_44x is not set | 36 | # CONFIG_44x is not set |
34 | # CONFIG_8xx is not set | 37 | # CONFIG_8xx is not set |
@@ -39,6 +42,7 @@ CONFIG_ALTIVEC=y | |||
39 | CONFIG_PPC_STD_MMU=y | 42 | CONFIG_PPC_STD_MMU=y |
40 | CONFIG_PPC_STD_MMU_32=y | 43 | CONFIG_PPC_STD_MMU_32=y |
41 | # CONFIG_SMP is not set | 44 | # CONFIG_SMP is not set |
45 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
42 | 46 | ||
43 | # | 47 | # |
44 | # Code maturity level options | 48 | # Code maturity level options |
@@ -72,10 +76,12 @@ CONFIG_PRINTK=y | |||
72 | CONFIG_BUG=y | 76 | CONFIG_BUG=y |
73 | CONFIG_ELF_CORE=y | 77 | CONFIG_ELF_CORE=y |
74 | CONFIG_BASE_FULL=y | 78 | CONFIG_BASE_FULL=y |
79 | CONFIG_RT_MUTEXES=y | ||
75 | CONFIG_FUTEX=y | 80 | CONFIG_FUTEX=y |
76 | CONFIG_EPOLL=y | 81 | CONFIG_EPOLL=y |
77 | CONFIG_SHMEM=y | 82 | CONFIG_SHMEM=y |
78 | CONFIG_SLAB=y | 83 | CONFIG_SLAB=y |
84 | CONFIG_VM_EVENT_COUNTERS=y | ||
79 | # CONFIG_TINY_SHMEM is not set | 85 | # CONFIG_TINY_SHMEM is not set |
80 | CONFIG_BASE_SMALL=0 | 86 | CONFIG_BASE_SMALL=0 |
81 | # CONFIG_SLOB is not set | 87 | # CONFIG_SLOB is not set |
@@ -119,6 +125,9 @@ CONFIG_PPC_MULTIPLATFORM=y | |||
119 | # CONFIG_APUS is not set | 125 | # CONFIG_APUS is not set |
120 | # CONFIG_PPC_CHRP is not set | 126 | # CONFIG_PPC_CHRP is not set |
121 | CONFIG_PPC_PMAC=y | 127 | CONFIG_PPC_PMAC=y |
128 | # CONFIG_PPC_CELL is not set | ||
129 | # CONFIG_PPC_CELL_NATIVE is not set | ||
130 | # CONFIG_UDBG_RTAS_CONSOLE is not set | ||
122 | CONFIG_MPIC=y | 131 | CONFIG_MPIC=y |
123 | # CONFIG_PPC_RTAS is not set | 132 | # CONFIG_PPC_RTAS is not set |
124 | # CONFIG_MMIO_NVRAM is not set | 133 | # CONFIG_MMIO_NVRAM is not set |
@@ -154,6 +163,7 @@ CONFIG_PREEMPT_NONE=y | |||
154 | # CONFIG_PREEMPT is not set | 163 | # CONFIG_PREEMPT is not set |
155 | CONFIG_BINFMT_ELF=y | 164 | CONFIG_BINFMT_ELF=y |
156 | CONFIG_BINFMT_MISC=m | 165 | CONFIG_BINFMT_MISC=m |
166 | CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y | ||
157 | # CONFIG_KEXEC is not set | 167 | # CONFIG_KEXEC is not set |
158 | CONFIG_ARCH_FLATMEM_ENABLE=y | 168 | CONFIG_ARCH_FLATMEM_ENABLE=y |
159 | CONFIG_SELECT_MEMORY_MODEL=y | 169 | CONFIG_SELECT_MEMORY_MODEL=y |
@@ -164,6 +174,7 @@ CONFIG_FLATMEM=y | |||
164 | CONFIG_FLAT_NODE_MEM_MAP=y | 174 | CONFIG_FLAT_NODE_MEM_MAP=y |
165 | # CONFIG_SPARSEMEM_STATIC is not set | 175 | # CONFIG_SPARSEMEM_STATIC is not set |
166 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 176 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
177 | # CONFIG_RESOURCES_64BIT is not set | ||
167 | CONFIG_PROC_DEVICETREE=y | 178 | CONFIG_PROC_DEVICETREE=y |
168 | # CONFIG_CMDLINE_BOOL is not set | 179 | # CONFIG_CMDLINE_BOOL is not set |
169 | CONFIG_PM=y | 180 | CONFIG_PM=y |
@@ -182,6 +193,7 @@ CONFIG_GENERIC_ISA_DMA=y | |||
182 | CONFIG_PPC_INDIRECT_PCI=y | 193 | CONFIG_PPC_INDIRECT_PCI=y |
183 | CONFIG_PCI=y | 194 | CONFIG_PCI=y |
184 | CONFIG_PCI_DOMAINS=y | 195 | CONFIG_PCI_DOMAINS=y |
196 | # CONFIG_PCIEPORTBUS is not set | ||
185 | # CONFIG_PCI_DEBUG is not set | 197 | # CONFIG_PCI_DEBUG is not set |
186 | 198 | ||
187 | # | 199 | # |
@@ -256,6 +268,8 @@ CONFIG_INET_ESP=y | |||
256 | # CONFIG_INET_IPCOMP is not set | 268 | # CONFIG_INET_IPCOMP is not set |
257 | # CONFIG_INET_XFRM_TUNNEL is not set | 269 | # CONFIG_INET_XFRM_TUNNEL is not set |
258 | # CONFIG_INET_TUNNEL is not set | 270 | # CONFIG_INET_TUNNEL is not set |
271 | # CONFIG_INET_XFRM_MODE_TRANSPORT is not set | ||
272 | # CONFIG_INET_XFRM_MODE_TUNNEL is not set | ||
259 | CONFIG_INET_DIAG=y | 273 | CONFIG_INET_DIAG=y |
260 | CONFIG_INET_TCP_DIAG=y | 274 | CONFIG_INET_TCP_DIAG=y |
261 | # CONFIG_TCP_CONG_ADVANCED is not set | 275 | # CONFIG_TCP_CONG_ADVANCED is not set |
@@ -268,6 +282,7 @@ CONFIG_TCP_CONG_BIC=y | |||
268 | # CONFIG_IPV6 is not set | 282 | # CONFIG_IPV6 is not set |
269 | # CONFIG_INET6_XFRM_TUNNEL is not set | 283 | # CONFIG_INET6_XFRM_TUNNEL is not set |
270 | # CONFIG_INET6_TUNNEL is not set | 284 | # CONFIG_INET6_TUNNEL is not set |
285 | # CONFIG_NETWORK_SECMARK is not set | ||
271 | CONFIG_NETFILTER=y | 286 | CONFIG_NETFILTER=y |
272 | # CONFIG_NETFILTER_DEBUG is not set | 287 | # CONFIG_NETFILTER_DEBUG is not set |
273 | 288 | ||
@@ -292,9 +307,11 @@ CONFIG_NETFILTER_XT_MATCH_MARK=m | |||
292 | CONFIG_NETFILTER_XT_MATCH_POLICY=m | 307 | CONFIG_NETFILTER_XT_MATCH_POLICY=m |
293 | CONFIG_NETFILTER_XT_MATCH_MULTIPORT=m | 308 | CONFIG_NETFILTER_XT_MATCH_MULTIPORT=m |
294 | CONFIG_NETFILTER_XT_MATCH_PKTTYPE=m | 309 | CONFIG_NETFILTER_XT_MATCH_PKTTYPE=m |
310 | # CONFIG_NETFILTER_XT_MATCH_QUOTA is not set | ||
295 | CONFIG_NETFILTER_XT_MATCH_REALM=m | 311 | CONFIG_NETFILTER_XT_MATCH_REALM=m |
296 | CONFIG_NETFILTER_XT_MATCH_SCTP=m | 312 | CONFIG_NETFILTER_XT_MATCH_SCTP=m |
297 | CONFIG_NETFILTER_XT_MATCH_STATE=m | 313 | CONFIG_NETFILTER_XT_MATCH_STATE=m |
314 | # CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set | ||
298 | CONFIG_NETFILTER_XT_MATCH_STRING=m | 315 | CONFIG_NETFILTER_XT_MATCH_STRING=m |
299 | CONFIG_NETFILTER_XT_MATCH_TCPMSS=m | 316 | CONFIG_NETFILTER_XT_MATCH_TCPMSS=m |
300 | 317 | ||
@@ -313,6 +330,7 @@ CONFIG_IP_NF_TFTP=m | |||
313 | CONFIG_IP_NF_AMANDA=m | 330 | CONFIG_IP_NF_AMANDA=m |
314 | CONFIG_IP_NF_PPTP=m | 331 | CONFIG_IP_NF_PPTP=m |
315 | CONFIG_IP_NF_H323=m | 332 | CONFIG_IP_NF_H323=m |
333 | # CONFIG_IP_NF_SIP is not set | ||
316 | # CONFIG_IP_NF_QUEUE is not set | 334 | # CONFIG_IP_NF_QUEUE is not set |
317 | CONFIG_IP_NF_IPTABLES=m | 335 | CONFIG_IP_NF_IPTABLES=m |
318 | CONFIG_IP_NF_MATCH_IPRANGE=m | 336 | CONFIG_IP_NF_MATCH_IPRANGE=m |
@@ -457,6 +475,7 @@ CONFIG_IRTTY_SIR=m | |||
457 | # CONFIG_ALI_FIR is not set | 475 | # CONFIG_ALI_FIR is not set |
458 | # CONFIG_VLSI_FIR is not set | 476 | # CONFIG_VLSI_FIR is not set |
459 | # CONFIG_VIA_FIR is not set | 477 | # CONFIG_VIA_FIR is not set |
478 | # CONFIG_MCS_FIR is not set | ||
460 | CONFIG_BT=m | 479 | CONFIG_BT=m |
461 | CONFIG_BT_L2CAP=m | 480 | CONFIG_BT_L2CAP=m |
462 | CONFIG_BT_SCO=m | 481 | CONFIG_BT_SCO=m |
@@ -500,6 +519,7 @@ CONFIG_WIRELESS_EXT=y | |||
500 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 519 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
501 | CONFIG_FW_LOADER=y | 520 | CONFIG_FW_LOADER=y |
502 | # CONFIG_DEBUG_DRIVER is not set | 521 | # CONFIG_DEBUG_DRIVER is not set |
522 | # CONFIG_SYS_HYPERVISOR is not set | ||
503 | 523 | ||
504 | # | 524 | # |
505 | # Connector - unified userspace <-> kernelspace linker | 525 | # Connector - unified userspace <-> kernelspace linker |
@@ -600,7 +620,6 @@ CONFIG_BLK_DEV_PDC202XX_NEW=y | |||
600 | CONFIG_BLK_DEV_IDE_PMAC=y | 620 | CONFIG_BLK_DEV_IDE_PMAC=y |
601 | CONFIG_BLK_DEV_IDE_PMAC_ATA100FIRST=y | 621 | CONFIG_BLK_DEV_IDE_PMAC_ATA100FIRST=y |
602 | CONFIG_BLK_DEV_IDEDMA_PMAC=y | 622 | CONFIG_BLK_DEV_IDEDMA_PMAC=y |
603 | CONFIG_BLK_DEV_IDE_PMAC_BLINK=y | ||
604 | # CONFIG_IDE_ARM is not set | 623 | # CONFIG_IDE_ARM is not set |
605 | CONFIG_BLK_DEV_IDEDMA=y | 624 | CONFIG_BLK_DEV_IDEDMA=y |
606 | # CONFIG_IDEDMA_IVB is not set | 625 | # CONFIG_IDEDMA_IVB is not set |
@@ -661,6 +680,7 @@ CONFIG_SCSI_AIC7XXX_OLD=m | |||
661 | # CONFIG_MEGARAID_LEGACY is not set | 680 | # CONFIG_MEGARAID_LEGACY is not set |
662 | # CONFIG_MEGARAID_SAS is not set | 681 | # CONFIG_MEGARAID_SAS is not set |
663 | # CONFIG_SCSI_SATA is not set | 682 | # CONFIG_SCSI_SATA is not set |
683 | # CONFIG_SCSI_HPTIOP is not set | ||
664 | # CONFIG_SCSI_BUSLOGIC is not set | 684 | # CONFIG_SCSI_BUSLOGIC is not set |
665 | # CONFIG_SCSI_DMX3191D is not set | 685 | # CONFIG_SCSI_DMX3191D is not set |
666 | # CONFIG_SCSI_EATA is not set | 686 | # CONFIG_SCSI_EATA is not set |
@@ -705,9 +725,7 @@ CONFIG_MD_LINEAR=m | |||
705 | CONFIG_MD_RAID0=m | 725 | CONFIG_MD_RAID0=m |
706 | CONFIG_MD_RAID1=m | 726 | CONFIG_MD_RAID1=m |
707 | CONFIG_MD_RAID10=m | 727 | CONFIG_MD_RAID10=m |
708 | CONFIG_MD_RAID5=m | 728 | # CONFIG_MD_RAID456 is not set |
709 | CONFIG_MD_RAID5_RESHAPE=y | ||
710 | CONFIG_MD_RAID6=m | ||
711 | CONFIG_MD_MULTIPATH=m | 729 | CONFIG_MD_MULTIPATH=m |
712 | CONFIG_MD_FAULTY=m | 730 | CONFIG_MD_FAULTY=m |
713 | CONFIG_BLK_DEV_DM=m | 731 | CONFIG_BLK_DEV_DM=m |
@@ -750,7 +768,6 @@ CONFIG_IEEE1394_OHCI1394=m | |||
750 | # | 768 | # |
751 | CONFIG_IEEE1394_VIDEO1394=m | 769 | CONFIG_IEEE1394_VIDEO1394=m |
752 | CONFIG_IEEE1394_SBP2=m | 770 | CONFIG_IEEE1394_SBP2=m |
753 | # CONFIG_IEEE1394_SBP2_PHYS_DMA is not set | ||
754 | # CONFIG_IEEE1394_ETH1394 is not set | 771 | # CONFIG_IEEE1394_ETH1394 is not set |
755 | CONFIG_IEEE1394_DV1394=m | 772 | CONFIG_IEEE1394_DV1394=m |
756 | CONFIG_IEEE1394_RAWIO=m | 773 | CONFIG_IEEE1394_RAWIO=m |
@@ -766,9 +783,12 @@ CONFIG_IEEE1394_RAWIO=m | |||
766 | CONFIG_ADB=y | 783 | CONFIG_ADB=y |
767 | CONFIG_ADB_CUDA=y | 784 | CONFIG_ADB_CUDA=y |
768 | CONFIG_ADB_PMU=y | 785 | CONFIG_ADB_PMU=y |
786 | CONFIG_ADB_PMU_LED=y | ||
787 | CONFIG_ADB_PMU_LED_IDE=y | ||
769 | CONFIG_PMAC_APM_EMU=m | 788 | CONFIG_PMAC_APM_EMU=m |
770 | CONFIG_PMAC_MEDIABAY=y | 789 | CONFIG_PMAC_MEDIABAY=y |
771 | CONFIG_PMAC_BACKLIGHT=y | 790 | CONFIG_PMAC_BACKLIGHT=y |
791 | CONFIG_PMAC_BACKLIGHT_LEGACY=y | ||
772 | CONFIG_INPUT_ADBHID=y | 792 | CONFIG_INPUT_ADBHID=y |
773 | CONFIG_MAC_EMUMOUSEBTN=y | 793 | CONFIG_MAC_EMUMOUSEBTN=y |
774 | CONFIG_THERM_WINDTUNNEL=m | 794 | CONFIG_THERM_WINDTUNNEL=m |
@@ -858,6 +878,7 @@ CONFIG_PCNET32=y | |||
858 | # CONFIG_CHELSIO_T1 is not set | 878 | # CONFIG_CHELSIO_T1 is not set |
859 | # CONFIG_IXGB is not set | 879 | # CONFIG_IXGB is not set |
860 | # CONFIG_S2IO is not set | 880 | # CONFIG_S2IO is not set |
881 | # CONFIG_MYRI10GE is not set | ||
861 | 882 | ||
862 | # | 883 | # |
863 | # Token Ring devices | 884 | # Token Ring devices |
@@ -908,6 +929,7 @@ CONFIG_APPLE_AIRPORT=m | |||
908 | # Prism GT/Duette 802.11(a/b/g) PCI/Cardbus support | 929 | # Prism GT/Duette 802.11(a/b/g) PCI/Cardbus support |
909 | # | 930 | # |
910 | CONFIG_PRISM54=m | 931 | CONFIG_PRISM54=m |
932 | # CONFIG_USB_ZD1201 is not set | ||
911 | # CONFIG_HOSTAP is not set | 933 | # CONFIG_HOSTAP is not set |
912 | CONFIG_NET_WIRELESS=y | 934 | CONFIG_NET_WIRELESS=y |
913 | 935 | ||
@@ -998,6 +1020,7 @@ CONFIG_SERIO=y | |||
998 | CONFIG_VT=y | 1020 | CONFIG_VT=y |
999 | CONFIG_VT_CONSOLE=y | 1021 | CONFIG_VT_CONSOLE=y |
1000 | CONFIG_HW_CONSOLE=y | 1022 | CONFIG_HW_CONSOLE=y |
1023 | # CONFIG_VT_HW_CONSOLE_BINDING is not set | ||
1001 | # CONFIG_SERIAL_NONSTANDARD is not set | 1024 | # CONFIG_SERIAL_NONSTANDARD is not set |
1002 | 1025 | ||
1003 | # | 1026 | # |
@@ -1029,6 +1052,7 @@ CONFIG_LEGACY_PTY_COUNT=256 | |||
1029 | # Watchdog Cards | 1052 | # Watchdog Cards |
1030 | # | 1053 | # |
1031 | # CONFIG_WATCHDOG is not set | 1054 | # CONFIG_WATCHDOG is not set |
1055 | # CONFIG_HW_RANDOM is not set | ||
1032 | CONFIG_NVRAM=y | 1056 | CONFIG_NVRAM=y |
1033 | CONFIG_GEN_RTC=y | 1057 | CONFIG_GEN_RTC=y |
1034 | # CONFIG_GEN_RTC_X is not set | 1058 | # CONFIG_GEN_RTC_X is not set |
@@ -1040,6 +1064,7 @@ CONFIG_GEN_RTC=y | |||
1040 | # Ftape, the floppy tape device driver | 1064 | # Ftape, the floppy tape device driver |
1041 | # | 1065 | # |
1042 | CONFIG_AGP=m | 1066 | CONFIG_AGP=m |
1067 | # CONFIG_AGP_SIS is not set | ||
1043 | # CONFIG_AGP_VIA is not set | 1068 | # CONFIG_AGP_VIA is not set |
1044 | CONFIG_AGP_UNINORTH=m | 1069 | CONFIG_AGP_UNINORTH=m |
1045 | CONFIG_DRM=m | 1070 | CONFIG_DRM=m |
@@ -1092,6 +1117,7 @@ CONFIG_I2C_ALGOBIT=y | |||
1092 | CONFIG_I2C_POWERMAC=y | 1117 | CONFIG_I2C_POWERMAC=y |
1093 | # CONFIG_I2C_MPC is not set | 1118 | # CONFIG_I2C_MPC is not set |
1094 | # CONFIG_I2C_NFORCE2 is not set | 1119 | # CONFIG_I2C_NFORCE2 is not set |
1120 | # CONFIG_I2C_OCORES is not set | ||
1095 | # CONFIG_I2C_PARPORT_LIGHT is not set | 1121 | # CONFIG_I2C_PARPORT_LIGHT is not set |
1096 | # CONFIG_I2C_PROSAVAGE is not set | 1122 | # CONFIG_I2C_PROSAVAGE is not set |
1097 | # CONFIG_I2C_SAVAGE4 is not set | 1123 | # CONFIG_I2C_SAVAGE4 is not set |
@@ -1156,12 +1182,13 @@ CONFIG_VIDEO_V4L2=y | |||
1156 | # | 1182 | # |
1157 | # Graphics support | 1183 | # Graphics support |
1158 | # | 1184 | # |
1185 | # CONFIG_FIRMWARE_EDID is not set | ||
1159 | CONFIG_FB=y | 1186 | CONFIG_FB=y |
1160 | CONFIG_FB_CFB_FILLRECT=y | 1187 | CONFIG_FB_CFB_FILLRECT=y |
1161 | CONFIG_FB_CFB_COPYAREA=y | 1188 | CONFIG_FB_CFB_COPYAREA=y |
1162 | CONFIG_FB_CFB_IMAGEBLIT=y | 1189 | CONFIG_FB_CFB_IMAGEBLIT=y |
1163 | CONFIG_FB_MACMODES=y | 1190 | CONFIG_FB_MACMODES=y |
1164 | CONFIG_FB_FIRMWARE_EDID=y | 1191 | CONFIG_FB_BACKLIGHT=y |
1165 | CONFIG_FB_MODE_HELPERS=y | 1192 | CONFIG_FB_MODE_HELPERS=y |
1166 | CONFIG_FB_TILEBLITTING=y | 1193 | CONFIG_FB_TILEBLITTING=y |
1167 | # CONFIG_FB_CIRRUS is not set | 1194 | # CONFIG_FB_CIRRUS is not set |
@@ -1178,6 +1205,7 @@ CONFIG_FB_IMSTT=y | |||
1178 | # CONFIG_FB_S1D13XXX is not set | 1205 | # CONFIG_FB_S1D13XXX is not set |
1179 | CONFIG_FB_NVIDIA=y | 1206 | CONFIG_FB_NVIDIA=y |
1180 | CONFIG_FB_NVIDIA_I2C=y | 1207 | CONFIG_FB_NVIDIA_I2C=y |
1208 | CONFIG_FB_NVIDIA_BACKLIGHT=y | ||
1181 | # CONFIG_FB_RIVA is not set | 1209 | # CONFIG_FB_RIVA is not set |
1182 | CONFIG_FB_MATROX=y | 1210 | CONFIG_FB_MATROX=y |
1183 | CONFIG_FB_MATROX_MILLENIUM=y | 1211 | CONFIG_FB_MATROX_MILLENIUM=y |
@@ -1187,12 +1215,15 @@ CONFIG_FB_MATROX_MYSTIQUE=y | |||
1187 | # CONFIG_FB_MATROX_MULTIHEAD is not set | 1215 | # CONFIG_FB_MATROX_MULTIHEAD is not set |
1188 | CONFIG_FB_RADEON=y | 1216 | CONFIG_FB_RADEON=y |
1189 | CONFIG_FB_RADEON_I2C=y | 1217 | CONFIG_FB_RADEON_I2C=y |
1218 | CONFIG_FB_RADEON_BACKLIGHT=y | ||
1190 | # CONFIG_FB_RADEON_DEBUG is not set | 1219 | # CONFIG_FB_RADEON_DEBUG is not set |
1191 | CONFIG_FB_ATY128=y | 1220 | CONFIG_FB_ATY128=y |
1221 | CONFIG_FB_ATY128_BACKLIGHT=y | ||
1192 | CONFIG_FB_ATY=y | 1222 | CONFIG_FB_ATY=y |
1193 | CONFIG_FB_ATY_CT=y | 1223 | CONFIG_FB_ATY_CT=y |
1194 | # CONFIG_FB_ATY_GENERIC_LCD is not set | 1224 | # CONFIG_FB_ATY_GENERIC_LCD is not set |
1195 | CONFIG_FB_ATY_GX=y | 1225 | CONFIG_FB_ATY_GX=y |
1226 | CONFIG_FB_ATY_BACKLIGHT=y | ||
1196 | # CONFIG_FB_SAVAGE is not set | 1227 | # CONFIG_FB_SAVAGE is not set |
1197 | # CONFIG_FB_SIS is not set | 1228 | # CONFIG_FB_SIS is not set |
1198 | # CONFIG_FB_NEOMAGIC is not set | 1229 | # CONFIG_FB_NEOMAGIC is not set |
@@ -1221,7 +1252,11 @@ CONFIG_LOGO=y | |||
1221 | CONFIG_LOGO_LINUX_MONO=y | 1252 | CONFIG_LOGO_LINUX_MONO=y |
1222 | CONFIG_LOGO_LINUX_VGA16=y | 1253 | CONFIG_LOGO_LINUX_VGA16=y |
1223 | CONFIG_LOGO_LINUX_CLUT224=y | 1254 | CONFIG_LOGO_LINUX_CLUT224=y |
1224 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | 1255 | CONFIG_BACKLIGHT_LCD_SUPPORT=y |
1256 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
1257 | CONFIG_BACKLIGHT_DEVICE=y | ||
1258 | CONFIG_LCD_CLASS_DEVICE=m | ||
1259 | CONFIG_LCD_DEVICE=y | ||
1225 | 1260 | ||
1226 | # | 1261 | # |
1227 | # Sound | 1262 | # Sound |
@@ -1278,6 +1313,18 @@ CONFIG_SND_DUMMY=m | |||
1278 | # CONFIG_SND_CMIPCI is not set | 1313 | # CONFIG_SND_CMIPCI is not set |
1279 | # CONFIG_SND_CS4281 is not set | 1314 | # CONFIG_SND_CS4281 is not set |
1280 | # CONFIG_SND_CS46XX is not set | 1315 | # CONFIG_SND_CS46XX is not set |
1316 | # CONFIG_SND_DARLA20 is not set | ||
1317 | # CONFIG_SND_GINA20 is not set | ||
1318 | # CONFIG_SND_LAYLA20 is not set | ||
1319 | # CONFIG_SND_DARLA24 is not set | ||
1320 | # CONFIG_SND_GINA24 is not set | ||
1321 | # CONFIG_SND_LAYLA24 is not set | ||
1322 | # CONFIG_SND_MONA is not set | ||
1323 | # CONFIG_SND_MIA is not set | ||
1324 | # CONFIG_SND_ECHO3G is not set | ||
1325 | # CONFIG_SND_INDIGO is not set | ||
1326 | # CONFIG_SND_INDIGOIO is not set | ||
1327 | # CONFIG_SND_INDIGODJ is not set | ||
1281 | # CONFIG_SND_EMU10K1 is not set | 1328 | # CONFIG_SND_EMU10K1 is not set |
1282 | # CONFIG_SND_EMU10K1X is not set | 1329 | # CONFIG_SND_EMU10K1X is not set |
1283 | # CONFIG_SND_ENS1370 is not set | 1330 | # CONFIG_SND_ENS1370 is not set |
@@ -1315,6 +1362,17 @@ CONFIG_SND_POWERMAC=m | |||
1315 | CONFIG_SND_POWERMAC_AUTO_DRC=y | 1362 | CONFIG_SND_POWERMAC_AUTO_DRC=y |
1316 | 1363 | ||
1317 | # | 1364 | # |
1365 | # Apple Onboard Audio driver | ||
1366 | # | ||
1367 | CONFIG_SND_AOA=m | ||
1368 | CONFIG_SND_AOA_FABRIC_LAYOUT=m | ||
1369 | CONFIG_SND_AOA_ONYX=m | ||
1370 | CONFIG_SND_AOA_TAS=m | ||
1371 | CONFIG_SND_AOA_TOONIE=m | ||
1372 | CONFIG_SND_AOA_SOUNDBUS=m | ||
1373 | CONFIG_SND_AOA_SOUNDBUS_I2S=m | ||
1374 | |||
1375 | # | ||
1318 | # USB devices | 1376 | # USB devices |
1319 | # | 1377 | # |
1320 | CONFIG_SND_USB_AUDIO=m | 1378 | CONFIG_SND_USB_AUDIO=m |
@@ -1355,6 +1413,7 @@ CONFIG_USB_DYNAMIC_MINORS=y | |||
1355 | CONFIG_USB_EHCI_HCD=m | 1413 | CONFIG_USB_EHCI_HCD=m |
1356 | CONFIG_USB_EHCI_SPLIT_ISO=y | 1414 | CONFIG_USB_EHCI_SPLIT_ISO=y |
1357 | CONFIG_USB_EHCI_ROOT_HUB_TT=y | 1415 | CONFIG_USB_EHCI_ROOT_HUB_TT=y |
1416 | # CONFIG_USB_EHCI_TT_NEWSCHED is not set | ||
1358 | # CONFIG_USB_ISP116X_HCD is not set | 1417 | # CONFIG_USB_ISP116X_HCD is not set |
1359 | CONFIG_USB_OHCI_HCD=y | 1418 | CONFIG_USB_OHCI_HCD=y |
1360 | # CONFIG_USB_OHCI_BIG_ENDIAN is not set | 1419 | # CONFIG_USB_OHCI_BIG_ENDIAN is not set |
@@ -1431,7 +1490,6 @@ CONFIG_USB_NET_NET1080=m | |||
1431 | # CONFIG_USB_NET_RNDIS_HOST is not set | 1490 | # CONFIG_USB_NET_RNDIS_HOST is not set |
1432 | # CONFIG_USB_NET_CDC_SUBSET is not set | 1491 | # CONFIG_USB_NET_CDC_SUBSET is not set |
1433 | CONFIG_USB_NET_ZAURUS=m | 1492 | CONFIG_USB_NET_ZAURUS=m |
1434 | # CONFIG_USB_ZD1201 is not set | ||
1435 | CONFIG_USB_MON=y | 1493 | CONFIG_USB_MON=y |
1436 | 1494 | ||
1437 | # | 1495 | # |
@@ -1499,10 +1557,12 @@ CONFIG_USB_EZUSB=y | |||
1499 | # CONFIG_USB_LEGOTOWER is not set | 1557 | # CONFIG_USB_LEGOTOWER is not set |
1500 | # CONFIG_USB_LCD is not set | 1558 | # CONFIG_USB_LCD is not set |
1501 | # CONFIG_USB_LED is not set | 1559 | # CONFIG_USB_LED is not set |
1560 | # CONFIG_USB_CY7C63 is not set | ||
1502 | # CONFIG_USB_CYTHERM is not set | 1561 | # CONFIG_USB_CYTHERM is not set |
1503 | # CONFIG_USB_PHIDGETKIT is not set | 1562 | # CONFIG_USB_PHIDGETKIT is not set |
1504 | # CONFIG_USB_PHIDGETSERVO is not set | 1563 | # CONFIG_USB_PHIDGETSERVO is not set |
1505 | # CONFIG_USB_IDMOUSE is not set | 1564 | # CONFIG_USB_IDMOUSE is not set |
1565 | CONFIG_USB_APPLEDISPLAY=m | ||
1506 | # CONFIG_USB_SISUSBVGA is not set | 1566 | # CONFIG_USB_SISUSBVGA is not set |
1507 | # CONFIG_USB_LD is not set | 1567 | # CONFIG_USB_LD is not set |
1508 | # CONFIG_USB_TEST is not set | 1568 | # CONFIG_USB_TEST is not set |
@@ -1524,7 +1584,8 @@ CONFIG_USB_EZUSB=y | |||
1524 | # | 1584 | # |
1525 | # LED devices | 1585 | # LED devices |
1526 | # | 1586 | # |
1527 | # CONFIG_NEW_LEDS is not set | 1587 | CONFIG_NEW_LEDS=y |
1588 | CONFIG_LEDS_CLASS=y | ||
1528 | 1589 | ||
1529 | # | 1590 | # |
1530 | # LED drivers | 1591 | # LED drivers |
@@ -1533,6 +1594,10 @@ CONFIG_USB_EZUSB=y | |||
1533 | # | 1594 | # |
1534 | # LED Triggers | 1595 | # LED Triggers |
1535 | # | 1596 | # |
1597 | CONFIG_LEDS_TRIGGERS=y | ||
1598 | # CONFIG_LEDS_TRIGGER_TIMER is not set | ||
1599 | CONFIG_LEDS_TRIGGER_IDE_DISK=y | ||
1600 | # CONFIG_LEDS_TRIGGER_HEARTBEAT is not set | ||
1536 | 1601 | ||
1537 | # | 1602 | # |
1538 | # InfiniBand support | 1603 | # InfiniBand support |
@@ -1549,6 +1614,19 @@ CONFIG_USB_EZUSB=y | |||
1549 | # CONFIG_RTC_CLASS is not set | 1614 | # CONFIG_RTC_CLASS is not set |
1550 | 1615 | ||
1551 | # | 1616 | # |
1617 | # DMA Engine support | ||
1618 | # | ||
1619 | # CONFIG_DMA_ENGINE is not set | ||
1620 | |||
1621 | # | ||
1622 | # DMA Clients | ||
1623 | # | ||
1624 | |||
1625 | # | ||
1626 | # DMA Devices | ||
1627 | # | ||
1628 | |||
1629 | # | ||
1552 | # File systems | 1630 | # File systems |
1553 | # | 1631 | # |
1554 | CONFIG_EXT2_FS=y | 1632 | CONFIG_EXT2_FS=y |
@@ -1569,6 +1647,7 @@ CONFIG_FS_POSIX_ACL=y | |||
1569 | # CONFIG_MINIX_FS is not set | 1647 | # CONFIG_MINIX_FS is not set |
1570 | # CONFIG_ROMFS_FS is not set | 1648 | # CONFIG_ROMFS_FS is not set |
1571 | CONFIG_INOTIFY=y | 1649 | CONFIG_INOTIFY=y |
1650 | CONFIG_INOTIFY_USER=y | ||
1572 | # CONFIG_QUOTA is not set | 1651 | # CONFIG_QUOTA is not set |
1573 | CONFIG_DNOTIFY=y | 1652 | CONFIG_DNOTIFY=y |
1574 | # CONFIG_AUTOFS_FS is not set | 1653 | # CONFIG_AUTOFS_FS is not set |
@@ -1649,6 +1728,7 @@ CONFIG_RPCSEC_GSS_KRB5=y | |||
1649 | CONFIG_SMB_FS=m | 1728 | CONFIG_SMB_FS=m |
1650 | # CONFIG_SMB_NLS_DEFAULT is not set | 1729 | # CONFIG_SMB_NLS_DEFAULT is not set |
1651 | # CONFIG_CIFS is not set | 1730 | # CONFIG_CIFS is not set |
1731 | # CONFIG_CIFS_DEBUG2 is not set | ||
1652 | # CONFIG_NCP_FS is not set | 1732 | # CONFIG_NCP_FS is not set |
1653 | # CONFIG_CODA_FS is not set | 1733 | # CONFIG_CODA_FS is not set |
1654 | # CONFIG_AFS_FS is not set | 1734 | # CONFIG_AFS_FS is not set |
@@ -1732,6 +1812,7 @@ CONFIG_TEXTSEARCH=y | |||
1732 | CONFIG_TEXTSEARCH_KMP=m | 1812 | CONFIG_TEXTSEARCH_KMP=m |
1733 | CONFIG_TEXTSEARCH_BM=m | 1813 | CONFIG_TEXTSEARCH_BM=m |
1734 | CONFIG_TEXTSEARCH_FSM=m | 1814 | CONFIG_TEXTSEARCH_FSM=m |
1815 | CONFIG_PLIST=y | ||
1735 | 1816 | ||
1736 | # | 1817 | # |
1737 | # Instrumentation Support | 1818 | # Instrumentation Support |
@@ -1744,12 +1825,15 @@ CONFIG_OPROFILE=y | |||
1744 | # | 1825 | # |
1745 | # CONFIG_PRINTK_TIME is not set | 1826 | # CONFIG_PRINTK_TIME is not set |
1746 | # CONFIG_MAGIC_SYSRQ is not set | 1827 | # CONFIG_MAGIC_SYSRQ is not set |
1828 | # CONFIG_UNUSED_SYMBOLS is not set | ||
1747 | CONFIG_DEBUG_KERNEL=y | 1829 | CONFIG_DEBUG_KERNEL=y |
1748 | CONFIG_LOG_BUF_SHIFT=14 | 1830 | CONFIG_LOG_BUF_SHIFT=14 |
1749 | CONFIG_DETECT_SOFTLOCKUP=y | 1831 | CONFIG_DETECT_SOFTLOCKUP=y |
1750 | # CONFIG_SCHEDSTATS is not set | 1832 | # CONFIG_SCHEDSTATS is not set |
1751 | # CONFIG_DEBUG_SLAB is not set | 1833 | # CONFIG_DEBUG_SLAB is not set |
1752 | # CONFIG_DEBUG_MUTEXES is not set | 1834 | # CONFIG_DEBUG_MUTEXES is not set |
1835 | # CONFIG_DEBUG_RT_MUTEXES is not set | ||
1836 | # CONFIG_RT_MUTEX_TESTER is not set | ||
1753 | # CONFIG_DEBUG_SPINLOCK is not set | 1837 | # CONFIG_DEBUG_SPINLOCK is not set |
1754 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set | 1838 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set |
1755 | # CONFIG_DEBUG_KOBJECT is not set | 1839 | # CONFIG_DEBUG_KOBJECT is not set |
@@ -1763,11 +1847,7 @@ CONFIG_XMON=y | |||
1763 | CONFIG_XMON_DEFAULT=y | 1847 | CONFIG_XMON_DEFAULT=y |
1764 | # CONFIG_BDI_SWITCH is not set | 1848 | # CONFIG_BDI_SWITCH is not set |
1765 | CONFIG_BOOTX_TEXT=y | 1849 | CONFIG_BOOTX_TEXT=y |
1766 | # CONFIG_PPC_EARLY_DEBUG_LPAR is not set | 1850 | # CONFIG_PPC_EARLY_DEBUG is not set |
1767 | # CONFIG_PPC_EARLY_DEBUG_G5 is not set | ||
1768 | # CONFIG_PPC_EARLY_DEBUG_RTAS is not set | ||
1769 | # CONFIG_PPC_EARLY_DEBUG_MAPLE is not set | ||
1770 | # CONFIG_PPC_EARLY_DEBUG_ISERIES is not set | ||
1771 | 1851 | ||
1772 | # | 1852 | # |
1773 | # Security options | 1853 | # Security options |
diff --git a/arch/powerpc/kernel/head_64.S b/arch/powerpc/kernel/head_64.S index e16eb2a33173..6ff3cf506088 100644 --- a/arch/powerpc/kernel/head_64.S +++ b/arch/powerpc/kernel/head_64.S | |||
@@ -191,6 +191,37 @@ exception_marker: | |||
191 | ori reg,reg,(label)@l; /* virt addr of handler ... */ | 191 | ori reg,reg,(label)@l; /* virt addr of handler ... */ |
192 | #endif | 192 | #endif |
193 | 193 | ||
194 | /* | ||
195 | * Equal to EXCEPTION_PROLOG_PSERIES, except that it forces 64bit mode. | ||
196 | * The firmware calls the registered system_reset_fwnmi and | ||
197 | * machine_check_fwnmi handlers in 32bit mode if the cpu happens to run | ||
198 | * a 32bit application at the time of the event. | ||
199 | * This firmware bug is present on POWER4 and JS20. | ||
200 | */ | ||
201 | #define EXCEPTION_PROLOG_PSERIES_FORCE_64BIT(area, label) \ | ||
202 | mfspr r13,SPRN_SPRG3; /* get paca address into r13 */ \ | ||
203 | std r9,area+EX_R9(r13); /* save r9 - r12 */ \ | ||
204 | std r10,area+EX_R10(r13); \ | ||
205 | std r11,area+EX_R11(r13); \ | ||
206 | std r12,area+EX_R12(r13); \ | ||
207 | mfspr r9,SPRN_SPRG1; \ | ||
208 | std r9,area+EX_R13(r13); \ | ||
209 | mfcr r9; \ | ||
210 | clrrdi r12,r13,32; /* get high part of &label */ \ | ||
211 | mfmsr r10; \ | ||
212 | /* force 64bit mode */ \ | ||
213 | li r11,5; /* MSR_SF_LG|MSR_ISF_LG */ \ | ||
214 | rldimi r10,r11,61,0; /* insert into top 3 bits */ \ | ||
215 | /* done 64bit mode */ \ | ||
216 | mfspr r11,SPRN_SRR0; /* save SRR0 */ \ | ||
217 | LOAD_HANDLER(r12,label) \ | ||
218 | ori r10,r10,MSR_IR|MSR_DR|MSR_RI; \ | ||
219 | mtspr SPRN_SRR0,r12; \ | ||
220 | mfspr r12,SPRN_SRR1; /* and SRR1 */ \ | ||
221 | mtspr SPRN_SRR1,r10; \ | ||
222 | rfid; \ | ||
223 | b . /* prevent speculative execution */ | ||
224 | |||
194 | #define EXCEPTION_PROLOG_PSERIES(area, label) \ | 225 | #define EXCEPTION_PROLOG_PSERIES(area, label) \ |
195 | mfspr r13,SPRN_SPRG3; /* get paca address into r13 */ \ | 226 | mfspr r13,SPRN_SPRG3; /* get paca address into r13 */ \ |
196 | std r9,area+EX_R9(r13); /* save r9 - r12 */ \ | 227 | std r9,area+EX_R9(r13); /* save r9 - r12 */ \ |
@@ -604,14 +635,14 @@ slb_miss_user_pseries: | |||
604 | system_reset_fwnmi: | 635 | system_reset_fwnmi: |
605 | HMT_MEDIUM | 636 | HMT_MEDIUM |
606 | mtspr SPRN_SPRG1,r13 /* save r13 */ | 637 | mtspr SPRN_SPRG1,r13 /* save r13 */ |
607 | EXCEPTION_PROLOG_PSERIES(PACA_EXGEN, system_reset_common) | 638 | EXCEPTION_PROLOG_PSERIES_FORCE_64BIT(PACA_EXGEN, system_reset_common) |
608 | 639 | ||
609 | .globl machine_check_fwnmi | 640 | .globl machine_check_fwnmi |
610 | .align 7 | 641 | .align 7 |
611 | machine_check_fwnmi: | 642 | machine_check_fwnmi: |
612 | HMT_MEDIUM | 643 | HMT_MEDIUM |
613 | mtspr SPRN_SPRG1,r13 /* save r13 */ | 644 | mtspr SPRN_SPRG1,r13 /* save r13 */ |
614 | EXCEPTION_PROLOG_PSERIES(PACA_EXMC, machine_check_common) | 645 | EXCEPTION_PROLOG_PSERIES_FORCE_64BIT(PACA_EXMC, machine_check_common) |
615 | 646 | ||
616 | #ifdef CONFIG_PPC_ISERIES | 647 | #ifdef CONFIG_PPC_ISERIES |
617 | /*** ISeries-LPAR interrupt handlers ***/ | 648 | /*** ISeries-LPAR interrupt handlers ***/ |
diff --git a/arch/powerpc/kernel/legacy_serial.c b/arch/powerpc/kernel/legacy_serial.c index 7e98e778b52f..359ab89748e0 100644 --- a/arch/powerpc/kernel/legacy_serial.c +++ b/arch/powerpc/kernel/legacy_serial.c | |||
@@ -112,7 +112,7 @@ static int __init add_legacy_port(struct device_node *np, int want_index, | |||
112 | static int __init add_legacy_soc_port(struct device_node *np, | 112 | static int __init add_legacy_soc_port(struct device_node *np, |
113 | struct device_node *soc_dev) | 113 | struct device_node *soc_dev) |
114 | { | 114 | { |
115 | phys_addr_t addr; | 115 | u64 addr; |
116 | u32 *addrp; | 116 | u32 *addrp; |
117 | upf_t flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_SHARE_IRQ; | 117 | upf_t flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_SHARE_IRQ; |
118 | 118 | ||
@@ -143,7 +143,7 @@ static int __init add_legacy_isa_port(struct device_node *np, | |||
143 | u32 *reg; | 143 | u32 *reg; |
144 | char *typep; | 144 | char *typep; |
145 | int index = -1; | 145 | int index = -1; |
146 | phys_addr_t taddr; | 146 | u64 taddr; |
147 | 147 | ||
148 | DBG(" -> add_legacy_isa_port(%s)\n", np->full_name); | 148 | DBG(" -> add_legacy_isa_port(%s)\n", np->full_name); |
149 | 149 | ||
@@ -165,10 +165,13 @@ static int __init add_legacy_isa_port(struct device_node *np, | |||
165 | if (typep && *typep == 'S') | 165 | if (typep && *typep == 'S') |
166 | index = simple_strtol(typep+1, NULL, 0) - 1; | 166 | index = simple_strtol(typep+1, NULL, 0) - 1; |
167 | 167 | ||
168 | /* Translate ISA address */ | 168 | /* Translate ISA address. If it fails, we still register the port |
169 | * with no translated address so that it can be picked up as an IO | ||
170 | * port later by the serial driver | ||
171 | */ | ||
169 | taddr = of_translate_address(np, reg); | 172 | taddr = of_translate_address(np, reg); |
170 | if (taddr == OF_BAD_ADDR) | 173 | if (taddr == OF_BAD_ADDR) |
171 | return -1; | 174 | taddr = 0; |
172 | 175 | ||
173 | /* Add port, irq will be dealt with later */ | 176 | /* Add port, irq will be dealt with later */ |
174 | return add_legacy_port(np, index, UPIO_PORT, reg[1], taddr, | 177 | return add_legacy_port(np, index, UPIO_PORT, reg[1], taddr, |
@@ -180,7 +183,7 @@ static int __init add_legacy_isa_port(struct device_node *np, | |||
180 | static int __init add_legacy_pci_port(struct device_node *np, | 183 | static int __init add_legacy_pci_port(struct device_node *np, |
181 | struct device_node *pci_dev) | 184 | struct device_node *pci_dev) |
182 | { | 185 | { |
183 | phys_addr_t addr, base; | 186 | u64 addr, base; |
184 | u32 *addrp; | 187 | u32 *addrp; |
185 | unsigned int flags; | 188 | unsigned int flags; |
186 | int iotype, index = -1, lindex = 0; | 189 | int iotype, index = -1, lindex = 0; |
diff --git a/arch/powerpc/kernel/misc_64.S b/arch/powerpc/kernel/misc_64.S index bfb407fc1aa1..e3ed21cd3d94 100644 --- a/arch/powerpc/kernel/misc_64.S +++ b/arch/powerpc/kernel/misc_64.S | |||
@@ -687,7 +687,7 @@ _GLOBAL(kexec_sequence) | |||
687 | /* clear out hardware hash page table and tlb */ | 687 | /* clear out hardware hash page table and tlb */ |
688 | ld r5,0(r27) /* deref function descriptor */ | 688 | ld r5,0(r27) /* deref function descriptor */ |
689 | mtctr r5 | 689 | mtctr r5 |
690 | bctrl /* ppc_md.hash_clear_all(void); */ | 690 | bctrl /* ppc_md.hpte_clear_all(void); */ |
691 | 691 | ||
692 | /* | 692 | /* |
693 | * kexec image calling is: | 693 | * kexec image calling is: |
diff --git a/arch/powerpc/kernel/prom_init.c b/arch/powerpc/kernel/prom_init.c index ebd501a59abd..462bced40c12 100644 --- a/arch/powerpc/kernel/prom_init.c +++ b/arch/powerpc/kernel/prom_init.c | |||
@@ -557,7 +557,9 @@ unsigned long prom_memparse(const char *ptr, const char **retptr) | |||
557 | static void __init early_cmdline_parse(void) | 557 | static void __init early_cmdline_parse(void) |
558 | { | 558 | { |
559 | struct prom_t *_prom = &RELOC(prom); | 559 | struct prom_t *_prom = &RELOC(prom); |
560 | #ifdef CONFIG_PPC64 | ||
560 | const char *opt; | 561 | const char *opt; |
562 | #endif | ||
561 | char *p; | 563 | char *p; |
562 | int l = 0; | 564 | int l = 0; |
563 | 565 | ||
@@ -2030,6 +2032,39 @@ static void __init fixup_device_tree_maple(void) | |||
2030 | #define fixup_device_tree_maple() | 2032 | #define fixup_device_tree_maple() |
2031 | #endif | 2033 | #endif |
2032 | 2034 | ||
2035 | #ifdef CONFIG_PPC_CHRP | ||
2036 | /* Pegasos lacks the "ranges" property in the isa node */ | ||
2037 | static void __init fixup_device_tree_chrp(void) | ||
2038 | { | ||
2039 | phandle isa; | ||
2040 | u32 isa_ranges[6]; | ||
2041 | char *name; | ||
2042 | int rc; | ||
2043 | |||
2044 | name = "/pci@80000000/isa@c"; | ||
2045 | isa = call_prom("finddevice", 1, 1, ADDR(name)); | ||
2046 | if (!PHANDLE_VALID(isa)) | ||
2047 | return; | ||
2048 | |||
2049 | rc = prom_getproplen(isa, "ranges"); | ||
2050 | if (rc != 0 && rc != PROM_ERROR) | ||
2051 | return; | ||
2052 | |||
2053 | prom_printf("Fixing up missing ISA range on Pegasos...\n"); | ||
2054 | |||
2055 | isa_ranges[0] = 0x1; | ||
2056 | isa_ranges[1] = 0x0; | ||
2057 | isa_ranges[2] = 0x01006000; | ||
2058 | isa_ranges[3] = 0x0; | ||
2059 | isa_ranges[4] = 0x0; | ||
2060 | isa_ranges[5] = 0x00010000; | ||
2061 | prom_setprop(isa, name, "ranges", | ||
2062 | isa_ranges, sizeof(isa_ranges)); | ||
2063 | } | ||
2064 | #else | ||
2065 | #define fixup_device_tree_chrp() | ||
2066 | #endif | ||
2067 | |||
2033 | #if defined(CONFIG_PPC64) && defined(CONFIG_PPC_PMAC) | 2068 | #if defined(CONFIG_PPC64) && defined(CONFIG_PPC_PMAC) |
2034 | static void __init fixup_device_tree_pmac(void) | 2069 | static void __init fixup_device_tree_pmac(void) |
2035 | { | 2070 | { |
@@ -2077,6 +2112,7 @@ static void __init fixup_device_tree_pmac(void) | |||
2077 | static void __init fixup_device_tree(void) | 2112 | static void __init fixup_device_tree(void) |
2078 | { | 2113 | { |
2079 | fixup_device_tree_maple(); | 2114 | fixup_device_tree_maple(); |
2115 | fixup_device_tree_chrp(); | ||
2080 | fixup_device_tree_pmac(); | 2116 | fixup_device_tree_pmac(); |
2081 | } | 2117 | } |
2082 | 2118 | ||
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c index 46c56cfd1b2f..6a9bc9ce54e0 100644 --- a/arch/powerpc/kernel/smp.c +++ b/arch/powerpc/kernel/smp.c | |||
@@ -144,13 +144,15 @@ void smp_message_recv(int msg, struct pt_regs *regs) | |||
144 | 144 | ||
145 | void smp_send_reschedule(int cpu) | 145 | void smp_send_reschedule(int cpu) |
146 | { | 146 | { |
147 | smp_ops->message_pass(cpu, PPC_MSG_RESCHEDULE); | 147 | if (likely(smp_ops)) |
148 | smp_ops->message_pass(cpu, PPC_MSG_RESCHEDULE); | ||
148 | } | 149 | } |
149 | 150 | ||
150 | #ifdef CONFIG_DEBUGGER | 151 | #ifdef CONFIG_DEBUGGER |
151 | void smp_send_debugger_break(int cpu) | 152 | void smp_send_debugger_break(int cpu) |
152 | { | 153 | { |
153 | smp_ops->message_pass(cpu, PPC_MSG_DEBUGGER_BREAK); | 154 | if (likely(smp_ops)) |
155 | smp_ops->message_pass(cpu, PPC_MSG_DEBUGGER_BREAK); | ||
154 | } | 156 | } |
155 | #endif | 157 | #endif |
156 | 158 | ||
@@ -158,7 +160,7 @@ void smp_send_debugger_break(int cpu) | |||
158 | void crash_send_ipi(void (*crash_ipi_callback)(struct pt_regs *)) | 160 | void crash_send_ipi(void (*crash_ipi_callback)(struct pt_regs *)) |
159 | { | 161 | { |
160 | crash_ipi_function_ptr = crash_ipi_callback; | 162 | crash_ipi_function_ptr = crash_ipi_callback; |
161 | if (crash_ipi_callback) { | 163 | if (crash_ipi_callback && smp_ops) { |
162 | mb(); | 164 | mb(); |
163 | smp_ops->message_pass(MSG_ALL_BUT_SELF, PPC_MSG_DEBUGGER_BREAK); | 165 | smp_ops->message_pass(MSG_ALL_BUT_SELF, PPC_MSG_DEBUGGER_BREAK); |
164 | } | 166 | } |
@@ -220,6 +222,9 @@ int smp_call_function (void (*func) (void *info), void *info, int nonatomic, | |||
220 | /* Can deadlock when called with interrupts disabled */ | 222 | /* Can deadlock when called with interrupts disabled */ |
221 | WARN_ON(irqs_disabled()); | 223 | WARN_ON(irqs_disabled()); |
222 | 224 | ||
225 | if (unlikely(smp_ops == NULL)) | ||
226 | return -1; | ||
227 | |||
223 | data.func = func; | 228 | data.func = func; |
224 | data.info = info; | 229 | data.info = info; |
225 | atomic_set(&data.started, 0); | 230 | atomic_set(&data.started, 0); |
@@ -357,7 +362,10 @@ void __init smp_prepare_cpus(unsigned int max_cpus) | |||
357 | smp_store_cpu_info(boot_cpuid); | 362 | smp_store_cpu_info(boot_cpuid); |
358 | cpu_callin_map[boot_cpuid] = 1; | 363 | cpu_callin_map[boot_cpuid] = 1; |
359 | 364 | ||
360 | max_cpus = smp_ops->probe(); | 365 | if (smp_ops) |
366 | max_cpus = smp_ops->probe(); | ||
367 | else | ||
368 | max_cpus = 1; | ||
361 | 369 | ||
362 | smp_space_timers(max_cpus); | 370 | smp_space_timers(max_cpus); |
363 | 371 | ||
@@ -453,7 +461,7 @@ void generic_mach_cpu_die(void) | |||
453 | 461 | ||
454 | static int __devinit cpu_enable(unsigned int cpu) | 462 | static int __devinit cpu_enable(unsigned int cpu) |
455 | { | 463 | { |
456 | if (smp_ops->cpu_enable) | 464 | if (smp_ops && smp_ops->cpu_enable) |
457 | return smp_ops->cpu_enable(cpu); | 465 | return smp_ops->cpu_enable(cpu); |
458 | 466 | ||
459 | return -ENOSYS; | 467 | return -ENOSYS; |
@@ -467,7 +475,8 @@ int __devinit __cpu_up(unsigned int cpu) | |||
467 | if (!cpu_enable(cpu)) | 475 | if (!cpu_enable(cpu)) |
468 | return 0; | 476 | return 0; |
469 | 477 | ||
470 | if (smp_ops->cpu_bootable && !smp_ops->cpu_bootable(cpu)) | 478 | if (smp_ops == NULL || |
479 | (smp_ops->cpu_bootable && !smp_ops->cpu_bootable(cpu))) | ||
471 | return -EINVAL; | 480 | return -EINVAL; |
472 | 481 | ||
473 | /* Make sure callin-map entry is 0 (can be leftover a CPU | 482 | /* Make sure callin-map entry is 0 (can be leftover a CPU |
@@ -568,7 +577,8 @@ void __init smp_cpus_done(unsigned int max_cpus) | |||
568 | old_mask = current->cpus_allowed; | 577 | old_mask = current->cpus_allowed; |
569 | set_cpus_allowed(current, cpumask_of_cpu(boot_cpuid)); | 578 | set_cpus_allowed(current, cpumask_of_cpu(boot_cpuid)); |
570 | 579 | ||
571 | smp_ops->setup_cpu(boot_cpuid); | 580 | if (smp_ops) |
581 | smp_ops->setup_cpu(boot_cpuid); | ||
572 | 582 | ||
573 | set_cpus_allowed(current, old_mask); | 583 | set_cpus_allowed(current, old_mask); |
574 | 584 | ||
diff --git a/arch/powerpc/kernel/sysfs.c b/arch/powerpc/kernel/sysfs.c index 010435095550..fec228cd0163 100644 --- a/arch/powerpc/kernel/sysfs.c +++ b/arch/powerpc/kernel/sysfs.c | |||
@@ -278,7 +278,7 @@ static void unregister_cpu_online(unsigned int cpu) | |||
278 | } | 278 | } |
279 | #endif /* CONFIG_HOTPLUG_CPU */ | 279 | #endif /* CONFIG_HOTPLUG_CPU */ |
280 | 280 | ||
281 | static int __devinit sysfs_cpu_notify(struct notifier_block *self, | 281 | static int __cpuinit sysfs_cpu_notify(struct notifier_block *self, |
282 | unsigned long action, void *hcpu) | 282 | unsigned long action, void *hcpu) |
283 | { | 283 | { |
284 | unsigned int cpu = (unsigned int)(long)hcpu; | 284 | unsigned int cpu = (unsigned int)(long)hcpu; |
@@ -296,7 +296,7 @@ static int __devinit sysfs_cpu_notify(struct notifier_block *self, | |||
296 | return NOTIFY_OK; | 296 | return NOTIFY_OK; |
297 | } | 297 | } |
298 | 298 | ||
299 | static struct notifier_block __devinitdata sysfs_cpu_nb = { | 299 | static struct notifier_block __cpuinitdata sysfs_cpu_nb = { |
300 | .notifier_call = sysfs_cpu_notify, | 300 | .notifier_call = sysfs_cpu_notify, |
301 | }; | 301 | }; |
302 | 302 | ||
diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c index 3c668078e524..2105767fcc57 100644 --- a/arch/powerpc/kernel/traps.c +++ b/arch/powerpc/kernel/traps.c | |||
@@ -150,13 +150,9 @@ int die(const char *str, struct pt_regs *regs, long err) | |||
150 | if (in_interrupt()) | 150 | if (in_interrupt()) |
151 | panic("Fatal exception in interrupt"); | 151 | panic("Fatal exception in interrupt"); |
152 | 152 | ||
153 | if (panic_on_oops) { | 153 | if (panic_on_oops) |
154 | #ifdef CONFIG_PPC64 | 154 | panic("Fatal exception: panic_on_oops"); |
155 | printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); | 155 | |
156 | ssleep(5); | ||
157 | #endif | ||
158 | panic("Fatal exception"); | ||
159 | } | ||
160 | do_exit(err); | 156 | do_exit(err); |
161 | 157 | ||
162 | return 0; | 158 | return 0; |
diff --git a/arch/powerpc/kernel/udbg_16550.c b/arch/powerpc/kernel/udbg_16550.c index 0835b4841dea..2d17f2b8eda7 100644 --- a/arch/powerpc/kernel/udbg_16550.c +++ b/arch/powerpc/kernel/udbg_16550.c | |||
@@ -81,10 +81,14 @@ static int udbg_550_getc(void) | |||
81 | void udbg_init_uart(void __iomem *comport, unsigned int speed, | 81 | void udbg_init_uart(void __iomem *comport, unsigned int speed, |
82 | unsigned int clock) | 82 | unsigned int clock) |
83 | { | 83 | { |
84 | unsigned int dll, base_bauds = clock / 16; | 84 | unsigned int dll, base_bauds; |
85 | 85 | ||
86 | if (clock == 0) | ||
87 | clock = 1843200; | ||
86 | if (speed == 0) | 88 | if (speed == 0) |
87 | speed = 9600; | 89 | speed = 9600; |
90 | |||
91 | base_bauds = clock / 16; | ||
88 | dll = base_bauds / speed; | 92 | dll = base_bauds / speed; |
89 | 93 | ||
90 | if (comport) { | 94 | if (comport) { |
diff --git a/arch/powerpc/kernel/vdso32/Makefile b/arch/powerpc/kernel/vdso32/Makefile index 8a3bed5f143a..3726358faae8 100644 --- a/arch/powerpc/kernel/vdso32/Makefile +++ b/arch/powerpc/kernel/vdso32/Makefile | |||
@@ -14,7 +14,8 @@ obj-vdso32 := $(addprefix $(obj)/, $(obj-vdso32)) | |||
14 | 14 | ||
15 | 15 | ||
16 | EXTRA_CFLAGS := -shared -s -fno-common -fno-builtin | 16 | EXTRA_CFLAGS := -shared -s -fno-common -fno-builtin |
17 | EXTRA_CFLAGS += -nostdlib -Wl,-soname=linux-vdso32.so.1 | 17 | EXTRA_CFLAGS += -nostdlib -Wl,-soname=linux-vdso32.so.1 \ |
18 | $(call ld-option, -Wl$(comma)--hash-style=sysv) | ||
18 | EXTRA_AFLAGS := -D__VDSO32__ -s | 19 | EXTRA_AFLAGS := -D__VDSO32__ -s |
19 | 20 | ||
20 | obj-y += vdso32_wrapper.o | 21 | obj-y += vdso32_wrapper.o |
diff --git a/arch/powerpc/kernel/vdso32/vdso32.lds.S b/arch/powerpc/kernel/vdso32/vdso32.lds.S index f4bad720cb0a..6187af2d54c3 100644 --- a/arch/powerpc/kernel/vdso32/vdso32.lds.S +++ b/arch/powerpc/kernel/vdso32/vdso32.lds.S | |||
@@ -14,6 +14,7 @@ SECTIONS | |||
14 | { | 14 | { |
15 | . = VDSO32_LBASE + SIZEOF_HEADERS; | 15 | . = VDSO32_LBASE + SIZEOF_HEADERS; |
16 | .hash : { *(.hash) } :text | 16 | .hash : { *(.hash) } :text |
17 | .gnu.hash : { *(.gnu.hash) } | ||
17 | .dynsym : { *(.dynsym) } | 18 | .dynsym : { *(.dynsym) } |
18 | .dynstr : { *(.dynstr) } | 19 | .dynstr : { *(.dynstr) } |
19 | .gnu.version : { *(.gnu.version) } | 20 | .gnu.version : { *(.gnu.version) } |
diff --git a/arch/powerpc/kernel/vdso64/Makefile b/arch/powerpc/kernel/vdso64/Makefile index ab39988452cc..43af9b2a6f3b 100644 --- a/arch/powerpc/kernel/vdso64/Makefile +++ b/arch/powerpc/kernel/vdso64/Makefile | |||
@@ -8,7 +8,8 @@ targets := $(obj-vdso64) vdso64.so | |||
8 | obj-vdso64 := $(addprefix $(obj)/, $(obj-vdso64)) | 8 | obj-vdso64 := $(addprefix $(obj)/, $(obj-vdso64)) |
9 | 9 | ||
10 | EXTRA_CFLAGS := -shared -s -fno-common -fno-builtin | 10 | EXTRA_CFLAGS := -shared -s -fno-common -fno-builtin |
11 | EXTRA_CFLAGS += -nostdlib -Wl,-soname=linux-vdso64.so.1 | 11 | EXTRA_CFLAGS += -nostdlib -Wl,-soname=linux-vdso64.so.1 \ |
12 | $(call ld-option, -Wl$(comma)--hash-style=sysv) | ||
12 | EXTRA_AFLAGS := -D__VDSO64__ -s | 13 | EXTRA_AFLAGS := -D__VDSO64__ -s |
13 | 14 | ||
14 | obj-y += vdso64_wrapper.o | 15 | obj-y += vdso64_wrapper.o |
diff --git a/arch/powerpc/kernel/vdso64/vdso64.lds.S b/arch/powerpc/kernel/vdso64/vdso64.lds.S index 4bdf224464ab..4a2b6dc0960c 100644 --- a/arch/powerpc/kernel/vdso64/vdso64.lds.S +++ b/arch/powerpc/kernel/vdso64/vdso64.lds.S | |||
@@ -12,6 +12,7 @@ SECTIONS | |||
12 | { | 12 | { |
13 | . = VDSO64_LBASE + SIZEOF_HEADERS; | 13 | . = VDSO64_LBASE + SIZEOF_HEADERS; |
14 | .hash : { *(.hash) } :text | 14 | .hash : { *(.hash) } :text |
15 | .gnu.hash : { *(.gnu.hash) } | ||
15 | .dynsym : { *(.dynsym) } | 16 | .dynsym : { *(.dynsym) } |
16 | .dynstr : { *(.dynstr) } | 17 | .dynstr : { *(.dynstr) } |
17 | .gnu.version : { *(.gnu.version) } | 18 | .gnu.version : { *(.gnu.version) } |
diff --git a/arch/powerpc/mm/lmb.c b/arch/powerpc/mm/lmb.c index 4b17a7359924..716a2906a24d 100644 --- a/arch/powerpc/mm/lmb.c +++ b/arch/powerpc/mm/lmb.c | |||
@@ -320,7 +320,8 @@ void __init lmb_enforce_memory_limit(unsigned long memory_limit) | |||
320 | break; | 320 | break; |
321 | } | 321 | } |
322 | 322 | ||
323 | lmb.rmo_size = lmb.memory.region[0].size; | 323 | if (lmb.memory.region[0].size < lmb.rmo_size) |
324 | lmb.rmo_size = lmb.memory.region[0].size; | ||
324 | 325 | ||
325 | /* And truncate any reserves above the limit also. */ | 326 | /* And truncate any reserves above the limit also. */ |
326 | for (i = 0; i < lmb.reserved.cnt; i++) { | 327 | for (i = 0; i < lmb.reserved.cnt; i++) { |
diff --git a/arch/powerpc/platforms/chrp/setup.c b/arch/powerpc/platforms/chrp/setup.c index 538e337d63e2..9c08ff322290 100644 --- a/arch/powerpc/platforms/chrp/setup.c +++ b/arch/powerpc/platforms/chrp/setup.c | |||
@@ -291,10 +291,6 @@ void __init chrp_setup_arch(void) | |||
291 | 291 | ||
292 | pci_create_OF_bus_map(); | 292 | pci_create_OF_bus_map(); |
293 | 293 | ||
294 | #ifdef CONFIG_SMP | ||
295 | smp_ops = &chrp_smp_ops; | ||
296 | #endif /* CONFIG_SMP */ | ||
297 | |||
298 | /* | 294 | /* |
299 | * Print the banner, then scroll down so boot progress | 295 | * Print the banner, then scroll down so boot progress |
300 | * can be printed. -- Cort | 296 | * can be printed. -- Cort |
@@ -479,6 +475,14 @@ void __init chrp_init_IRQ(void) | |||
479 | chrp_find_openpic(); | 475 | chrp_find_openpic(); |
480 | chrp_find_8259(); | 476 | chrp_find_8259(); |
481 | 477 | ||
478 | #ifdef CONFIG_SMP | ||
479 | /* Pegasos has no MPIC, those ops would make it crash. It might be an | ||
480 | * option to move setting them to after we probe the PIC though | ||
481 | */ | ||
482 | if (chrp_mpic != NULL) | ||
483 | smp_ops = &chrp_smp_ops; | ||
484 | #endif /* CONFIG_SMP */ | ||
485 | |||
482 | if (_chrp_type == _CHRP_Pegasos) | 486 | if (_chrp_type == _CHRP_Pegasos) |
483 | ppc_md.get_irq = i8259_irq; | 487 | ppc_md.get_irq = i8259_irq; |
484 | 488 | ||
diff --git a/arch/powerpc/platforms/maple/setup.c b/arch/powerpc/platforms/maple/setup.c index cb528c9de4c3..57567dfb9819 100644 --- a/arch/powerpc/platforms/maple/setup.c +++ b/arch/powerpc/platforms/maple/setup.c | |||
@@ -221,10 +221,17 @@ static void __init maple_init_IRQ(void) | |||
221 | * in Maple device-tree where the type of the controller is | 221 | * in Maple device-tree where the type of the controller is |
222 | * open-pic and not interrupt-controller | 222 | * open-pic and not interrupt-controller |
223 | */ | 223 | */ |
224 | for_each_node_by_type(np, "open-pic") { | 224 | |
225 | mpic_node = np; | 225 | for_each_node_by_type(np, "interrupt-controller") |
226 | break; | 226 | if (device_is_compatible(np, "open-pic")) { |
227 | } | 227 | mpic_node = np; |
228 | break; | ||
229 | } | ||
230 | if (mpic_node == NULL) | ||
231 | for_each_node_by_type(np, "open-pic") { | ||
232 | mpic_node = np; | ||
233 | break; | ||
234 | } | ||
228 | if (mpic_node == NULL) { | 235 | if (mpic_node == NULL) { |
229 | printk(KERN_ERR | 236 | printk(KERN_ERR |
230 | "Failed to locate the MPIC interrupt controller\n"); | 237 | "Failed to locate the MPIC interrupt controller\n"); |
@@ -252,6 +259,8 @@ static void __init maple_init_IRQ(void) | |||
252 | 259 | ||
253 | /* XXX Maple specific bits */ | 260 | /* XXX Maple specific bits */ |
254 | flags |= MPIC_BROKEN_U3 | MPIC_WANTS_RESET; | 261 | flags |= MPIC_BROKEN_U3 | MPIC_WANTS_RESET; |
262 | /* All U3/U4 are big-endian, older SLOF firmware doesn't encode this */ | ||
263 | flags |= MPIC_BIG_ENDIAN; | ||
255 | 264 | ||
256 | /* Setup the openpic driver. More device-tree junks, we hard code no | 265 | /* Setup the openpic driver. More device-tree junks, we hard code no |
257 | * ISUs for now. I'll have to revisit some stuffs with the folks doing | 266 | * ISUs for now. I'll have to revisit some stuffs with the folks doing |
diff --git a/arch/powerpc/platforms/powermac/backlight.c b/arch/powerpc/platforms/powermac/backlight.c index 74eed6b74cd6..d66415491055 100644 --- a/arch/powerpc/platforms/powermac/backlight.c +++ b/arch/powerpc/platforms/powermac/backlight.c | |||
@@ -10,19 +10,32 @@ | |||
10 | #include <linux/kernel.h> | 10 | #include <linux/kernel.h> |
11 | #include <linux/fb.h> | 11 | #include <linux/fb.h> |
12 | #include <linux/backlight.h> | 12 | #include <linux/backlight.h> |
13 | #include <linux/adb.h> | ||
14 | #include <linux/pmu.h> | ||
15 | #include <asm/atomic.h> | ||
13 | #include <asm/prom.h> | 16 | #include <asm/prom.h> |
14 | #include <asm/backlight.h> | 17 | #include <asm/backlight.h> |
15 | 18 | ||
16 | #define OLD_BACKLIGHT_MAX 15 | 19 | #define OLD_BACKLIGHT_MAX 15 |
17 | 20 | ||
18 | static void pmac_backlight_key_worker(void *data); | 21 | static void pmac_backlight_key_worker(void *data); |
22 | static void pmac_backlight_set_legacy_worker(void *data); | ||
23 | |||
19 | static DECLARE_WORK(pmac_backlight_key_work, pmac_backlight_key_worker, NULL); | 24 | static DECLARE_WORK(pmac_backlight_key_work, pmac_backlight_key_worker, NULL); |
25 | static DECLARE_WORK(pmac_backlight_set_legacy_work, pmac_backlight_set_legacy_worker, NULL); | ||
20 | 26 | ||
21 | /* Although this variable is used in interrupt context, it makes no sense to | 27 | /* Although these variables are used in interrupt context, it makes no sense to |
22 | * protect it. No user is able to produce enough key events per second and | 28 | * protect them. No user is able to produce enough key events per second and |
23 | * notice the errors that might happen. | 29 | * notice the errors that might happen. |
24 | */ | 30 | */ |
25 | static int pmac_backlight_key_queued; | 31 | static int pmac_backlight_key_queued; |
32 | static int pmac_backlight_set_legacy_queued; | ||
33 | |||
34 | /* The via-pmu code allows the backlight to be grabbed, in which case the | ||
35 | * in-kernel control of the brightness needs to be disabled. This should | ||
36 | * only be used by really old PowerBooks. | ||
37 | */ | ||
38 | static atomic_t kernel_backlight_disabled = ATOMIC_INIT(0); | ||
26 | 39 | ||
27 | /* Protect the pmac_backlight variable */ | 40 | /* Protect the pmac_backlight variable */ |
28 | DEFINE_MUTEX(pmac_backlight_mutex); | 41 | DEFINE_MUTEX(pmac_backlight_mutex); |
@@ -82,6 +95,9 @@ int pmac_backlight_curve_lookup(struct fb_info *info, int value) | |||
82 | 95 | ||
83 | static void pmac_backlight_key_worker(void *data) | 96 | static void pmac_backlight_key_worker(void *data) |
84 | { | 97 | { |
98 | if (atomic_read(&kernel_backlight_disabled)) | ||
99 | return; | ||
100 | |||
85 | mutex_lock(&pmac_backlight_mutex); | 101 | mutex_lock(&pmac_backlight_mutex); |
86 | if (pmac_backlight) { | 102 | if (pmac_backlight) { |
87 | struct backlight_properties *props; | 103 | struct backlight_properties *props; |
@@ -107,8 +123,12 @@ static void pmac_backlight_key_worker(void *data) | |||
107 | mutex_unlock(&pmac_backlight_mutex); | 123 | mutex_unlock(&pmac_backlight_mutex); |
108 | } | 124 | } |
109 | 125 | ||
126 | /* This function is called in interrupt context */ | ||
110 | void pmac_backlight_key(int direction) | 127 | void pmac_backlight_key(int direction) |
111 | { | 128 | { |
129 | if (atomic_read(&kernel_backlight_disabled)) | ||
130 | return; | ||
131 | |||
112 | /* we can receive multiple interrupts here, but the scheduled work | 132 | /* we can receive multiple interrupts here, but the scheduled work |
113 | * will run only once, with the last value | 133 | * will run only once, with the last value |
114 | */ | 134 | */ |
@@ -116,7 +136,7 @@ void pmac_backlight_key(int direction) | |||
116 | schedule_work(&pmac_backlight_key_work); | 136 | schedule_work(&pmac_backlight_key_work); |
117 | } | 137 | } |
118 | 138 | ||
119 | int pmac_backlight_set_legacy_brightness(int brightness) | 139 | static int __pmac_backlight_set_legacy_brightness(int brightness) |
120 | { | 140 | { |
121 | int error = -ENXIO; | 141 | int error = -ENXIO; |
122 | 142 | ||
@@ -145,6 +165,28 @@ int pmac_backlight_set_legacy_brightness(int brightness) | |||
145 | return error; | 165 | return error; |
146 | } | 166 | } |
147 | 167 | ||
168 | static void pmac_backlight_set_legacy_worker(void *data) | ||
169 | { | ||
170 | if (atomic_read(&kernel_backlight_disabled)) | ||
171 | return; | ||
172 | |||
173 | __pmac_backlight_set_legacy_brightness(pmac_backlight_set_legacy_queued); | ||
174 | } | ||
175 | |||
176 | /* This function is called in interrupt context */ | ||
177 | void pmac_backlight_set_legacy_brightness_pmu(int brightness) { | ||
178 | if (atomic_read(&kernel_backlight_disabled)) | ||
179 | return; | ||
180 | |||
181 | pmac_backlight_set_legacy_queued = brightness; | ||
182 | schedule_work(&pmac_backlight_set_legacy_work); | ||
183 | } | ||
184 | |||
185 | int pmac_backlight_set_legacy_brightness(int brightness) | ||
186 | { | ||
187 | return __pmac_backlight_set_legacy_brightness(brightness); | ||
188 | } | ||
189 | |||
148 | int pmac_backlight_get_legacy_brightness() | 190 | int pmac_backlight_get_legacy_brightness() |
149 | { | 191 | { |
150 | int result = -ENXIO; | 192 | int result = -ENXIO; |
@@ -167,6 +209,16 @@ int pmac_backlight_get_legacy_brightness() | |||
167 | return result; | 209 | return result; |
168 | } | 210 | } |
169 | 211 | ||
212 | void pmac_backlight_disable() | ||
213 | { | ||
214 | atomic_inc(&kernel_backlight_disabled); | ||
215 | } | ||
216 | |||
217 | void pmac_backlight_enable() | ||
218 | { | ||
219 | atomic_dec(&kernel_backlight_disabled); | ||
220 | } | ||
221 | |||
170 | EXPORT_SYMBOL_GPL(pmac_backlight); | 222 | EXPORT_SYMBOL_GPL(pmac_backlight); |
171 | EXPORT_SYMBOL_GPL(pmac_backlight_mutex); | 223 | EXPORT_SYMBOL_GPL(pmac_backlight_mutex); |
172 | EXPORT_SYMBOL_GPL(pmac_has_backlight_type); | 224 | EXPORT_SYMBOL_GPL(pmac_has_backlight_type); |
diff --git a/arch/powerpc/platforms/powermac/bootx_init.c b/arch/powerpc/platforms/powermac/bootx_init.c index 871b002c9f90..6a026c733f6a 100644 --- a/arch/powerpc/platforms/powermac/bootx_init.c +++ b/arch/powerpc/platforms/powermac/bootx_init.c | |||
@@ -181,13 +181,18 @@ static void __init bootx_add_chosen_props(unsigned long base, | |||
181 | } | 181 | } |
182 | 182 | ||
183 | static void __init bootx_add_display_props(unsigned long base, | 183 | static void __init bootx_add_display_props(unsigned long base, |
184 | unsigned long *mem_end) | 184 | unsigned long *mem_end, |
185 | int has_real_node) | ||
185 | { | 186 | { |
186 | boot_infos_t *bi = bootx_info; | 187 | boot_infos_t *bi = bootx_info; |
187 | u32 tmp; | 188 | u32 tmp; |
188 | 189 | ||
189 | bootx_dt_add_prop("linux,boot-display", NULL, 0, mem_end); | 190 | if (has_real_node) { |
190 | bootx_dt_add_prop("linux,opened", NULL, 0, mem_end); | 191 | bootx_dt_add_prop("linux,boot-display", NULL, 0, mem_end); |
192 | bootx_dt_add_prop("linux,opened", NULL, 0, mem_end); | ||
193 | } else | ||
194 | bootx_dt_add_prop("linux,bootx-noscreen", NULL, 0, mem_end); | ||
195 | |||
191 | tmp = bi->dispDeviceDepth; | 196 | tmp = bi->dispDeviceDepth; |
192 | bootx_dt_add_prop("linux,bootx-depth", &tmp, 4, mem_end); | 197 | bootx_dt_add_prop("linux,bootx-depth", &tmp, 4, mem_end); |
193 | tmp = bi->dispDeviceRect[2] - bi->dispDeviceRect[0]; | 198 | tmp = bi->dispDeviceRect[2] - bi->dispDeviceRect[0]; |
@@ -241,11 +246,6 @@ static void __init bootx_scan_dt_build_strings(unsigned long base, | |||
241 | DBG(" detected display ! adding properties names !\n"); | 246 | DBG(" detected display ! adding properties names !\n"); |
242 | bootx_dt_add_string("linux,boot-display", mem_end); | 247 | bootx_dt_add_string("linux,boot-display", mem_end); |
243 | bootx_dt_add_string("linux,opened", mem_end); | 248 | bootx_dt_add_string("linux,opened", mem_end); |
244 | bootx_dt_add_string("linux,bootx-depth", mem_end); | ||
245 | bootx_dt_add_string("linux,bootx-width", mem_end); | ||
246 | bootx_dt_add_string("linux,bootx-height", mem_end); | ||
247 | bootx_dt_add_string("linux,bootx-linebytes", mem_end); | ||
248 | bootx_dt_add_string("linux,bootx-addr", mem_end); | ||
249 | strncpy(bootx_disp_path, namep, 255); | 249 | strncpy(bootx_disp_path, namep, 255); |
250 | } | 250 | } |
251 | 251 | ||
@@ -329,10 +329,13 @@ static void __init bootx_scan_dt_build_struct(unsigned long base, | |||
329 | ppp = &pp->next; | 329 | ppp = &pp->next; |
330 | } | 330 | } |
331 | 331 | ||
332 | if (node == bootx_node_chosen) | 332 | if (node == bootx_node_chosen) { |
333 | bootx_add_chosen_props(base, mem_end); | 333 | bootx_add_chosen_props(base, mem_end); |
334 | if (node == bootx_info->dispDeviceRegEntryOffset) | 334 | if (bootx_info->dispDeviceRegEntryOffset == 0) |
335 | bootx_add_display_props(base, mem_end); | 335 | bootx_add_display_props(base, mem_end, 0); |
336 | } | ||
337 | else if (node == bootx_info->dispDeviceRegEntryOffset) | ||
338 | bootx_add_display_props(base, mem_end, 1); | ||
336 | 339 | ||
337 | /* do all our children */ | 340 | /* do all our children */ |
338 | cpp = &np->child; | 341 | cpp = &np->child; |
@@ -374,6 +377,14 @@ static unsigned long __init bootx_flatten_dt(unsigned long start) | |||
374 | mem_end += 4; | 377 | mem_end += 4; |
375 | bootx_dt_strend = mem_end; | 378 | bootx_dt_strend = mem_end; |
376 | bootx_scan_dt_build_strings(base, 4, &mem_end); | 379 | bootx_scan_dt_build_strings(base, 4, &mem_end); |
380 | /* Add some strings */ | ||
381 | bootx_dt_add_string("linux,bootx-noscreen", &mem_end); | ||
382 | bootx_dt_add_string("linux,bootx-depth", &mem_end); | ||
383 | bootx_dt_add_string("linux,bootx-width", &mem_end); | ||
384 | bootx_dt_add_string("linux,bootx-height", &mem_end); | ||
385 | bootx_dt_add_string("linux,bootx-linebytes", &mem_end); | ||
386 | bootx_dt_add_string("linux,bootx-addr", &mem_end); | ||
387 | /* Wrap up strings */ | ||
377 | hdr->off_dt_strings = bootx_dt_strbase - mem_start; | 388 | hdr->off_dt_strings = bootx_dt_strbase - mem_start; |
378 | hdr->dt_strings_size = bootx_dt_strend - bootx_dt_strbase; | 389 | hdr->dt_strings_size = bootx_dt_strend - bootx_dt_strbase; |
379 | 390 | ||
@@ -471,6 +482,7 @@ void __init bootx_init(unsigned long r3, unsigned long r4) | |||
471 | if (bi->dispDeviceDepth == 16) | 482 | if (bi->dispDeviceDepth == 16) |
472 | bi->dispDeviceDepth = 15; | 483 | bi->dispDeviceDepth = 15; |
473 | 484 | ||
485 | |||
474 | #ifdef CONFIG_BOOTX_TEXT | 486 | #ifdef CONFIG_BOOTX_TEXT |
475 | ptr = (unsigned long)bi->logicalDisplayBase; | 487 | ptr = (unsigned long)bi->logicalDisplayBase; |
476 | ptr += bi->dispDeviceRect[1] * bi->dispDeviceRowBytes; | 488 | ptr += bi->dispDeviceRect[1] * bi->dispDeviceRowBytes; |
@@ -508,6 +520,7 @@ void __init bootx_init(unsigned long r3, unsigned long r4) | |||
508 | #ifdef CONFIG_BOOTX_TEXT | 520 | #ifdef CONFIG_BOOTX_TEXT |
509 | btext_welcome(bi); | 521 | btext_welcome(bi); |
510 | #endif | 522 | #endif |
523 | |||
511 | /* New BootX enters kernel with MMU off, i/os are not allowed | 524 | /* New BootX enters kernel with MMU off, i/os are not allowed |
512 | * here. This hack will have been done by the boostrap anyway. | 525 | * here. This hack will have been done by the boostrap anyway. |
513 | */ | 526 | */ |
diff --git a/arch/powerpc/platforms/powermac/cpufreq_64.c b/arch/powerpc/platforms/powermac/cpufreq_64.c index f08a14516139..7b1156ea5341 100644 --- a/arch/powerpc/platforms/powermac/cpufreq_64.c +++ b/arch/powerpc/platforms/powermac/cpufreq_64.c | |||
@@ -10,6 +10,8 @@ | |||
10 | * that is iMac G5 and latest single CPU desktop. | 10 | * that is iMac G5 and latest single CPU desktop. |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #undef DEBUG | ||
14 | |||
13 | #include <linux/module.h> | 15 | #include <linux/module.h> |
14 | #include <linux/types.h> | 16 | #include <linux/types.h> |
15 | #include <linux/errno.h> | 17 | #include <linux/errno.h> |
@@ -30,13 +32,7 @@ | |||
30 | #include <asm/smu.h> | 32 | #include <asm/smu.h> |
31 | #include <asm/pmac_pfunc.h> | 33 | #include <asm/pmac_pfunc.h> |
32 | 34 | ||
33 | #undef DEBUG | 35 | #define DBG(fmt...) pr_debug(fmt) |
34 | |||
35 | #ifdef DEBUG | ||
36 | #define DBG(fmt...) printk(fmt) | ||
37 | #else | ||
38 | #define DBG(fmt...) | ||
39 | #endif | ||
40 | 36 | ||
41 | /* see 970FX user manual */ | 37 | /* see 970FX user manual */ |
42 | 38 | ||
@@ -82,8 +78,6 @@ static struct freq_attr* g5_cpu_freqs_attr[] = { | |||
82 | /* Power mode data is an array of the 32 bits PCR values to use for | 78 | /* Power mode data is an array of the 32 bits PCR values to use for |
83 | * the various frequencies, retrieved from the device-tree | 79 | * the various frequencies, retrieved from the device-tree |
84 | */ | 80 | */ |
85 | static u32 *g5_pmode_data; | ||
86 | static int g5_pmode_max; | ||
87 | static int g5_pmode_cur; | 81 | static int g5_pmode_cur; |
88 | 82 | ||
89 | static void (*g5_switch_volt)(int speed_mode); | 83 | static void (*g5_switch_volt)(int speed_mode); |
@@ -93,6 +87,11 @@ static int (*g5_query_freq)(void); | |||
93 | static DEFINE_MUTEX(g5_switch_mutex); | 87 | static DEFINE_MUTEX(g5_switch_mutex); |
94 | 88 | ||
95 | 89 | ||
90 | #ifdef CONFIG_PMAC_SMU | ||
91 | |||
92 | static u32 *g5_pmode_data; | ||
93 | static int g5_pmode_max; | ||
94 | |||
96 | static struct smu_sdbp_fvt *g5_fvt_table; /* table of op. points */ | 95 | static struct smu_sdbp_fvt *g5_fvt_table; /* table of op. points */ |
97 | static int g5_fvt_count; /* number of op. points */ | 96 | static int g5_fvt_count; /* number of op. points */ |
98 | static int g5_fvt_cur; /* current op. point */ | 97 | static int g5_fvt_cur; /* current op. point */ |
@@ -210,6 +209,16 @@ static int g5_scom_query_freq(void) | |||
210 | } | 209 | } |
211 | 210 | ||
212 | /* | 211 | /* |
212 | * Fake voltage switching for platforms with missing support | ||
213 | */ | ||
214 | |||
215 | static void g5_dummy_switch_volt(int speed_mode) | ||
216 | { | ||
217 | } | ||
218 | |||
219 | #endif /* CONFIG_PMAC_SMU */ | ||
220 | |||
221 | /* | ||
213 | * Platform function based voltage switching for PowerMac7,2 & 7,3 | 222 | * Platform function based voltage switching for PowerMac7,2 & 7,3 |
214 | */ | 223 | */ |
215 | 224 | ||
@@ -248,6 +257,9 @@ static int g5_pfunc_switch_freq(int speed_mode) | |||
248 | struct pmf_args args; | 257 | struct pmf_args args; |
249 | u32 done = 0; | 258 | u32 done = 0; |
250 | unsigned long timeout; | 259 | unsigned long timeout; |
260 | int rc; | ||
261 | |||
262 | DBG("g5_pfunc_switch_freq(%d)\n", speed_mode); | ||
251 | 263 | ||
252 | /* If frequency is going up, first ramp up the voltage */ | 264 | /* If frequency is going up, first ramp up the voltage */ |
253 | if (speed_mode < g5_pmode_cur) | 265 | if (speed_mode < g5_pmode_cur) |
@@ -255,9 +267,12 @@ static int g5_pfunc_switch_freq(int speed_mode) | |||
255 | 267 | ||
256 | /* Do it */ | 268 | /* Do it */ |
257 | if (speed_mode == CPUFREQ_HIGH) | 269 | if (speed_mode == CPUFREQ_HIGH) |
258 | pmf_call_one(pfunc_cpu_setfreq_high, NULL); | 270 | rc = pmf_call_one(pfunc_cpu_setfreq_high, NULL); |
259 | else | 271 | else |
260 | pmf_call_one(pfunc_cpu_setfreq_low, NULL); | 272 | rc = pmf_call_one(pfunc_cpu_setfreq_low, NULL); |
273 | |||
274 | if (rc) | ||
275 | printk(KERN_WARNING "cpufreq: pfunc switch error %d\n", rc); | ||
261 | 276 | ||
262 | /* It's an irq GPIO so we should be able to just block here, | 277 | /* It's an irq GPIO so we should be able to just block here, |
263 | * I'll do that later after I've properly tested the IRQ code for | 278 | * I'll do that later after I've properly tested the IRQ code for |
@@ -296,13 +311,6 @@ static int g5_pfunc_query_freq(void) | |||
296 | return val ? CPUFREQ_HIGH : CPUFREQ_LOW; | 311 | return val ? CPUFREQ_HIGH : CPUFREQ_LOW; |
297 | } | 312 | } |
298 | 313 | ||
299 | /* | ||
300 | * Fake voltage switching for platforms with missing support | ||
301 | */ | ||
302 | |||
303 | static void g5_dummy_switch_volt(int speed_mode) | ||
304 | { | ||
305 | } | ||
306 | 314 | ||
307 | /* | 315 | /* |
308 | * Common interface to the cpufreq core | 316 | * Common interface to the cpufreq core |
@@ -375,6 +383,8 @@ static struct cpufreq_driver g5_cpufreq_driver = { | |||
375 | }; | 383 | }; |
376 | 384 | ||
377 | 385 | ||
386 | #ifdef CONFIG_PMAC_SMU | ||
387 | |||
378 | static int __init g5_neo2_cpufreq_init(struct device_node *cpus) | 388 | static int __init g5_neo2_cpufreq_init(struct device_node *cpus) |
379 | { | 389 | { |
380 | struct device_node *cpunode; | 390 | struct device_node *cpunode; |
@@ -525,6 +535,9 @@ static int __init g5_neo2_cpufreq_init(struct device_node *cpus) | |||
525 | return rc; | 535 | return rc; |
526 | } | 536 | } |
527 | 537 | ||
538 | #endif /* CONFIG_PMAC_SMU */ | ||
539 | |||
540 | |||
528 | static int __init g5_pm72_cpufreq_init(struct device_node *cpus) | 541 | static int __init g5_pm72_cpufreq_init(struct device_node *cpus) |
529 | { | 542 | { |
530 | struct device_node *cpuid = NULL, *hwclock = NULL, *cpunode = NULL; | 543 | struct device_node *cpuid = NULL, *hwclock = NULL, *cpunode = NULL; |
@@ -533,6 +546,9 @@ static int __init g5_pm72_cpufreq_init(struct device_node *cpus) | |||
533 | u64 max_freq, min_freq, ih, il; | 546 | u64 max_freq, min_freq, ih, il; |
534 | int has_volt = 1, rc = 0; | 547 | int has_volt = 1, rc = 0; |
535 | 548 | ||
549 | DBG("cpufreq: Initializing for PowerMac7,2, PowerMac7,3 and" | ||
550 | " RackMac3,1...\n"); | ||
551 | |||
536 | /* Get first CPU node */ | 552 | /* Get first CPU node */ |
537 | for (cpunode = NULL; | 553 | for (cpunode = NULL; |
538 | (cpunode = of_get_next_child(cpus, cpunode)) != NULL;) { | 554 | (cpunode = of_get_next_child(cpus, cpunode)) != NULL;) { |
@@ -636,6 +652,15 @@ static int __init g5_pm72_cpufreq_init(struct device_node *cpus) | |||
636 | */ | 652 | */ |
637 | ih = *((u32 *)(eeprom + 0x10)); | 653 | ih = *((u32 *)(eeprom + 0x10)); |
638 | il = *((u32 *)(eeprom + 0x20)); | 654 | il = *((u32 *)(eeprom + 0x20)); |
655 | |||
656 | /* Check for machines with no useful settings */ | ||
657 | if (il == ih) { | ||
658 | printk(KERN_WARNING "cpufreq: No low frequency mode available" | ||
659 | " on this model !\n"); | ||
660 | rc = -ENODEV; | ||
661 | goto bail; | ||
662 | } | ||
663 | |||
639 | min_freq = 0; | 664 | min_freq = 0; |
640 | if (ih != 0 && il != 0) | 665 | if (ih != 0 && il != 0) |
641 | min_freq = (max_freq * il) / ih; | 666 | min_freq = (max_freq * il) / ih; |
@@ -643,7 +668,7 @@ static int __init g5_pm72_cpufreq_init(struct device_node *cpus) | |||
643 | /* Sanity check */ | 668 | /* Sanity check */ |
644 | if (min_freq >= max_freq || min_freq < 1000) { | 669 | if (min_freq >= max_freq || min_freq < 1000) { |
645 | printk(KERN_ERR "cpufreq: Can't calculate low frequency !\n"); | 670 | printk(KERN_ERR "cpufreq: Can't calculate low frequency !\n"); |
646 | rc = -ENODEV; | 671 | rc = -ENXIO; |
647 | goto bail; | 672 | goto bail; |
648 | } | 673 | } |
649 | g5_cpu_freqs[0].frequency = max_freq; | 674 | g5_cpu_freqs[0].frequency = max_freq; |
@@ -690,16 +715,10 @@ static int __init g5_pm72_cpufreq_init(struct device_node *cpus) | |||
690 | return rc; | 715 | return rc; |
691 | } | 716 | } |
692 | 717 | ||
693 | static int __init g5_rm31_cpufreq_init(struct device_node *cpus) | ||
694 | { | ||
695 | /* NYI */ | ||
696 | return 0; | ||
697 | } | ||
698 | |||
699 | static int __init g5_cpufreq_init(void) | 718 | static int __init g5_cpufreq_init(void) |
700 | { | 719 | { |
701 | struct device_node *cpus; | 720 | struct device_node *cpus; |
702 | int rc; | 721 | int rc = 0; |
703 | 722 | ||
704 | cpus = of_find_node_by_path("/cpus"); | 723 | cpus = of_find_node_by_path("/cpus"); |
705 | if (cpus == NULL) { | 724 | if (cpus == NULL) { |
@@ -708,12 +727,13 @@ static int __init g5_cpufreq_init(void) | |||
708 | } | 727 | } |
709 | 728 | ||
710 | if (machine_is_compatible("PowerMac7,2") || | 729 | if (machine_is_compatible("PowerMac7,2") || |
711 | machine_is_compatible("PowerMac7,3")) | 730 | machine_is_compatible("PowerMac7,3") || |
731 | machine_is_compatible("RackMac3,1")) | ||
712 | rc = g5_pm72_cpufreq_init(cpus); | 732 | rc = g5_pm72_cpufreq_init(cpus); |
713 | else if (machine_is_compatible("RackMac3,1")) | 733 | #ifdef CONFIG_PMAC_SMU |
714 | rc = g5_rm31_cpufreq_init(cpus); | ||
715 | else | 734 | else |
716 | rc = g5_neo2_cpufreq_init(cpus); | 735 | rc = g5_neo2_cpufreq_init(cpus); |
736 | #endif /* CONFIG_PMAC_SMU */ | ||
717 | 737 | ||
718 | of_node_put(cpus); | 738 | of_node_put(cpus); |
719 | return rc; | 739 | return rc; |
diff --git a/arch/powerpc/platforms/pseries/setup.c b/arch/powerpc/platforms/pseries/setup.c index 54a52437265c..71c634e0b87c 100644 --- a/arch/powerpc/platforms/pseries/setup.c +++ b/arch/powerpc/platforms/pseries/setup.c | |||
@@ -501,7 +501,8 @@ static void pseries_dedicated_idle_sleep(void) | |||
501 | } | 501 | } |
502 | 502 | ||
503 | /* | 503 | /* |
504 | * Cede if the other thread is not idle, so that it can | 504 | * If not SMT, cede processor. If CPU is running SMT |
505 | * cede if the other thread is not idle, so that it can | ||
505 | * go single-threaded. If the other thread is idle, | 506 | * go single-threaded. If the other thread is idle, |
506 | * we ask the hypervisor if it has pending work it | 507 | * we ask the hypervisor if it has pending work it |
507 | * wants to do and cede if it does. Otherwise we keep | 508 | * wants to do and cede if it does. Otherwise we keep |
@@ -514,7 +515,8 @@ static void pseries_dedicated_idle_sleep(void) | |||
514 | * very low priority. The cede enables interrupts, which | 515 | * very low priority. The cede enables interrupts, which |
515 | * doesn't matter here. | 516 | * doesn't matter here. |
516 | */ | 517 | */ |
517 | if (!lppaca[cpu ^ 1].idle || poll_pending() == H_PENDING) | 518 | if (!cpu_has_feature(CPU_FTR_SMT) || !lppaca[cpu ^ 1].idle |
519 | || poll_pending() == H_PENDING) | ||
518 | cede_processor(); | 520 | cede_processor(); |
519 | 521 | ||
520 | out: | 522 | out: |
diff --git a/arch/ppc/kernel/vmlinux.lds.S b/arch/ppc/kernel/vmlinux.lds.S index 09c6525cfa61..095fd3323323 100644 --- a/arch/ppc/kernel/vmlinux.lds.S +++ b/arch/ppc/kernel/vmlinux.lds.S | |||
@@ -8,6 +8,7 @@ SECTIONS | |||
8 | . = + SIZEOF_HEADERS; | 8 | . = + SIZEOF_HEADERS; |
9 | .interp : { *(.interp) } | 9 | .interp : { *(.interp) } |
10 | .hash : { *(.hash) } | 10 | .hash : { *(.hash) } |
11 | .gnu.hash : { *(.gnu.hash) } | ||
11 | .dynsym : { *(.dynsym) } | 12 | .dynsym : { *(.dynsym) } |
12 | .dynstr : { *(.dynstr) } | 13 | .dynstr : { *(.dynstr) } |
13 | .rel.text : { *(.rel.text) } | 14 | .rel.text : { *(.rel.text) } |
diff --git a/arch/s390/appldata/appldata_base.c b/arch/s390/appldata/appldata_base.c index d0f82c995af6..6a4b5f9715c9 100644 --- a/arch/s390/appldata/appldata_base.c +++ b/arch/s390/appldata/appldata_base.c | |||
@@ -617,7 +617,8 @@ appldata_offline_cpu(int cpu) | |||
617 | spin_unlock(&appldata_timer_lock); | 617 | spin_unlock(&appldata_timer_lock); |
618 | } | 618 | } |
619 | 619 | ||
620 | static int __cpuinit | 620 | #ifdef CONFIG_HOTPLUG_CPU |
621 | static int | ||
621 | appldata_cpu_notify(struct notifier_block *self, | 622 | appldata_cpu_notify(struct notifier_block *self, |
622 | unsigned long action, void *hcpu) | 623 | unsigned long action, void *hcpu) |
623 | { | 624 | { |
@@ -625,20 +626,19 @@ appldata_cpu_notify(struct notifier_block *self, | |||
625 | case CPU_ONLINE: | 626 | case CPU_ONLINE: |
626 | appldata_online_cpu((long) hcpu); | 627 | appldata_online_cpu((long) hcpu); |
627 | break; | 628 | break; |
628 | #ifdef CONFIG_HOTPLUG_CPU | ||
629 | case CPU_DEAD: | 629 | case CPU_DEAD: |
630 | appldata_offline_cpu((long) hcpu); | 630 | appldata_offline_cpu((long) hcpu); |
631 | break; | 631 | break; |
632 | #endif | ||
633 | default: | 632 | default: |
634 | break; | 633 | break; |
635 | } | 634 | } |
636 | return NOTIFY_OK; | 635 | return NOTIFY_OK; |
637 | } | 636 | } |
638 | 637 | ||
639 | static struct notifier_block __devinitdata appldata_nb = { | 638 | static struct notifier_block appldata_nb = { |
640 | .notifier_call = appldata_cpu_notify, | 639 | .notifier_call = appldata_cpu_notify, |
641 | }; | 640 | }; |
641 | #endif | ||
642 | 642 | ||
643 | /* | 643 | /* |
644 | * appldata_init() | 644 | * appldata_init() |
@@ -662,7 +662,7 @@ static int __init appldata_init(void) | |||
662 | appldata_online_cpu(i); | 662 | appldata_online_cpu(i); |
663 | 663 | ||
664 | /* Register cpu hotplug notifier */ | 664 | /* Register cpu hotplug notifier */ |
665 | register_cpu_notifier(&appldata_nb); | 665 | register_hotcpu_notifier(&appldata_nb); |
666 | 666 | ||
667 | appldata_sysctl_header = register_sysctl_table(appldata_dir_table, 1); | 667 | appldata_sysctl_header = register_sysctl_table(appldata_dir_table, 1); |
668 | #ifdef MODULE | 668 | #ifdef MODULE |
diff --git a/arch/s390/defconfig b/arch/s390/defconfig index f4dfc10026d2..f1d4591eddbb 100644 --- a/arch/s390/defconfig +++ b/arch/s390/defconfig | |||
@@ -1,13 +1,16 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.17-rc1 | 3 | # Linux kernel version: 2.6.18-rc2 |
4 | # Mon Apr 3 14:34:15 2006 | 4 | # Thu Jul 27 13:51:07 2006 |
5 | # | 5 | # |
6 | CONFIG_MMU=y | 6 | CONFIG_MMU=y |
7 | CONFIG_LOCKDEP_SUPPORT=y | ||
8 | CONFIG_STACKTRACE_SUPPORT=y | ||
7 | CONFIG_RWSEM_XCHGADD_ALGORITHM=y | 9 | CONFIG_RWSEM_XCHGADD_ALGORITHM=y |
8 | CONFIG_GENERIC_HWEIGHT=y | 10 | CONFIG_GENERIC_HWEIGHT=y |
9 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 11 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
10 | CONFIG_S390=y | 12 | CONFIG_S390=y |
13 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
11 | 14 | ||
12 | # | 15 | # |
13 | # Code maturity level options | 16 | # Code maturity level options |
@@ -25,6 +28,7 @@ CONFIG_SWAP=y | |||
25 | CONFIG_SYSVIPC=y | 28 | CONFIG_SYSVIPC=y |
26 | CONFIG_POSIX_MQUEUE=y | 29 | CONFIG_POSIX_MQUEUE=y |
27 | # CONFIG_BSD_PROCESS_ACCT is not set | 30 | # CONFIG_BSD_PROCESS_ACCT is not set |
31 | # CONFIG_TASKSTATS is not set | ||
28 | CONFIG_SYSCTL=y | 32 | CONFIG_SYSCTL=y |
29 | CONFIG_AUDIT=y | 33 | CONFIG_AUDIT=y |
30 | # CONFIG_AUDITSYSCALL is not set | 34 | # CONFIG_AUDITSYSCALL is not set |
@@ -43,10 +47,12 @@ CONFIG_PRINTK=y | |||
43 | CONFIG_BUG=y | 47 | CONFIG_BUG=y |
44 | CONFIG_ELF_CORE=y | 48 | CONFIG_ELF_CORE=y |
45 | CONFIG_BASE_FULL=y | 49 | CONFIG_BASE_FULL=y |
50 | CONFIG_RT_MUTEXES=y | ||
46 | CONFIG_FUTEX=y | 51 | CONFIG_FUTEX=y |
47 | CONFIG_EPOLL=y | 52 | CONFIG_EPOLL=y |
48 | CONFIG_SHMEM=y | 53 | CONFIG_SHMEM=y |
49 | CONFIG_SLAB=y | 54 | CONFIG_SLAB=y |
55 | CONFIG_VM_EVENT_COUNTERS=y | ||
50 | # CONFIG_TINY_SHMEM is not set | 56 | # CONFIG_TINY_SHMEM is not set |
51 | CONFIG_BASE_SMALL=0 | 57 | CONFIG_BASE_SMALL=0 |
52 | # CONFIG_SLOB is not set | 58 | # CONFIG_SLOB is not set |
@@ -94,7 +100,6 @@ CONFIG_HOTPLUG_CPU=y | |||
94 | CONFIG_DEFAULT_MIGRATION_COST=1000000 | 100 | CONFIG_DEFAULT_MIGRATION_COST=1000000 |
95 | CONFIG_COMPAT=y | 101 | CONFIG_COMPAT=y |
96 | CONFIG_SYSVIPC_COMPAT=y | 102 | CONFIG_SYSVIPC_COMPAT=y |
97 | CONFIG_BINFMT_ELF32=y | ||
98 | 103 | ||
99 | # | 104 | # |
100 | # Code generation options | 105 | # Code generation options |
@@ -115,6 +120,7 @@ CONFIG_FLATMEM=y | |||
115 | CONFIG_FLAT_NODE_MEM_MAP=y | 120 | CONFIG_FLAT_NODE_MEM_MAP=y |
116 | # CONFIG_SPARSEMEM_STATIC is not set | 121 | # CONFIG_SPARSEMEM_STATIC is not set |
117 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 122 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
123 | CONFIG_RESOURCES_64BIT=y | ||
118 | 124 | ||
119 | # | 125 | # |
120 | # I/O subsystem configuration | 126 | # I/O subsystem configuration |
@@ -142,6 +148,7 @@ CONFIG_VIRT_CPU_ACCOUNTING=y | |||
142 | # CONFIG_APPLDATA_BASE is not set | 148 | # CONFIG_APPLDATA_BASE is not set |
143 | CONFIG_NO_IDLE_HZ=y | 149 | CONFIG_NO_IDLE_HZ=y |
144 | CONFIG_NO_IDLE_HZ_INIT=y | 150 | CONFIG_NO_IDLE_HZ_INIT=y |
151 | CONFIG_S390_HYPFS_FS=y | ||
145 | CONFIG_KEXEC=y | 152 | CONFIG_KEXEC=y |
146 | 153 | ||
147 | # | 154 | # |
@@ -174,6 +181,8 @@ CONFIG_IP_FIB_HASH=y | |||
174 | # CONFIG_INET_IPCOMP is not set | 181 | # CONFIG_INET_IPCOMP is not set |
175 | # CONFIG_INET_XFRM_TUNNEL is not set | 182 | # CONFIG_INET_XFRM_TUNNEL is not set |
176 | # CONFIG_INET_TUNNEL is not set | 183 | # CONFIG_INET_TUNNEL is not set |
184 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
185 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
177 | CONFIG_INET_DIAG=y | 186 | CONFIG_INET_DIAG=y |
178 | CONFIG_INET_TCP_DIAG=y | 187 | CONFIG_INET_TCP_DIAG=y |
179 | # CONFIG_TCP_CONG_ADVANCED is not set | 188 | # CONFIG_TCP_CONG_ADVANCED is not set |
@@ -186,7 +195,10 @@ CONFIG_IPV6=y | |||
186 | # CONFIG_INET6_IPCOMP is not set | 195 | # CONFIG_INET6_IPCOMP is not set |
187 | # CONFIG_INET6_XFRM_TUNNEL is not set | 196 | # CONFIG_INET6_XFRM_TUNNEL is not set |
188 | # CONFIG_INET6_TUNNEL is not set | 197 | # CONFIG_INET6_TUNNEL is not set |
198 | CONFIG_INET6_XFRM_MODE_TRANSPORT=y | ||
199 | CONFIG_INET6_XFRM_MODE_TUNNEL=y | ||
189 | # CONFIG_IPV6_TUNNEL is not set | 200 | # CONFIG_IPV6_TUNNEL is not set |
201 | # CONFIG_NETWORK_SECMARK is not set | ||
190 | # CONFIG_NETFILTER is not set | 202 | # CONFIG_NETFILTER is not set |
191 | 203 | ||
192 | # | 204 | # |
@@ -263,6 +275,7 @@ CONFIG_NET_ESTIMATOR=y | |||
263 | # Network testing | 275 | # Network testing |
264 | # | 276 | # |
265 | # CONFIG_NET_PKTGEN is not set | 277 | # CONFIG_NET_PKTGEN is not set |
278 | # CONFIG_NET_TCPPROBE is not set | ||
266 | # CONFIG_HAMRADIO is not set | 279 | # CONFIG_HAMRADIO is not set |
267 | # CONFIG_IRDA is not set | 280 | # CONFIG_IRDA is not set |
268 | # CONFIG_BT is not set | 281 | # CONFIG_BT is not set |
@@ -276,6 +289,7 @@ CONFIG_STANDALONE=y | |||
276 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 289 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
277 | # CONFIG_FW_LOADER is not set | 290 | # CONFIG_FW_LOADER is not set |
278 | # CONFIG_DEBUG_DRIVER is not set | 291 | # CONFIG_DEBUG_DRIVER is not set |
292 | CONFIG_SYS_HYPERVISOR=y | ||
279 | 293 | ||
280 | # | 294 | # |
281 | # Connector - unified userspace <-> kernelspace linker | 295 | # Connector - unified userspace <-> kernelspace linker |
@@ -334,6 +348,7 @@ CONFIG_BLK_DEV_NBD=m | |||
334 | CONFIG_BLK_DEV_RAM=y | 348 | CONFIG_BLK_DEV_RAM=y |
335 | CONFIG_BLK_DEV_RAM_COUNT=16 | 349 | CONFIG_BLK_DEV_RAM_COUNT=16 |
336 | CONFIG_BLK_DEV_RAM_SIZE=4096 | 350 | CONFIG_BLK_DEV_RAM_SIZE=4096 |
351 | CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | ||
337 | CONFIG_BLK_DEV_INITRD=y | 352 | CONFIG_BLK_DEV_INITRD=y |
338 | # CONFIG_CDROM_PKTCDVD is not set | 353 | # CONFIG_CDROM_PKTCDVD is not set |
339 | 354 | ||
@@ -359,9 +374,7 @@ CONFIG_MD_LINEAR=m | |||
359 | CONFIG_MD_RAID0=m | 374 | CONFIG_MD_RAID0=m |
360 | CONFIG_MD_RAID1=m | 375 | CONFIG_MD_RAID1=m |
361 | # CONFIG_MD_RAID10 is not set | 376 | # CONFIG_MD_RAID10 is not set |
362 | CONFIG_MD_RAID5=m | 377 | # CONFIG_MD_RAID456 is not set |
363 | # CONFIG_MD_RAID5_RESHAPE is not set | ||
364 | # CONFIG_MD_RAID6 is not set | ||
365 | CONFIG_MD_MULTIPATH=m | 378 | CONFIG_MD_MULTIPATH=m |
366 | # CONFIG_MD_FAULTY is not set | 379 | # CONFIG_MD_FAULTY is not set |
367 | CONFIG_BLK_DEV_DM=y | 380 | CONFIG_BLK_DEV_DM=y |
@@ -419,7 +432,8 @@ CONFIG_S390_TAPE_34XX=m | |||
419 | # | 432 | # |
420 | # Cryptographic devices | 433 | # Cryptographic devices |
421 | # | 434 | # |
422 | CONFIG_Z90CRYPT=m | 435 | CONFIG_ZCRYPT=m |
436 | # CONFIG_ZCRYPT_MONOLITHIC is not set | ||
423 | 437 | ||
424 | # | 438 | # |
425 | # Network device support | 439 | # Network device support |
@@ -509,6 +523,7 @@ CONFIG_FS_MBCACHE=y | |||
509 | # CONFIG_MINIX_FS is not set | 523 | # CONFIG_MINIX_FS is not set |
510 | # CONFIG_ROMFS_FS is not set | 524 | # CONFIG_ROMFS_FS is not set |
511 | CONFIG_INOTIFY=y | 525 | CONFIG_INOTIFY=y |
526 | CONFIG_INOTIFY_USER=y | ||
512 | # CONFIG_QUOTA is not set | 527 | # CONFIG_QUOTA is not set |
513 | CONFIG_DNOTIFY=y | 528 | CONFIG_DNOTIFY=y |
514 | # CONFIG_AUTOFS_FS is not set | 529 | # CONFIG_AUTOFS_FS is not set |
@@ -614,26 +629,36 @@ CONFIG_MSDOS_PARTITION=y | |||
614 | # Instrumentation Support | 629 | # Instrumentation Support |
615 | # | 630 | # |
616 | # CONFIG_PROFILING is not set | 631 | # CONFIG_PROFILING is not set |
617 | # CONFIG_STATISTICS is not set | 632 | CONFIG_STATISTICS=y |
633 | CONFIG_KPROBES=y | ||
618 | 634 | ||
619 | # | 635 | # |
620 | # Kernel hacking | 636 | # Kernel hacking |
621 | # | 637 | # |
638 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
622 | # CONFIG_PRINTK_TIME is not set | 639 | # CONFIG_PRINTK_TIME is not set |
623 | CONFIG_MAGIC_SYSRQ=y | 640 | CONFIG_MAGIC_SYSRQ=y |
641 | # CONFIG_UNUSED_SYMBOLS is not set | ||
624 | CONFIG_DEBUG_KERNEL=y | 642 | CONFIG_DEBUG_KERNEL=y |
625 | CONFIG_LOG_BUF_SHIFT=17 | 643 | CONFIG_LOG_BUF_SHIFT=17 |
626 | # CONFIG_DETECT_SOFTLOCKUP is not set | 644 | # CONFIG_DETECT_SOFTLOCKUP is not set |
627 | # CONFIG_SCHEDSTATS is not set | 645 | # CONFIG_SCHEDSTATS is not set |
628 | # CONFIG_DEBUG_SLAB is not set | 646 | # CONFIG_DEBUG_SLAB is not set |
629 | CONFIG_DEBUG_PREEMPT=y | 647 | CONFIG_DEBUG_PREEMPT=y |
630 | CONFIG_DEBUG_MUTEXES=y | 648 | # CONFIG_DEBUG_RT_MUTEXES is not set |
649 | # CONFIG_RT_MUTEX_TESTER is not set | ||
631 | CONFIG_DEBUG_SPINLOCK=y | 650 | CONFIG_DEBUG_SPINLOCK=y |
651 | CONFIG_DEBUG_MUTEXES=y | ||
652 | # CONFIG_DEBUG_RWSEMS is not set | ||
653 | # CONFIG_DEBUG_LOCK_ALLOC is not set | ||
654 | # CONFIG_PROVE_LOCKING is not set | ||
632 | CONFIG_DEBUG_SPINLOCK_SLEEP=y | 655 | CONFIG_DEBUG_SPINLOCK_SLEEP=y |
656 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set | ||
633 | # CONFIG_DEBUG_KOBJECT is not set | 657 | # CONFIG_DEBUG_KOBJECT is not set |
634 | # CONFIG_DEBUG_INFO is not set | 658 | # CONFIG_DEBUG_INFO is not set |
635 | CONFIG_DEBUG_FS=y | 659 | CONFIG_DEBUG_FS=y |
636 | # CONFIG_DEBUG_VM is not set | 660 | # CONFIG_DEBUG_VM is not set |
661 | # CONFIG_FRAME_POINTER is not set | ||
637 | # CONFIG_UNWIND_INFO is not set | 662 | # CONFIG_UNWIND_INFO is not set |
638 | CONFIG_FORCED_INLINING=y | 663 | CONFIG_FORCED_INLINING=y |
639 | # CONFIG_RCU_TORTURE_TEST is not set | 664 | # CONFIG_RCU_TORTURE_TEST is not set |
@@ -688,3 +713,4 @@ CONFIG_CRYPTO=y | |||
688 | # CONFIG_CRC16 is not set | 713 | # CONFIG_CRC16 is not set |
689 | CONFIG_CRC32=m | 714 | CONFIG_CRC32=m |
690 | # CONFIG_LIBCRC32C is not set | 715 | # CONFIG_LIBCRC32C is not set |
716 | CONFIG_PLIST=y | ||
diff --git a/arch/sh/kernel/cpu/sh4/sq.c b/arch/sh/kernel/cpu/sh4/sq.c index 781dbb11c038..b09805f3ee23 100644 --- a/arch/sh/kernel/cpu/sh4/sq.c +++ b/arch/sh/kernel/cpu/sh4/sq.c | |||
@@ -421,18 +421,22 @@ static struct miscdevice sq_dev = { | |||
421 | 421 | ||
422 | static int __init sq_api_init(void) | 422 | static int __init sq_api_init(void) |
423 | { | 423 | { |
424 | int ret; | ||
424 | printk(KERN_NOTICE "sq: Registering store queue API.\n"); | 425 | printk(KERN_NOTICE "sq: Registering store queue API.\n"); |
425 | 426 | ||
426 | #ifdef CONFIG_PROC_FS | ||
427 | create_proc_read_entry("sq_mapping", 0, 0, sq_mapping_read_proc, 0); | 427 | create_proc_read_entry("sq_mapping", 0, 0, sq_mapping_read_proc, 0); |
428 | #endif | ||
429 | 428 | ||
430 | return misc_register(&sq_dev); | 429 | ret = misc_register(&sq_dev); |
430 | if (ret) | ||
431 | remove_proc_entry("sq_mapping", NULL); | ||
432 | |||
433 | return ret; | ||
431 | } | 434 | } |
432 | 435 | ||
433 | static void __exit sq_api_exit(void) | 436 | static void __exit sq_api_exit(void) |
434 | { | 437 | { |
435 | misc_deregister(&sq_dev); | 438 | misc_deregister(&sq_dev); |
439 | remove_proc_entry("sq_mapping", NULL); | ||
436 | } | 440 | } |
437 | 441 | ||
438 | module_init(sq_api_init); | 442 | module_init(sq_api_init); |
diff --git a/arch/sparc/kernel/time.c b/arch/sparc/kernel/time.c index 04eb1eab6e3e..845081b01267 100644 --- a/arch/sparc/kernel/time.c +++ b/arch/sparc/kernel/time.c | |||
@@ -225,6 +225,32 @@ static __inline__ int has_low_battery(void) | |||
225 | return (data1 == data2); /* Was the write blocked? */ | 225 | return (data1 == data2); /* Was the write blocked? */ |
226 | } | 226 | } |
227 | 227 | ||
228 | static void __init mostek_set_system_time(void) | ||
229 | { | ||
230 | unsigned int year, mon, day, hour, min, sec; | ||
231 | struct mostek48t02 *mregs; | ||
232 | |||
233 | mregs = (struct mostek48t02 *)mstk48t02_regs; | ||
234 | if(!mregs) { | ||
235 | prom_printf("Something wrong, clock regs not mapped yet.\n"); | ||
236 | prom_halt(); | ||
237 | } | ||
238 | spin_lock_irq(&mostek_lock); | ||
239 | mregs->creg |= MSTK_CREG_READ; | ||
240 | sec = MSTK_REG_SEC(mregs); | ||
241 | min = MSTK_REG_MIN(mregs); | ||
242 | hour = MSTK_REG_HOUR(mregs); | ||
243 | day = MSTK_REG_DOM(mregs); | ||
244 | mon = MSTK_REG_MONTH(mregs); | ||
245 | year = MSTK_CVT_YEAR( MSTK_REG_YEAR(mregs) ); | ||
246 | xtime.tv_sec = mktime(year, mon, day, hour, min, sec); | ||
247 | xtime.tv_nsec = (INITIAL_JIFFIES % HZ) * (NSEC_PER_SEC / HZ); | ||
248 | set_normalized_timespec(&wall_to_monotonic, | ||
249 | -xtime.tv_sec, -xtime.tv_nsec); | ||
250 | mregs->creg &= ~MSTK_CREG_READ; | ||
251 | spin_unlock_irq(&mostek_lock); | ||
252 | } | ||
253 | |||
228 | /* Probe for the real time clock chip on Sun4 */ | 254 | /* Probe for the real time clock chip on Sun4 */ |
229 | static __inline__ void sun4_clock_probe(void) | 255 | static __inline__ void sun4_clock_probe(void) |
230 | { | 256 | { |
@@ -273,6 +299,7 @@ static __inline__ void sun4_clock_probe(void) | |||
273 | #endif | 299 | #endif |
274 | } | 300 | } |
275 | 301 | ||
302 | #ifndef CONFIG_SUN4 | ||
276 | static int __devinit clock_probe(struct of_device *op, const struct of_device_id *match) | 303 | static int __devinit clock_probe(struct of_device *op, const struct of_device_id *match) |
277 | { | 304 | { |
278 | struct device_node *dp = op->node; | 305 | struct device_node *dp = op->node; |
@@ -307,6 +334,8 @@ static int __devinit clock_probe(struct of_device *op, const struct of_device_id | |||
307 | if (mostek_read(mstk48t02_regs + MOSTEK_SEC) & MSTK_STOP) | 334 | if (mostek_read(mstk48t02_regs + MOSTEK_SEC) & MSTK_STOP) |
308 | kick_start_clock(); | 335 | kick_start_clock(); |
309 | 336 | ||
337 | mostek_set_system_time(); | ||
338 | |||
310 | return 0; | 339 | return 0; |
311 | } | 340 | } |
312 | 341 | ||
@@ -325,56 +354,37 @@ static struct of_platform_driver clock_driver = { | |||
325 | 354 | ||
326 | 355 | ||
327 | /* Probe for the mostek real time clock chip. */ | 356 | /* Probe for the mostek real time clock chip. */ |
328 | static void clock_init(void) | 357 | static int __init clock_init(void) |
329 | { | 358 | { |
330 | of_register_driver(&clock_driver, &of_bus_type); | 359 | return of_register_driver(&clock_driver, &of_bus_type); |
331 | } | 360 | } |
332 | 361 | ||
362 | /* Must be after subsys_initcall() so that busses are probed. Must | ||
363 | * be before device_initcall() because things like the RTC driver | ||
364 | * need to see the clock registers. | ||
365 | */ | ||
366 | fs_initcall(clock_init); | ||
367 | #endif /* !CONFIG_SUN4 */ | ||
368 | |||
333 | void __init sbus_time_init(void) | 369 | void __init sbus_time_init(void) |
334 | { | 370 | { |
335 | unsigned int year, mon, day, hour, min, sec; | ||
336 | struct mostek48t02 *mregs; | ||
337 | |||
338 | #ifdef CONFIG_SUN4 | ||
339 | int temp; | ||
340 | struct intersil *iregs; | ||
341 | #endif | ||
342 | 371 | ||
343 | BTFIXUPSET_CALL(bus_do_settimeofday, sbus_do_settimeofday, BTFIXUPCALL_NORM); | 372 | BTFIXUPSET_CALL(bus_do_settimeofday, sbus_do_settimeofday, BTFIXUPCALL_NORM); |
344 | btfixup(); | 373 | btfixup(); |
345 | 374 | ||
346 | if (ARCH_SUN4) | 375 | if (ARCH_SUN4) |
347 | sun4_clock_probe(); | 376 | sun4_clock_probe(); |
348 | else | ||
349 | clock_init(); | ||
350 | 377 | ||
351 | sparc_init_timers(timer_interrupt); | 378 | sparc_init_timers(timer_interrupt); |
352 | 379 | ||
353 | #ifdef CONFIG_SUN4 | 380 | #ifdef CONFIG_SUN4 |
354 | if(idprom->id_machtype == (SM_SUN4 | SM_4_330)) { | 381 | if(idprom->id_machtype == (SM_SUN4 | SM_4_330)) { |
355 | #endif | 382 | mostek_set_system_time(); |
356 | mregs = (struct mostek48t02 *)mstk48t02_regs; | ||
357 | if(!mregs) { | ||
358 | prom_printf("Something wrong, clock regs not mapped yet.\n"); | ||
359 | prom_halt(); | ||
360 | } | ||
361 | spin_lock_irq(&mostek_lock); | ||
362 | mregs->creg |= MSTK_CREG_READ; | ||
363 | sec = MSTK_REG_SEC(mregs); | ||
364 | min = MSTK_REG_MIN(mregs); | ||
365 | hour = MSTK_REG_HOUR(mregs); | ||
366 | day = MSTK_REG_DOM(mregs); | ||
367 | mon = MSTK_REG_MONTH(mregs); | ||
368 | year = MSTK_CVT_YEAR( MSTK_REG_YEAR(mregs) ); | ||
369 | xtime.tv_sec = mktime(year, mon, day, hour, min, sec); | ||
370 | xtime.tv_nsec = (INITIAL_JIFFIES % HZ) * (NSEC_PER_SEC / HZ); | ||
371 | set_normalized_timespec(&wall_to_monotonic, | ||
372 | -xtime.tv_sec, -xtime.tv_nsec); | ||
373 | mregs->creg &= ~MSTK_CREG_READ; | ||
374 | spin_unlock_irq(&mostek_lock); | ||
375 | #ifdef CONFIG_SUN4 | ||
376 | } else if(idprom->id_machtype == (SM_SUN4 | SM_4_260) ) { | 383 | } else if(idprom->id_machtype == (SM_SUN4 | SM_4_260) ) { |
377 | /* initialise the intersil on sun4 */ | 384 | /* initialise the intersil on sun4 */ |
385 | unsigned int year, mon, day, hour, min, sec; | ||
386 | int temp; | ||
387 | struct intersil *iregs; | ||
378 | 388 | ||
379 | iregs=intersil_clock; | 389 | iregs=intersil_clock; |
380 | if(!iregs) { | 390 | if(!iregs) { |
diff --git a/arch/um/kernel/dyn.lds.S b/arch/um/kernel/dyn.lds.S index 2517ecb8bf27..68ed24df5c8f 100644 --- a/arch/um/kernel/dyn.lds.S +++ b/arch/um/kernel/dyn.lds.S | |||
@@ -26,6 +26,7 @@ SECTIONS | |||
26 | 26 | ||
27 | /* Read-only sections, merged into text segment: */ | 27 | /* Read-only sections, merged into text segment: */ |
28 | .hash : { *(.hash) } | 28 | .hash : { *(.hash) } |
29 | .gnu.hash : { *(.gnu.hash) } | ||
29 | .dynsym : { *(.dynsym) } | 30 | .dynsym : { *(.dynsym) } |
30 | .dynstr : { *(.dynstr) } | 31 | .dynstr : { *(.dynstr) } |
31 | .gnu.version : { *(.gnu.version) } | 32 | .gnu.version : { *(.gnu.version) } |
diff --git a/arch/v850/kernel/setup.c b/arch/v850/kernel/setup.c index 62bdb8d29fc0..1bf672a25692 100644 --- a/arch/v850/kernel/setup.c +++ b/arch/v850/kernel/setup.c | |||
@@ -1,8 +1,8 @@ | |||
1 | /* | 1 | /* |
2 | * arch/v850/kernel/setup.c -- Arch-dependent initialization functions | 2 | * arch/v850/kernel/setup.c -- Arch-dependent initialization functions |
3 | * | 3 | * |
4 | * Copyright (C) 2001,02,03,05 NEC Electronics Corporation | 4 | * Copyright (C) 2001,02,03,05,06 NEC Electronics Corporation |
5 | * Copyright (C) 2001,02,03,05 Miles Bader <miles@gnu.org> | 5 | * Copyright (C) 2001,02,03,05,06 Miles Bader <miles@gnu.org> |
6 | * | 6 | * |
7 | * This file is subject to the terms and conditions of the GNU General | 7 | * This file is subject to the terms and conditions of the GNU General |
8 | * Public License. See the file COPYING in the main directory of this | 8 | * Public License. See the file COPYING in the main directory of this |
@@ -190,7 +190,7 @@ void free_initmem (void) | |||
190 | for (addr = start; addr < end; addr += PAGE_SIZE) { | 190 | for (addr = start; addr < end; addr += PAGE_SIZE) { |
191 | struct page *page = virt_to_page (addr); | 191 | struct page *page = virt_to_page (addr); |
192 | ClearPageReserved (page); | 192 | ClearPageReserved (page); |
193 | set_page_count (page, 1); | 193 | init_page_count (page); |
194 | __free_page (page); | 194 | __free_page (page); |
195 | total_ram_pages++; | 195 | total_ram_pages++; |
196 | } | 196 | } |
diff --git a/arch/v850/kernel/v850_ksyms.c b/arch/v850/kernel/v850_ksyms.c index c03ad6ed61cc..67bc48e57c60 100644 --- a/arch/v850/kernel/v850_ksyms.c +++ b/arch/v850/kernel/v850_ksyms.c | |||
@@ -21,9 +21,6 @@ EXPORT_SYMBOL (trap_table); | |||
21 | 21 | ||
22 | /* platform dependent support */ | 22 | /* platform dependent support */ |
23 | EXPORT_SYMBOL (kernel_thread); | 23 | EXPORT_SYMBOL (kernel_thread); |
24 | EXPORT_SYMBOL (enable_irq); | ||
25 | EXPORT_SYMBOL (disable_irq); | ||
26 | EXPORT_SYMBOL (disable_irq_nosync); | ||
27 | EXPORT_SYMBOL (__bug); | 24 | EXPORT_SYMBOL (__bug); |
28 | 25 | ||
29 | /* Networking helper routines. */ | 26 | /* Networking helper routines. */ |
@@ -33,22 +30,9 @@ EXPORT_SYMBOL (ip_compute_csum); | |||
33 | EXPORT_SYMBOL (ip_fast_csum); | 30 | EXPORT_SYMBOL (ip_fast_csum); |
34 | 31 | ||
35 | /* string / mem functions */ | 32 | /* string / mem functions */ |
36 | EXPORT_SYMBOL (strcpy); | ||
37 | EXPORT_SYMBOL (strncpy); | ||
38 | EXPORT_SYMBOL (strcat); | ||
39 | EXPORT_SYMBOL (strncat); | ||
40 | EXPORT_SYMBOL (strcmp); | ||
41 | EXPORT_SYMBOL (strncmp); | ||
42 | EXPORT_SYMBOL (strchr); | ||
43 | EXPORT_SYMBOL (strlen); | ||
44 | EXPORT_SYMBOL (strnlen); | ||
45 | EXPORT_SYMBOL (strrchr); | ||
46 | EXPORT_SYMBOL (strstr); | ||
47 | EXPORT_SYMBOL (memset); | 33 | EXPORT_SYMBOL (memset); |
48 | EXPORT_SYMBOL (memcpy); | 34 | EXPORT_SYMBOL (memcpy); |
49 | EXPORT_SYMBOL (memmove); | 35 | EXPORT_SYMBOL (memmove); |
50 | EXPORT_SYMBOL (memcmp); | ||
51 | EXPORT_SYMBOL (memscan); | ||
52 | 36 | ||
53 | /* semaphores */ | 37 | /* semaphores */ |
54 | EXPORT_SYMBOL (__down); | 38 | EXPORT_SYMBOL (__down); |
diff --git a/arch/x86_64/defconfig b/arch/x86_64/defconfig index 83d389b8ebd8..840d5d93d5cc 100644 --- a/arch/x86_64/defconfig +++ b/arch/x86_64/defconfig | |||
@@ -1,7 +1,7 @@ | |||
1 | # | 1 | # |
2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
3 | # Linux kernel version: 2.6.17-git22 | 3 | # Linux kernel version: 2.6.18-rc2 |
4 | # Tue Jul 4 14:24:40 2006 | 4 | # Tue Jul 18 17:13:20 2006 |
5 | # | 5 | # |
6 | CONFIG_X86_64=y | 6 | CONFIG_X86_64=y |
7 | CONFIG_64BIT=y | 7 | CONFIG_64BIT=y |
@@ -37,6 +37,7 @@ CONFIG_SWAP=y | |||
37 | CONFIG_SYSVIPC=y | 37 | CONFIG_SYSVIPC=y |
38 | CONFIG_POSIX_MQUEUE=y | 38 | CONFIG_POSIX_MQUEUE=y |
39 | # CONFIG_BSD_PROCESS_ACCT is not set | 39 | # CONFIG_BSD_PROCESS_ACCT is not set |
40 | # CONFIG_TASKSTATS is not set | ||
40 | CONFIG_SYSCTL=y | 41 | CONFIG_SYSCTL=y |
41 | # CONFIG_AUDIT is not set | 42 | # CONFIG_AUDIT is not set |
42 | CONFIG_IKCONFIG=y | 43 | CONFIG_IKCONFIG=y |
@@ -413,6 +414,7 @@ CONFIG_BLK_DEV_LOOP=y | |||
413 | CONFIG_BLK_DEV_RAM=y | 414 | CONFIG_BLK_DEV_RAM=y |
414 | CONFIG_BLK_DEV_RAM_COUNT=16 | 415 | CONFIG_BLK_DEV_RAM_COUNT=16 |
415 | CONFIG_BLK_DEV_RAM_SIZE=4096 | 416 | CONFIG_BLK_DEV_RAM_SIZE=4096 |
417 | CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | ||
416 | CONFIG_BLK_DEV_INITRD=y | 418 | CONFIG_BLK_DEV_INITRD=y |
417 | # CONFIG_CDROM_PKTCDVD is not set | 419 | # CONFIG_CDROM_PKTCDVD is not set |
418 | # CONFIG_ATA_OVER_ETH is not set | 420 | # CONFIG_ATA_OVER_ETH is not set |
@@ -1195,7 +1197,7 @@ CONFIG_USB_MON=y | |||
1195 | # CONFIG_USB_LEGOTOWER is not set | 1197 | # CONFIG_USB_LEGOTOWER is not set |
1196 | # CONFIG_USB_LCD is not set | 1198 | # CONFIG_USB_LCD is not set |
1197 | # CONFIG_USB_LED is not set | 1199 | # CONFIG_USB_LED is not set |
1198 | # CONFIG_USB_CY7C63 is not set | 1200 | # CONFIG_USB_CYPRESS_CY7C63 is not set |
1199 | # CONFIG_USB_CYTHERM is not set | 1201 | # CONFIG_USB_CYTHERM is not set |
1200 | # CONFIG_USB_PHIDGETKIT is not set | 1202 | # CONFIG_USB_PHIDGETKIT is not set |
1201 | # CONFIG_USB_PHIDGETSERVO is not set | 1203 | # CONFIG_USB_PHIDGETSERVO is not set |
@@ -1373,7 +1375,6 @@ CONFIG_SUNRPC=y | |||
1373 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1375 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
1374 | # CONFIG_SMB_FS is not set | 1376 | # CONFIG_SMB_FS is not set |
1375 | # CONFIG_CIFS is not set | 1377 | # CONFIG_CIFS is not set |
1376 | # CONFIG_CIFS_DEBUG2 is not set | ||
1377 | # CONFIG_NCP_FS is not set | 1378 | # CONFIG_NCP_FS is not set |
1378 | # CONFIG_CODA_FS is not set | 1379 | # CONFIG_CODA_FS is not set |
1379 | # CONFIG_AFS_FS is not set | 1380 | # CONFIG_AFS_FS is not set |
diff --git a/arch/x86_64/ia32/Makefile b/arch/x86_64/ia32/Makefile index 62bc5f56da9e..cdae36435e21 100644 --- a/arch/x86_64/ia32/Makefile +++ b/arch/x86_64/ia32/Makefile | |||
@@ -23,6 +23,7 @@ targets := $(foreach F,sysenter syscall,vsyscall-$F.o vsyscall-$F.so) | |||
23 | # The DSO images are built using a special linker script | 23 | # The DSO images are built using a special linker script |
24 | quiet_cmd_syscall = SYSCALL $@ | 24 | quiet_cmd_syscall = SYSCALL $@ |
25 | cmd_syscall = $(CC) -m32 -nostdlib -shared -s \ | 25 | cmd_syscall = $(CC) -m32 -nostdlib -shared -s \ |
26 | $(call ld-option, -Wl$(comma)--hash-style=sysv) \ | ||
26 | -Wl,-soname=linux-gate.so.1 -o $@ \ | 27 | -Wl,-soname=linux-gate.so.1 -o $@ \ |
27 | -Wl,-T,$(filter-out FORCE,$^) | 28 | -Wl,-T,$(filter-out FORCE,$^) |
28 | 29 | ||
diff --git a/arch/x86_64/ia32/ia32entry.S b/arch/x86_64/ia32/ia32entry.S index 9b5bb413a6e9..5d4a7d125ed0 100644 --- a/arch/x86_64/ia32/ia32entry.S +++ b/arch/x86_64/ia32/ia32entry.S | |||
@@ -103,7 +103,7 @@ ENTRY(ia32_sysenter_target) | |||
103 | pushq %rax | 103 | pushq %rax |
104 | CFI_ADJUST_CFA_OFFSET 8 | 104 | CFI_ADJUST_CFA_OFFSET 8 |
105 | cld | 105 | cld |
106 | SAVE_ARGS 0,0,1 | 106 | SAVE_ARGS 0,0,0 |
107 | /* no need to do an access_ok check here because rbp has been | 107 | /* no need to do an access_ok check here because rbp has been |
108 | 32bit zero extended */ | 108 | 32bit zero extended */ |
109 | 1: movl (%rbp),%r9d | 109 | 1: movl (%rbp),%r9d |
diff --git a/arch/x86_64/ia32/vsyscall.lds b/arch/x86_64/ia32/vsyscall.lds index f2e75ed4c6c7..1dc86ff5bcb9 100644 --- a/arch/x86_64/ia32/vsyscall.lds +++ b/arch/x86_64/ia32/vsyscall.lds | |||
@@ -11,6 +11,7 @@ SECTIONS | |||
11 | . = VSYSCALL_BASE + SIZEOF_HEADERS; | 11 | . = VSYSCALL_BASE + SIZEOF_HEADERS; |
12 | 12 | ||
13 | .hash : { *(.hash) } :text | 13 | .hash : { *(.hash) } :text |
14 | .gnu.hash : { *(.gnu.hash) } | ||
14 | .dynsym : { *(.dynsym) } | 15 | .dynsym : { *(.dynsym) } |
15 | .dynstr : { *(.dynstr) } | 16 | .dynstr : { *(.dynstr) } |
16 | .gnu.version : { *(.gnu.version) } | 17 | .gnu.version : { *(.gnu.version) } |
diff --git a/arch/x86_64/kernel/entry.S b/arch/x86_64/kernel/entry.S index d464dded68c0..6f810424df44 100644 --- a/arch/x86_64/kernel/entry.S +++ b/arch/x86_64/kernel/entry.S | |||
@@ -513,6 +513,7 @@ END(stub_rt_sigreturn) | |||
513 | swapgs | 513 | swapgs |
514 | 1: incl %gs:pda_irqcount # RED-PEN should check preempt count | 514 | 1: incl %gs:pda_irqcount # RED-PEN should check preempt count |
515 | cmoveq %gs:pda_irqstackptr,%rsp | 515 | cmoveq %gs:pda_irqstackptr,%rsp |
516 | push %rbp # backlink for old unwinder | ||
516 | /* | 517 | /* |
517 | * We entered an interrupt context - irqs are off: | 518 | * We entered an interrupt context - irqs are off: |
518 | */ | 519 | */ |
@@ -1139,18 +1140,21 @@ ENTRY(machine_check) | |||
1139 | END(machine_check) | 1140 | END(machine_check) |
1140 | #endif | 1141 | #endif |
1141 | 1142 | ||
1143 | /* Call softirq on interrupt stack. Interrupts are off. */ | ||
1142 | ENTRY(call_softirq) | 1144 | ENTRY(call_softirq) |
1143 | CFI_STARTPROC | 1145 | CFI_STARTPROC |
1144 | movq %gs:pda_irqstackptr,%rax | 1146 | push %rbp |
1145 | movq %rsp,%rdx | 1147 | CFI_ADJUST_CFA_OFFSET 8 |
1146 | CFI_DEF_CFA_REGISTER rdx | 1148 | CFI_REL_OFFSET rbp,0 |
1149 | mov %rsp,%rbp | ||
1150 | CFI_DEF_CFA_REGISTER rbp | ||
1147 | incl %gs:pda_irqcount | 1151 | incl %gs:pda_irqcount |
1148 | cmove %rax,%rsp | 1152 | cmove %gs:pda_irqstackptr,%rsp |
1149 | pushq %rdx | 1153 | push %rbp # backlink for old unwinder |
1150 | /*todo CFI_DEF_CFA_EXPRESSION ...*/ | ||
1151 | call __do_softirq | 1154 | call __do_softirq |
1152 | popq %rsp | 1155 | leaveq |
1153 | CFI_DEF_CFA_REGISTER rsp | 1156 | CFI_DEF_CFA_REGISTER rsp |
1157 | CFI_ADJUST_CFA_OFFSET -8 | ||
1154 | decl %gs:pda_irqcount | 1158 | decl %gs:pda_irqcount |
1155 | ret | 1159 | ret |
1156 | CFI_ENDPROC | 1160 | CFI_ENDPROC |
diff --git a/arch/x86_64/kernel/machine_kexec.c b/arch/x86_64/kernel/machine_kexec.c index 83fb24a02821..106076b370fc 100644 --- a/arch/x86_64/kernel/machine_kexec.c +++ b/arch/x86_64/kernel/machine_kexec.c | |||
@@ -207,14 +207,11 @@ NORET_TYPE void machine_kexec(struct kimage *image) | |||
207 | __flush_tlb(); | 207 | __flush_tlb(); |
208 | 208 | ||
209 | 209 | ||
210 | /* The segment registers are funny things, they are | 210 | /* The segment registers are funny things, they have both a |
211 | * automatically loaded from a table, in memory wherever you | 211 | * visible and an invisible part. Whenever the visible part is |
212 | * set them to a specific selector, but this table is never | 212 | * set to a specific selector, the invisible part is loaded |
213 | * accessed again unless you set the segment to a different selector. | 213 | * with from a table in memory. At no other time is the |
214 | * | 214 | * descriptor table in memory accessed. |
215 | * The more common model are caches where the behide | ||
216 | * the scenes work is done, but is also dropped at arbitrary | ||
217 | * times. | ||
218 | * | 215 | * |
219 | * I take advantage of this here by force loading the | 216 | * I take advantage of this here by force loading the |
220 | * segments, before I zap the gdt with an invalid value. | 217 | * segments, before I zap the gdt with an invalid value. |
diff --git a/arch/x86_64/kernel/mce.c b/arch/x86_64/kernel/mce.c index 88845674c661..4e017fb30fb3 100644 --- a/arch/x86_64/kernel/mce.c +++ b/arch/x86_64/kernel/mce.c | |||
@@ -615,7 +615,7 @@ static __cpuinit int mce_create_device(unsigned int cpu) | |||
615 | } | 615 | } |
616 | 616 | ||
617 | #ifdef CONFIG_HOTPLUG_CPU | 617 | #ifdef CONFIG_HOTPLUG_CPU |
618 | static __cpuinit void mce_remove_device(unsigned int cpu) | 618 | static void mce_remove_device(unsigned int cpu) |
619 | { | 619 | { |
620 | int i; | 620 | int i; |
621 | 621 | ||
@@ -626,10 +626,9 @@ static __cpuinit void mce_remove_device(unsigned int cpu) | |||
626 | sysdev_remove_file(&per_cpu(device_mce,cpu), &attr_check_interval); | 626 | sysdev_remove_file(&per_cpu(device_mce,cpu), &attr_check_interval); |
627 | sysdev_unregister(&per_cpu(device_mce,cpu)); | 627 | sysdev_unregister(&per_cpu(device_mce,cpu)); |
628 | } | 628 | } |
629 | #endif | ||
630 | 629 | ||
631 | /* Get notified when a cpu comes on/off. Be hotplug friendly. */ | 630 | /* Get notified when a cpu comes on/off. Be hotplug friendly. */ |
632 | static __cpuinit int | 631 | static int |
633 | mce_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) | 632 | mce_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) |
634 | { | 633 | { |
635 | unsigned int cpu = (unsigned long)hcpu; | 634 | unsigned int cpu = (unsigned long)hcpu; |
@@ -638,18 +637,17 @@ mce_cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) | |||
638 | case CPU_ONLINE: | 637 | case CPU_ONLINE: |
639 | mce_create_device(cpu); | 638 | mce_create_device(cpu); |
640 | break; | 639 | break; |
641 | #ifdef CONFIG_HOTPLUG_CPU | ||
642 | case CPU_DEAD: | 640 | case CPU_DEAD: |
643 | mce_remove_device(cpu); | 641 | mce_remove_device(cpu); |
644 | break; | 642 | break; |
645 | #endif | ||
646 | } | 643 | } |
647 | return NOTIFY_OK; | 644 | return NOTIFY_OK; |
648 | } | 645 | } |
649 | 646 | ||
650 | static struct notifier_block __cpuinitdata mce_cpu_notifier = { | 647 | static struct notifier_block mce_cpu_notifier = { |
651 | .notifier_call = mce_cpu_callback, | 648 | .notifier_call = mce_cpu_callback, |
652 | }; | 649 | }; |
650 | #endif | ||
653 | 651 | ||
654 | static __init int mce_init_device(void) | 652 | static __init int mce_init_device(void) |
655 | { | 653 | { |
@@ -664,7 +662,7 @@ static __init int mce_init_device(void) | |||
664 | mce_create_device(i); | 662 | mce_create_device(i); |
665 | } | 663 | } |
666 | 664 | ||
667 | register_cpu_notifier(&mce_cpu_notifier); | 665 | register_hotcpu_notifier(&mce_cpu_notifier); |
668 | misc_register(&mce_log_device); | 666 | misc_register(&mce_log_device); |
669 | return err; | 667 | return err; |
670 | } | 668 | } |
diff --git a/arch/x86_64/kernel/mce_amd.c b/arch/x86_64/kernel/mce_amd.c index db2acbf7ad28..883fe747f64c 100644 --- a/arch/x86_64/kernel/mce_amd.c +++ b/arch/x86_64/kernel/mce_amd.c | |||
@@ -558,7 +558,7 @@ out: | |||
558 | * of shared sysfs dir/files, and rest of the cores will be symlinked to it. | 558 | * of shared sysfs dir/files, and rest of the cores will be symlinked to it. |
559 | */ | 559 | */ |
560 | 560 | ||
561 | static __cpuinit void deallocate_threshold_block(unsigned int cpu, | 561 | static void deallocate_threshold_block(unsigned int cpu, |
562 | unsigned int bank) | 562 | unsigned int bank) |
563 | { | 563 | { |
564 | struct threshold_block *pos = NULL; | 564 | struct threshold_block *pos = NULL; |
@@ -578,7 +578,7 @@ static __cpuinit void deallocate_threshold_block(unsigned int cpu, | |||
578 | per_cpu(threshold_banks, cpu)[bank]->blocks = NULL; | 578 | per_cpu(threshold_banks, cpu)[bank]->blocks = NULL; |
579 | } | 579 | } |
580 | 580 | ||
581 | static __cpuinit void threshold_remove_bank(unsigned int cpu, int bank) | 581 | static void threshold_remove_bank(unsigned int cpu, int bank) |
582 | { | 582 | { |
583 | int i = 0; | 583 | int i = 0; |
584 | struct threshold_bank *b; | 584 | struct threshold_bank *b; |
@@ -618,7 +618,7 @@ free_out: | |||
618 | per_cpu(threshold_banks, cpu)[bank] = NULL; | 618 | per_cpu(threshold_banks, cpu)[bank] = NULL; |
619 | } | 619 | } |
620 | 620 | ||
621 | static __cpuinit void threshold_remove_device(unsigned int cpu) | 621 | static void threshold_remove_device(unsigned int cpu) |
622 | { | 622 | { |
623 | unsigned int bank; | 623 | unsigned int bank; |
624 | 624 | ||
@@ -629,14 +629,8 @@ static __cpuinit void threshold_remove_device(unsigned int cpu) | |||
629 | } | 629 | } |
630 | } | 630 | } |
631 | 631 | ||
632 | #else /* !CONFIG_HOTPLUG_CPU */ | ||
633 | static void threshold_remove_device(unsigned int cpu) | ||
634 | { | ||
635 | } | ||
636 | #endif | ||
637 | |||
638 | /* get notified when a cpu comes on/off */ | 632 | /* get notified when a cpu comes on/off */ |
639 | static int __cpuinit threshold_cpu_callback(struct notifier_block *nfb, | 633 | static int threshold_cpu_callback(struct notifier_block *nfb, |
640 | unsigned long action, void *hcpu) | 634 | unsigned long action, void *hcpu) |
641 | { | 635 | { |
642 | /* cpu was unsigned int to begin with */ | 636 | /* cpu was unsigned int to begin with */ |
@@ -659,9 +653,10 @@ static int __cpuinit threshold_cpu_callback(struct notifier_block *nfb, | |||
659 | return NOTIFY_OK; | 653 | return NOTIFY_OK; |
660 | } | 654 | } |
661 | 655 | ||
662 | static struct notifier_block threshold_cpu_notifier __cpuinitdata = { | 656 | static struct notifier_block threshold_cpu_notifier = { |
663 | .notifier_call = threshold_cpu_callback, | 657 | .notifier_call = threshold_cpu_callback, |
664 | }; | 658 | }; |
659 | #endif /* CONFIG_HOTPLUG_CPU */ | ||
665 | 660 | ||
666 | static __init int threshold_init_device(void) | 661 | static __init int threshold_init_device(void) |
667 | { | 662 | { |
@@ -673,7 +668,7 @@ static __init int threshold_init_device(void) | |||
673 | if (err) | 668 | if (err) |
674 | return err; | 669 | return err; |
675 | } | 670 | } |
676 | register_cpu_notifier(&threshold_cpu_notifier); | 671 | register_hotcpu_notifier(&threshold_cpu_notifier); |
677 | return 0; | 672 | return 0; |
678 | } | 673 | } |
679 | 674 | ||
diff --git a/arch/x86_64/kernel/pci-calgary.c b/arch/x86_64/kernel/pci-calgary.c index e71ed53b08fb..146924ba5df5 100644 --- a/arch/x86_64/kernel/pci-calgary.c +++ b/arch/x86_64/kernel/pci-calgary.c | |||
@@ -85,7 +85,8 @@ | |||
85 | #define CSR_AGENT_MASK 0xffe0ffff | 85 | #define CSR_AGENT_MASK 0xffe0ffff |
86 | 86 | ||
87 | #define MAX_NUM_OF_PHBS 8 /* how many PHBs in total? */ | 87 | #define MAX_NUM_OF_PHBS 8 /* how many PHBs in total? */ |
88 | #define MAX_PHB_BUS_NUM (MAX_NUM_OF_PHBS * 2) /* max dev->bus->number */ | 88 | #define MAX_NUM_CHASSIS 8 /* max number of chassis */ |
89 | #define MAX_PHB_BUS_NUM (MAX_NUM_OF_PHBS * MAX_NUM_CHASSIS * 2) /* max dev->bus->number */ | ||
89 | #define PHBS_PER_CALGARY 4 | 90 | #define PHBS_PER_CALGARY 4 |
90 | 91 | ||
91 | /* register offsets in Calgary's internal register space */ | 92 | /* register offsets in Calgary's internal register space */ |
@@ -110,7 +111,8 @@ static const unsigned long phb_offsets[] = { | |||
110 | 0xB000 /* PHB3 */ | 111 | 0xB000 /* PHB3 */ |
111 | }; | 112 | }; |
112 | 113 | ||
113 | void* tce_table_kva[MAX_NUM_OF_PHBS * MAX_NUMNODES]; | 114 | static char bus_to_phb[MAX_PHB_BUS_NUM]; |
115 | void* tce_table_kva[MAX_PHB_BUS_NUM]; | ||
114 | unsigned int specified_table_size = TCE_TABLE_SIZE_UNSPECIFIED; | 116 | unsigned int specified_table_size = TCE_TABLE_SIZE_UNSPECIFIED; |
115 | static int translate_empty_slots __read_mostly = 0; | 117 | static int translate_empty_slots __read_mostly = 0; |
116 | static int calgary_detected __read_mostly = 0; | 118 | static int calgary_detected __read_mostly = 0; |
@@ -119,7 +121,7 @@ static int calgary_detected __read_mostly = 0; | |||
119 | * the bitmap of PHBs the user requested that we disable | 121 | * the bitmap of PHBs the user requested that we disable |
120 | * translation on. | 122 | * translation on. |
121 | */ | 123 | */ |
122 | static DECLARE_BITMAP(translation_disabled, MAX_NUMNODES * MAX_PHB_BUS_NUM); | 124 | static DECLARE_BITMAP(translation_disabled, MAX_PHB_BUS_NUM); |
123 | 125 | ||
124 | static void tce_cache_blast(struct iommu_table *tbl); | 126 | static void tce_cache_blast(struct iommu_table *tbl); |
125 | 127 | ||
@@ -452,7 +454,7 @@ static struct dma_mapping_ops calgary_dma_ops = { | |||
452 | 454 | ||
453 | static inline int busno_to_phbid(unsigned char num) | 455 | static inline int busno_to_phbid(unsigned char num) |
454 | { | 456 | { |
455 | return bus_to_phb(num) % PHBS_PER_CALGARY; | 457 | return bus_to_phb[num]; |
456 | } | 458 | } |
457 | 459 | ||
458 | static inline unsigned long split_queue_offset(unsigned char num) | 460 | static inline unsigned long split_queue_offset(unsigned char num) |
@@ -812,7 +814,7 @@ static int __init calgary_init(void) | |||
812 | int i, ret = -ENODEV; | 814 | int i, ret = -ENODEV; |
813 | struct pci_dev *dev = NULL; | 815 | struct pci_dev *dev = NULL; |
814 | 816 | ||
815 | for (i = 0; i <= num_online_nodes() * MAX_NUM_OF_PHBS; i++) { | 817 | for (i = 0; i < MAX_PHB_BUS_NUM; i++) { |
816 | dev = pci_get_device(PCI_VENDOR_ID_IBM, | 818 | dev = pci_get_device(PCI_VENDOR_ID_IBM, |
817 | PCI_DEVICE_ID_IBM_CALGARY, | 819 | PCI_DEVICE_ID_IBM_CALGARY, |
818 | dev); | 820 | dev); |
@@ -822,7 +824,7 @@ static int __init calgary_init(void) | |||
822 | calgary_init_one_nontraslated(dev); | 824 | calgary_init_one_nontraslated(dev); |
823 | continue; | 825 | continue; |
824 | } | 826 | } |
825 | if (!tce_table_kva[i] && !translate_empty_slots) { | 827 | if (!tce_table_kva[dev->bus->number] && !translate_empty_slots) { |
826 | pci_dev_put(dev); | 828 | pci_dev_put(dev); |
827 | continue; | 829 | continue; |
828 | } | 830 | } |
@@ -842,7 +844,7 @@ error: | |||
842 | pci_dev_put(dev); | 844 | pci_dev_put(dev); |
843 | continue; | 845 | continue; |
844 | } | 846 | } |
845 | if (!tce_table_kva[i] && !translate_empty_slots) | 847 | if (!tce_table_kva[dev->bus->number] && !translate_empty_slots) |
846 | continue; | 848 | continue; |
847 | calgary_disable_translation(dev); | 849 | calgary_disable_translation(dev); |
848 | calgary_free_tar(dev); | 850 | calgary_free_tar(dev); |
@@ -876,9 +878,10 @@ static inline int __init determine_tce_table_size(u64 ram) | |||
876 | void __init detect_calgary(void) | 878 | void __init detect_calgary(void) |
877 | { | 879 | { |
878 | u32 val; | 880 | u32 val; |
879 | int bus, table_idx; | 881 | int bus; |
880 | void *tbl; | 882 | void *tbl; |
881 | int detected = 0; | 883 | int calgary_found = 0; |
884 | int phb = -1; | ||
882 | 885 | ||
883 | /* | 886 | /* |
884 | * if the user specified iommu=off or iommu=soft or we found | 887 | * if the user specified iommu=off or iommu=soft or we found |
@@ -889,38 +892,46 @@ void __init detect_calgary(void) | |||
889 | 892 | ||
890 | specified_table_size = determine_tce_table_size(end_pfn * PAGE_SIZE); | 893 | specified_table_size = determine_tce_table_size(end_pfn * PAGE_SIZE); |
891 | 894 | ||
892 | for (bus = 0, table_idx = 0; | 895 | for (bus = 0; bus < MAX_PHB_BUS_NUM; bus++) { |
893 | bus <= num_online_nodes() * MAX_PHB_BUS_NUM; | 896 | int dev; |
894 | bus++) { | 897 | |
895 | BUG_ON(bus > MAX_NUMNODES * MAX_PHB_BUS_NUM); | 898 | tce_table_kva[bus] = NULL; |
899 | bus_to_phb[bus] = -1; | ||
900 | |||
896 | if (read_pci_config(bus, 0, 0, 0) != PCI_VENDOR_DEVICE_ID_CALGARY) | 901 | if (read_pci_config(bus, 0, 0, 0) != PCI_VENDOR_DEVICE_ID_CALGARY) |
897 | continue; | 902 | continue; |
903 | |||
904 | /* | ||
905 | * There are 4 PHBs per Calgary chip. Set phb to which phb (0-3) | ||
906 | * it is connected to releative to the clagary chip. | ||
907 | */ | ||
908 | phb = (phb + 1) % PHBS_PER_CALGARY; | ||
909 | |||
898 | if (test_bit(bus, translation_disabled)) { | 910 | if (test_bit(bus, translation_disabled)) { |
899 | printk(KERN_INFO "Calgary: translation is disabled for " | 911 | printk(KERN_INFO "Calgary: translation is disabled for " |
900 | "PHB 0x%x\n", bus); | 912 | "PHB 0x%x\n", bus); |
901 | /* skip this phb, don't allocate a tbl for it */ | 913 | /* skip this phb, don't allocate a tbl for it */ |
902 | tce_table_kva[table_idx] = NULL; | ||
903 | table_idx++; | ||
904 | continue; | 914 | continue; |
905 | } | 915 | } |
906 | /* | 916 | /* |
907 | * scan the first slot of the PCI bus to see if there | 917 | * Scan the slots of the PCI bus to see if there is a device present. |
908 | * are any devices present | 918 | * The parent bus will be the zero-ith device, so start at 1. |
909 | */ | 919 | */ |
910 | val = read_pci_config(bus, 1, 0, 0); | 920 | for (dev = 1; dev < 8; dev++) { |
911 | if (val != 0xffffffff || translate_empty_slots) { | 921 | val = read_pci_config(bus, dev, 0, 0); |
912 | tbl = alloc_tce_table(); | 922 | if (val != 0xffffffff || translate_empty_slots) { |
913 | if (!tbl) | 923 | tbl = alloc_tce_table(); |
914 | goto cleanup; | 924 | if (!tbl) |
915 | detected = 1; | 925 | goto cleanup; |
916 | } else | 926 | tce_table_kva[bus] = tbl; |
917 | tbl = NULL; | 927 | bus_to_phb[bus] = phb; |
918 | 928 | calgary_found = 1; | |
919 | tce_table_kva[table_idx] = tbl; | 929 | break; |
920 | table_idx++; | 930 | } |
931 | } | ||
921 | } | 932 | } |
922 | 933 | ||
923 | if (detected) { | 934 | if (calgary_found) { |
924 | iommu_detected = 1; | 935 | iommu_detected = 1; |
925 | calgary_detected = 1; | 936 | calgary_detected = 1; |
926 | printk(KERN_INFO "PCI-DMA: Calgary IOMMU detected. " | 937 | printk(KERN_INFO "PCI-DMA: Calgary IOMMU detected. " |
@@ -929,9 +940,9 @@ void __init detect_calgary(void) | |||
929 | return; | 940 | return; |
930 | 941 | ||
931 | cleanup: | 942 | cleanup: |
932 | for (--table_idx; table_idx >= 0; --table_idx) | 943 | for (--bus; bus >= 0; --bus) |
933 | if (tce_table_kva[table_idx]) | 944 | if (tce_table_kva[bus]) |
934 | free_tce_table(tce_table_kva[table_idx]); | 945 | free_tce_table(tce_table_kva[bus]); |
935 | } | 946 | } |
936 | 947 | ||
937 | int __init calgary_iommu_init(void) | 948 | int __init calgary_iommu_init(void) |
@@ -1002,7 +1013,7 @@ static int __init calgary_parse_options(char *p) | |||
1002 | if (p == endp) | 1013 | if (p == endp) |
1003 | break; | 1014 | break; |
1004 | 1015 | ||
1005 | if (bridge <= (num_online_nodes() * MAX_PHB_BUS_NUM)) { | 1016 | if (bridge < MAX_PHB_BUS_NUM) { |
1006 | printk(KERN_INFO "Calgary: disabling " | 1017 | printk(KERN_INFO "Calgary: disabling " |
1007 | "translation for PHB 0x%x\n", bridge); | 1018 | "translation for PHB 0x%x\n", bridge); |
1008 | set_bit(bridge, translation_disabled); | 1019 | set_bit(bridge, translation_disabled); |
diff --git a/arch/x86_64/kernel/pci-nommu.c b/arch/x86_64/kernel/pci-nommu.c index c4c3cc36ac5b..aad7609d8e92 100644 --- a/arch/x86_64/kernel/pci-nommu.c +++ b/arch/x86_64/kernel/pci-nommu.c | |||
@@ -92,5 +92,7 @@ void __init no_iommu_init(void) | |||
92 | { | 92 | { |
93 | if (dma_ops) | 93 | if (dma_ops) |
94 | return; | 94 | return; |
95 | |||
96 | force_iommu = 0; /* no HW IOMMU */ | ||
95 | dma_ops = &nommu_dma_ops; | 97 | dma_ops = &nommu_dma_ops; |
96 | } | 98 | } |
diff --git a/arch/x86_64/kernel/pci-swiotlb.c b/arch/x86_64/kernel/pci-swiotlb.c index ebdb77fe2057..6a55f87ba97f 100644 --- a/arch/x86_64/kernel/pci-swiotlb.c +++ b/arch/x86_64/kernel/pci-swiotlb.c | |||
@@ -31,9 +31,10 @@ struct dma_mapping_ops swiotlb_dma_ops = { | |||
31 | void pci_swiotlb_init(void) | 31 | void pci_swiotlb_init(void) |
32 | { | 32 | { |
33 | /* don't initialize swiotlb if iommu=off (no_iommu=1) */ | 33 | /* don't initialize swiotlb if iommu=off (no_iommu=1) */ |
34 | if (!iommu_detected && !no_iommu && | 34 | if (!iommu_detected && !no_iommu && end_pfn > MAX_DMA32_PFN) |
35 | (end_pfn > MAX_DMA32_PFN || force_iommu)) | ||
36 | swiotlb = 1; | 35 | swiotlb = 1; |
36 | if (swiotlb_force) | ||
37 | swiotlb = 1; | ||
37 | if (swiotlb) { | 38 | if (swiotlb) { |
38 | printk(KERN_INFO "PCI-DMA: Using software bounce buffering for IO (SWIOTLB)\n"); | 39 | printk(KERN_INFO "PCI-DMA: Using software bounce buffering for IO (SWIOTLB)\n"); |
39 | swiotlb_init(); | 40 | swiotlb_init(); |
diff --git a/arch/x86_64/kernel/smp.c b/arch/x86_64/kernel/smp.c index 5a1c0a3bf872..06af6ca60129 100644 --- a/arch/x86_64/kernel/smp.c +++ b/arch/x86_64/kernel/smp.c | |||
@@ -203,7 +203,7 @@ int __cpuinit init_smp_flush(void) | |||
203 | { | 203 | { |
204 | int i; | 204 | int i; |
205 | for_each_cpu_mask(i, cpu_possible_map) { | 205 | for_each_cpu_mask(i, cpu_possible_map) { |
206 | spin_lock_init(&per_cpu(flush_state.tlbstate_lock, i)); | 206 | spin_lock_init(&per_cpu(flush_state, i).tlbstate_lock); |
207 | } | 207 | } |
208 | return 0; | 208 | return 0; |
209 | } | 209 | } |
diff --git a/arch/x86_64/kernel/tce.c b/arch/x86_64/kernel/tce.c index d3a9e79e954c..5530dda3f27a 100644 --- a/arch/x86_64/kernel/tce.c +++ b/arch/x86_64/kernel/tce.c | |||
@@ -96,7 +96,6 @@ static inline unsigned int table_size_to_number_of_entries(unsigned char size) | |||
96 | static int tce_table_setparms(struct pci_dev *dev, struct iommu_table *tbl) | 96 | static int tce_table_setparms(struct pci_dev *dev, struct iommu_table *tbl) |
97 | { | 97 | { |
98 | unsigned int bitmapsz; | 98 | unsigned int bitmapsz; |
99 | unsigned int tce_table_index; | ||
100 | unsigned long bmppages; | 99 | unsigned long bmppages; |
101 | int ret; | 100 | int ret; |
102 | 101 | ||
@@ -105,8 +104,7 @@ static int tce_table_setparms(struct pci_dev *dev, struct iommu_table *tbl) | |||
105 | /* set the tce table size - measured in entries */ | 104 | /* set the tce table size - measured in entries */ |
106 | tbl->it_size = table_size_to_number_of_entries(specified_table_size); | 105 | tbl->it_size = table_size_to_number_of_entries(specified_table_size); |
107 | 106 | ||
108 | tce_table_index = bus_to_phb(tbl->it_busno); | 107 | tbl->it_base = (unsigned long)tce_table_kva[dev->bus->number]; |
109 | tbl->it_base = (unsigned long)tce_table_kva[tce_table_index]; | ||
110 | if (!tbl->it_base) { | 108 | if (!tbl->it_base) { |
111 | printk(KERN_ERR "Calgary: iommu_table_setparms: " | 109 | printk(KERN_ERR "Calgary: iommu_table_setparms: " |
112 | "no table allocated?!\n"); | 110 | "no table allocated?!\n"); |
diff --git a/arch/x86_64/kernel/time.c b/arch/x86_64/kernel/time.c index b9ff75992c16..7a9b18224182 100644 --- a/arch/x86_64/kernel/time.c +++ b/arch/x86_64/kernel/time.c | |||
@@ -28,6 +28,7 @@ | |||
28 | #include <linux/acpi.h> | 28 | #include <linux/acpi.h> |
29 | #ifdef CONFIG_ACPI | 29 | #ifdef CONFIG_ACPI |
30 | #include <acpi/achware.h> /* for PM timer frequency */ | 30 | #include <acpi/achware.h> /* for PM timer frequency */ |
31 | #include <acpi/acpi_bus.h> | ||
31 | #endif | 32 | #endif |
32 | #include <asm/8253pit.h> | 33 | #include <asm/8253pit.h> |
33 | #include <asm/pgtable.h> | 34 | #include <asm/pgtable.h> |
@@ -193,7 +194,7 @@ unsigned long profile_pc(struct pt_regs *regs) | |||
193 | is just accounted to the spinlock function. | 194 | is just accounted to the spinlock function. |
194 | Better would be to write these functions in assembler again | 195 | Better would be to write these functions in assembler again |
195 | and check exactly. */ | 196 | and check exactly. */ |
196 | if (in_lock_functions(pc)) { | 197 | if (!user_mode(regs) && in_lock_functions(pc)) { |
197 | char *v = *(char **)regs->rsp; | 198 | char *v = *(char **)regs->rsp; |
198 | if ((v >= _stext && v <= _etext) || | 199 | if ((v >= _stext && v <= _etext) || |
199 | (v >= _sinittext && v <= _einittext) || | 200 | (v >= _sinittext && v <= _einittext) || |
@@ -953,11 +954,18 @@ __cpuinit int unsynchronized_tsc(void) | |||
953 | #ifdef CONFIG_SMP | 954 | #ifdef CONFIG_SMP |
954 | if (apic_is_clustered_box()) | 955 | if (apic_is_clustered_box()) |
955 | return 1; | 956 | return 1; |
956 | /* Intel systems are normally all synchronized. Exceptions | ||
957 | are handled in the check above. */ | ||
958 | if (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL) | ||
959 | return 0; | ||
960 | #endif | 957 | #endif |
958 | /* Most intel systems have synchronized TSCs except for | ||
959 | multi node systems */ | ||
960 | if (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL) { | ||
961 | #ifdef CONFIG_ACPI | ||
962 | /* But TSC doesn't tick in C3 so don't use it there */ | ||
963 | if (acpi_fadt.length > 0 && acpi_fadt.plvl3_lat < 100) | ||
964 | return 1; | ||
965 | #endif | ||
966 | return 0; | ||
967 | } | ||
968 | |||
961 | /* Assume multi socket systems are not synchronized */ | 969 | /* Assume multi socket systems are not synchronized */ |
962 | return num_present_cpus() > 1; | 970 | return num_present_cpus() > 1; |
963 | } | 971 | } |
diff --git a/arch/x86_64/kernel/traps.c b/arch/x86_64/kernel/traps.c index eb39a2775236..4e9938dee060 100644 --- a/arch/x86_64/kernel/traps.c +++ b/arch/x86_64/kernel/traps.c | |||
@@ -254,7 +254,6 @@ void show_trace(struct task_struct *tsk, struct pt_regs *regs, unsigned long * s | |||
254 | { | 254 | { |
255 | const unsigned cpu = safe_smp_processor_id(); | 255 | const unsigned cpu = safe_smp_processor_id(); |
256 | unsigned long *irqstack_end = (unsigned long *)cpu_pda(cpu)->irqstackptr; | 256 | unsigned long *irqstack_end = (unsigned long *)cpu_pda(cpu)->irqstackptr; |
257 | int i = 11; | ||
258 | unsigned used = 0; | 257 | unsigned used = 0; |
259 | 258 | ||
260 | printk("\nCall Trace:\n"); | 259 | printk("\nCall Trace:\n"); |
@@ -275,11 +274,20 @@ void show_trace(struct task_struct *tsk, struct pt_regs *regs, unsigned long * s | |||
275 | if (unwind_init_blocked(&info, tsk) == 0) | 274 | if (unwind_init_blocked(&info, tsk) == 0) |
276 | unw_ret = show_trace_unwind(&info, NULL); | 275 | unw_ret = show_trace_unwind(&info, NULL); |
277 | } | 276 | } |
278 | if (unw_ret > 0) { | 277 | if (unw_ret > 0 && !arch_unw_user_mode(&info)) { |
279 | if (call_trace > 0) | 278 | #ifdef CONFIG_STACK_UNWIND |
279 | unsigned long rip = info.regs.rip; | ||
280 | print_symbol("DWARF2 unwinder stuck at %s\n", rip); | ||
281 | if (call_trace == 1) { | ||
282 | printk("Leftover inexact backtrace:\n"); | ||
283 | stack = (unsigned long *)info.regs.rsp; | ||
284 | } else if (call_trace > 1) | ||
280 | return; | 285 | return; |
281 | printk("Legacy call trace:"); | 286 | else |
282 | i = 18; | 287 | printk("Full inexact backtrace again:\n"); |
288 | #else | ||
289 | printk("Inexact backtrace:\n"); | ||
290 | #endif | ||
283 | } | 291 | } |
284 | } | 292 | } |
285 | 293 | ||
@@ -521,7 +529,7 @@ void __kprobes oops_end(unsigned long flags) | |||
521 | /* Nest count reaches zero, release the lock. */ | 529 | /* Nest count reaches zero, release the lock. */ |
522 | spin_unlock_irqrestore(&die_lock, flags); | 530 | spin_unlock_irqrestore(&die_lock, flags); |
523 | if (panic_on_oops) | 531 | if (panic_on_oops) |
524 | panic("Oops"); | 532 | panic("Fatal exception: panic_on_oops"); |
525 | } | 533 | } |
526 | 534 | ||
527 | void __kprobes __die(const char * str, struct pt_regs * regs, long err) | 535 | void __kprobes __die(const char * str, struct pt_regs * regs, long err) |
@@ -1118,8 +1126,10 @@ static int __init call_trace_setup(char *s) | |||
1118 | call_trace = -1; | 1126 | call_trace = -1; |
1119 | else if (strcmp(s, "both") == 0) | 1127 | else if (strcmp(s, "both") == 0) |
1120 | call_trace = 0; | 1128 | call_trace = 0; |
1121 | else if (strcmp(s, "new") == 0) | 1129 | else if (strcmp(s, "newfallback") == 0) |
1122 | call_trace = 1; | 1130 | call_trace = 1; |
1131 | else if (strcmp(s, "new") == 0) | ||
1132 | call_trace = 2; | ||
1123 | return 1; | 1133 | return 1; |
1124 | } | 1134 | } |
1125 | __setup("call_trace=", call_trace_setup); | 1135 | __setup("call_trace=", call_trace_setup); |
diff --git a/arch/x86_64/pci/k8-bus.c b/arch/x86_64/pci/k8-bus.c index b50a7c7c47f8..3acf60ded2a0 100644 --- a/arch/x86_64/pci/k8-bus.c +++ b/arch/x86_64/pci/k8-bus.c | |||
@@ -2,7 +2,6 @@ | |||
2 | #include <linux/pci.h> | 2 | #include <linux/pci.h> |
3 | #include <asm/mpspec.h> | 3 | #include <asm/mpspec.h> |
4 | #include <linux/cpumask.h> | 4 | #include <linux/cpumask.h> |
5 | #include <asm/k8.h> | ||
6 | 5 | ||
7 | /* | 6 | /* |
8 | * This discovers the pcibus <-> node mapping on AMD K8. | 7 | * This discovers the pcibus <-> node mapping on AMD K8. |
@@ -19,6 +18,7 @@ | |||
19 | #define NR_LDT_BUS_NUMBER_REGISTERS 3 | 18 | #define NR_LDT_BUS_NUMBER_REGISTERS 3 |
20 | #define SECONDARY_LDT_BUS_NUMBER(dword) ((dword >> 8) & 0xFF) | 19 | #define SECONDARY_LDT_BUS_NUMBER(dword) ((dword >> 8) & 0xFF) |
21 | #define SUBORDINATE_LDT_BUS_NUMBER(dword) ((dword >> 16) & 0xFF) | 20 | #define SUBORDINATE_LDT_BUS_NUMBER(dword) ((dword >> 16) & 0xFF) |
21 | #define PCI_DEVICE_ID_K8HTCONFIG 0x1100 | ||
22 | 22 | ||
23 | /** | 23 | /** |
24 | * fill_mp_bus_to_cpumask() | 24 | * fill_mp_bus_to_cpumask() |
@@ -28,7 +28,8 @@ | |||
28 | __init static int | 28 | __init static int |
29 | fill_mp_bus_to_cpumask(void) | 29 | fill_mp_bus_to_cpumask(void) |
30 | { | 30 | { |
31 | int i, j, k; | 31 | struct pci_dev *nb_dev = NULL; |
32 | int i, j; | ||
32 | u32 ldtbus, nid; | 33 | u32 ldtbus, nid; |
33 | static int lbnr[3] = { | 34 | static int lbnr[3] = { |
34 | LDT_BUS_NUMBER_REGISTER_0, | 35 | LDT_BUS_NUMBER_REGISTER_0, |
@@ -36,9 +37,8 @@ fill_mp_bus_to_cpumask(void) | |||
36 | LDT_BUS_NUMBER_REGISTER_2 | 37 | LDT_BUS_NUMBER_REGISTER_2 |
37 | }; | 38 | }; |
38 | 39 | ||
39 | cache_k8_northbridges(); | 40 | while ((nb_dev = pci_get_device(PCI_VENDOR_ID_AMD, |
40 | for (k = 0; k < num_k8_northbridges; k++) { | 41 | PCI_DEVICE_ID_K8HTCONFIG, nb_dev))) { |
41 | struct pci_dev *nb_dev = k8_northbridges[k]; | ||
42 | pci_read_config_dword(nb_dev, NODE_ID_REGISTER, &nid); | 42 | pci_read_config_dword(nb_dev, NODE_ID_REGISTER, &nid); |
43 | 43 | ||
44 | for (i = 0; i < NR_LDT_BUS_NUMBER_REGISTERS; i++) { | 44 | for (i = 0; i < NR_LDT_BUS_NUMBER_REGISTERS; i++) { |
diff --git a/arch/xtensa/kernel/traps.c b/arch/xtensa/kernel/traps.c index 27e409089a7b..9734960a2451 100644 --- a/arch/xtensa/kernel/traps.c +++ b/arch/xtensa/kernel/traps.c | |||
@@ -487,11 +487,9 @@ void die(const char * str, struct pt_regs * regs, long err) | |||
487 | if (in_interrupt()) | 487 | if (in_interrupt()) |
488 | panic("Fatal exception in interrupt"); | 488 | panic("Fatal exception in interrupt"); |
489 | 489 | ||
490 | if (panic_on_oops) { | 490 | if (panic_on_oops) |
491 | printk(KERN_EMERG "Fatal exception: panic in 5 seconds\n"); | 491 | panic("Fatal exception: panic_on_oops"); |
492 | ssleep(5); | 492 | |
493 | panic("Fatal exception"); | ||
494 | } | ||
495 | do_exit(err); | 493 | do_exit(err); |
496 | } | 494 | } |
497 | 495 | ||