1
0
mirror of https://review.coreboot.org/flashrom.git synced 2025-08-16 03:44:41 +02:00

Move all printing code to print.c

Drop no longer needed MAX macro, we have a max() function.

Corresponding to flashrom svn r601.

Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Acked-by: Uwe Hermann <uwe@hermann-uwe.de>
This commit is contained in:
Uwe Hermann
2009-06-17 12:07:12 +00:00
parent d168057805
commit ba290d1ce3
6 changed files with 235 additions and 206 deletions

View File

@@ -948,9 +948,6 @@ static int get_flashbase_sc520(struct pci_dev *dev, const char *name)
return 0;
}
#define OK 0
#define NT 1 /* Not tested */
/* Please keep this list alphabetically sorted by vendor/device. */
const struct penable chipset_enables[] = {
{0x10B9, 0x1533, OK, "ALi", "M1533", enable_flash_ali_m1533},
@@ -1035,29 +1032,6 @@ const struct penable chipset_enables[] = {
{},
};
void print_supported_chipsets(void)
{
int i, j, chipsetcount = 0;
const struct penable *c = chipset_enables;
for (i = 0; c[i].vendor_name != NULL; i++)
chipsetcount++;
printf("\nSupported chipsets (total: %d):\n\nVendor: "
"Chipset: PCI IDs:\n\n", chipsetcount);
for (i = 0; c[i].vendor_name != NULL; i++) {
printf("%s", c[i].vendor_name);
for (j = 0; j < 25 - strlen(c[i].vendor_name); j++)
printf(" ");
printf("%s", c[i].device_name);
for (j = 0; j < 25 - strlen(c[i].device_name); j++)
printf(" ");
printf("%04x:%04x%s\n", c[i].vendor_id, c[i].device_id,
(c[i].status == OK) ? "" : " (untested)");
}
}
int chipset_flash_enable(void)
{
struct pci_dev *dev = 0;