Hello, I've been looking at the source code to the transaction engine / DMU and was wondering what the purpose of dn->dn_assigned_txg was for? Looking through the source, I've found the dmu_tx structure but I'm afraid I don't understand it fully and need some extra comments/help here.
The reason I ask is this line of code within dmu_tx_try_assign() (from opensolaris source) : 757 if (dn->dn_assigned_txg == tx->tx_txg - 1) { If this condition is true, then tx->tx_needassign_txh is set, which has an impact later on if dmu_tx_wait() is called. In simple terms, what are we trying to test for here? Which brings me onto the next part - for the most part, I see that dmu_tx_wait ends up calling txg_wait_open() to move the transaction engine along, but when tx_needassign_txh is set we end up taking the other condition. Could someone tell me what this branch of dmu_tx_wait() is designed to do? Apologies if these are dumb questions. Many thanks, Jason