summaryrefslogtreecommitdiffstats
path: root/usr.sbin/burncd
diff options
context:
space:
mode:
authorrodrigc <rodrigc@FreeBSD.org>2011-10-09 21:42:02 +0000
committerrodrigc <rodrigc@FreeBSD.org>2011-10-09 21:42:02 +0000
commitc78f4c8ed16ca19e4db3ef5375fdbd4c180cfbdf (patch)
tree16473b900b3a85275f2aa26cac205be19c9e2d2c /usr.sbin/burncd
parent0616806cd05505bb43dc4c0bc664c801fdb9e539 (diff)
downloadFreeBSD-src-c78f4c8ed16ca19e4db3ef5375fdbd4c180cfbdf.zip
FreeBSD-src-c78f4c8ed16ca19e4db3ef5375fdbd4c180cfbdf.tar.gz
Add a "kern.features.ata_cam" sysctl in the kernel when the ATA_CAM kernel
option is defined. This sysctl can be queried by feature_present(3). Query for this feature in /sbin/atacontrol and /usr/sbin/burncd. If these utilities detect that ATA_CAM is enabled, then these utilities will error out. These utilities are compatible with the old ATA driver, but are incomptible with the new ATA_CAM driver. By erroring out, we give end-users an idea as to what remedies to use, and reduce the need for them to file PR's. For atacontrol, camcontrol must be used instead, and for burncd, alternative utilties from the ports collection must be used such as sysutils/cdrtools. In future, maybe someone can re-write burncd to work with ATA_CAM, but at least for now, we give a somewhat useful error message to end users. PR: 160979 Reviewed by: jh, Arnaud Lacombe <lacombar at gmail dot com> Reported by: Joe Barbish <fbsd8 at a1poweruser dot com> MFC after: 3 days
Diffstat (limited to 'usr.sbin/burncd')
-rw-r--r--usr.sbin/burncd/burncd.829
-rw-r--r--usr.sbin/burncd/burncd.c7
2 files changed, 35 insertions, 1 deletions
diff --git a/usr.sbin/burncd/burncd.8 b/usr.sbin/burncd/burncd.8
index e2996ba..64387c3 100644
--- a/usr.sbin/burncd/burncd.8
+++ b/usr.sbin/burncd/burncd.8
@@ -27,12 +27,19 @@
.\"
.\" $FreeBSD$
.\"
-.Dd December 21, 2009
+.Dd October 9, 2011
.Dt BURNCD 8
.Os
.Sh NAME
.Nm burncd
.Nd control the ATAPI CD-R/RW driver
+.Pp
+This utility was
+.Em deprecated
+in
+.Fx 9.0 .
+See
+.Sx NOTES .
.Sh SYNOPSIS
.Nm
.Op Fl deFlmnpqtv
@@ -211,6 +218,10 @@ The
.Nm
utility appeared in
.Fx 4.0 .
+.Pp
+.Nm
+was deprecated in
+.Fx 9.0 .
.Sh AUTHORS
The
.Nm
@@ -220,3 +231,19 @@ Denmark
.Aq sos@FreeBSD.org .
.Sh BUGS
Probably, please report when found.
+.Sh NOTES
+When
+.Bd -ragged -offset indent
+.Cd "options ATA_CAM"
+.Ed
+.Pp
+is compiled into the kernel, then
+.Xr cdrecord 1 ,
+available in the
+.Fx
+Ports Collection as part of the
+.Pa sysutils/cdrtools
+port, must be used instead.
+Refer to:
+.Pp
+http://www.freebsd.org/doc/handbook/creating-cds.html#CDRECORD
diff --git a/usr.sbin/burncd/burncd.c b/usr.sbin/burncd/burncd.c
index 43a0a09..ab31997 100644
--- a/usr.sbin/burncd/burncd.c
+++ b/usr.sbin/burncd/burncd.c
@@ -82,6 +82,13 @@ main(int argc, char **argv)
int block_size = 0, block_type = 0, cdopen = 0, dvdrw = 0;
const char *dev, *env_speed;
+ if (feature_present("ata_cam")) {
+ errx(1, "\nATA_CAM option is enabled in kernel.\n"
+ "Install the sysutils/cdrtools port and use cdrecord instead.\n\n"
+ "Please refer to:\n"
+ "http://www.freebsd.org/doc/handbook/creating-cds.html#CDRECORD");
+ }
+
if ((dev = getenv("CDROM")) == NULL)
dev = "/dev/acd0";
OpenPOWER on IntegriCloud