git: f40cd16bfda4 - main - kern: Move devctl_systems[] out of sys/sys/devctl.h
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 08 Jun 2023 16:30:54 UTC
The branch main has been updated by emaste:
URL: https://cgit.FreeBSD.org/src/commit/?id=f40cd16bfda4f4512033bb9e7212ee5d8b94b9a7
commit f40cd16bfda4f4512033bb9e7212ee5d8b94b9a7
Author: Ed Maste <emaste@FreeBSD.org>
AuthorDate: 2023-06-08 13:58:26 +0000
Commit: Ed Maste <emaste@FreeBSD.org>
CommitDate: 2023-06-08 16:28:04 +0000
kern: Move devctl_systems[] out of sys/sys/devctl.h
The amd64-gcc12 build was failing with `error: 'devctl_systems' defined
but not used`. Just move it to the C file where it's used.
PR: 271903
Sponsored by: The FreeBSD Foundation
---
sys/netlink/netlink_sysevent.c | 23 +++++++++++++++++++++++
sys/sys/devctl.h | 23 -----------------------
2 files changed, 23 insertions(+), 23 deletions(-)
diff --git a/sys/netlink/netlink_sysevent.c b/sys/netlink/netlink_sysevent.c
index 9da72a121ecd..01d0837b14d2 100644
--- a/sys/netlink/netlink_sysevent.c
+++ b/sys/netlink/netlink_sysevent.c
@@ -53,6 +53,29 @@ static struct sysevent_group {
uint32_t id;
} sysevent_groups[MAX_SYSEVENT_GROUPS] = {};
+static const char *devctl_systems[] = {
+ "ACPI",
+ "AEON",
+ "CAM",
+ "CARP",
+ "coretemp",
+ "DEVFS",
+ "device",
+ "ETHERNET",
+ "GEOM",
+ "HYPERV_NIC_VF",
+ "IFNET",
+ "INFINIBAND",
+ "KERNEL",
+ "nvme",
+ "PMU",
+ "RCTL",
+ "USB",
+ "VFS",
+ "VT",
+ "ZFS",
+};
+
static void
sysevent_write(struct sysevent_group *se, const char *subsystem, const char *type,
const char *data)
diff --git a/sys/sys/devctl.h b/sys/sys/devctl.h
index 5b613cf427df..da26eaabc26c 100644
--- a/sys/sys/devctl.h
+++ b/sys/sys/devctl.h
@@ -13,29 +13,6 @@
* hook to send the message.
*/
-static const char *devctl_systems[] = {
- "ACPI",
- "AEON",
- "CAM",
- "CARP",
- "coretemp",
- "DEVFS",
- "device",
- "ETHERNET",
- "GEOM",
- "HYPERV_NIC_VF",
- "IFNET",
- "INFINIBAND",
- "KERNEL",
- "nvme",
- "PMU",
- "RCTL",
- "USB",
- "VFS",
- "VT",
- "ZFS",
-};
-
bool devctl_process_running(void);
void devctl_notify(const char *__system, const char *__subsystem,
const char *__type, const char *__data);