|
@@ -367,12 +367,15 @@ static void __jump_label_update(struct static_key *key,
|
|
|
{
|
|
|
for (; (entry < stop) && (jump_entry_key(entry) == key); entry++) {
|
|
|
/*
|
|
|
- * entry->code set to 0 invalidates module init text sections
|
|
|
- * kernel_text_address() verifies we are not in core kernel
|
|
|
- * init code, see jump_label_invalidate_module_init().
|
|
|
+ * An entry->code of 0 indicates an entry which has been
|
|
|
+ * disabled because it was in an init text area.
|
|
|
*/
|
|
|
- if (entry->code && kernel_text_address(entry->code))
|
|
|
- arch_jump_label_transform(entry, jump_label_type(entry));
|
|
|
+ if (entry->code) {
|
|
|
+ if (kernel_text_address(entry->code))
|
|
|
+ arch_jump_label_transform(entry, jump_label_type(entry));
|
|
|
+ else
|
|
|
+ WARN_ONCE(1, "can't patch jump_label at %pS", (void *)entry->code);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|