mirror of
https://github.com/schoebel/mars
synced 2025-01-24 16:22:59 +00:00
trans_logger: improve event handling
This commit is contained in:
parent
776e83fea4
commit
d9aa8046b7
@ -115,6 +115,9 @@ void log_write_endio(struct generic_callback *cb)
|
||||
done:
|
||||
put_log_cb_info(cb_info);
|
||||
atomic_dec(&logst->mref_flying);
|
||||
if (logst->signal_event)
|
||||
wake_up_interruptible(logst->signal_event);
|
||||
|
||||
return;
|
||||
|
||||
err:
|
||||
|
@ -88,6 +88,8 @@ struct log_header_v1 {
|
||||
/* Bookkeeping status between calls
|
||||
*/
|
||||
struct log_status {
|
||||
// interfacing
|
||||
wait_queue_head_t *signal_event;
|
||||
// tunables
|
||||
int align_size; // alignment between requests
|
||||
int chunk_size; // must be at least 8K (better 64k)
|
||||
|
@ -2224,6 +2224,7 @@ void _init_input(struct trans_logger_input *input)
|
||||
loff_t start_pos = input->log_start_pos;
|
||||
|
||||
init_logst(logst, (void*)input, 0);
|
||||
logst->signal_event = &brick->worker_event;
|
||||
logst->align_size = brick->align_size;
|
||||
logst->chunk_size = brick->chunk_size;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user