diff options
author | 諏訪子 <suwako@076.moe> | 2024-06-22 00:05:39 +0900 |
---|---|---|
committer | 諏訪子 <suwako@076.moe> | 2024-06-22 00:05:39 +0900 |
commit | 9589610848271187a59d3a6fffeb966f282fe6c6 (patch) | |
tree | ac8727f51cc322aaaedba785f13b9475e3dfcb47 /src | |
parent | fab26582abedc53175117287ac925bb88e3b5ff3 (diff) |
NetBSD: ストレージとGPUの修正
Diffstat (limited to 'src')
-rw-r--r-- | src/gpu.c | 2 | ||||
-rw-r--r-- | src/storage.c | 5 |
2 files changed, 7 insertions, 0 deletions
@@ -42,8 +42,10 @@ const char *display_gpu() { "elif [ \"$(dmesg | grep \"viadrmums.* at drm.*\")\" ]; " "then grep -i \"viadrmums.* at drm.*\"; " "else grep -i \"graphics\"; fi | " + "sed 's/^.*: //' | " "sed 's/^.* \"//' | " "sed 's/\".*$//' | head -1"); + // [ 1.018778] i915drmkms0 at pci0 dev 2 function 0: Intel HD Graphics 5500 (rev. 0x09) #elif defined(__FreeBSD__) || defined(__DragonFly__) return run_command_s("pciconf -lv | grep -B 4 -F \"VGA\" | " "grep -F \"device\" | sed 's/^.* device//' | " diff --git a/src/storage.c b/src/storage.c index 096d5db..b43529e 100644 --- a/src/storage.c +++ b/src/storage.c @@ -11,6 +11,11 @@ const char *display_storage() { "sh: command not found: zpool", strlen("sh: command not found: zpool") ) == 0 || + strncmp( + iszfs, + "internal error: failed to initialize ZFS library", + strlen("internal error: failed to initialize ZFS library") + ) == 0 || strncmp(iszfs, "sh: zpool: not found", strlen("sh: zpool: not found") ) == 0) { return run_command_s("df -h | " |