tsc: Use alternative delay sources whenever appropriate.
PIT isn't available on some of new hardware including Hyper-V. So use pmtimer for calibration. Moreover pmtimer calibration is faster, so use it on coreboor where booting time is important. Based on patch by Michael Chang.
This commit is contained in:
parent
3d2c8048da
commit
d43a5ee651
13 changed files with 451 additions and 121 deletions
|
@ -61,18 +61,6 @@ static const struct grub_arg_option options[] = {
|
|||
{0, 0, 0, 0, 0, 0}
|
||||
};
|
||||
|
||||
/* Simple checksum by summing all bytes. Used by ACPI and SMBIOS. */
|
||||
grub_uint8_t
|
||||
grub_byte_checksum (void *base, grub_size_t size)
|
||||
{
|
||||
grub_uint8_t *ptr;
|
||||
grub_uint8_t ret = 0;
|
||||
for (ptr = (grub_uint8_t *) base; ptr < ((grub_uint8_t *) base) + size;
|
||||
ptr++)
|
||||
ret += *ptr;
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* rev1 is 1 if ACPIv1 is to be generated, 0 otherwise.
|
||||
rev2 contains the revision of ACPIv2+ to generate or 0 if none. */
|
||||
static int rev1, rev2;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue