mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-07 19:34:56 +00:00
linux/pc: enable IOMMU config for intel fb
to apply scanout scratch page GTT workaround drivers/gpu/drm/i915/gt/intel_ggtt.c -> gen8_gmch_probe() -> intel_scanout_needs_vtd_wa(i915) Fixes #4659
This commit is contained in:
parent
bb067f529b
commit
5df68922eb
@ -577,3 +577,16 @@ int pci_bus_write_config_byte(struct pci_bus *bus, unsigned int devfn,
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_enable_msi(struct pci_dev *dev)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
|
||||
void pci_disable_msi(struct pci_dev *dev)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
}
|
||||
|
@ -17,6 +17,7 @@
|
||||
|
||||
#include <linux/dma-fence.h>
|
||||
#include <linux/fs.h>
|
||||
#include <linux/intel-iommu.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/proc_fs.h>
|
||||
@ -31,7 +32,8 @@ struct dma_fence_ops const i915_fence_ops;
|
||||
pteval_t __default_kernel_pte_mask __read_mostly = ~0;
|
||||
|
||||
|
||||
int acpi_disabled = 0;
|
||||
int acpi_disabled = 0;
|
||||
int intel_iommu_gfx_mapped = 0;
|
||||
|
||||
|
||||
void intel_wopcm_init_early(struct intel_wopcm * wopcm)
|
||||
@ -217,6 +219,15 @@ void intel_gt_init_early(struct intel_gt * gt, struct drm_i915_private * i915)
|
||||
|
||||
/* disable panel self refresh (required for FUJITSU S937/S938) */
|
||||
i915->params.enable_psr = 0;
|
||||
|
||||
/*
|
||||
* Tells driver that IOMMU, e.g. VT-d, is on, so that scratch page
|
||||
* workaround is applied by Intel display driver:
|
||||
*
|
||||
* drivers/gpu/drm/i915/gt/intel_ggtt.c
|
||||
* -> gen8_gmch_probe() -> intel_scanout_needs_vtd_wa(i915)
|
||||
*/
|
||||
intel_iommu_gfx_mapped = 1;
|
||||
}
|
||||
|
||||
|
||||
|
@ -29,6 +29,7 @@ drivers/usb/host/xhci-ext-caps.h
|
||||
drivers/usb/host/xhci-pci.h
|
||||
drivers/usb/host/xhci-trace.h
|
||||
drivers/usb/host/xhci.h
|
||||
include/asm-generic/dma-mapping.h
|
||||
include/asm-generic/export.h
|
||||
include/linux/bcd.h
|
||||
include/linux/extcon.h
|
||||
|
@ -85,3 +85,26 @@ int pci_write_config_word(const struct pci_dev * dev,int where,u16 val)
|
||||
}
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_alloc_irq_vectors_affinity(struct pci_dev *dev, unsigned int min_vecs,
|
||||
unsigned int max_vecs, unsigned int flags,
|
||||
struct irq_affinity *aff_desc)
|
||||
{
|
||||
if ((flags & PCI_IRQ_LEGACY) && min_vecs == 1 && dev->irq)
|
||||
return 1;
|
||||
return -ENOSPC;
|
||||
}
|
||||
|
||||
|
||||
int pci_irq_vector(struct pci_dev *dev, unsigned int nr)
|
||||
{
|
||||
if (WARN_ON_ONCE(nr > 0))
|
||||
return -EINVAL;
|
||||
return dev->irq;
|
||||
}
|
||||
|
||||
|
||||
void pci_free_irq_vectors(struct pci_dev *dev)
|
||||
{
|
||||
}
|
||||
|
@ -339,3 +339,18 @@ void synchronize_rcu_expedited(void)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_enable_msi(struct pci_dev *dev)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
|
||||
int pci_enable_msix_range(struct pci_dev *dev, struct msix_entry *entries,
|
||||
int minvec, int maxvec)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
@ -15,7 +15,10 @@ LX_ENABLE += BINFMT_ELF BINFMT_SCRIPT BLK_DEV_INITRD
|
||||
LX_ENABLE += SERIAL_8250 SERIAL_8250_CONSOLE
|
||||
|
||||
# PCI support
|
||||
LX_ENABLE += PCI
|
||||
LX_ENABLE += PCI PCI_MSI
|
||||
|
||||
# IOMMU support (used by Intel fb to apply scanout scratch page workaround)
|
||||
LX_ENABLE += IOMMU_SUPPORT INTEL_IOMMU
|
||||
|
||||
# ACPI support
|
||||
LX_ENABLE += ACPI
|
||||
|
Loading…
x
Reference in New Issue
Block a user