aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/scd
Commit message (Collapse)AuthorAgeFilesLines
* Use __FBSDID().David E. O'Brien2003-08-242-2/+6
| | | | | | | Also some minor style cleanups. Notes: svn path=/head/; revision=119419
* Don't include <sys/disklabel.h>Poul-Henning Kamp2003-04-161-1/+0
| | | | Notes: svn path=/head/; revision=113581
* Use bioq_flush() to drain a bio queue with a specific error code.Poul-Henning Kamp2003-04-011-1/+1
| | | | | | | | | | | Retain the mistake of not updating the devstat API for now. Spell bioq_disksort() consistently with the remaining bioq_*(). #include <geom/geom_disk.h> where this is more appropriate. Notes: svn path=/head/; revision=112946
* Gigacommit to improve device-driver source compatibility betweenPoul-Henning Kamp2003-03-031-13/+8
| | | | | | | | | | | | | | | | branches: Initialize struct cdevsw using C99 sparse initializtion and remove all initializations to default values. This patch is automatically generated and has been tested by compiling LINT with all the fields in struct cdevsw in reverse order on alpha, sparc64 and i386. Approved by: re(scottl) Notes: svn path=/head/; revision=111815
* Replace {disable,enable}_intr() with critical_{enter,exit}().Matthew N. Dodd2002-11-101-2/+2
| | | | Notes: svn path=/head/; revision=106719
* Whitespace, style fixes.Matthew N. Dodd2002-11-061-124/+99
| | | | Notes: svn path=/head/; revision=106490
* Remove undefined variable.Matthew N. Dodd2002-11-051-1/+1
| | | | | | | Somehow this didn't make it in the last commits. Notes: svn path=/head/; revision=106453
* Style/whitespace changes.Matthew N. Dodd2002-11-051-82/+78
| | | | Notes: svn path=/head/; revision=106451
* Fix for GEOM.Matthew N. Dodd2002-11-052-56/+11
| | | | | | | Tested on: i386 Notes: svn path=/head/; revision=106450
* - Convert to newbus, bus_space etc.Matthew N. Dodd2002-11-054-391/+587
| | | | | | | | | - Move to MI space. Tested on: i386 Notes: svn path=/head/; revision=106449
* Remove duplicate make_dev() calls.Matthew N. Dodd2002-10-041-4/+0
| | | | Notes: svn path=/head/; revision=104448
* If GEOM is in the kernel, take these three out. I have no way ofPoul-Henning Kamp2002-09-301-0/+3
| | | | | | | | | | | testing any modifications to them, they shouldn't even bother with disklabels in the first place and they are just plain obsolete old hardware which should be axed entirely before 5.0-R IMO. Sponsored by: DARPA & NAI Labs. Notes: svn path=/head/; revision=104210
* Replace various spelling with FALLTHROUGH which is lint()ablePhilippe Charnier2002-08-251-1/+1
| | | | Notes: svn path=/head/; revision=102412
* Fix typo in the BSD copyright: s/withough/without/Jens Schweikhardt2002-06-021-1/+1
| | | | | | | | Spotted and suggested by: des MFC after: 3 weeks Notes: svn path=/head/; revision=97748
* Retire the bogus ioctl DIOCGPART in toto.Poul-Henning Kamp2002-04-021-5/+0
| | | | | | | | | | Once again we can notice that badly thought out hacks ferment and infect far more code than initially expected. Sponsored by: DARPA and NAI Labs. Notes: svn path=/head/; revision=93657
* Don't call cdevsw_add()Poul-Henning Kamp2001-11-041-4/+0
| | | | Notes: svn path=/head/; revision=86010
* KSE Milestone 2Julian Elischer2001-09-121-3/+3
| | | | | | | | | | | | | | | | | Note ALL MODULES MUST BE RECOMPILED make the kernel aware that there are smaller units of scheduling than the process. (but only allow one thread per process at this time). This is functionally equivalent to teh previousl -current except that there is a thread associated with each process. Sorry john! (your next MFC will be a doosie!) Reviewed by: peter@freebsd.org, dillon@freebsd.org X-MFC after: ha ha ha ha Notes: svn path=/head/; revision=83366
* Send the remains (such as I have located) of "block major numbers" toPoul-Henning Kamp2001-03-261-2/+1
| | | | | | | the bit-bucket. Notes: svn path=/head/; revision=74810
* Remove unneeded #include <machine/clock.h>Poul-Henning Kamp2000-10-151-1/+0
| | | | Notes: svn path=/head/; revision=67164
* Mass update of isa drivers using compatability shims to usePeter Wemm2000-05-281-2/+9
| | | | | | | COMPAT_ISA_DRIVER() so that we can get rid of the evil isa_compat.h table. Notes: svn path=/head/; revision=61011
* Separate the struct bio related stuff out of <sys/buf.h> intoPoul-Henning Kamp2000-05-051-1/+1
| | | | | | | | | | | | | | | | | | <sys/bio.h>. <sys/bio.h> is now a prerequisite for <sys/buf.h> but it shall not be made a nested include according to bdes teachings on the subject of nested includes. Diskdrivers and similar stuff below specfs::strategy() should no longer need to include <sys/buf.> unless they need caching of data. Still a few bogus uses of struct buf to track down. Repocopy by: peter Notes: svn path=/head/; revision=60041
* Complete the bio/buf divorce for all code below devfs::strategyPoul-Henning Kamp2000-04-151-32/+32
| | | | | | | | | | | | | Exceptions: Vinum untouched. This means that it cannot be compiled. Greg Lehey is on the case. CCD not converted yet, casts to struct buf (still safe) atapi-cd casts to struct buf to examine B_PHYS Notes: svn path=/head/; revision=59249
* Move B_ERROR flag to b_ioflags and call it BIO_ERROR.Poul-Henning Kamp2000-04-021-3/+3
| | | | | | | | | | | | | | | | (Much of this done by script) Move B_ORDERED flag to b_ioflags and call it BIO_ORDERED. Move b_pblkno and b_iodone_chain to struct bio while we transition, they will be obsoleted once bio structs chain/stack. Add bio_queue field for struct bio aware disksort. Address a lot of stylistic issues brought up by bde. Notes: svn path=/head/; revision=58934
* Remove B_READ, B_WRITE and B_FREEBUF and replace them with a newPoul-Henning Kamp2000-03-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | field in struct buf: b_iocmd. The b_iocmd is enforced to have exactly one bit set. B_WRITE was bogusly defined as zero giving rise to obvious coding mistakes. Also eliminate the redundant struct buf flag B_CALL, it can just as efficiently be done by comparing b_iodone to NULL. Should you get a panic or drop into the debugger, complaining about "b_iocmd", don't continue. It is likely to write on your disk where it should have been reading. This change is a step in the direction towards a stackable BIO capability. A lot of this patch were machine generated (Thanks to style(9) compliance!) Vinum users: Greg has not had time to test this yet, be careful. Notes: svn path=/head/; revision=58345
* Remove #if NFOO > 0 (it's not required in most cases) and also where itPeter Wemm2000-01-291-3/+0
| | | | | | | | isn't used as a result, remove #include "foo.h". Many of these drivers still use NFOO for softc struct sizing etc however. Notes: svn path=/head/; revision=56843
* Remove five now unused fields from struct cdevsw. They should neverPoul-Henning Kamp1999-09-251-5/+0
| | | | | | | | | | | have been there in the first place. A GENERIC kernel shrinks almost 1k. Add a slightly different safetybelt under nostop for tty drivers. Add some missing FreeBSD tags Notes: svn path=/head/; revision=51658
* Trying to set BAD144 handling on a CD is sufficiently "Dont Do ThatPoul-Henning Kamp1999-09-201-3/+0
| | | | | | | then" that we don't need to give the ioctl special treatment. Notes: svn path=/head/; revision=51468
* Changes to centralise the default blocksize behaviour.Julian Elischer1999-09-091-2/+2
| | | | | | | | | More likely to follow. Submitted by: phk@freebsd.org Notes: svn path=/head/; revision=51111
* Set si_bsize_phys and si_bsize_max in all legacy CD drivers.Poul-Henning Kamp1999-09-011-0/+2
| | | | Notes: svn path=/head/; revision=50748
* $Id$ -> $FreeBSD$Peter Wemm1999-08-282-2/+2
| | | | Notes: svn path=/head/; revision=50477
* Convert DEVFS hooks in (most) drivers to make_dev().Poul-Henning Kamp1999-08-231-29/+9
| | | | | | | | | | | | | | | | | | | Diskslice/label code not yet handled. Vinum, i4b, alpha, pc98 not dealt with (left to respective Maintainers) Add the correct hook for devfs to kern_conf.c The net result of this excercise is that a lot less files depends on DEVFS, and devtoname() gets more sensible output in many cases. A few drivers had minor additional cleanups performed relating to cdevsw registration. A few drivers don't register a cdevsw{} anymore, but only use make_dev(). Notes: svn path=/head/; revision=50254
* Simplify cdevsw registration.Poul-Henning Kamp1999-05-311-16/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The cdevsw_add() function now finds the major number(s) in the struct cdevsw passed to it. cdevsw_add_generic() is no longer needed, cdevsw_add() does the same thing. cdevsw_add() will print an message if the d_maj field looks bogus. Remove nblkdev and nchrdev variables. Most places they were used bogusly. Instead check a dev_t for validity by seeing if devsw() or bdevsw() returns NULL. Move bdevsw() and devsw() functions to kern/kern_conf.c Bump __FreeBSD_version to 400006 This commit removes: 72 bogus makedev() calls 26 bogus SYSINIT functions if_xe.c bogusly accessed cdevsw[], author/maintainer please fix. I4b and vinum not changed. Patches emailed to authors. LINT probably broken until they catch up. Notes: svn path=/head/; revision=47640
* This commit should be a extensive NO-OP:Poul-Henning Kamp1999-05-301-6/+21
| | | | | | | | | | | | | | | | Reformat and initialize correctly all "struct cdevsw". Initialize the d_maj and d_bmaj fields. The d_reset field was not removed, although it is never used. I used a program to do most of this, so all the files now use the same consistent format. Please keep it that way. Vinum and i4b not modified, patches emailed to respective authors. Notes: svn path=/head/; revision=47625
* don't confuse units and devices.Poul-Henning Kamp1999-05-091-6/+4
| | | | Notes: svn path=/head/; revision=46833
* Introduce two functions: physread() and physwrite() and use these directlyPoul-Henning Kamp1999-05-071-9/+2
| | | | | | | | | in *devsw[] rather than the 46 local copies of the same functions. (grog will do the same for vinum when he has time) Notes: svn path=/head/; revision=46625
* Missing 'int' in declaration of variables.Peter Wemm1999-05-061-2/+2
| | | | Notes: svn path=/head/; revision=46573
* s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/.Dmitrij Tejblum1999-04-281-2/+2
| | | | | | | (Edited automatically) Notes: svn path=/head/; revision=46153
* Move a couple of functions to make __inline work. While I'm here,Eivind Eklund1999-01-121-9/+10
| | | | | | | | split a couple of function declarations to make the style internally consistent. Notes: svn path=/head/; revision=42552
* Fixed printf format errors (only 1 left in GENERIC now).Bruce Evans1998-07-131-5/+6
| | | | Notes: svn path=/head/; revision=37618
* There is no such thing any more as "struct bdevsw".Julian Elischer1998-07-041-8/+18
| | | | | | | | | | | | | | | | | | | | | There is only cdevsw (which should be renamed in a later edit to deventry or something). cdevsw contains the union of what were in both bdevsw an cdevsw entries. The bdevsw[] table stiff exists and is a second pointer to the cdevsw entry of the device. it's major is in d_bmaj rather than d_maj. some cleanup still to happen (e.g. dsopen now gets two pointers to the same cdevsw struct instead of one to a bdevsw and one to a cdevsw). rawread()/rawwrite() went away as part of this though it's not strictly the same patch, just that it involves all the same lines in the drivers. cdroms no longer have write() entries (they did have rawwrite (?)). tapes no longer have support for bdev operations. Reviewed by: Eivind Eklund and Mike Smith Changes suggested by eivind. Notes: svn path=/head/; revision=37389
* Fixed pedantic semantics errors (bitfields not of type int, signed intBruce Evans1998-06-081-3/+3
| | | | | | | | | | or unsigned int (this doesn't change the struct layout, size or alignment in any of the files changed in this commit, at least for gcc on i386's. Using bitfields of type u_char may affect size and alignment but not packing)). Notes: svn path=/head/; revision=36767
* This commit fixes various 64bit portability problems required forDoug Rabson1998-06-071-2/+2
| | | | | | | | | | | | | FreeBSD/alpha. The most significant item is to change the command argument to ioctl functions from int to u_long. This change brings us inline with various other BSD versions. Driver writers may like to use (__FreeBSD_version == 300003) to detect this change. The prototype FreeBSD/alpha machdep will follow in a couple of days time. Notes: svn path=/head/; revision=36735
* Support compiling with `gcc -ansi'.Bruce Evans1998-04-151-3/+3
| | | | Notes: svn path=/head/; revision=35210
* Make all file-system (MFS, FFS, NFS, LFS, DEVFS) related option new-style.Eivind Eklund1998-01-241-1/+2
| | | | | | | | | | | This introduce an xxxFS_BOOT for each of the rootable filesystems. (Presently not required, but encouraged to allow a smooth move of option *FS to opt_dontuse.h later.) LFS is temporarily disabled, and will be re-enabled tomorrow. Notes: svn path=/head/; revision=32726
* In all such uses of struct buf: 's/b_un.b_addr/b_data/g'Poul-Henning Kamp1997-12-021-2/+2
| | | | Notes: svn path=/head/; revision=31493
* aha1542.c aic6360.c cy.c fd.c ft.cJustin T. Gibbs1997-09-211-26/+29
| | | | | | | | | | | | | | | if_ie.c if_wl.c if_zp.c isa.c isa_device.h labpc.c mcd.c ncr5380.c scd.c seagate.c si.c sio.c tw.c ultra14f.c wcd.c wd.c: Update for changes in the callout interface. apic_vector.s icu_vector.s ipl.s ipl_funcs.c: Add CAM software/hardware interrupt support. Notes: svn path=/head/; revision=29677
* Removed unused #includes.Bruce Evans1997-07-201-7/+1
| | | | Notes: svn path=/head/; revision=27555
* Add the D_DISK flag to the cdevsw structs of various CD-ROM drivers.Joerg Wunsch1997-05-101-2/+2
| | | | Notes: svn path=/head/; revision=25657
* This mega-commit brings the following:Joerg Wunsch1997-05-041-1/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | . It makes cd9660 root f/s working again. . It makes CD9660 a new-style option. . It adds support to mount an ISO9660 multi-session CD-ROM as the root filesystem (the last session actually, but that's what is expected behaviour). Sigh. The CDIOREADTOCENTRYS did a copyout() of its own, and thus has been unusable for me for this work. Too bad it didn't simply stuff the max 100 entries into the struct ioc_read_toc_entry, but relied on a user supplied data buffer instead. :-( I now had to reinvent the wheel, and created a CDIOREADTOCENTRY ioctl command that can be used in a kernel context. While doing this, i noticed the following bogosities in existing CD-ROM drivers: wcd: This driver is likely to be totally bogus when someone tries two succeeding CDIOREADTOCENTRYS (or now CDIOREADTOCENTRY) commands with requesting MSF format, since it apparently operates on an internal table. scd: This driver apparently returns just a single TOC entry only for the CDIOREADTOCENTRYS command. I have only been able to test the CDIOREADTOCENTRY command with the cd(4) driver. I hereby request the respective maintainers of the other CD-ROM drivers to verify my code for their driver. When it comes to merging this CD-ROM multisession stuff into RELENG_2_2 i will only consider drivers where i've got a confirmation that it actually works. Notes: svn path=/head/; revision=25460
* Fixed the type of timeout functions and removed casts that hid theBruce Evans1997-04-201-14/+21
| | | | | | | | | | | | type mismatches. mcd and scd were/are particularly bogus. They used a general purpose function taking 2 args for the timeout function and fudged varargs stuff to supply the second arg for the timeout case. This broke `cc -mrtd'. Bounce through a timeout function instead. The timeout arg still gets bogusly cast from int to `void *' and back. Notes: svn path=/head/; revision=25056