summaryrefslogtreecommitdiffstats
path: root/sys/geom/geom_subr.c
Commit message (Collapse)AuthorAgeFilesLines
* Use __FBSDID().obrien2003-06-111-2/+2
| | | | Approved by: phk
* Drop a memory-corruption debugging test-tool.phk2003-06-071-13/+0
|
* Add missing va_end() calls.phk2003-06-071-2/+4
| | | | Noticed by: tmm
* Introduce g_provider_by_name() function, and use it.phk2003-06-041-0/+17
|
* Add a KASSERT to prevent the same GEOM class from being processed loadedphk2003-06-041-0/+6
| | | | | | twice. Enforce that classes should have different names while we are here.
* constify g_sanity()phk2003-06-011-1/+1
|
* Introduce a init and fini member functions on a class.phk2003-05-311-22/+100
| | | | | | | | | Use ->init() and ->fini() to handle the mutex in geom_disk.c Remove the g_add_class() function and replace it with a standardized g_modevent() function. This adds the basic infrastructure for loading/unloading GEOM classes
* Back out all the stuff that didn't belong in the last commit.phk2003-05-021-9/+12
|
* Use g_slice_spoiled() rather than g_std_spoiled().phk2003-05-021-12/+9
| | | | Remember to free the buffer we got from g_read_data().
* Rework the "withering" mechanism:phk2003-05-021-17/+46
| | | | Introduce g_wither_geom() to do the work in one single place.
* Remove the now obsolete geomidorname hack.phk2003-05-011-83/+0
|
* Remove now unneeded special case for "geom.ctl".phk2003-05-011-2/+0
|
* Rename g_call_me() to g_post_event(), and give it a flagphk2003-04-231-4/+5
| | | | argument to determine if we can M_WAITOK in malloc.
* Turn EV_NEW_PROVIDER into a g_call_me() event.phk2003-04-231-2/+31
|
* Convert EV_SPOILED event to use g_call_me().phk2003-04-231-1/+23
|
* Turn the hardwired NEW_CLASS event into a g_call_me() event.phk2003-04-231-2/+33
|
* Remove unused event pointers in object structures.phk2003-04-231-3/+0
| | | | Remove KASSERTS which checked that they were unused.
* Time has run from the "run GEOM in userland" harness, and the new regressionphk2003-04-131-11/+0
| | | | | | | test is built to test GEOM as running in the kernel. This commit is basically "unifdef -D_KERNEL" to remove the mainly #include related code to support the userland-harness.
* If we hit access ahead of a spoil event, we should have negativephk2003-04-121-7/+3
| | | | delta access-counts and proceed.
* Change events to have an array of "void *" references, and give thephk2003-04-021-7/+7
| | | | | | | | | | | event posting functions varargs to fill these. Attribute g_call_me() to appropriate g_geom's where necessary. Add a flag argument to g_call_me() methods which will be used to signal cancellation of events in the future. This commit should be a no-op.
* Only orphan things if the open/close actually succeeded.phk2003-04-021-11/+10
|
* g_class_by_name() was unused too.phk2003-03-251-13/+0
|
* Remove unuse g_insert_geom().phk2003-03-251-38/+0
|
* Introduce g_cancel_events() and use it a couple of places where it makesphk2003-03-231-0/+3
| | | | sense.
* Retire the GEOM private statistics code and use devstat instead.phk2003-03-181-4/+7
|
* Including <sys/stdint.h> is (almost?) universally only to be able to usephk2003-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.
* Remove unneeded #include of geom_stats.hphk2003-03-091-1/+0
|
* Don't use statistics counters to detect outstanding I/O.phk2003-03-091-1/+1
|
* Back out M_* changes, per decision of the TRB.imp2003-02-191-7/+7
| | | | Approved by: trb
* Implement a handle for efficient implementation of perforations inphk2003-02-121-3/+6
| | | | | | | | | | | | | lower extremities. Setting bit 4 in debugflags (sysctl kern.geom.debugflags=16) will allow any open to succeed on rank#1 providers. This will generally correspond to the physical disk devices: ad0, da0, md0 etc. This fundamentally violates the mechanics of GEOMs autoconfiguration, and is only provided as a debugging facility, so obviously error reports on GEOM where this bit is or has been set will not be accepted.
* Move the g_stat struct to its own .h file, we will export it to other code.phk2003-02-081-3/+7
| | | | | | | | | | | | | | | | | | Insted of embedding a struct g_stat in consumers and providers, merely include a pointer. Remove a couple of <sys/time.h> includes now unneeded. Add a special allocator for struct g_stat. This allocator will allocate entire pages and hand out g_stat functions from there. The "id" field indicates free/used status. Add "/dev/geom.stats" device driver whic exports the pages from the allocator to userland with mmap(2) in read-only mode. This mmap(2) interface should be considered a non-public interface and the functions in libgeom (not yet committed) should be used to access the statistics data.
* Commit the correct copy of the g_stat structure.phk2003-02-071-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add debug.sizeof.g_stat sysctl. Set the id field of the g_stat when we create consumers and providers. Remove biocount from consumer, we will use the counters in the g_stat structure instead. Replace one field which will need to be atomically manipulated with two fields which will not (stat.nop and stat.nend). Change add companion field to bio_children: bio_inbed for the exact same reason. Don't output the biocount in the confdot output. Fix KASSERT in g_io_request(). Add sysctl kern.geom.collectstats defaulting to off. Collect the following raw statistics conditioned on this sysctl: for each consumer and provider { total number of operations started. total number of operations completed. time last operation completed. sum of idle-time. for each of BIO_READ, BIO_WRITE and BIO_DELETE { number of operations completed. number of bytes completed. number of ENOMEM errors. number of other errors. sum of transaction time. } } API for getting hold of these statistics data not included yet.
* Rename bio_linkage to the more obvious bio_parent.phk2003-02-071-1/+1
| | | | Add bio_t0 timestamp, and include <sys/time.h> where needed
* Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0.alfred2003-01-211-7/+7
| | | | Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT.
* We should not need to hold Giant for sbuf operations any more.phk2002-12-261-4/+0
|
* Constification and some s/int/u_int/ changes.phk2002-12-161-7/+7
|
* Straighten up the geom.ctl config interface definitions.phk2002-11-061-1/+1
| | | | Sponsored by: DARPA & NAI Labs
* Polish a bit here and there.phk2002-11-041-3/+5
| | | | | | Reenable the geom.ctl device so people can play with gbde. Sponsored by: DARPA & NAI Labs
* Use a better test to prevent tasting geom.ctl so we don't screw thephk2002-10-241-1/+1
| | | | regression tests.
* Don't taste the first provider, it's /dev/geom.ctl and it's not goingphk2002-10-241-1/+2
| | | | to taste like anything we like anyway.
* The g_id*() functions are not needed in the userland test-suite sophk2002-10-201-0/+2
| | | | | | #ifdef _KERNEL them rather than deal with a copyin simulation. Sponsored by: DARPA & NAI Labs
* Use %jd instead of %lld now that we have it.phk2002-10-201-2/+3
|
* Implement the GEOMCONFIGGEOM ioctl which can be used to manually createphk2002-10-141-37/+82
| | | | | | and configure an instance of a class on a give provider. Sponsored by: DARPA & NAI Labs
* Add support g_clone_bio() and g_std_done() to spawn multiple childrenphk2002-10-091-4/+6
| | | | | | of a bio and correctly gather status when done. Sponsored by: DARPA & NAI Labs.
* Retire g_io_fail() and let g_io_deliver() take an error argument instead.phk2002-09-301-4/+4
| | | | Sponsored by: DARPA & NAI Labs.
* Disable the g_sanity() check unless people ask for it in the debugflags.phk2002-09-301-0/+2
| | | | Sponsored by: DARPA & NAI Labs.
* Remove "magicspace". It looks good on paper, it doesn't work in practice.phk2002-09-061-44/+0
| | | | Sponsored by: DARPA & NAI Labs.
* Improve some on the naming.phk2002-06-091-15/+15
| | | | Submitted by: iedowse
* Change the registration of magic spaces so it does its own memory management.phk2002-06-051-19/+30
| | | | Sponsored by: DARPA & NAI Labs.
* Introduce the concept of "magic spaces", and implement them in most ofphk2002-05-211-0/+33
| | | | | | | | | | | | | | | | the relevant classes. Some methods may implement various "magic spaces", this is reserved or magic areas on the disk, set a side for various and sundry purposes. A good example is the BSD disklabel and boot code on i386 which occupies a total of four magic spaces: boot1, the disklabel, the padding behind the disklabel and boot2. The reason we don't simply tell people to write the appropriate stuff on the underlying device is that (some of) the magic spaces might be real-time modifiable. It is for instance possible to change a disklabel while partitions are open, provided the open partitions do not get trampled in the process. Sponsored by: DARPA & NAI Labs.
OpenPOWER on IntegriCloud