summaryrefslogtreecommitdiff
path: root/sys/dev/vnd.c
AgeCommit message (Collapse)Author
2004-03-043 buglets.Ted Unangst
if keylen < 0, bad things happen. large keys are useless, limit size and use stack for temp storage bzero of keyctx is unrelated to keylen, wipe whole thing. ok markus tdeval
2004-03-03Make sure than svnd read their disklabel as svnd, not vnd devices.Miod Vallat
ok tedu@
2004-02-15knfTed Unangst
2004-02-15new arg to disk_unbusy, to record separate read/write statistics.Ted Unangst
looked at by various, testing henning@ mcbride@ dan weeks mostly from netbsd via Pedro Martelletto <pbastos@rdc.puc-rio.br>
2003-10-17vndunit() wasn't quite right after last change, limiting vnds to 16.Ted Unangst
apply fix from tom cosgrove to get the full range.
2003-10-11bump minor gap for svnd devices, so more vnds are allowed.Ted Unangst
this change REQUIRES running MAKEDEV again after booting with a new kernel. with a hint from tom cosgrove. ok deraadt@ millert@
2003-08-15change arguments to suser. suser now takes the process, and a flagsTed Unangst
argument. old cred only calls user suser_ucred. this will allow future work to more flexibly implement the idea of a root process. looks like something i saw in freebsd, but a little different. use of suser_ucred vs suser in file system code should be looked at again, for the moment semantics remain unchanged. review and input from art@ testing and further review miod@
2003-06-02Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-04-19Some string cleanup: sprintf -> snprintf and magic numbers to sizeofKenneth R Westerback
(remember: d_[type|pack]name do not need terminating null). Take the opportunity to introduce some paranoia and check the device name lengths to make sure they fit, with appropriate errors if not. ok tedu@ tdeval@
2003-04-06The return value for bounds_check_with_label() is not set in stone, and itMiod Vallat
turns out that some arches will return (-1) in case of error, while others will return (0). Until we make our minds on this, make sure that callers of this function properly handle 0 or (-1) as failure. ok krw@
2003-02-25remove useless check.Ted Unangst
ok niklas@
2002-05-24Make sure that b_iodone handlers are called at splbio (and ↵Artur Grabowski
splassert(IPL_BIO) in all known callers, just to make sure).
2002-05-23Protect biodone calls with splbio.Artur Grabowski
2002-03-14First round of __P removal in sysTodd C. Miller
2001-12-19UBC was a disaster. It worked very good when it worked, but on someArtur Grabowski
machines or some configurations or in some phase of the moon (we actually don't know when or why) files disappeared. Since we've not been able to track down the problem in two weeks intense debugging and we need -current to be stable, back out everything to a state it had before UBC. We apologise for the inconvenience.
2001-12-07Make vnds larger than 2G work, mostly by Daniel Lucq <daniel@lucq.org>Niklas Hallqvist
toouches by me.
2001-11-27Merge in the unified buffer cache code as found in NetBSD 2001/03/10. TheArtur Grabowski
code is written mostly by Chuck Silvers <chuq@chuq.com>/<chs@netbsd.org>. Tested for the past few weeks by many developers, should be in a pretty stable state, but will require optimizations and additional cleanups.
2001-11-15Remove creds from struct buf, move the creds that nfs need into the nfs node.Artur Grabowski
While in the area, convert nfs node allocation from malloc to pool and do some cleanups. Based on the UBC changes in NetBSD. niklas@ ok.
2000-07-05Make return statements adhere to KNFNiklas Hallqvist
2000-06-26let svnd deal with sparse files, okay art@ deraadt@Niels Provos
2000-06-22on unconfig, bzero the key before free; from aazubel@core-sdi.com.Federico G. Schwindt
2000-06-20add encryption for svnd's for Erich <hh@cyberpass.net>. You can do aNiels Provos
poor man's encrypted file system with this. Blame the Greek. okay niklas@
1998-10-03Add a "spoofonly" argument to readdisklabel() which will be used toTodd C. Miller
implement an ioctl to get a spoofed label even for disks that have a label on them.
1998-08-04make b_resid size_tTodd C. Miller
1998-03-10Clear dependcy list so we don't panic a soft updates kernel.Todd C. Miller
1997-11-06Updates for VFS Lite 2 + soft update.Constantine Sapuntzakis
1997-10-18avoid "no disklabel" error messagesTheo de Raadt
1997-10-06back out vfs lite2 till after 2.2Theo de Raadt
1997-10-06VFS Lite2 ChangesConstantine Sapuntzakis
1997-08-08Change the bounds_check_with_label API to also take a cpu_disklabelNiklas Hallqvist
reference for making transferral of meta-information possible from readdisklabel to bounds_check_with_label. The first (and maybe only) thing that will use this is the multi-disklabel-format code on the alpha where the labelsector is passed via cpu_disklabel so the label write-protection can work correctly no matter what label was found. Also use a new macro DKBAD to get at the dkbad field of the cpu_disklabel implementations that contain it. This too is for multi-disklabel architectures where the "bad" field can be inside a union. Use this macro as a means for a driver to check if an architecture supports dkbad constructs. Remove proto of bounds_check_with_label from all MD disklabel.h as it is in sys/disklabel.h. I have not been able to test the changes everywhere, if I break anything I apologize, and promise to fix it as soon as I become aware of it.
1997-06-09zone and constrain according to disklabel partition slots; part by ↵Theo de Raadt
gson@araneus.fi
1997-06-08init d_secperunit nicelyTheo de Raadt
1997-05-18null uio_procpTheo de Raadt
1997-05-17Make comment reflect reality and fix a typoTodd C. Miller
1997-05-17&proc0 should never be usedTheo de Raadt
1997-05-16Some buffers have NULL in b_proc when passed to vndstrategy,Niklas Hallqvist
however ffs_write needs a proc pointer in the uio structure, so fill in &proc0 to avoid a NULL deref
1997-05-14Add a new mode of operation: "safe" vnd, aka svnd, which goesNiklas Hallqvist
through the buffercache thus maintaining cache-coherency after unmount of a mounted vnd. This is good for diskimage creation, you should still use the old vnds for swapping on, though
1997-01-04readdisklabel() with correct dev_tTheo de Raadt
1996-12-21add disklabel supportTheo de Raadt
1996-04-21partial sync with netbsd 960418, more to comeTheo de Raadt
1996-03-02From NetBSD: sync with 960217 sourcesNiklas Hallqvist
1996-02-27From NetBSD: update to 960217 sourcesNiklas Hallqvist
1996-01-12from netbsd;Theo de Raadt
New generic disk framework. Highlights: New metrics handling. Metrics are now kept in the new `struct disk'. Busy time is now stored as a timeval, and transfer count in bytes. Storage for disklabels is now dynamically allocated, so that the size of the disk structure is not machine-dependent. Several new functions for attaching and detaching disks, and handling metrics calculation. Old-style instrumentation is still supported in drivers that did it before. However, old-style instrumentation is being deprecated, and will go away once the userland utilities are updated for the new framework. For usage and architectural details, see the forthcoming disk(9) manual page.
1995-12-14from netbsd:Theo de Raadt
Bring in several changes from the ccd: * Be a bit better with prototypes * Use struct dkdevice in vnd_softc. * Prevent the unit from being unconfigured while open. * Implement a simple locking mechanism and use it for sanity's sake. Still needs more work; needs to support disklabels and the like.
1995-10-18initial import of NetBSD treeTheo de Raadt