The direct implication of the comment and the lock dance with the
temporary list and the processed flag is that stuff can be added to the
ima_keys list after you drop the mutex. Your explanation in the prior
couple of emails says that nothing can be added because the
ima_process_keys flag setting prevents it. If the latter is true, you
can simply drop the lock after setting the flag and rely on ima_keys
not changing to run it through process_buffer_measurement without
needing any of the intermediate list or the processed flag. If the
latter isn't true then any key added to ima_keys after the mutex is
dropped is never processed.
James