X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=libringbuffer%2Ffrontend_internal.h;h=51b652d2a3d2ed5dbb9eb41d0942a522bd4c86a7;hb=bae63afc923740627352cdd6b0aeab1b0706387e;hp=8a0f78f32ee774e19e853b3c7c511957ed7adb85;hpb=0b5389bbeb5da342a12a195d34ea8c6d0db55a04;p=lttng-ust.git diff --git a/libringbuffer/frontend_internal.h b/libringbuffer/frontend_internal.h index 8a0f78f3..51b652d2 100644 --- a/libringbuffer/frontend_internal.h +++ b/libringbuffer/frontend_internal.h @@ -499,23 +499,20 @@ void lib_ring_buffer_write_commit_counter(const struct lttng_ust_lib_ring_buffer unsigned long idx, unsigned long buf_offset, unsigned long commit_count, - size_t slot_size, struct lttng_ust_shm_handle *handle) { - unsigned long offset, commit_seq_old; + unsigned long commit_seq_old; if (config->oops != RING_BUFFER_OOPS_CONSISTENCY) return; - offset = buf_offset + slot_size; - /* * subbuf_offset includes commit_count_mask. We can simply * compare the offsets within the subbuffer without caring about * buffer full/empty mismatch because offset is never zero here * (subbuffer header and record headers have non-zero length). */ - if (caa_unlikely(subbuf_offset(offset - commit_count, chan))) + if (caa_unlikely(subbuf_offset(buf_offset - commit_count, chan))) return; commit_seq_old = v_read(config, &shmp_index(handle, buf->commit_hot, idx)->seq);