Start FreeBSD driver test. Not currently working though.

freebsd.cam: check for error in ioctl.
This commit is contained in:
R. Bernstein
2010-01-06 02:15:32 -05:00
parent d675551d19
commit f7d11d586c
5 changed files with 117 additions and 3 deletions

View File

@@ -122,8 +122,9 @@ init_freebsd_cam (_img_private_t *p_env)
return false;
}
(void)ioctl(p_env->gen.fd, CDIOCALLOW);
if (ioctl(p_env->gen.fd, CDIOCALLOW) == -1) {
cdio_warn("ioctl(fd, CDIOCALLOW) failed: %s\n", strerror(errno));
}
if (ioctl (p_env->gen.fd, CAMGETPASSTHRU, &p_env->ccb) < 0)
{
cdio_warn ("open: %s", strerror (errno));