Skip to content

Commit

Permalink
panic: remove oops_id
Browse files Browse the repository at this point in the history
The oops id has been added as part of the end of trace marker for the
kerneloops.org project.  The id is used to automatically identify
duplicate submissions of the same report.  Identical looking reports
with different a id can be considered as the same oops occurred again.

The early initialisation of the oops_id can create a warning if the
random core is not yet fully initialized.  On PREEMPT_RT it is
problematic if the id is initialized on demand from non preemptible
context.

The kernel oops project is not available since 2017.  Remove the oops_id
and use 0 in the output in case parser rely on it.

Link: https://bugs.debian.org/953172
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Sebastian Andrzej Siewior <[email protected]>
Cc: Arjan van de Ven <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Sebastian Andrzej Siewior authored and torvalds committed Jan 20, 2022
1 parent 23b36fe commit e83a447
Showing 1 changed file with 1 addition and 18 deletions.
19 changes: 1 addition & 18 deletions kernel/panic.c
Original file line number Diff line number Diff line change
Expand Up @@ -534,26 +534,9 @@ void oops_enter(void)
trigger_all_cpu_backtrace();
}

/*
* 64-bit random ID for oopses:
*/
static u64 oops_id;

static int init_oops_id(void)
{
if (!oops_id)
get_random_bytes(&oops_id, sizeof(oops_id));
else
oops_id++;

return 0;
}
late_initcall(init_oops_id);

static void print_oops_end_marker(void)
{
init_oops_id();
pr_warn("---[ end trace %016llx ]---\n", (unsigned long long)oops_id);
pr_warn("---[ end trace %016llx ]---\n", 0ULL);
}

/*
Expand Down

0 comments on commit e83a447

Please sign in to comment.