Lines Matching refs:snap
38 ring->size.snap = size_snap; in skc_extent_ring_init()
67 return SKC_MIN_MACRO(skc_extent_ring_rem(ring),ring->size.snap) - skc_extent_ring_wip_count(ring); in skc_extent_ring_wip_rem()
73 …return skc_extent_ring_wip_count(ring) == SKC_MIN_MACRO(skc_extent_ring_rem(ring),ring->size.snap); in skc_extent_ring_wip_is_full()
102 struct skc_extent_ring_snap * snap = in skc_extent_ring_snap_alloc() local
105 sizeof(*snap),&id,NULL); in skc_extent_ring_snap_alloc()
107 snap->id = id; in skc_extent_ring_snap_alloc()
110 snap->ring = ring; in skc_extent_ring_snap_alloc()
111 snap->next = NULL; in skc_extent_ring_snap_alloc()
114 snap->reads = ring->inner.reads; in skc_extent_ring_snap_alloc()
115 snap->writes = ring->inner.reads = ring->inner.writes; in skc_extent_ring_snap_alloc()
118 snap->is_free = false; in skc_extent_ring_snap_alloc()
123 ring->head = snap; in skc_extent_ring_snap_alloc()
124 ring->last = snap; in skc_extent_ring_snap_alloc()
128 ring->last->next = snap; in skc_extent_ring_snap_alloc()
129 ring->last = snap; in skc_extent_ring_snap_alloc()
132 return snap; in skc_extent_ring_snap_alloc()
141 struct skc_extent_ring_snap * const snap) in skc_extent_ring_snap_free() argument
144 snap->is_free = true; in skc_extent_ring_snap_free()
150 struct skc_extent_ring * const ring = snap->ring; in skc_extent_ring_snap_free()
185 skc_extent_ring_snap_count(struct skc_extent_ring_snap const * const snap) in skc_extent_ring_snap_count() argument
187 return snap->writes - snap->reads; in skc_extent_ring_snap_count()
191 skc_extent_ring_snap_from(struct skc_extent_ring_snap const * const snap) in skc_extent_ring_snap_from() argument
193 return snap->reads & snap->ring->size.mask; in skc_extent_ring_snap_from()
197 skc_extent_ring_snap_to(struct skc_extent_ring_snap const * const snap) in skc_extent_ring_snap_to() argument
199 return snap->writes & snap->ring->size.mask; in skc_extent_ring_snap_to()