From 44778ef7b61d717709d2ee05aad3594283c5037e Mon Sep 17 00:00:00 2001 From: jmatthew Date: Tue, 12 Sep 2023 08:22:07 +0000 Subject: [PATCH] Add an "openbsd,gic-its-id" property to gic-its nodes containing the ITS ID. ok kettenis@ patrick@ --- sys/arch/arm64/stand/efiboot/efiacpi.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/arch/arm64/stand/efiboot/efiacpi.c b/sys/arch/arm64/stand/efiboot/efiacpi.c index 3eed8163009..4d200311933 100644 --- a/sys/arch/arm64/stand/efiboot/efiacpi.c +++ b/sys/arch/arm64/stand/efiboot/efiacpi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: efiacpi.c,v 1.14 2022/01/02 02:13:33 jsg Exp $ */ +/* $OpenBSD: efiacpi.c,v 1.15 2023/09/12 08:22:07 jmatthew Exp $ */ /* * Copyright (c) 2018 Mark Kettenis @@ -491,11 +491,13 @@ efi_acpi_madt_gic_its(struct acpi_madt_gic_its *its) static uint32_t phandle = 2; void *node, *child; uint64_t reg[2]; + uint32_t its_id; char name[32]; snprintf(name, sizeof(name), "gic-its@%llx", its->base_address); reg[0] = htobe64(its->base_address); reg[1] = htobe64(0x20000); + its_id = htobe32(its->gic_its_id); /* Create "gic-its" node. */ node = fdt_find_node("/interrupt-controller"); @@ -504,6 +506,8 @@ efi_acpi_madt_gic_its(struct acpi_madt_gic_its *its) fdt_node_add_property(child, "msi-controller", NULL, 0); fdt_node_add_property(child, "reg", reg, sizeof(reg)); fdt_node_add_property(child, "phandle", &phandle, sizeof(phandle)); + fdt_node_add_property(child, "openbsd,gic-its-id", &its_id, + sizeof(its_id)); phandle++; } -- 2.20.1