• Kent Overstreet's avatar
    bcachefs: bch2_journal_halt() now takes journal lock · dfc0f7ea
    Kent Overstreet authored
    This change is prep work for moving some work from
    __journal_entry_close() to journal_entry_open(): without this change,
    journal_entry_open() doesn't know if it's going to be able to open a new
    journal entry until the cmpxchg loop, meaning it can't create the new
    journal pin entry and update other global state because those have to be
    done prior to the cmpxchg opening the new journal entry.
    
    Fortunately, we don't call bch2_journal_halt() from interrupt context.
    Signed-off-by: default avatarKent Overstreet <kent.overstreet@gmail.com>
    dfc0f7ea
journal.c 33 KB