ck_epoch: Flip arguments, specify epoch_entry before destructor.

ck_pring
Samy Al Bahra 13 years ago
parent 79c7e453ec
commit cc4b83793f

@ -112,7 +112,7 @@ ck_epoch_end(ck_epoch_record_t *record)
}
CK_CC_INLINE static void
ck_epoch_retire(ck_epoch_record_t *record, ck_epoch_destructor_t destroy, ck_epoch_entry_t *entry)
ck_epoch_retire(ck_epoch_record_t *record, ck_epoch_entry_t *entry, ck_epoch_destructor_t destroy)
{
entry->destroy = destroy;
@ -128,7 +128,7 @@ void ck_epoch_unregister(ck_epoch_record_t *);
void ck_epoch_tick(ck_epoch_t *, ck_epoch_record_t *);
bool ck_epoch_reclaim(ck_epoch_record_t *);
void ck_epoch_write_begin(ck_epoch_record_t *);
void ck_epoch_free(ck_epoch_record_t *, ck_epoch_destructor_t, ck_epoch_entry_t *);
void ck_epoch_free(ck_epoch_record_t *, ck_epoch_entry_t *, ck_epoch_destructor_t);
void ck_epoch_purge(ck_epoch_record_t *record);
#endif /* _CK_EPOCH_H */

@ -211,8 +211,8 @@ ck_epoch_write_begin(struct ck_epoch_record *record)
void
ck_epoch_free(struct ck_epoch_record *record,
ck_epoch_destructor_t destroy,
ck_epoch_entry_t *entry)
ck_epoch_entry_t *entry,
ck_epoch_destructor_t destroy)
{
unsigned int epoch = ck_pr_load_uint(&record->epoch);
struct ck_epoch *global = record->global;

Loading…
Cancel
Save