aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorarrowd <arrowd@FreeBSD.org>2019-11-02 14:25:27 +0800
committerarrowd <arrowd@FreeBSD.org>2019-11-02 14:25:27 +0800
commita6579720bfb166f73f75966aa08b28b554132b8e (patch)
tree8c8454bb121c2706115a7d3e504e95409478b96c
parent1ac827458ec5ff8b7b762cda8b4ec12ebdb57a2c (diff)
downloadfreebsd-ports-gnome-a6579720bfb166f73f75966aa08b28b554132b8e.tar.gz
freebsd-ports-gnome-a6579720bfb166f73f75966aa08b28b554132b8e.tar.zst
freebsd-ports-gnome-a6579720bfb166f73f75966aa08b28b554132b8e.zip
sysutils/bsdisks: Add a patch to handle NVMe drives properly.
PR: 241645 Submitted by: cmt
-rw-r--r--sysutils/bsdisks/Makefile1
-rw-r--r--sysutils/bsdisks/files/patch-camcontrol.c16
2 files changed, 17 insertions, 0 deletions
diff --git a/sysutils/bsdisks/Makefile b/sysutils/bsdisks/Makefile
index 0f324f514da0..3c739dd89fd0 100644
--- a/sysutils/bsdisks/Makefile
+++ b/sysutils/bsdisks/Makefile
@@ -2,6 +2,7 @@
PORTNAME= bsdisks
DISTVERSION= 0.9
+PORTREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= https://bitbucket.org/arrowd/bsdisks/downloads/
diff --git a/sysutils/bsdisks/files/patch-camcontrol.c b/sysutils/bsdisks/files/patch-camcontrol.c
new file mode 100644
index 000000000000..3cf169b0deaa
--- /dev/null
+++ b/sysutils/bsdisks/files/patch-camcontrol.c
@@ -0,0 +1,16 @@
+--- camcontrol.c.orig 2019-09-08 10:38:26 UTC
++++ camcontrol.c
+@@ -166,9 +166,11 @@ int cam_is_removable(const char* device_path)
+ int timeout = 0, retry_count = 1;
+ int unit = 0;
+
+- if (cam_get_device(device_path, name, sizeof name, &unit)
+- == -1)
++ if (cam_get_device(device_path, name, sizeof name, &unit) == -1)
++ {
+ errx(1, "%s", cam_errbuf);
++ return (-1);
++ }
+
+ if ((cam_dev = cam_open_spec_device(device,unit,O_RDWR,NULL))
+ == NULL)