summaryrefslogtreecommitdiffstats
path: root/sys/geom
Commit message (Collapse)AuthorAgeFilesLines
* Correctly calculate what to do and how to retry a request to a plex whenle2005-02-232-12/+47
| | | | | | | the previous one failed and there are more than one plex in the volume. This could have led to a flood of error messages on the console and probably a deadlock in certain situations.
* Try to unbreak the vnode locking around vop_reclaim() (based mostly onphk2005-02-191-0/+4
| | | | | | | | | patch from kan@). Pull bufobj_invalbuf() out of vinvalbuf() and make g_vfs call it on close. This is not yet a generally safe function, but for this very specific use it is safe. This solves the problem with buffers not being flushed by unmount or after failed mount attempts.
* In case of drive errors, don't close the associated consumer andle2005-02-171-10/+2
| | | | | | detach it, but instead let the geom wither away. Bump copyright year.
* Fix year in copyrights.pjd2005-02-162-2/+2
|
* Update copyright in files changed this year.pjd2005-02-168-8/+8
|
* Fix year in copyrights.pjd2005-02-162-2/+2
|
* Remove mutex asserion from g_gate_find(). We don't want g_gate_list_mtxpjd2005-02-161-1/+0
| | | | mutex to be held here, because we want speed here.
* Remove TDP_GEOM flag from thread after ggate device creation.pjd2005-02-161-0/+7
| | | | | | | This flag means "wait for all pending requests before returning to userland". There are pending events for sure, because we just created new provider and other classes want to taste it, but we cannot answer on I/O requests until we're here.
* Fix typo. We want to unlock mutex here.pjd2005-02-121-1/+1
| | | | | Submitted by: Andreas Kohn <andreas.kohn@gmail.com> MFC after: 1 week
* Make various random things staticphk2005-02-104-5/+6
|
* - Remove g_gate_hold()/g_gate_release() from start/done paths. It savespjd2005-02-092-59/+40
| | | | | | | | | | 4 mutex operations per I/O requests. - Use only one mutex to protect both (incoming and outgoing) queue. As MUTEX_PROFILING(9) shows, there is no big contention for this lock. - Protect sc_queue_count with queue mutex, instead of doing atomic operations on it. - Remove DROP_GIANT()/PICKUP_GIANT() - ggate is marked as MPSAFE and no Giant there.
* merge from geom_vol_ffs.c rev 1.14 (avoid unaligned I/O requests)des2005-02-081-0/+10
|
* Take care not to issue unaligned I/O requests while tasting a provider.des2005-02-081-0/+10
|
* - Use bioq_insert_tail()/bioq_insert_head() instead of bioq_disksort().pjd2005-02-051-3/+7
| | | | | | - Improve mediasize checking. MFC after: 1 week
* When dumping to a unpartitioned disk, make sure to chop thephk2005-01-291-0/+2
| | | | | | length of the dump area accordingly. Run into by: scottl
* - If mpsafevfs is off, acquire giant around all calls to bufdone().jeff2005-01-281-0/+4
| | | | Sponsored by: Isilon Systems, Inc.
* Introduce and use g_vfs_close().phk2005-01-252-0/+12
|
* Create a correctly sized vnode objects for disk devices.phk2005-01-241-0/+1
|
* - Don't acquire giant around calls to bufdone().jeff2005-01-241-2/+0
| | | | Sponsored By: Isilon Systems, Inc.
* Only report state changes of subdisks and plexes when there'sle2005-01-211-2/+14
| | | | | | really a state change. Reword the info a bit.
* Don't initialize error with ENXIO as we might end up here whenle2005-01-211-2/+1
| | | | the plex has no more consumers (e.g. orphaning).
* Protect against recursive slices creation in simlar way as it is donepjd2005-01-201-7/+33
| | | | | | | | | | in BSD class, ie. if provider below us uses the same metadata, don't create slices based on the metadata. This allows to create slices on geoms with rank != 1 without hacks. Discussed with: phk Approved by: phk MFC after: 2 weeks
* Rename synchronization and initialization threads and prefix themle2005-01-191-2/+2
| | | | with 'gv_' for consistency.
* Although an object may already be known in the configuration, it'sle2005-01-193-5/+32
| | | | | | | worker thread may have been destroyed (e.g. during orphaning). Make sure that objects get back their worker threads when they get a new geom.
* Reset object flags after killing off an object's worker thread.le2005-01-191-0/+6
|
* Discontinue zero-length g_ctl arguments as "just give him this pointer"phk2005-01-171-6/+1
| | | | | transfers. The necessary context for calling copyin() isn't available anyway and automatic code-validation chokes on this.
* CAM will sometimes remove a disk again even before it finished beingphk2005-01-141-2/+4
| | | | | initialized. We already cancel the pending events but we need to not dereference the geom pointer which never got set different from NULL.
* Introduce a new GEOM class - SHSEC. It provides sharing secret betweenpjd2005-01-112-0/+935
| | | | | | | | the given providers. Without even one of the configured components there should be no way to get the secret. Supported by: WHEEL Sp. z o.o. http://www.wheel.pl
* Add BO_SYNC() and add a default which uses the secret vnode pointerphk2005-01-111-0/+1
| | | | and VOP_FSYNC() for now.
* Increase default synchronization speed.pjd2005-01-092-2/+2
| | | | MFC after: 3 days
* /* -> /*- for copyright notices, minor format tweaks as necessaryimp2005-01-0615-20/+29
|
* - Fix 'rebuild' command - it can no longer relay on retaste eventpjd2005-01-043-50/+34
| | | | | | | | (we ignore it). - Remove code used for handling spoil events, as spoiling is not possible anymore, because we keep consumers open for writing all the time. MFC after: 4 days
* Spoiling is now not possible, because we keep consumers open for writingpjd2005-01-043-38/+13
| | | | | | all the time. Remove unused code then. MFC after: 4 days
* Fix 'rebuild' command (we ignore retaste event now, so don't relay on it).pjd2005-01-033-11/+23
|
* Remove unused #include.pjd2005-01-031-1/+0
|
* Stop explicitly touching td_base_pri outside of the scheduler and simplyjhb2004-12-303-6/+19
| | | | | set a thread's priority via sched_prio() when that is the desired action. The schedulers will start managing td_base_pri internally shortly.
* Remove debug code.pjd2004-12-281-10/+2
|
* - Add genid field to the metadata which will allow to improve reliability a bit.pjd2004-12-253-61/+206
| | | | | | | | | | | | | | | After this change, when component is disconnected because of an I/O error, it will not be connected and synchronized automatically, it will be logged as broken and skipped. Autosynchronization can occur, when component is disconnected (on orphan event) and connected again - there were no I/O error, so there is no need to not connected the component, but when there were writes while it wasn't connected, it will be synchronized. This fix cases, when component is disconnected because of I/O error and can be connected again and again. - Bump version number. - Implement backward compatibility mechanism. After this change when metadata in old version is detected, it is automatically upgraded to the new (current) version.
* Update disk->d_genid field when increasing sc->sc_genid.pjd2004-12-231-0/+1
|
* - Add genid field to the metadata which will allow to improve reliability a bit.pjd2004-12-223-57/+185
| | | | | | | | | | | | | | | | After this change, when component is disconnected because of an I/O error, it will not be connected and synchronized automatically, it will be logged as broken and skipped. Autosynchronization can occur, when component is disconnected (on orphan event) and connected again - there were no I/O error, so there is no need to not connected the component, but when there were writes while it wasn't connected, it will be synchronized. This fix cases, when component is disconnected because of I/O error and can be connected again and again. - Bump version number. - Add version change history. - Implement backward compatibility mechanism. After this change when metadata in old version is detected, it is automatically upgraded to the new (current) version.
* Now, when force device destruction is done on shutdown, hide warning,pjd2004-12-212-2/+2
| | | | | | that device cannot be destroyed immediately, under debug=1. Suggested by: simon
* Improve reliability and clean up code a bit.pjd2004-12-211-189/+140
| | | | For more details check src/sys/geom/mirror/g_mirror.c rev.1.47,1.48,1.49,1.50.
* This should not be permitted, but some GEOM classes held the topology lockpjd2004-12-211-6/+30
| | | | | | while doing g_(read|write)_data() (e.g. BSD). This can cause a deadlock in MIRROR class. Not sure if this is safe to drop the topology lock in BSD class, so change the code in MIRROR class to avoid this deadlock.
* Implement g_topology_try_lock().pjd2004-12-211-0/+2
| | | | No objection from: phk
* Remove unused variables.pjd2004-12-191-6/+1
|
* - Argument 'flags' in g_mirror_destroy_consumer() function is unsed -pjd2004-12-191-2/+3
| | | | | | mark it as such. - Before closing consumer check if it is open. It can be closed here when g_mirror_connect_disk() fails on g_access().
* Some major cleanups.pjd2004-12-191-175/+107
| | | | | | | | | | | | | | | | | | | | | | Keeping consumers open when device is closed is very hard. We need to open consumers sometimes to update metadata, etc. Many hacks was introduced in the past to made it possible. You cannot be sure that you can open consumer for writing always, even if you think it should be allowed. If one of the mirror components is for example da0 and you try to open it, you can get EPERM when da0s1 is opened for reading (because BSD class opens consumers (da0) with an extra 'e' bit set). Waiting for the events queue to be empty may do the trick, but it makes code much uglier (as you cannot always call g_waitidle()), it doesn't solve all edge cases and it can introduce deadlocks if there are events in the queue that wait for gmirror. I removed those hacks. Now all consumers are open r1w1e1 always, even if device is closed. Maybe it is less clean from GEOM perspective, but simpify code a lot and make it much more reliable. The only issue was retaste event which is sent when we close consumers opened for writing. I ignore retaste event by not detaching consumer immediately (so retaste event is not send to my class) and sending event right after it to detach and destroy consumer.
* Don't quit on first failure, just skip failures.pjd2004-12-191-6/+6
|
* Fix typo in a comment.brueffer2004-12-151-1/+1
| | | | MFC after: 3 days
* bioq_insert_head() function is already in subr_disk.c.pjd2004-12-131-10/+0
|
OpenPOWER on IntegriCloud