History log of /dragonfly/sys/kern/kern_sysref.c (Results 1 – 18 of 18)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: v6.2.1, v6.2.0, v6.3.0, v6.0.1, v6.0.0, v6.0.0rc1, v6.1.0, v5.8.3, v5.8.2, v5.8.1, v5.8.0, v5.9.0, v5.8.0rc1, v5.6.3
# dd0e3cd7 02-Dec-2019 Matthew Dillon <dillon@apollo.backplane.com>

devfs - Ensure lock held around devfs_cdev_terminate()

* Ensure that a lock is held around devfs_cdev_terminate() on
sysref release (which can occur from any thread, not just the
devfs thread).


# dae65060 20-Oct-2019 zrj <rimvydas.jasinskas@gmail.com>

<sys/sysref.h>: Switch to lighter <sys/_malloc.h> header.

* Make <sys/sysref2.h> a kernel only header.
* Remove sys/types.h includes that follow <sys/param.h> in devfs(5).
* Add sys/malloc.h incl

<sys/sysref.h>: Switch to lighter <sys/_malloc.h> header.

* Make <sys/sysref2.h> a kernel only header.
* Remove sys/types.h includes that follow <sys/param.h> in devfs(5).
* Add sys/malloc.h includes where it is actually used in sources.

While there, minor whitespace cleanup.

show more ...


Revision tags: v5.6.2, v5.6.1, v5.6.0, v5.6.0rc1, v5.7.0, v5.4.3, v5.4.2, v5.4.1, v5.4.0, v5.5.0, v5.4.0rc1, v5.2.2, v5.2.1, v5.2.0, v5.3.0, v5.2.0rc, v5.0.2, v5.0.1, v5.0.0, v5.0.0rc2, v5.1.0, v5.0.0rc1, v4.8.1, v4.8.0, v4.6.2, v4.9.0, v4.8.0rc, v4.6.1, v4.6.0, v4.6.0rc2, v4.6.0rc, v4.7.0, v4.4.3, v4.4.2, v4.4.1, v4.4.0, v4.5.0, v4.4.0rc, v4.2.4, v4.3.1, v4.2.3, v4.2.1, v4.2.0, v4.0.6, v4.3.0, v4.2.0rc, v4.0.5, v4.0.4, v4.0.3, v4.0.2, v4.0.1, v4.0.0, v4.0.0rc3, v4.0.0rc2, v4.0.0rc, v4.1.0
# ba87a4ab 24-Aug-2014 Sascha Wildner <saw@online.de>

kernel/spinlock: Add a description to struct spinlock.

And add it to spin_init() and SPINLOCK_INITIALIZER().

