aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64/kernel/setup.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ia64/kernel/setup.c')
-rw-r--r--arch/ia64/kernel/setup.c26
1 files changed, 16 insertions, 10 deletions
diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
index 7d6fe65c93f4..dc7dd7648ec5 100644
--- a/arch/ia64/kernel/setup.c
+++ b/arch/ia64/kernel/setup.c
@@ -91,8 +91,6 @@ static struct resource code_resource = {
91 .name = "Kernel code", 91 .name = "Kernel code",
92 .flags = IORESOURCE_BUSY | IORESOURCE_MEM 92 .flags = IORESOURCE_BUSY | IORESOURCE_MEM
93}; 93};
94extern void efi_initialize_iomem_resources(struct resource *,
95 struct resource *);
96extern char _text[], _end[], _etext[]; 94extern char _text[], _end[], _etext[];
97 95
98unsigned long ia64_max_cacheline_size; 96unsigned long ia64_max_cacheline_size;
@@ -642,7 +640,7 @@ show_cpuinfo (struct seq_file *m, void *v)
642 "features : %s\n" 640 "features : %s\n"
643 "cpu number : %lu\n" 641 "cpu number : %lu\n"
644 "cpu regs : %u\n" 642 "cpu regs : %u\n"
645 "cpu MHz : %lu.%06lu\n" 643 "cpu MHz : %lu.%03lu\n"
646 "itc MHz : %lu.%06lu\n" 644 "itc MHz : %lu.%06lu\n"
647 "BogoMIPS : %lu.%02lu\n", 645 "BogoMIPS : %lu.%02lu\n",
648 cpunum, c->vendor, c->family, c->model, 646 cpunum, c->vendor, c->family, c->model,
@@ -694,12 +692,15 @@ struct seq_operations cpuinfo_op = {
694 .show = show_cpuinfo 692 .show = show_cpuinfo
695}; 693};
696 694
697static char brandname[128]; 695#define MAX_BRANDS 8
696static char brandname[MAX_BRANDS][128];
698 697
699static char * __cpuinit 698static char * __cpuinit
700get_model_name(__u8 family, __u8 model) 699get_model_name(__u8 family, __u8 model)
701{ 700{
701 static int overflow;
702 char brand[128]; 702 char brand[128];
703 int i;
703 704
704 memcpy(brand, "Unknown", 8); 705 memcpy(brand, "Unknown", 8);
705 if (ia64_pal_get_brand_info(brand)) { 706 if (ia64_pal_get_brand_info(brand)) {
@@ -711,12 +712,17 @@ get_model_name(__u8 family, __u8 model)
711 case 2: memcpy(brand, "Madison up to 9M cache", 23); break; 712 case 2: memcpy(brand, "Madison up to 9M cache", 23); break;
712 } 713 }
713 } 714 }
714 if (brandname[0] == '\0') 715 for (i = 0; i < MAX_BRANDS; i++)
715 return strcpy(brandname, brand); 716 if (strcmp(brandname[i], brand) == 0)
716 else if (strcmp(brandname, brand) == 0) 717 return brandname[i];
717 return brandname; 718 for (i = 0; i < MAX_BRANDS; i++)
718 else 719 if (brandname[i][0] == '\0')
719 return kstrdup(brand, GFP_KERNEL); 720 return strcpy(brandname[i], brand);
721 if (overflow++ == 0)
722 printk(KERN_ERR
723 "%s: Table overflow. Some processor model information will be missing\n",
724 __FUNCTION__);
725 return "Unknown";
720} 726}
721 727
722static void __cpuinit 728static void __cpuinit