do_for_each_ftrace_rec(pg, rec) {
/*
- * Skip over free records and records that have
- * failed.
+ * Skip over free records, records that have
+ * failed and not converted.
*/
if (rec->flags & FTRACE_FL_FREE ||
- rec->flags & FTRACE_FL_FAILED)
+ rec->flags & FTRACE_FL_FAILED ||
+ rec->flags & FTRACE_FL_CONVERTED)
continue;
/* ignore updates to this record's mcount site */
}
failed = __ftrace_replace_code(rec, enable);
- if (failed && (rec->flags & FTRACE_FL_CONVERTED)) {
+ if (failed) {
rec->flags |= FTRACE_FL_FAILED;
if ((system_state == SYSTEM_BOOTING) ||
!core_kernel_text(rec->ip)) {