livepatch: Introduce klp_for_each_patch macro
There are already macros to iterate over struct klp_func and klp_object. Add also klp_for_each_patch(). But make it internal because also klp_patches list is internal. Suggested-by: Josh Poimboeuf <jpoimboe@redhat.com> Acked-by: Miroslav Benes <mbenes@suse.cz> Acked-by: Joe Lawrence <joe.lawrence@redhat.com> Signed-off-by: Petr Mladek <pmladek@suse.com>
This commit is contained in:
@@ -642,6 +642,6 @@ void klp_force_transition(void)
|
||||
for_each_possible_cpu(cpu)
|
||||
klp_update_patch_state(idle_task(cpu));
|
||||
|
||||
list_for_each_entry(patch, &klp_patches, list)
|
||||
klp_for_each_patch(patch)
|
||||
patch->forced = true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user