···3838from process context. However, this can fail in a similar manner.39394040Suppose that an RCU-based algorithm again scans a linked list containing4141-elements A, B, and C in process contexts, but that it invokes a function4141+elements A, B, and C in process context, but that it invokes a function4242on each element as it is scanned. Suppose further that this function4343deletes element B from the list, then passes it to call_rcu() for deferred4444freeing. This may be a bit unconventional, but it is perfectly legal···5959Suppose that call_rcu() is invoked while holding a lock, and that the6060callback function must acquire this same lock. In this case, if6161call_rcu() were to directly invoke the callback, the result would6262-be self-deadlock.6262+be self-deadlock *even if* this invocation occurred from a later6363+call_rcu() invocation a full grace period later.63646465In some cases, it would possible to restructure to code so that6566the call_rcu() is delayed until after the lock is released. However,···8584 What locking restriction must RCU callbacks respect?86858786:ref:`Answers to Quick Quiz <answer_quick_quiz_up>`8787+8888+It is important to note that userspace RCU implementations *do*8989+permit call_rcu() to directly invoke callbacks, but only if a full9090+grace period has elapsed since those callbacks were queued. This is9191+the case because some userspace environments are extremely constrained.9292+Nevertheless, people writing userspace RCU implementations are strongly9393+encouraged to avoid invoking callbacks from call_rcu(), thus obtaining9494+the deadlock-avoidance benefits called out above.88958996Summary9097-------