Lines Matching full:transaction

28 pub(crate) struct Transaction {  struct
31 pub(crate) from_parent: Option<DArc<Transaction>>, argument
49 impl ListArcSafe<0> for Transaction { untracked; } argument
52 impl Transaction { impl
55 from_parent: Option<DArc<Transaction>>, in new() argument
83 pr_warn!("Oneway transaction should not be in a transaction stack."); in new()
95 Ok(DTRWrap::arc_pin_init(pin_init!(Transaction { in new()
107 allocation <- kernel::new_spinlock!(Some(alloc.success()), "Transaction::new"), in new()
135 Ok(DTRWrap::arc_pin_init(pin_init!(Transaction { in new_reply()
147 allocation <- kernel::new_spinlock!(Some(alloc.success()), "Transaction::new"), in new_reply()
175 /// Determines if the transaction is stacked on top of the given transaction.
184 /// Returns a pointer to the next transaction on the transaction stack, if there is one.
189 /// Searches in the transaction stack for a thread that belongs to the target process. This is
190 /// useful when finding a target for a new transaction: if the node belongs to a process that
191 /// is already part of the transaction stack, we reuse the thread.
194 while let Some(transaction) = it { in find_target_thread()
195 if Arc::ptr_eq(&transaction.from.process, &self.to) { in find_target_thread()
196 return Some(transaction.from.clone()); in find_target_thread()
198 it = &transaction.from_parent; in find_target_thread()
203 /// Searches in the transaction stack for a transaction originating at the given thread.
204 pub(crate) fn find_from(&self, thread: &Thread) -> Option<&DArc<Transaction>> { in find_from() argument
206 while let Some(transaction) = it { in find_from()
207 if core::ptr::eq(thread, transaction.from.as_ref()) { in find_from()
208 return Some(transaction); in find_from()
211 it = &transaction.from_parent; in find_from()
228 // transaction. It also cannot race with `set_outstanding`, since submission happens in drop_outstanding_txn()
236 /// Submits the transaction to a work queue. Uses a thread if there is one in the transaction
258 // Save the transaction to be dropped after locks are released. in submit()
279 pr_err!("Failed to submit oneway transaction to node."); in submit()
308 /// Check whether one oneway transaction can supersede another.
309 pub(crate) fn can_replace(&self, old: &Transaction) -> bool { in can_replace()
344 impl DeliverToRead for Transaction { implementation
362 // transaction on the recipient. in do_work()
395 // Write the transaction code and data to the user buffer. in do_work()
406 // Dismiss the completion of transaction with a failure. No failure paths are allowed from in do_work()
419 // When this is not a reply and not a oneway transaction, update `current_transaction`. If in do_work()
432 // If this is not a reply or oneway transaction, then send a dead reply. in cancel()
452 impl PinnedDrop for Transaction { implementation