MCPcopy Create free account
hub / github.com/F-Stack/f-stack / dbuf_sync_list

Function dbuf_sync_list

freebsd/contrib/openzfs/module/zfs/dbuf.c:4322–4354  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4320}
4321
4322void
4323dbuf_sync_list(list_t *list, int level, dmu_tx_t *tx)
4324{
4325 dbuf_dirty_record_t *dr;
4326
4327 while ((dr = list_head(list))) {
4328 if (dr->dr_zio != NULL) {
4329 /*
4330 * If we find an already initialized zio then we
4331 * are processing the meta-dnode, and we have finished.
4332 * The dbufs for all dnodes are put back on the list
4333 * during processing, so that we can zio_wait()
4334 * these IOs after initiating all child IOs.
4335 */
4336 ASSERT3U(dr->dr_dbuf->db.db_object, ==,
4337 DMU_META_DNODE_OBJECT);
4338 break;
4339 }
4340 list_remove(list, dr);
4341 if (dr->dr_dbuf == NULL) {
4342 dbuf_sync_lightweight(dr, tx);
4343 } else {
4344 if (dr->dr_dbuf->db_blkid != DMU_BONUS_BLKID &&
4345 dr->dr_dbuf->db_blkid != DMU_SPILL_BLKID) {
4346 VERIFY3U(dr->dr_dbuf->db_level, ==, level);
4347 }
4348 if (dr->dr_dbuf->db_level > 0)
4349 dbuf_sync_indirect(dr, tx);
4350 else
4351 dbuf_sync_leaf(dr, tx);
4352 }
4353 }
4354}
4355
4356/* ARGSUSED */
4357static void

Callers 2

dbuf_sync_indirectFunction · 0.85
dnode_syncFunction · 0.85

Calls 5

dbuf_sync_lightweightFunction · 0.85
dbuf_sync_indirectFunction · 0.85
dbuf_sync_leafFunction · 0.85
list_headFunction · 0.50
list_removeFunction · 0.50

Tested by

no test coverage detected