From nobody Thu Oct 24 03:58:19 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XYsZz41Ctz5b2G5; Thu, 24 Oct 2024 03:58:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XYsZz3Jf8z4HkM; Thu, 24 Oct 2024 03:58:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729742299; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ESOmHc6F+7UxnZkIXzbN08fqFsZIgqyO+7KwAgO1ZHM=; b=MS8kaHsfkoGaBXpx5q4ZfH2TsyZ66LeYibQSTh6ZxnhjkAdT3MlRinBamwxBgzZUDgZg43 gHBCt6ohb+AqV/P8nP5g/usgPlrciDrrhNwzndNaKt7CmDQNgy9CGGzyMn72dN8ElcUqZX VOgVtx0A8ow1Ov2hWnIqOd8Juyg3+DdE+XSTQTA6Mn1wVVOq/0YG3Yi18T//N+ydufkmog wODSdjmnZYRBkn+Xv4x4t5AcKG4MvQvjZLRonV53T4AKZKjWeKSpJcLzeOfoqJhyymDces jMQpjQ0jkjxgIex+Rji80boMaQtT64B5LxZ5K02dZmtvJTMbY0mJpF+f4CFmYQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729742299; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ESOmHc6F+7UxnZkIXzbN08fqFsZIgqyO+7KwAgO1ZHM=; b=J2J6jwAJ/NZeAe5hTm6w88jIlDCsgPTuKfLwSurO4S8h6l7jb/ht5mWgyIshX6vZZWJO53 iOYLOeVFXua2wweMLT9/vOJsSOUtRvrS+zUrKXoBZRDyeJePQkZoy9HfLXC9R4N6ZyaB2f /dVkfqFGbxZnTZ9PmbyJ0BD9/HWJAaNZjC24YT7Qzbnt+ftszj0+eGD6twNyLcJ8xc935a jwYLlvYxUwMNo2CcAaT0gm12noUeMqUoIEAOaHKviKJR6jocUiiZMpm7XKDdWBVKGUD6J/ sR6M9KWHttWIBwNNTgWWixbkQA9eke5aAQXQj+YjZO0m5DS3quNYJjCycT1rrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1729742299; a=rsa-sha256; cv=none; b=K6qj3Mpe4jzDrO4G6DdldVTo2v1cupDIzyunEC9CpmolyN669M9YAKeQz7UqkJA/aJ/lev 0ec5JJGP2+dihPDFr9pXnNJX+mjkV8xZ623oc1vw6wUIFFMTVdTvwCpQjgbgybnhW1gFNR hDpjyr4jKBwS9s99EYL9rIzVdvXOFVGTRBuJpsOR2DXHYw9NlvmxvzxlLBEmNY+bcji+nI 1xUTejnehVUuHMOl0mv3xeQJ+oBlpZffRK32J3DPBLiTTj5TvyUwVfD1I+xbviN1fSjXha 90tJ2PSUU3lh/4/eiVu4V1YCj15DMPx6HQtsv1mOyy+7+WGdzXT7eNdaZ0G7Sw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XYsZz2WY9zRQ9; Thu, 24 Oct 2024 03:58:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 49O3wJBn018249; Thu, 24 Oct 2024 03:58:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 49O3wJs0018246; Thu, 24 Oct 2024 03:58:19 GMT (envelope-from git) Date: Thu, 24 Oct 2024 03:58:19 GMT Message-Id: <202410240358.49O3wJs0018246@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: d64442a89896 - main - arm{,64}: use genassym for INTR_ROOT_* values List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d64442a89896d616eb1225eea43ed64dc736f74d Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=d64442a89896d616eb1225eea43ed64dc736f74d commit d64442a89896d616eb1225eea43ed64dc736f74d Author: Elliott Mitchell AuthorDate: 2024-10-24 03:55:21 +0000 Commit: Kyle Evans CommitDate: 2024-10-24 03:55:21 +0000 arm{,64}: use genassym for INTR_ROOT_* values Rather than keeping the entire machine interrupt header assembly-safe, switch to use of the existing genassym.c program to generate them. This will be handier in the long-term, most of the header never needs to be exposed to assembly-language. --- sys/arm/arm/exception.S | 3 +-- sys/arm/arm/genassym.c | 2 ++ sys/arm64/arm64/exception.S | 3 +-- sys/arm64/arm64/genassym.c | 5 +++++ sys/arm64/include/intr.h | 3 --- sys/sys/intr.h | 4 ---- 6 files changed, 9 insertions(+), 11 deletions(-) diff --git a/sys/arm/arm/exception.S b/sys/arm/arm/exception.S index a17898a53d49..3df91d6e3c1e 100644 --- a/sys/arm/arm/exception.S +++ b/sys/arm/arm/exception.S @@ -48,12 +48,11 @@ #include "assym.inc" -#include - #include #include #include #include + #ifdef KDTRACE_HOOKS .bss .align 4 diff --git a/sys/arm/arm/genassym.c b/sys/arm/arm/genassym.c index b7c3512dcb16..2cf1861b1178 100644 --- a/sys/arm/arm/genassym.c +++ b/sys/arm/arm/genassym.c @@ -131,6 +131,8 @@ ASSYM(DCACHE_LINE_MASK, offsetof(struct cpuinfo, dcache_line_mask)); ASSYM(ICACHE_LINE_SIZE, offsetof(struct cpuinfo, icache_line_size)); ASSYM(ICACHE_LINE_MASK, offsetof(struct cpuinfo, icache_line_mask)); +ASSYM(INTR_ROOT_IRQ, INTR_ROOT_IRQ); + /* * Emit the LOCORE_MAP_MB option as a #define only if the option was set. */ diff --git a/sys/arm64/arm64/exception.S b/sys/arm64/arm64/exception.S index b3f2a3931e08..d8c024d01921 100644 --- a/sys/arm64/arm64/exception.S +++ b/sys/arm64/arm64/exception.S @@ -26,11 +26,10 @@ */ #include -#include #include #include -#include + #include "assym.inc" .text diff --git a/sys/arm64/arm64/genassym.c b/sys/arm64/arm64/genassym.c index 8cbafba45a7d..db076e1ebf48 100644 --- a/sys/arm64/arm64/genassym.c +++ b/sys/arm64/arm64/genassym.c @@ -28,10 +28,12 @@ #include #include +#include #include #include #include +#include #include #include @@ -77,3 +79,6 @@ ASSYM(TF_ELR, offsetof(struct trapframe, tf_elr)); ASSYM(TF_SPSR, offsetof(struct trapframe, tf_spsr)); ASSYM(TF_ESR, offsetof(struct trapframe, tf_esr)); ASSYM(TF_X, offsetof(struct trapframe, tf_x)); + +ASSYM(INTR_ROOT_IRQ, INTR_ROOT_IRQ); +ASSYM(INTR_ROOT_FIQ, INTR_ROOT_FIQ); diff --git a/sys/arm64/include/intr.h b/sys/arm64/include/intr.h index f7aa2de0ee00..99b4d15ccc1c 100644 --- a/sys/arm64/include/intr.h +++ b/sys/arm64/include/intr.h @@ -27,7 +27,6 @@ #ifndef _MACHINE_INTR_H_ #define _MACHINE_INTR_H_ -#ifndef LOCORE #ifdef FDT #include #endif @@ -49,8 +48,6 @@ arm_irq_memory_barrier(uintptr_t irq) #define ACPI_GPIO_XREF 3 #endif -#endif /* !LOCORE */ - #define INTR_ROOT_FIQ 1 #define INTR_ROOT_NUM 2 diff --git a/sys/sys/intr.h b/sys/sys/intr.h index 54e838e5015a..c1e440a9fa93 100644 --- a/sys/sys/intr.h +++ b/sys/sys/intr.h @@ -33,15 +33,12 @@ #error Need INTRNG for this file #endif -#ifndef LOCORE #include -#endif #define INTR_IRQ_INVALID 0xFFFFFFFF #define INTR_ROOT_IRQ 0 -#ifndef LOCORE enum intr_map_data_type { INTR_MAP_DATA_ACPI = 0, INTR_MAP_DATA_FDT, @@ -172,5 +169,4 @@ void intr_ipi_dispatch(u_int ipi); /* Main interrupt handler called from asm on most archs except riscv. */ void intr_irq_handler(struct trapframe *tf, uint32_t rootnum); -#endif /* !LOCORE */ #endif /* _SYS_INTR_H */