From b1596f216b5b63f4100837e0858c715cf28fa55c Mon Sep 17 00:00:00 2001 From: Carl-Daniel Hailfinger Date: Sun, 20 Jul 2008 21:05:25 +0000 Subject: [PATCH] Rename mainboard_part_number to mainboard_name in various places. This is the logical continuation of r416 which happened a year ago. As an added bonus, we now have consistent naming again, making grepping the source for dts properties possible. Build tested on all targets. Patch attached for Gmail users. Signed-off-by: Carl-Daniel Hailfinger Acked-by: Ronald G. Minnich git-svn-id: svn://coreboot.org/repository/coreboot-v3@697 f3766cd6-281f-0410-b1cd-43a5c92072e9 --- arch/x86/coreboot_table.c | 6 +++--- mainboard/adl/msm800sev/dts | 2 +- mainboard/amd/db800/dts | 2 +- mainboard/amd/norwich/dts | 2 +- mainboard/artecgroup/dbe61/dts | 2 +- mainboard/artecgroup/dbe62/dts | 2 +- mainboard/emulation/qemu-x86/dts | 2 +- mainboard/pcengines/alix1c/dts | 2 +- mainboard/pcengines/alix2c3/dts | 2 +- util/dtc/flattree.c | 16 ++++++++-------- 10 files changed, 19 insertions(+), 19 deletions(-) diff --git a/arch/x86/coreboot_table.c b/arch/x86/coreboot_table.c index 9b2cbb91f1..b707d2fe76 100644 --- a/arch/x86/coreboot_table.c +++ b/arch/x86/coreboot_table.c @@ -142,14 +142,14 @@ struct lb_mainboard *lb_mainboard(struct lb_header *header) { struct lb_record *rec; struct lb_mainboard *mainboard; - extern char *mainboard_vendor, *mainboard_part_number; + extern char *mainboard_vendor, *mainboard_name; rec = lb_new_record(header); mainboard = (struct lb_mainboard *)rec; mainboard->tag = LB_TAG_MAINBOARD; mainboard->size = (sizeof(*mainboard) + strlen(mainboard_vendor) + 1 + - strlen(mainboard_part_number) + 1 + + strlen(mainboard_name) + 1 + 3) & ~3; mainboard->vendor_idx = 0; @@ -158,7 +158,7 @@ struct lb_mainboard *lb_mainboard(struct lb_header *header) memcpy(mainboard->strings + mainboard->vendor_idx, mainboard_vendor, strlen(mainboard_vendor) + 1); memcpy(mainboard->strings + mainboard->part_number_idx, - mainboard_part_number, strlen(mainboard_part_number) + 1); + mainboard_name, strlen(mainboard_name) + 1); return mainboard; } diff --git a/mainboard/adl/msm800sev/dts b/mainboard/adl/msm800sev/dts index f040974ae9..d3ebc037b8 100644 --- a/mainboard/adl/msm800sev/dts +++ b/mainboard/adl/msm800sev/dts @@ -22,7 +22,7 @@ /{ mainboard_vendor = "Advanced Digital Logic"; - mainboard-name = "MSM800SEV"; + mainboard_name = "MSM800SEV"; mainboard_pci_subsystem_vendor = "0x1022"; mainboard_pci_subsystem_device = "0x2323"; cpus { }; diff --git a/mainboard/amd/db800/dts b/mainboard/amd/db800/dts index 1541e7589c..45c9e26b06 100644 --- a/mainboard/amd/db800/dts +++ b/mainboard/amd/db800/dts @@ -20,7 +20,7 @@ /{ mainboard_vendor = "AMD"; - mainboard-name = "DB800"; + mainboard_name = "DB800"; mainboard_pci_subsystem_vendor = "0x1022"; mainboard_pci_subsystem_device = "0x2323"; cpus { }; diff --git a/mainboard/amd/norwich/dts b/mainboard/amd/norwich/dts index b4ac4a1a1d..61ee5c48be 100644 --- a/mainboard/amd/norwich/dts +++ b/mainboard/amd/norwich/dts @@ -20,7 +20,7 @@ /{ mainboard_vendor = "AMD"; - mainboard-name = "NORWICH"; + mainboard_name = "NORWICH"; mainboard_pci_subsystem_vendor = "0x1022"; mainboard_pci_subsystem_device = "0x2323"; cpus { }; diff --git a/mainboard/artecgroup/dbe61/dts b/mainboard/artecgroup/dbe61/dts index 41fd675cad..f5690bb196 100644 --- a/mainboard/artecgroup/dbe61/dts +++ b/mainboard/artecgroup/dbe61/dts @@ -74,7 +74,7 @@ end /{ mainboard_vendor = "Artec Group"; - mainboard-name = "DBE61"; + mainboard_name = "DBE61"; mainboard_pci_subsystem_vendor = "0x1022"; mainboard_pci_subsystem_device = "0x2323"; cpus { }; diff --git a/mainboard/artecgroup/dbe62/dts b/mainboard/artecgroup/dbe62/dts index 91c3d247e3..feb8b58591 100644 --- a/mainboard/artecgroup/dbe62/dts +++ b/mainboard/artecgroup/dbe62/dts @@ -20,7 +20,7 @@ /{ mainboard_vendor = "Artec"; - mainboard-name = "DBE62"; + mainboard_name = "DBE62"; cpus { }; apic@0 { /config/("northbridge/amd/geodelx/apic"); diff --git a/mainboard/emulation/qemu-x86/dts b/mainboard/emulation/qemu-x86/dts index 9baad5ee86..74b8c7701f 100644 --- a/mainboard/emulation/qemu-x86/dts +++ b/mainboard/emulation/qemu-x86/dts @@ -20,7 +20,7 @@ /{ mainboard_vendor = "Emulation"; - mainboard-name = "QEMU x86"; + mainboard_name = "QEMU x86"; mainboard_pci_subsystem_vendor = "0x15ad"; mainboard_pci_subsystem_device = "0x1976"; device_operations = "qemuvga_pci_ops_dev"; diff --git a/mainboard/pcengines/alix1c/dts b/mainboard/pcengines/alix1c/dts index 77ac82f6ec..93a9a4750d 100644 --- a/mainboard/pcengines/alix1c/dts +++ b/mainboard/pcengines/alix1c/dts @@ -20,7 +20,7 @@ /{ mainboard_vendor = "PC Engines"; - mainboard-name = "ALIX1.C"; + mainboard_name = "ALIX1.C"; cpus { }; apic@0 { /config/("northbridge/amd/geodelx/apic"); diff --git a/mainboard/pcengines/alix2c3/dts b/mainboard/pcengines/alix2c3/dts index d4f2713ef3..52cc6be650 100644 --- a/mainboard/pcengines/alix2c3/dts +++ b/mainboard/pcengines/alix2c3/dts @@ -20,7 +20,7 @@ /{ mainboard_vendor = "PC Engines"; - mainboard-name = "ALIX.2C3"; + mainboard_name = "ALIX.2C3"; cpus { }; apic@0 { /config/("northbridge/amd/geodelx/apic"); diff --git a/util/dtc/flattree.c b/util/dtc/flattree.c index 3088fe397a..304c20fffa 100644 --- a/util/dtc/flattree.c +++ b/util/dtc/flattree.c @@ -1328,7 +1328,7 @@ void dt_to_coreboot(FILE *f, struct boot_info *bi, int version, int boot_cpuid_p extern char *code; struct node *next; extern struct node *first_node; - int found_mainboard_vendor = 0, found_mainboard_partnumber = 0, found_mainboard_subsys = 0; + int found_mainboard_vendor = 0, found_mainboard_name = 0, found_mainboard_subsys = 0; labeltree(bi->dt); @@ -1357,9 +1357,9 @@ void dt_to_coreboot(FILE *f, struct boot_info *bi, int version, int boot_cpuid_p found_mainboard_vendor = 1; fprintf(f, "const char *mainboard_vendor = \"%s\";\n", prop->val.val); } - if (streq(prop->name, "mainboard-name")){ - found_mainboard_partnumber = 1; - fprintf(f, "const char *mainboard_part_number = \"%s\";\n", prop->val.val); + if (streq(prop->name, "mainboard_name")){ + found_mainboard_name = 1; + fprintf(f, "const char *mainboard_name = \"%s\";\n", prop->val.val); } if (streq(prop->name, "mainboard_pci_subsystem_vendor")){ found_mainboard_subsys++; @@ -1373,11 +1373,11 @@ void dt_to_coreboot(FILE *f, struct boot_info *bi, int version, int boot_cpuid_p if (! found_mainboard_vendor){ die("There is no mainboard_vendor property in the root. Please add one." - "(and make sure there is a mainboard-name property too"); + "(and make sure there is a mainboard_name property too"); } - if (! found_mainboard_partnumber){ - die("There is no mainboard-name property in the root. " + if (! found_mainboard_name){ + die("There is no mainboard_name property in the root. " "Please add one." "(and make sure there is a mainboard_vendor property too"); } @@ -1436,7 +1436,7 @@ void dt_to_corebooth(FILE *f, struct boot_info *bi, int version, int boot_cpuid_ fix_next(bi->dt); /* emit any includes that we need -- TODO: ONLY ONCE PER TYPE*/ fprintf(f, "#include \n#include \n"); - fprintf(f, "extern const char *mainboard_vendor, *mainboard_part_number;\n"); + fprintf(f, "extern const char *mainboard_vendor, *mainboard_name;\n"); for_each_property(bi->dt, prop) { if (streq(prop->name, "mainboard_pci_subsystem_vendor")){