[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v8 6/6] x86/iommu: add map-reserved dom0-iommu option to map reserved memory ranges





On 9/7/18 4:07 PM, Roger Pau Monne wrote:
Several people have reported hardware issues (malfunctioning USB
controllers) due to iommu page faults on Intel hardware. Those faults
are caused by missing RMRR (VTd) entries in the ACPI tables. Those can
be worked around on VTd hardware by manually adding RMRR entries on
the command line, this is however limited to Intel hardware and quite
cumbersome to do.

In order to solve those issues add a new dom0-iommu=map-reserved
option that identity maps all regions marked as reserved in the memory
map. Note that regions used by devices emulated by Xen (LAPIC, IO-APIC
or PCIe MCFG regions) are specifically avoided. Note that this option
is available to all Dom0 modes (as opposed to the inclusive option
which only works for PV Dom0).

Signed-off-by: Roger Pau Monné<roger.pau@xxxxxxxxxx>
Reviewed-by: Kevin Tian<kevin.tian@xxxxxxxxx>
Reviewed-by: Wei Liu<wei.liu2@xxxxxxxxxx>
Acked-by: Jan Beulich<jbeulich@xxxxxxxx>
---
Changes since v7:
  - Don't use true/false with int8_t.
  - Print a warning message if map-reserved is set on ARM.

Changes since v6:
  - Reword the map-reserved help to make it clear it's available to
    both PV and PVH Dom0.
  - Assign type inside of the switch expression.
  - Remove the comment about IO-APIC MMIO relocation, this is not
    supported ATM.

Changes since v5:
  - Merge with the vpci MMCFG helper patch.
  - Add a TODO item about the issues with relocating the LAPIC or
    IOAPIC MMIO regions.
  - Use the newly introduced page_get_ram_type that returns all the
    types that fall between a page.
  - Use paging_mode_translate instead of iommu_use_hap_pt when deciding
    whether to use set_identity_p2m_entry or iommu_map_page.

Changes since v4:
  - Use pfn_to_paddr.
  - Rebase on top of previous changes.
  - Change the default option setting to use if instead of a ternary
    operator.
  - Rename to map-reserved.

Changes since v3:
  - Add mappings if the iommu page tables are shared.

Changes since v2:
  - Fix comment regarding dom0-strict.
  - Change documentation style of xen command line.
  - Rename iommu_map to hwdom_iommu_map.
  - Move all the checks to hwdom_iommu_map.

Changes since v1:
  - Introduce a new reserved option instead of abusing the inclusive
    option.
  - Use the same helper function for PV and PVH in order to decide if a
    page should be added to the domain page tables.
  - Use the data inside of the domain struct to detect overlaps with
    emulated MMIO regions.
---
Cc: Andrew Cooper<andrew.cooper3@xxxxxxxxxx>
Cc: George Dunlap<George.Dunlap@xxxxxxxxxxxxx>
Cc: Ian Jackson<ian.jackson@xxxxxxxxxxxxx>
Cc: Jan Beulich<jbeulich@xxxxxxxx>
Cc: Julien Grall<julien.grall@xxxxxxx>
Cc: Konrad Rzeszutek Wilk<konrad.wilk@xxxxxxxxxx>
Cc: Stefano Stabellini<sstabellini@xxxxxxxxxx>
Cc: Tim Deegan<tim@xxxxxxx>
Cc: Wei Liu<wei.liu2@xxxxxxxxxx>
Cc: Paul Durrant<paul.durrant@xxxxxxxxxx>
Cc: Suravee Suthikulpanit<suravee.suthikulpanit@xxxxxxx>
Cc: Brian Woods<brian.woods@xxxxxxx>
Cc: Kevin Tian<kevin.tian@xxxxxxxxx>

For AMD-related changes.

Acked-by: Suravee Suthikulpanit <suravee.suthikulpanit@xxxxxxx>

Thank you,
Suravee

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.