Submitted-by: dclink (see <http://bugs.dragonflybsd.org/issues/2714>)
OK'd-by: dill

kernel/spinlock: Add a description to struct spinlock.

And add it to spin_init() and SPINLOCK_INITIALIZER().

Submitted-by: dclink (see <http://bugs.dragonflybsd.org/issues/2714>)
OK'd-by: dillon

show more ...


Revision tags: v3.8.2, v3.8.1, v3.6.3, v3.8.0, v3.8.0rc2, v3.9.0, v3.8.0rc, v3.6.2, v3.6.1, v3.6.0, v3.7.1, v3.6.0rc, v3.7.0, v3.4.3, v3.4.2, v3.4.0, v3.4.1, v3.4.0rc, v3.5.0, v3.2.2, v3.2.1
# 2fce2579 21-Oct-2012 Sepherosa Ziehau <sephe@dragonflybsd.org>

objcache: objcache_create on longer changes cluster_limit

It is no longer needed to pass the pointer to cluster_limit.


Revision tags: v3.2.0, v3.3.0, v3.0.3, v3.0.2, v3.0.1, v3.1.0, v3.0.0
# 86d7f5d3 26-Nov-2011 John Marino <draco@marino.st>

Initial import of binutils 2.22 on the new vendor branch

Future versions of binutils will also reside on this branch rather
than continuing to create new binutils branches for each new version.


Revision tags: v2.12.0, v2.13.0, v2.10.1, v2.11.0, v2.10.0, v2.9.1, v2.8.2, v2.8.1, v2.8.0, v2.9.0, v2.6.3, v2.7.3, v2.6.2, v2.7.2, v2.7.1, v2.6.1, v2.7.0, v2.6.0, v2.5.1, v2.4.1, v2.5.0, v2.4.0, v2.3.2, v2.3.1, v2.2.1, v2.2.0, v2.3.0, v2.1.1
# 0aa16b5d 26-Oct-2008 Sepherosa Ziehau <sephe@dragonflybsd.org>

- Return the real cluster limit used by the objcache
- For mbuf objcaches, raise backing kmalloc pools' limit according to the
cluster limits.
Suggested-by: dillon@

Reviewed-by: aggelos@, nth@


Revision tags: v2.0.1
# 698331b0 29-May-2007 Matthew Dillon <dillon@dragonflybsd.org>

Rename private to privdata and class to srclass to avoid conflicts with
C++.

Reported-by: Hasso Tepper <bugs@crater.dragonflybsd.org>
Dragonfly-bug: <http://bugs.dragonflybsd.org/issue663>


# 3551ce6b 26-May-2007 Matthew Dillon <dillon@dragonflybsd.org>

Add the kernel support function allocsysid().


# 3c37c940 06-May-2007 Matthew Dillon <dillon@dragonflybsd.org>

Use SYSREF to reference count struct vnode. v_usecount is now
v_sysref(.refcnt). v_holdcnt is now v_auxrefs. SYSREF's termination state
(using a negative reference count from -0x40000000+) now pla

Use SYSREF to reference count struct vnode. v_usecount is now
v_sysref(.refcnt). v_holdcnt is now v_auxrefs. SYSREF's termination state
(using a negative reference count from -0x40000000+) now places the vnode in
a VCACHED or VFREE state and deactivates it. The vnode is now assigned a
64 bit unique id via SYSREF.

vhold() (which manipulates v_auxrefs) no longer reactivates a vnode and
is explicitly used only to track references from auxillary structures
and references to prevent premature destruction of the vnode. vdrop()
will now only move a vnode from VCACHED to VFREE on the 1->0 transition
of v_auxrefs if the vnode is in a termination state.

vref() will now panic if used on a vnode in a termination state. vget()
must now be used to explicitly reactivate a vnode. These requirements
existed before but are now explicitly asserted.

vlrureclaim() and allocvnode() should now interact a bit better. In
particular, vlrureclaim() will do a better job of finding vnodes to flush
and transition from VCACHED to VFREE, and allocvnode() will do a better
job finding vnodes to reuse without getting blocked by a flush.

allocvnode now uses a real VX lock to sequence vnodes into VRECLAIMED. All
vnode special state processing now uses a VX lock.

Vnodes are now able to be slowly returned to the memory pool when
kern.maxvnodes is reduced at run time.

Various initialization elements have been moved to CTOR/DTOR and are
no longer in the critical path, improving performance. However, since
SYSREF uses atomic_cmpset_int() (aka cmpxchgl), which reduces performance
somewhat, overall performance tends to be about the same.

show more ...


# ba39e2e0 30-Apr-2007 Matthew Dillon <dillon@dragonflybsd.org>

Revamp SYSINIT ordering. Relabel sysinit IDs (SI_* in sys/kernel.h) to
make them less confusing, particularly with regard to the relative order
init routines are called in.

Reorder many sysinits.

Revamp SYSINIT ordering. Relabel sysinit IDs (SI_* in sys/kernel.h) to
make them less confusing, particularly with regard to the relative order
init routines are called in.

Reorder many sysinits. Reorder the SMP and CLOCK code to bring all the
cpus up far earlier in the boot sequence and to make the full threading and
clocking subsystems available for device config.

show more ...


# f66589b7 29-Apr-2007 Matthew Dillon <dillon@dragonflybsd.org>

Remove unneeded references to sys/syslink.h. Get syslink_desc from
sys/syslink_rpc.h


# 10aa77c0 29-Apr-2007 Matthew Dillon <dillon@dragonflybsd.org>

Implement SYSREF - structural reference counting, allocation, and sysid
management subsystem.

* Structural reference count management, including creation and termination
sequencing (e.g. where the

Implement SYSREF - structural reference counting, allocation, and sysid
management subsystem.

* Structural reference count management, including creation and termination
sequencing (e.g. where the structure might be temporarily referenced
during termination).

* Allocation. It uses an objcache backend for optimal allocation,
deallocation, and memory recovery.

* Sysid assignment and red-black tree indexing. It does this in the
objcache CTOR and DTOR so it costs us absolutely nothing in the
resource allocation / deallocation critical path. sysids will be
reused unless they are externally accessed.

show more ...


# 521f81c7 09-Mar-2011 Matthew Dillon <dillon@apollo.backplane.com>

kernel - Add vm.cache_vmspaces boot-time tunable

* Add vm.cache_vmspaces boot-time tunable, defaulting to 32 objects.
This controls how many free vmspace+pmap structures can be maintained
in the

kernel - Add vm.cache_vmspaces boot-time tunable

* Add vm.cache_vmspaces boot-time tunable, defaulting to 32 objects.
This controls how many free vmspace+pmap structures can be maintained
in the objcache.

* Change the sysref API a bit. mag_capacity becomes nom_cache.

Related-to: IRC conversion thesjg & vsrinivas

show more ...


# 287a8577 30-Aug-2010 Alex Hornung <ahornung@gmail.com>

spinlocks - Rename API to spin_{try,un,}lock

* Rename the API to spin_trylock, spin_unlock and spin_lock instead of
spin_lock_wr, spin_unlock_wr and spin_trylock_wr now that we only have
exclusi

spinlocks - Rename API to spin_{try,un,}lock

* Rename the API to spin_trylock, spin_unlock and spin_lock instead of
spin_lock_wr, spin_unlock_wr and spin_trylock_wr now that we only have
exclusive spinlocks.

* 99% of this patch was generated by a semantic coccinelle patch

show more ...


# 18b4c2bb 13-Aug-2010 Matthew Dillon <dillon@apollo.backplane.com>

kernel - Add sysref assertions

* Add checks in the sysref code to detect use-after-free situations.


# e654922c 11-Feb-2010 Matthew Dillon <dillon@apollo.backplane.com>

kernel - sysref - Fix vnode interlock for 1->0 transition

* When the vnode refcount drops to 0 vnode_terminate() is called. This
function previously acquired the vx_lock() after the 1->0 transiti

kernel - sysref - Fix vnode interlock for 1->0 transition

* When the vnode refcount drops to 0 vnode_terminate() is called. This
function previously acquired the vx_lock() after the 1->0 transition.

Instead integrate the acquisition of the vx_lock() into the 1->0
transition to close a small MP race.

show more ...


# 63f45d59 21-Dec-2009 Matthew Dillon <dillon@apollo.backplane.com>

kernel - Split an assertion in the sysref code to make it MPSAFE

* An assertion in the sysref code was not MPSAFE. Test SRF_ALLOCATED
after we have determined that the object is completely free.


# b0911300 28-Dec-2009 Matthew Dillon <dillon@apollo.backplane.com>

kernel - MPSAFE stabilization

* Fix for 'panic: sysref_activate: bad count 00000002'. Mistakenly
assumed the lockmgr lock was sufficient protection but forgot it
might be acquired LK_SHARED. E

kernel - MPSAFE stabilization

* Fix for 'panic: sysref_activate: bad count 00000002'. Mistakenly
assumed the lockmgr lock was sufficient protection but forgot it
might be acquired LK_SHARED. Extend v_spinlock protection to fix
the problem.

show more ...