mb/*/*: Clean up FADT checksum assignment

The assignment of header->checksum was in some cases done twice, or
unnecessarily split into two lines.

Change-Id: Ib0c0890d7589e6a24b11e9bda10e6969c7d73c56
Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net>
Reviewed-on: https://review.coreboot.org/28988
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marc Jones <marc@marcjonesconsulting.com>
This commit is contained in:
Jonathan Neuschäfer 2018-10-10 14:22:48 +02:00 committed by Patrick Georgi
parent 9814f8f037
commit e1de6482d0
27 changed files with 26 additions and 70 deletions

View File

@ -30,9 +30,7 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
#if PLATFORM_HAS_FADT_CUSTOMIZATIONS
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
#endif
}

View File

@ -157,6 +157,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -170,8 +170,7 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}
unsigned long acpi_fill_madt(unsigned long current)

View File

@ -25,8 +25,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -23,6 +23,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -42,6 +42,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
acpi_fill_in_fadt(fadt);
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -147,6 +147,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -42,6 +42,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
acpi_fill_in_fadt(fadt);
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -42,6 +42,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
acpi_fill_in_fadt(fadt);
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -41,6 +41,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
acpi_fill_in_fadt(fadt);
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -147,6 +147,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -147,6 +147,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -25,7 +25,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -23,7 +23,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -30,9 +30,6 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
#if PLATFORM_HAS_FADT_CUSTOMIZATIONS
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
#endif
}

View File

@ -25,8 +25,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -30,9 +30,6 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
#if PLATFORM_HAS_FADT_CUSTOMIZATIONS
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
#endif
}

View File

@ -42,6 +42,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
acpi_fill_in_fadt(fadt);
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -41,6 +41,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
acpi_fill_in_fadt(fadt);
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -148,6 +148,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -148,6 +148,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -23,7 +23,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -23,7 +23,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -25,8 +25,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -148,6 +148,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
fadt->x_gpe1_blk.addrl = 0x0;
fadt->x_gpe1_blk.addrh = 0x0;
header->checksum =
acpi_checksum((void *) fadt, header->length);
header->checksum = acpi_checksum((void *) fadt, header->length);
}

View File

@ -23,7 +23,5 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}

View File

@ -25,7 +25,5 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt)
/* Platform specific customizations go here */
header->checksum = 0;
header->checksum =
acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
header->checksum = acpi_checksum((void *) fadt, sizeof(acpi_fadt_t));
}