Know the machines FreeBSD runs on. Print the machine value for

unknown machines.

MFC after: 1 week
This commit is contained in:
marcel 2005-12-17 23:24:34 +00:00
parent 8f7e8790b1
commit c9778a66ea

View File

@ -243,6 +243,8 @@ d_tags(u_int64_t tag) {
static const char *
e_machines(u_int mach)
{
static char machdesc[64];
switch (mach) {
case EM_NONE: return "EM_NONE";
case EM_M32: return "EM_M32";
@ -250,12 +252,18 @@ e_machines(u_int mach)
case EM_386: return "EM_386";
case EM_68K: return "EM_68K";
case EM_88K: return "EM_88K";
case EM_486: return "EM_486";
case EM_860: return "EM_860";
case EM_MIPS: return "EM_MIPS";
case EM_PPC: return "EM_PPC";
case EM_ARM: return "EM_ARM";
case EM_ALPHA: return "EM_ALPHA (legacy)";
case EM_SPARCV9:return "EM_SPARCV9";
case EM_IA_64: return "EM_IA_64";
case EM_X86_64: return "EM_X86_64";
}
return "(unknown machine)";
snprintf(machdesc, sizeof(machdesc),
"(unknown machine) -- type 0x%x", mach);
return (machdesc);
}
const char *e_types[] = {