diff options
author | avg <avg@FreeBSD.org> | 2010-10-11 09:27:37 +0000 |
---|---|---|
committer | avg <avg@FreeBSD.org> | 2010-10-11 09:27:37 +0000 |
commit | 2c6068194e36b120c621126818a018bcc1a5deda (patch) | |
tree | 319e6771ec96d6267eacbb3f052cbbf379a12a37 /lib/libcam/cam.3 | |
parent | a439b1697175031d7107049552fe05df636a7d4f (diff) | |
download | FreeBSD-src-2c6068194e36b120c621126818a018bcc1a5deda.zip FreeBSD-src-2c6068194e36b120c621126818a018bcc1a5deda.tar.gz |
cam_get_device, cam_open_device: make behavior simpler and more deterministic
Remove or re-work support for the several features from the past:
- remove incomplete support for trimming slice/partition names
- remove mapping from old device names "sd" and "st"
- remove whitespace trimming
- remove unconditional skipping of leading 'r' in a device name
- skip leading 'n' or 'e' only if the following device name matches
a list of known devices that support no-rewind and eject-on-close
features; currently this is only sa(4)
- reflect the above changes in comments in code and in cam(3)
- remove a note cautioning against use of cam_get_device and
cam_open_device in cam(3)
Reviewed by: mjacob
Diffstat (limited to 'lib/libcam/cam.3')
-rw-r--r-- | lib/libcam/cam.3 | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/lib/libcam/cam.3 b/lib/libcam/cam.3 index 25328c2..c11d8fd 100644 --- a/lib/libcam/cam.3 +++ b/lib/libcam/cam.3 @@ -190,12 +190,6 @@ into a device name and unit number. Once the device name and unit number are determined, a lookup is performed to determine the passthrough device that corresponds to the given device. -.Fn cam_open_device -is rather simple to use, but it is not really suitable for general use -because its behavior is not necessarily deterministic. -Programmers writing -new applications should make the extra effort to use one of the other open -routines documented below. .Pp .Fn cam_open_spec_device opens the @@ -354,19 +348,15 @@ respectively. can handle strings of the following forms, at least: .Pp .Bl -tag -width 1234 -compact -.It /dev/foo0a -.It /dev/foo1s2c +.It /dev/foo1 .It foo0 -.It foo0a -.It nfoo0 +.It nsa2 .El .Pp .Fn cam_get_device is provided as a convenience function for applications that need to provide functionality similar to .Fn cam_open_device . -Programmers are encouraged to use more deterministic methods of obtaining -device names and unit numbers if possible. .Sh RETURN VALUES .Fn cam_open_device , .Fn cam_open_spec_device , |