summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author諏訪子 <suwako@076.moe>2024-06-19 22:50:17 +0900
committer諏訪子 <suwako@076.moe>2024-06-19 22:50:17 +0900
commitea757665d051d6330caf236e9cbb7b14312bc8c6 (patch)
treeb457cb002a0066ef13ac413d0aa4066d768626d7
parent5708db2ffff3592f58107d50716a52ac9adff301 (diff)
NetBSD: GPU情報の表示
-rw-r--r--src/gpu.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gpu.c b/src/gpu.c
index ea69841..5873dd5 100644
--- a/src/gpu.c
+++ b/src/gpu.c
@@ -44,6 +44,9 @@ const char *display_gpu() {
#if defined(__OpenBSD__)
return run_gpu_command("dmesg | grep -i graphics | sed 's/^.* \"//' | "
"sed 's/\".*$//'");
+#elif defined(__NetBSD__)
+ return run_gpu_command("dmesg | grep -i graphics | sed 's/^.*: //' | "
+ "sed 's/ (.*$//'");
#elif defined(__FreeBSD__) || defined(__DragonFly__)
return run_gpu_command("pciconf -lv | grep -B 4 -F \"VGA\" | "
"grep -F \"device\" | sed 's/^.* device//' | "