/openbmc/linux/fs/jbd2/ |
H A D | journal.c | 137 journal_t *journal = from_timer(journal, t, j_commit_timer); in commit_timeout() local 139 wake_up_process(journal->j_task); in commit_timeout() 162 journal_t *journal = arg; in kjournald2() local 169 timer_setup(&journal->j_commit_timer, commit_timeout, 0); in kjournald2() 174 journal->j_task = current; in kjournald2() 175 wake_up(&journal->j_wait_done_commit); in kjournald2() 188 write_lock(&journal->j_state_lock); in kjournald2() 191 if (journal->j_flags & JBD2_UNMOUNT) in kjournald2() 195 journal->j_commit_sequence, journal->j_commit_request); in kjournald2() 197 if (journal->j_commit_sequence != journal->j_commit_request) { in kjournald2() [all …]
|
H A D | checkpoint.c | 49 void __jbd2_log_wait_for_space(journal_t *journal) in __jbd2_log_wait_for_space() argument 50 __acquires(&journal->j_state_lock) in __jbd2_log_wait_for_space() 51 __releases(&journal->j_state_lock) in __jbd2_log_wait_for_space() 56 nblocks = journal->j_max_transaction_buffers; in __jbd2_log_wait_for_space() 57 while (jbd2_log_space_left(journal) < nblocks) { in __jbd2_log_wait_for_space() 58 write_unlock(&journal->j_state_lock); in __jbd2_log_wait_for_space() 59 mutex_lock_io(&journal->j_checkpoint_mutex); in __jbd2_log_wait_for_space() 72 write_lock(&journal->j_state_lock); in __jbd2_log_wait_for_space() 73 if (journal->j_flags & JBD2_ABORT) { in __jbd2_log_wait_for_space() 74 mutex_unlock(&journal->j_checkpoint_mutex); in __jbd2_log_wait_for_space() [all …]
|
H A D | commit.c | 114 static int journal_submit_commit_record(journal_t *journal, in journal_submit_commit_record() argument 126 if (is_journal_aborted(journal)) in journal_submit_commit_record() 139 if (jbd2_has_feature_checksum(journal)) { in journal_submit_commit_record() 144 jbd2_commit_block_csum_set(journal, bh); in journal_submit_commit_record() 152 if (journal->j_flags & JBD2_BARRIER && in journal_submit_commit_record() 153 !jbd2_has_feature_async_commit(journal)) in journal_submit_commit_record() 165 static int journal_wait_on_commit_record(journal_t *journal, in journal_wait_on_commit_record() argument 181 int jbd2_submit_inode_data(journal_t *journal, struct jbd2_inode *jinode) in jbd2_submit_inode_data() argument 187 return journal->j_submit_inode_data_buffers(jinode); in jbd2_submit_inode_data() 192 int jbd2_wait_inode_data(journal_t *journal, struct jbd2_inode *jinode) in jbd2_wait_inode_data() argument [all …]
|
H A D | transaction.c | 80 static void jbd2_get_transaction(journal_t *journal, in jbd2_get_transaction() argument 83 transaction->t_journal = journal; in jbd2_get_transaction() 86 transaction->t_tid = journal->j_transaction_sequence++; in jbd2_get_transaction() 87 transaction->t_expires = jiffies + journal->j_commit_interval; in jbd2_get_transaction() 90 journal->j_transaction_overhead_buffers + in jbd2_get_transaction() 91 atomic_read(&journal->j_reserved_credits)); in jbd2_get_transaction() 98 journal->j_commit_timer.expires = round_jiffies_up(transaction->t_expires); in jbd2_get_transaction() 99 add_timer(&journal->j_commit_timer); in jbd2_get_transaction() 101 J_ASSERT(journal->j_running_transaction == NULL); in jbd2_get_transaction() 102 journal->j_running_transaction = transaction; in jbd2_get_transaction() [all …]
|
H A D | revoke.c | 131 static inline int hash(journal_t *journal, unsigned long long block) in hash() argument 133 return hash_64(block, journal->j_revoke->hash_shift); in hash() 136 static int insert_revoke_hash(journal_t *journal, unsigned long long blocknr, in insert_revoke_hash() argument 151 hash_list = &journal->j_revoke->hash_table[hash(journal, blocknr)]; in insert_revoke_hash() 152 spin_lock(&journal->j_revoke_lock); in insert_revoke_hash() 154 spin_unlock(&journal->j_revoke_lock); in insert_revoke_hash() 160 static struct jbd2_revoke_record_s *find_revoke_record(journal_t *journal, in find_revoke_record() argument 166 hash_list = &journal->j_revoke->hash_table[hash(journal, blocknr)]; in find_revoke_record() 168 spin_lock(&journal->j_revoke_lock); in find_revoke_record() 172 spin_unlock(&journal->j_revoke_lock); in find_revoke_record() [all …]
|
H A D | recovery.c | 39 static int do_one_pass(journal_t *journal, 67 static int do_readahead(journal_t *journal, unsigned int start) in do_readahead() argument 77 max = start + (128 * 1024 / journal->j_blocksize); in do_readahead() 78 if (max > journal->j_total_len) in do_readahead() 79 max = journal->j_total_len; in do_readahead() 87 err = jbd2_journal_bmap(journal, next, &blocknr); in do_readahead() 95 bh = __getblk(journal->j_dev, blocknr, journal->j_blocksize); in do_readahead() 129 static int jread(struct buffer_head **bhp, journal_t *journal, in jread() argument 138 if (offset >= journal->j_total_len) { in jread() 143 err = jbd2_journal_bmap(journal, offset, &blocknr); in jread() [all …]
|
/openbmc/linux/fs/reiserfs/ |
H A D | journal.c | 94 struct reiserfs_journal *journal); 115 struct reiserfs_journal *journal = SB_JOURNAL(sb); in init_journal_hash() local 116 memset(journal->j_hash_table, 0, in init_journal_hash() 157 struct reiserfs_journal *journal = SB_JOURNAL(sb); in get_bitmap_node() local 159 struct list_head *entry = journal->j_bitmap_nodes.next; in get_bitmap_node() 161 journal->j_used_bitmap_nodes++; in get_bitmap_node() 164 if (entry != &journal->j_bitmap_nodes) { in get_bitmap_node() 168 journal->j_free_bitmap_nodes--; in get_bitmap_node() 181 struct reiserfs_journal *journal = SB_JOURNAL(sb); in free_bitmap_node() local 182 journal->j_used_bitmap_nodes--; in free_bitmap_node() [all …]
|
/openbmc/linux/drivers/md/bcache/ |
H A D | journal.c | 38 struct journal_device *ja = &ca->journal; in journal_read_bucket() 42 struct jset *j, *data = ca->set->journal.w[0].data; in journal_read_bucket() 183 struct journal_device *ja = &ca->journal; in bch_journal_read() 285 c->journal.seq = list_entry(list->prev, in bch_journal_read() 298 struct journal *j = &c->journal; in bch_journal_mark() 409 void bch_journal_space_reserve(struct journal *j) in bch_journal_space_reserve() 424 if (c->journal.btree_flushing) in btree_flush_write() 427 spin_lock(&c->journal.flush_write_lock); in btree_flush_write() 428 if (c->journal.btree_flushing) { in btree_flush_write() 429 spin_unlock(&c->journal.flush_write_lock); in btree_flush_write() [all …]
|
/openbmc/phosphor-power/phosphor-regulators/src/ |
H A D | journal.cpp | 46 explicit JournalCloser(sd_journal* journal) : journal{journal} {} in JournalCloser() argument 50 sd_journal_close(journal); in ~JournalCloser() 54 sd_journal* journal{nullptr}; member in phosphor::power::regulators::JournalCloser 65 sd_journal* journal; in getMessages() local 66 int rc = sd_journal_open(&journal, SD_JOURNAL_LOCAL_ONLY); in getMessages() 74 JournalCloser closer{journal}; in getMessages() 78 rc = sd_journal_add_match(journal, match.c_str(), 0); in getMessages() 89 SD_JOURNAL_FOREACH_BACKWARDS(journal) in getMessages() 92 timeStamp = getTimeStamp(journal); in getMessages() 93 syslogID = getFieldValue(journal, "SYSLOG_IDENTIFIER"); in getMessages() [all …]
|
H A D | error_logging.cpp | 37 Journal& journal) in logConfigFileError() argument 52 logError(message, severity, additionalData, journal); in logConfigFileError() 55 void DBusErrorLogging::logDBusError(Entry::Level severity, Journal& journal) in logDBusError() argument 59 journal); in logDBusError() 62 void DBusErrorLogging::logI2CError(Entry::Level severity, Journal& journal, in logI2CError() argument 79 journal); in logI2CError() 82 void DBusErrorLogging::logInternalError(Entry::Level severity, Journal& journal) in logInternalError() argument 86 additionalData, journal); in logInternalError() 90 Entry::Level severity, Journal& journal, PhaseFaultType type, in logPhaseFault() argument 99 logError(message, severity, additionalData, journal); in logPhaseFault() [all …]
|
H A D | error_logging.hpp | 67 Journal& journal) = 0; 77 virtual void logDBusError(Entry::Level severity, Journal& journal) = 0; 89 virtual void logI2CError(Entry::Level severity, Journal& journal, 99 virtual void logInternalError(Entry::Level severity, Journal& journal) = 0; 114 Entry::Level severity, Journal& journal, PhaseFaultType type, 129 virtual void logPMBusError(Entry::Level severity, Journal& journal, 144 Entry::Level severity, Journal& journal, 173 Journal& journal) override; 176 virtual void logDBusError(Entry::Level severity, Journal& journal) override; 179 virtual void logI2CError(Entry::Level severity, Journal& journal, [all …]
|
/openbmc/linux/fs/ocfs2/ |
H A D | journal.c | 62 static void ocfs2_queue_recovery_completion(struct ocfs2_journal *journal, 155 ocfs2_queue_recovery_completion(osb->journal, i, NULL, in ocfs2_queue_replay_slots() 294 struct ocfs2_journal *journal = NULL; in ocfs2_commit_cache() local 296 journal = osb->journal; in ocfs2_commit_cache() 299 down_write(&journal->j_trans_barrier); in ocfs2_commit_cache() 301 flushed = atomic_read(&journal->j_num_trans); in ocfs2_commit_cache() 304 up_write(&journal->j_trans_barrier); in ocfs2_commit_cache() 308 jbd2_journal_lock_updates(journal->j_journal); in ocfs2_commit_cache() 309 status = jbd2_journal_flush(journal->j_journal, 0); in ocfs2_commit_cache() 310 jbd2_journal_unlock_updates(journal->j_journal); in ocfs2_commit_cache() [all …]
|
/openbmc/phosphor-logging/extensions/openpower-pels/ |
H A D | journal.cpp | 43 explicit JournalCloser(sd_journal* journal) : journal{journal} {} in JournalCloser() argument 47 sd_journal_close(journal); in ~JournalCloser() 51 sd_journal* journal{nullptr}; member in openpower::pels::JournalCloser 82 sd_journal* journal; in getMessages() local 83 int rc = sd_journal_open(&journal, SD_JOURNAL_LOCAL_ONLY); in getMessages() 90 JournalCloser closer{journal}; in getMessages() 96 rc = sd_journal_add_match(journal, match.c_str(), 0); in getMessages() 109 SD_JOURNAL_FOREACH_BACKWARDS(journal) in getMessages() 111 timeStamp = getTimeStamp(journal); in getMessages() 112 sID = getFieldValue(journal, "SYSLOG_IDENTIFIER"); in getMessages() [all …]
|
/openbmc/linux/include/linux/ |
H A D | jbd2.h | 1276 void (*j_fc_cleanup_callback)(struct journal_s *journal, int full, tid_t tid); 1289 int (*j_fc_replay_callback)(struct journal_s *journal, 1300 int (*j_bmap)(struct journal_s *journal, sector_t *block); 1439 int jbd2_journal_get_log_tail(journal_t *journal, tid_t *tid, 1441 int __jbd2_update_log_tail(journal_t *journal, tid_t tid, unsigned long block); 1442 void jbd2_update_log_tail(journal_t *journal, tid_t tid, unsigned long block); 1448 void __jbd2_journal_clean_checkpoint_list(journal_t *journal, bool destroy); 1449 unsigned long jbd2_journal_shrink_checkpoint_list(journal_t *journal, unsigned long *nr_to_scan); 1452 void jbd2_journal_destroy_checkpoint(journal_t *journal); 1539 bool jbd2_journal_try_to_free_buffers(journal_t *journal, struct folio *folio); [all …]
|
/openbmc/linux/include/trace/events/ |
H A D | jbd2.h | 16 TP_PROTO(journal_t *journal, int result), 18 TP_ARGS(journal, result), 26 __entry->dev = journal->j_fs_dev->bd_dev; 36 TP_PROTO(journal_t *journal, transaction_t *commit_transaction), 38 TP_ARGS(journal, commit_transaction), 47 __entry->dev = journal->j_fs_dev->bd_dev; 59 TP_PROTO(journal_t *journal, transaction_t *commit_transaction), 61 TP_ARGS(journal, commit_transaction) 66 TP_PROTO(journal_t *journal, transaction_t *commit_transaction), 68 TP_ARGS(journal, commit_transaction) [all …]
|
/openbmc/phosphor-power/phosphor-regulators/test/ |
H A D | phase_fault_detection_tests.cpp | 209 MockJournal& journal = services.getMockJournal(); in TEST_F() local 210 EXPECT_CALL(journal, logError(std::vector<std::string>{"Logic error"})) in TEST_F() 212 EXPECT_CALL(journal, in TEST_F() 216 journal, in TEST_F() 220 journal, in TEST_F() 224 journal, in TEST_F() 228 journal, in TEST_F() 297 MockJournal& journal = services.getMockJournal(); in TEST_F() local 298 EXPECT_CALL(journal, logError(A<const std::string&>())).Times(0); in TEST_F() 327 MockJournal& journal = services.getMockJournal(); in TEST_F() local [all …]
|
H A D | mock_error_logging.hpp | 43 (Entry::Level severity, Journal& journal), (override)); 45 MOCK_METHOD(void, logDBusError, (Entry::Level severity, Journal& journal), 49 (Entry::Level severity, Journal& journal, 54 (Entry::Level severity, Journal& journal), (override)); 57 (Entry::Level severity, Journal& journal, PhaseFaultType type, 63 (Entry::Level severity, Journal& journal, 68 (Entry::Level severity, Journal& journal,
|
H A D | error_logging_utils_tests.cpp | 74 MockJournal& journal = services.getMockJournal(); in TEST() local 78 Entry::Level::Error, Ref(journal), in TEST() 116 MockJournal& journal = services.getMockJournal(); in TEST() local 118 logI2CError(Entry::Level::Critical, Ref(journal), in TEST() 152 MockJournal& journal = services.getMockJournal(); in TEST() local 154 logConfigFileError(Entry::Level::Warning, Ref(journal))) in TEST() 180 MockJournal& journal = services.getMockJournal(); in TEST() local 182 logConfigFileError(Entry::Level::Error, Ref(journal))) in TEST() 213 MockJournal& journal = services.getMockJournal(); in TEST() local 215 logPMBusError(Entry::Level::Error, Ref(journal), in TEST() [all …]
|
/openbmc/bmcweb/redfish-core/include/utils/ |
H A D | journal_utils.hpp | 27 inline int getJournalMetadata(sd_journal* journal, const char* field, in getJournalMetadata() argument 37 ret = sd_journal_get_data(journal, field, dataVoid, &length); in getJournalMetadata() 48 inline int getJournalMetadataInt(sd_journal* journal, const char* field, in getJournalMetadataInt() argument 53 int ret = getJournalMetadata(journal, field, metadata); in getJournalMetadataInt() 67 inline bool getEntryTimestamp(sd_journal* journal, std::string& entryTimestamp) in getEntryTimestamp() argument 71 ret = sd_journal_get_realtime_usec(journal, ×tamp); in getEntryTimestamp() 82 sd_journal* journal, nlohmann::json::object_t& bmcJournalLogEntryJson) in fillBMCJournalLogEntryJson() argument 85 int ret = sd_journal_get_cursor(journal, &cursor); in fillBMCJournalLogEntryJson() 96 ret = getJournalMetadata(journal, "SYSLOG_IDENTIFIER", syslogID); in fillBMCJournalLogEntryJson() 107 ret = getJournalMetadata(journal, "MESSAGE", msg); in fillBMCJournalLogEntryJson() [all …]
|
/openbmc/phosphor-fan-presence/monitor/ |
H A D | fan_error.cpp | 59 explicit JournalCloser(sd_journal* journal) : journal{journal} {} in JournalCloser() argument 63 sd_journal_close(journal); in ~JournalCloser() 67 sd_journal* journal{nullptr}; member in phosphor::fan::monitor::JournalCloser 212 sd_journal* journal; in getJournalEntries() local 213 int rc = sd_journal_open(&journal, SD_JOURNAL_LOCAL_ONLY); in getJournalEntries() 223 JournalCloser closer{journal}; in getJournalEntries() 234 rc = sd_journal_add_match(journal, match.c_str(), 0); in getJournalEntries() 249 SD_JOURNAL_FOREACH_BACKWARDS(journal) in getJournalEntries() 252 timeStamp = getTimeStamp(journal); in getJournalEntries() 253 syslogID = getFieldValue(journal, "SYSLOG_IDENTIFIER"); in getJournalEntries() [all …]
|
/openbmc/openpower-hw-diags/util/ |
H A D | ffdc.cpp | 20 std::string sdjGetFieldValue(sd_journal* journal, const char* field) in sdjGetFieldValue() argument 26 if (0 == sd_journal_get_data(journal, field, (const void**)&data, &length)) in sdjGetFieldValue() 67 sd_journal* journal; in sdjGetMessages() local 70 if (0 == sd_journal_open(&journal, SD_JOURNAL_LOCAL_ONLY)) in sdjGetMessages() 72 SD_JOURNAL_FOREACH_BACKWARDS(journal) in sdjGetMessages() 75 std::string value = sdjGetFieldValue(journal, field.c_str()); in sdjGetMessages() 82 sdjGetFieldValue(journal, "SYSLOG_IDENTIFIER"); in sdjGetMessages() 85 std::string pid = sdjGetFieldValue(journal, "_PID"); in sdjGetMessages() 88 std::string message = sdjGetFieldValue(journal, "MESSAGE"); in sdjGetMessages() 92 if (0 == sd_journal_get_realtime_usec(journal, &usec)) in sdjGetMessages() [all …]
|
/openbmc/bmcweb/redfish-core/lib/ |
H A D | manager_logservices_journal.hpp | 75 std::unique_ptr<sd_journal, decltype(&sd_journal_close)> journal; member 117 if (!fillBMCJournalLogEntryJson(readState.journal.get(), in readJournalEntries() 125 int ret = sd_journal_next(readState.journal.get()); in readJournalEntries() 187 std::unique_ptr<sd_journal, decltype(&sd_journal_close)> journal( in handleManagersJournalLogEntryCollectionGet() local 192 if (sd_journal_seek_tail(journal.get()) < 0) in handleManagersJournalLogEntryCollectionGet() 199 if (sd_journal_previous(journal.get()) < 0) in handleManagersJournalLogEntryCollectionGet() 209 if (sd_journal_get_seqnum(journal.get(), &endSeqNum, nullptr) < 0) in handleManagersJournalLogEntryCollectionGet() 218 if (sd_journal_seek_head(journal.get()) < 0) in handleManagersJournalLogEntryCollectionGet() 225 if (sd_journal_next(journal.get()) < 0) in handleManagersJournalLogEntryCollectionGet() 235 if (sd_journal_get_seqnum(journal.get(), &startSeqNum, nullptr) < 0) in handleManagersJournalLogEntryCollectionGet() [all …]
|
/openbmc/linux/Documentation/filesystems/ext4/ |
H A D | journal.rst | 6 Introduced in ext3, the ext4 filesystem employs a journal to protect the 8 to 10,240,000 file system blocks (see man mke2fs(8) for more details on journal 12 cache, a record of the data being committed is also written to the journal. At 13 some later point in time, the journal code writes the transactions to their 16 crash during the second slow write, the journal can be replayed all the 18 gets written through the journal to the disk. The effect of this is to 23 through the journal. This means that file data blocks are /not/ 26 option to control journal behavior. If ``data=journal``, all data and 27 metadata are written to disk through the journal. This is slower but 29 disk before the metadata are written to disk through the journal. [all …]
|
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-core/sdbus-c++/sdbus-c++-libsystemd/ |
H A D | 0010-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch | 23 src/libsystemd/sd-journal/journal-send.c | 5 +++++ 57 diff --git a/src/libsystemd/sd-journal/journal-send.c b/src/libsystemd/sd-journal/journal-send.c 59 --- a/src/libsystemd/sd-journal/journal-send.c 60 +++ b/src/libsystemd/sd-journal/journal-send.c
|
/openbmc/openbmc/poky/meta/recipes-core/systemd/systemd/ |
H A D | 0010-distinguish-XSI-compliant-strerror_r-from-GNU-specif.patch | 23 src/libsystemd/sd-journal/journal-send.c | 5 +++++ 57 diff --git a/src/libsystemd/sd-journal/journal-send.c b/src/libsystemd/sd-journal/journal-send.c 59 --- a/src/libsystemd/sd-journal/journal-send.c 60 +++ b/src/libsystemd/sd-journal/journal-send.c
|