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

Conversation

miczyg1
Copy link
Contributor

@miczyg1 miczyg1 commented Nov 23, 2024

No description provided.

Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
…r IOMMU

Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
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>
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
… register

Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
@pietrushnic pietrushnic mentioned this pull request Nov 23, 2024
10 tasks
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 miczyg1 force-pushed the apu2_iommu_fix branch 2 times, most recently from 2b58e23 to aed43dc Compare November 26, 2024 23:23
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
…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>
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
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>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant