Commit 8f772955 authored by Sunil V L's avatar Sunil V L Committed by Joerg Roedel
Browse files

ACPI: RISC-V: Add support for RIMT

RISC-V IO Mapping Table (RIMT) is a static ACPI table to communicate
IOMMU information to the OS. The spec is available at [1].

The changes at high level are,
	a) Initialize data structures required for IOMMU/device
	   configuration using the data from RIMT. Provide APIs required
	   for device configuration.
	b) Provide an API for IOMMU drivers to register the
	   fwnode with RIMT data structures. This API will create a
	   fwnode for PCIe IOMMU.

[1] - https://github.com/riscv-non-isa/riscv-acpi-rimt



Signed-off-by: default avatarSunil V L <sunilvl@ventanamicro.com>
Reviewed-by: default avatarAnup Patel <anup@brainfault.org>
Link: https://lore.kernel.org/r/20250818045807.763922-2-sunilvl@ventanamicro.com


Signed-off-by: default avatarJoerg Roedel <joerg.roedel@amd.com>
parent 8f5ae30d
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -347,6 +347,7 @@ L: linux-acpi@vger.kernel.org
L:	linux-riscv@lists.infradead.org
S:	Maintained
F:	drivers/acpi/riscv/
F:	include/linux/acpi_rimt.h
ACPI PCC(Platform Communication Channel) MAILBOX DRIVER
M:	Sudeep Holla <sudeep.holla@arm.com>
+1 −0
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@ config RISCV
	select ACPI_MCFG if (ACPI && PCI)
	select ACPI_PPTT if ACPI
	select ACPI_REDUCED_HARDWARE_ONLY if ACPI
	select ACPI_RIMT if ACPI
	select ACPI_SPCR_TABLE if ACPI
	select ARCH_DMA_DEFAULT_COHERENT
	select ARCH_ENABLE_HUGEPAGE_MIGRATION if HUGETLB_PAGE && MIGRATION
+4 −0
Original line number Diff line number Diff line
@@ -547,6 +547,10 @@ if ARM64
source "drivers/acpi/arm64/Kconfig"
endif

if RISCV
source "drivers/acpi/riscv/Kconfig"
endif

config ACPI_PPTT
	bool

+7 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0-only
#
# ACPI Configuration for RISC-V
#

config ACPI_RIMT
	bool
+1 −0
Original line number Diff line number Diff line
@@ -2,3 +2,4 @@
obj-y					+= rhct.o init.o irq.o
obj-$(CONFIG_ACPI_PROCESSOR_IDLE)	+= cpuidle.o
obj-$(CONFIG_ACPI_CPPC_LIB)		+= cppc.o
obj-$(CONFIG_ACPI_RIMT)			+= rimt.o
Loading