Skip to content
Tom Barbette edited this page Oct 3, 2018 · 2 revisions

PathSpinlock Element Documentation

NAME

PathSpinlock — Click element; acquires a spinlock, push/pull the packets then release the lock

SYNOPSIS

PathSpinlock(LOCK)

Batching: Batching natively supported
Ports: 1 or more inputs, the same number of outputs
Processing: agnostic

DESCRIPTION

Acquires the spinlock named LOCK. LOCK must be defined in a SpinlockInfo element. In a push context, the packet is then pushed through the pipeline and when the processing down the push path is done, releases the lock. In a pull contextn, the pacjet us then pulled and before being returned, the lock is released.

NOTES

Ensure that a push path or a pull part will not be traversed by multiple threads at the same time while SpinlockAcquire/SpinlockRelease work for any path but do not support dropping packets between a SpinlockAcquire and a SpinlockRelease

SEE ALSO

SpinlockInfo, SpinlockAcquire, SpinlockRelease

Generated by click-elem2man from ../elements/threads/pathspinlock.hh:7 on 2018/10/03.

Clone this wiki locally