svn commit: r263746 - stable/10/sys/x86/iommu
Konstantin Belousov
kib at FreeBSD.org
Tue Mar 25 20:16:29 UTC 2014
Author: kib
Date: Tue Mar 25 20:16:28 2014
New Revision: 263746
URL: http://svnweb.freebsd.org/changeset/base/263746
Log:
MFC r263305:
Provide a workaround by identity mapping the 32 pages after the bogus
entry start, which seems to be enough for the reported BIOS.
Modified:
stable/10/sys/x86/iommu/intel_ctx.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/x86/iommu/intel_ctx.c
==============================================================================
--- stable/10/sys/x86/iommu/intel_ctx.c Tue Mar 25 19:28:40 2014 (r263745)
+++ stable/10/sys/x86/iommu/intel_ctx.c Tue Mar 25 20:16:28 2014 (r263746)
@@ -182,6 +182,15 @@ ctx_init_rmrr(struct dmar_ctx *ctx, devi
end = entry->end;
entry->start = trunc_page(start);
entry->end = round_page(end);
+ if (entry->start == entry->end) {
+ /* Workaround for some AMI (?) BIOSes */
+ if (bootverbose) {
+ device_printf(dev, "BIOS bug: dmar%d RMRR "
+ "region (%jx, %jx) corrected\n",
+ ctx->dmar->unit, start, end);
+ }
+ entry->end += DMAR_PAGE_SIZE * 0x20;
+ }
size = OFF_TO_IDX(entry->end - entry->start);
ma = malloc(sizeof(vm_page_t) * size, M_TEMP, M_WAITOK);
for (i = 0; i < size; i++) {
More information about the svn-src-stable-10
mailing list