aboutsummaryrefslogtreecommitdiff
path: root/sys/contrib/dev/fla/fla.c
Commit message (Collapse)AuthorAgeFilesLines
* Send the fla driver in the AtticPoul-Henning Kamp2004-07-131-288/+0
| | | | Notes: svn path=/head/; revision=132113
* Do the dreaded s/dev_t/struct cdev */Poul-Henning Kamp2004-06-161-1/+1
| | | | | | | Bump __FreeBSD_version accordingly. Notes: svn path=/head/; revision=130585
* Change the disk(9) API in order to make device removal more robust.Poul-Henning Kamp2004-02-181-12/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | Previously the "struct disk" were owned by the device driver and this gave us problems when the device disappared and the users of that device were not immediately disappearing. Now the struct disk is allocate with a new call, disk_alloc() and owned by geom_disk and just abandonned by the device driver when disk_create() is called. Unfortunately, this results in a ton of "s/\./->/" changes to device drivers. Since I'm doing the sweep anyway, a couple of other API improvements have been carried out at the same time: The Giant awareness flag has been flipped from DISKFLAG_NOGIANT to DISKFLAG_NEEDSGIANT A version number have been added to disk_create() so that we can detect, report and ignore binary drivers with old ABI in the future. Manual page update to follow shortly. Notes: svn path=/head/; revision=125975
* Use bioq_flush() to drain a bio queue with a specific error code.Poul-Henning Kamp2003-04-011-2/+2
| | | | | | | | | | | 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
* Including <sys/stdint.h> is (almost?) universally only to be able to usePoul-Henning Kamp2003-03-181-1/+0
| | | | | | | | %j in printfs, so put a newsted include in <sys/systm.h> where the printf prototype lives and save everybody else the trouble. Notes: svn path=/head/; revision=112367
* Centralize the devstat handling for all GEOM disk device driversPoul-Henning Kamp2003-03-081-9/+1
| | | | | | | | | | | in geom_disk.c. As a side effect this makes a lot of #include <sys/devicestat.h> lines not needed and some biofinish() calls can be reduced to biodone() again. Notes: svn path=/head/; revision=111979
* NO_GEOM cleanup:Poul-Henning Kamp2003-02-221-68/+16
| | | | | | | | | Move to "struct disk *" centric use of disk_* API. Remove NOOP ioctl, spl*() and some debug printfs. Notes: svn path=/head/; revision=111247
* Back out M_* changes, per decision of the TRB.Warner Losh2003-02-191-1/+1
| | | | | | | Approved by: trb Notes: svn path=/head/; revision=111119
* Mark our struct disk with DISKFLAG_CANDELETE instead of the cdevsw withPoul-Henning Kamp2003-02-111-1/+2
| | | | | | | D_CANFREE. Notes: svn path=/head/; revision=110694
* Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0.Alfred Perlstein2003-01-211-1/+1
| | | | | | | Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT. Notes: svn path=/head/; revision=109623
* (This commit touches about 15 disk device drivers in a very consistentPoul-Henning Kamp2002-09-201-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | and predictable way, and I apologize if I have gotten it wrong anywhere, getting prior review on a patch like this is not feasible, considering the number of people involved and hardware availability etc.) If struct disklabel is the messenger: kill the messenger. Inside struct disk we had a struct disklabel which disk drivers used to communicate certain metrics to the disklayer above (GEOM or the disk mini-layer). This commit changes this communication to use four explicit fields instead. Amongst the benefits is that the fields do not get overwritten by wrong or bogus on-disk disklabels. Once that is clear, <sys/disk.h> which is included in the drivers no longer need to pull <sys/disklabel.h> and <sys/diskslice.h> in, the few places that needs them, have gotten explicit #includes for them. The disklabel inside struct disk is now only for internal use in the disk mini-layer, so instead of embedding it, we malloc it as we need it. This concludes (modulus any mistakes) the series of disklabel related commits. I belive it all amounts to a NOP for all the rest of you :-) Sponsored by: DARPA & NAI Labs. Notes: svn path=/head/; revision=103714
* Don't call dkunit() to find our unit number, it is in our softc.Poul-Henning Kamp2002-09-201-1/+1
| | | | | | | Sponsored by: DARPA & NAI Labs. Notes: svn path=/head/; revision=103688
* fix blockno printf formatting warnings.Alfred Perlstein2002-03-191-4/+6
| | | | Notes: svn path=/head/; revision=92720
* KSE Milestone 2Julian Elischer2001-09-121-6/+6
| | | | | | | | | | | | | | | | | 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
* Actually biofinish(struct bio *, struct devstat *, int error) is more generalPoul-Henning Kamp2001-05-061-2/+1
| | | | | | | | | than the bioerror(). Most of this patch is generated by scripts. Notes: svn path=/head/; revision=76322
* Send the remains (such as I have located) of "block major numbers" toPoul-Henning Kamp2001-03-261-2/+0
| | | | | | | the bit-bucket. Notes: svn path=/head/; revision=74810
* Staticize some malloc M_ instances.Poul-Henning Kamp2000-12-081-1/+1
| | | | Notes: svn path=/head/; revision=69774
* Remove unneeded #include <machine/clock.h>Poul-Henning Kamp2000-10-151-1/+0
| | | | Notes: svn path=/head/; revision=67164
* remove unused #include.Poul-Henning Kamp2000-10-071-1/+0
| | | | Notes: svn path=/head/; revision=66795
* Remove SMP hack.Poul-Henning Kamp2000-09-161-6/+0
| | | | Notes: svn path=/head/; revision=65933
* Unused include: #include "fla.h"Peter Wemm2000-06-101-1/+0
| | | | Notes: svn path=/head/; revision=61483
* 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
* Enforce and respect the 8 unit limit.Poul-Henning Kamp2000-04-231-1/+3
| | | | Notes: svn path=/head/; revision=59532
* Complete the bio/buf divorce for all code below devfs::strategyPoul-Henning Kamp2000-04-151-22/+22
| | | | | | | | | | | | | 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-1/+1
| | | | | | | | | | | | | | | | (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-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | 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
* Revamp the devstat priority system. All disks now have the same priority.Kenneth D. Merry1999-12-081-1/+2
| | | | | | | | | | | | | | | | | | | | | The same goes for CD drivers and tape drivers. In systems with mixed IDE and SCSI, devices in the same priority class will be sorted in attach order. Also, the 'CCD' priority is now the 'ARRAY' priority, and a number of drivers have been modified to use that priority. This includes the necessary changes to all drivers, except the ATA drivers. Soren will modify those separately. This does not include and does not require any change in the devstat version number, since no known userland applications use the priority enumerations. Reviewed by: msmith, sos, phk, jlemon, mjacob, bde Notes: svn path=/head/; revision=54279
* * Add struct resource_list* argument to resource_list_alloc andDoug Rabson1999-10-121-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | resource_list_release. This removes the dependancy on the layout of ivars. * Move set_resource, get_resource and delete_resource from isa_if.m to bus_if.m. * Simplify driver code by providing wrappers to those methods: bus_set_resource(dev, type, rid, start, count); bus_get_resource(dev, type, rid, startp, countp); bus_get_resource_start(dev, type, rid); bus_get_resource_count(dev, type, rid); bus_delete_resource(dev, type, rid); * Delete isa_get_rsrc and use bus_get_resource_start instead. * Fix a stupid typo in isa_alloc_resource reported by Takahashi Yoshihiro <nyan@FreeBSD.org>. * Print a diagnostic message if we can't assign resources to a PnP device. * Change device_print_prettyname() so that it doesn't print "(no driver assigned)-1" for anonymous devices. Notes: svn path=/head/; revision=52174
* remove unused #includes.Poul-Henning Kamp1999-10-111-2/+0
| | | | Notes: svn path=/head/; revision=52134
* 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
* Use devstat_end_transaction_buf() rather than Use devstat_end_transaction()Poul-Henning Kamp1999-09-181-7/+4
| | | | Notes: svn path=/head/; revision=51376
* Bite the bullet and allocate the devsw entry at compile time.Poul-Henning Kamp1999-09-121-1/+2
| | | | Notes: svn path=/head/; revision=51215
* Use a different tactic when creating the devsw so that disk_create()Poul-Henning Kamp1999-09-121-1/+1
| | | | | | | doesn't need to malloc. Notes: svn path=/head/; revision=51198
* Improve the micro "disk" layer after gaining more experience with it.Poul-Henning Kamp1999-09-011-2/+1
| | | | Notes: svn path=/head/; revision=50728
* Remove unneeded slice element.Poul-Henning Kamp1999-08-291-1/+0
| | | | Notes: svn path=/head/; revision=50570
* Convert to use the new "disk" layer.Poul-Henning Kamp1999-08-291-106/+78
| | | | | | | A few cleanups while here. Notes: svn path=/head/; revision=50566
* We don't need to pass the diskname argument all over the diskslice/labelPoul-Henning Kamp1999-08-281-2/+2
| | | | | | | code, we can find the name from any convenient dev_t Notes: svn path=/head/; revision=50511
* $Id$ -> $FreeBSD$Peter Wemm1999-08-281-1/+1
| | | | Notes: svn path=/head/; revision=50480
* SMP: Release the giant lock while we work the flash arrayPoul-Henning Kamp1999-08-151-97/+40
| | | | | | | | | Use splbio() rather than fiddling the hardware interrupts. Remove the compatibility stuff for older FreeBSD versions. Add devstat support. Notes: svn path=/head/; revision=49847
* Spring cleaning around strategy and disklabels/slices:Poul-Henning Kamp1999-08-141-9/+9
| | | | | | | | | | | | | | | | | Introduce BUF_STRATEGY(struct buf *, int flag) macro, and use it throughout. please see comment in sys/conf.h about the flag argument. Remove strategy argument from all the diskslice/label/bad144 implementations, it should be found from the dev_t. Remove bogus and unused strategy1 routines. Remove open/close arguments from dssize(). Pick them up from dev_t. Remove unused and unfinished setgeom support from diskslice/label/bad144 code. Notes: svn path=/head/; revision=49771
* Fixed a bogus include pathname which broke compiling in an obj directory.Bruce Evans1999-08-071-2/+2
| | | | Notes: svn path=/head/; revision=49500
* Add driver support for M-systems DiskOnChip Products.Poul-Henning Kamp1999-08-061-0/+451
Sponsored by: M-systems Inc. http://www.m-sys.com Notes: svn path=/head/; revision=49467