Recognize Ampere EMAG8180
This commit is contained in:
parent
276c1791ea
commit
e8d82c01d4
|
@ -41,6 +41,8 @@
|
||||||
#define CPU_THUNDERX2T99 8
|
#define CPU_THUNDERX2T99 8
|
||||||
//Hisilicon
|
//Hisilicon
|
||||||
#define CPU_TSV110 9
|
#define CPU_TSV110 9
|
||||||
|
// Ampere
|
||||||
|
#define CPU_EMAG8180 10
|
||||||
|
|
||||||
static char *cpuname[] = {
|
static char *cpuname[] = {
|
||||||
"UNKNOWN",
|
"UNKNOWN",
|
||||||
|
@ -52,7 +54,8 @@ static char *cpuname[] = {
|
||||||
"FALKOR",
|
"FALKOR",
|
||||||
"THUNDERX",
|
"THUNDERX",
|
||||||
"THUNDERX2T99",
|
"THUNDERX2T99",
|
||||||
"TSV110"
|
"TSV110",
|
||||||
|
"EMAG8180"
|
||||||
};
|
};
|
||||||
|
|
||||||
static char *cpuname_lower[] = {
|
static char *cpuname_lower[] = {
|
||||||
|
@ -65,7 +68,8 @@ static char *cpuname_lower[] = {
|
||||||
"falkor",
|
"falkor",
|
||||||
"thunderx",
|
"thunderx",
|
||||||
"thunderx2t99",
|
"thunderx2t99",
|
||||||
"tsv110"
|
"tsv110",
|
||||||
|
"emag8180"
|
||||||
};
|
};
|
||||||
|
|
||||||
int get_feature(char *search)
|
int get_feature(char *search)
|
||||||
|
@ -152,6 +156,9 @@ int detect(void)
|
||||||
// HiSilicon
|
// HiSilicon
|
||||||
else if (strstr(cpu_implementer, "0x48") && strstr(cpu_part, "0xd01"))
|
else if (strstr(cpu_implementer, "0x48") && strstr(cpu_part, "0xd01"))
|
||||||
return CPU_TSV110;
|
return CPU_TSV110;
|
||||||
|
// Ampere
|
||||||
|
else if (strstr(cpu_implementer, "0x50") && strstr(cpu_part, "0x000"))
|
||||||
|
return CPU_EMAG8180;
|
||||||
}
|
}
|
||||||
|
|
||||||
p = (char *) NULL ;
|
p = (char *) NULL ;
|
||||||
|
@ -335,6 +342,18 @@ void get_cpuconfig(void)
|
||||||
printf("#define DTB_DEFAULT_ENTRIES 64 \n");
|
printf("#define DTB_DEFAULT_ENTRIES 64 \n");
|
||||||
printf("#define DTB_SIZE 4096 \n");
|
printf("#define DTB_SIZE 4096 \n");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case CPU_EMAG8180:
|
||||||
|
// Minimum parameters for ARMv8 (based on A53)
|
||||||
|
printf("#define EMAG8180\n");
|
||||||
|
printf("#define L1_CODE_SIZE 32768\n");
|
||||||
|
printf("#define L1_DATA_SIZE 32768\n");
|
||||||
|
printf("#define L1_DATA_LINESIZE 64\n");
|
||||||
|
printf("#define L2_SIZE 262144\n");
|
||||||
|
printf("#define L2_LINESIZE 64\n");
|
||||||
|
printf("#define DTB_DEFAULT_ENTRIES 64\n");
|
||||||
|
printf("#define DTB_SIZE 4096\n");
|
||||||
|
|
||||||
}
|
}
|
||||||
get_cpucount();
|
get_cpucount();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue