Date: Sat, 14 Jan 2006 14:32:41 +0000 (UTC) From: Matt Jacob <mjacob@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/cam/scsi scsi_sa.c Message-ID: <200601141432.k0EEWglh077342@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
mjacob 2006-01-14 14:32:41 UTC
FreeBSD src repository
Modified files:
sys/cam/scsi scsi_sa.c
Log:
Incorporate the O_NONBLOCK open semantics of Linux and Solaris. This allows
an application to upon a tape (yea, even the non-control device) even if
it cannot establish a mount session. If the open cannot establish a mount
session and O_NONBLOCK was specified, the tape becomes 'open pending mount'.
All I/O operations that would require access to a tape thereafter until
a close attempt to initiate the mount session. If the mount session succeeds,
the tape driver transitions to full open state, else returns an appropriate
I/O error (ENXIO).
At the same time, add a change that remembers whether tape is being opened
read-only. If so, disallow 'write' operations like writing filemarks that
bypass the normal read-only filtering operations that happen in the write(2)
syscall.
Reviewed by: ken, justin, grog
MFC after: 2 weeks
Suggested by: The Bacula Team
Revision Changes Path
1.106 +87 -6 src/sys/cam/scsi/scsi_sa.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200601141432.k0EEWglh077342>
