Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apu2 iommu fix #592

Open
wants to merge 11 commits into
base: dasharo
Choose a base branch
from
Open

Apu2 iommu fix #592

wants to merge 11 commits into from

Commits on Nov 23, 2024

  1. northbridge/amd/pi/00730F01/acpi/northbridge.asl: Add IOMMU device

    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 23, 2024
    Configuration menu
    Copy the full SHA
    30d9513 View commit details
    Browse the repository at this point in the history
  2. src/mainboard/pcengines/apu2/acpi/routing.asl: Add PCI INT routing fo…

    …r IOMMU
    
    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 23, 2024
    Configuration menu
    Copy the full SHA
    e6353d9 View commit details
    Browse the repository at this point in the history
  3. northbridge/amd/pi/00730F01/northbridge.c: Disable Guest AVIC

    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 23, 2024
    Configuration menu
    Copy the full SHA
    65c40ff View commit details
    Browse the repository at this point in the history
  4. nb/amd/pi/00730F01/northbridge.c: Enable GNB IOAPIC in northbridge_init

    Move the GNB IOAPIC enabling to northbridge init where the IOAPIC is
    initialized.
    
    Remove the comment about IoapicSbFeatureEn, this bit is not touched
    here.
    
    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 23, 2024
    Configuration menu
    Copy the full SHA
    d3c3fff View commit details
    Browse the repository at this point in the history
  5. src/mainboard/pcengines/apu2/mainboard.c: Assign INTB# to IRQ17

    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 23, 2024
    Configuration menu
    Copy the full SHA
    716d217 View commit details
    Browse the repository at this point in the history
  6. src/mainboard/pcengines/apu2/mainboard.c: Clear the right bits in ECC…

    … register
    
    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 23, 2024
    Configuration menu
    Copy the full SHA
    6986e35 View commit details
    Browse the repository at this point in the history

Commits on Nov 26, 2024

  1. src/northbridge/amd/pi/00730F01/northbridge.c: Add PCI_DEVID macro

    Introduce PCI_DEVID macro which allows to construct PCI device
    addresses or range with bus numbers.
    
    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 26, 2024
    Configuration menu
    Copy the full SHA
    fe8a301 View commit details
    Browse the repository at this point in the history
  2. src/northbridge/amd/pi/00730F01/northbridge.c: Rework IVRS generation

    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 26, 2024
    Configuration menu
    Copy the full SHA
    900e49a View commit details
    Browse the repository at this point in the history
  3. northbridge/amd/pi/00730F01/northbridge.c: Soft reserve CC6 save stat…

    …e area
    
    Use the IORESOURCE_SOFT_RESERVE attribute to reserve CC6 save state DRAM.
    Using regualr reserved memory makes it hard on EDK2 to detect if it is MMIO
    or reserved DRAM, as TOM2 is equal to the base of the CC6 save state area,
    not its limit.
    
    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 26, 2024
    Configuration menu
    Copy the full SHA
    97ab6bb View commit details
    Browse the repository at this point in the history
  4. configs/config.pcengines_uefi_apu: Bump edk2 revision to fix IOMMU

    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 26, 2024
    Configuration menu
    Copy the full SHA
    acc4e71 View commit details
    Browse the repository at this point in the history
  5. nb/amd/pi/00730F01,dsdt_top: Add hook for _PIC method

    Per family 16h models 30h-3fh BKDG the IoapicSbFeatureEn must be
    configured according to the interrupt routing mode selecte by OS.
    If OS chose APIC mode, the IoapicSbFeatureEn must be cleared.
    Otherwise, it must be set, meaning PIC mode is used.
    
    Add a hook to _PIC method to call SoC/northbridge specific code to
    set/clear the bit to configure GNB IOAPIC properly.
    
    ACPI specification says that _PIC method is optional and can be
    called by OSPM to provide the interrupt routing mode information to
    the firmware. However, if the method is not called, the firmware
    must assume PIC mode is used. AGESA sets the IoapicSbFeatureEn
    already to be compliant with ACPI. Previously, coreboot cleared the
    bit unconditionally and left a comment to move that part to DSDT.
    The hook allows to clear the IoapicSbFeatureEn bit if OS chooses APIC
    mode for interrupt routing.
    
    Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
    miczyg1 committed Nov 26, 2024
    Configuration menu
    Copy the full SHA
    e4edeca View commit details
    Browse the repository at this point in the history