Unverified Commit fb4366ba authored by Christian Brauner's avatar Christian Brauner
Browse files

coredump: rename format_corename()

It's not really about the name anymore. It parses very distinct
information. Reflect that in the name.

Link: https://lore.kernel.org/20250612-work-coredump-massage-v1-1-315c0c34ba94@kernel.org


Signed-off-by: default avatarChristian Brauner <brauner@kernel.org>
parent e04f97c8
Loading
Loading
Loading
Loading
+7 −6
Original line number Diff line number Diff line
@@ -225,11 +225,12 @@ static int cn_print_exe_file(struct core_name *cn, bool name_only)
	return ret;
}

/* format_corename will inspect the pattern parameter, and output a
 * name into corename, which must have space for at least
 * CORENAME_MAX_SIZE bytes plus one byte for the zero terminator.
/*
 * coredump_parse will inspect the pattern parameter, and output a name
 * into corename, which must have space for at least CORENAME_MAX_SIZE
 * bytes plus one byte for the zero terminator.
 */
static int format_corename(struct core_name *cn, struct coredump_params *cprm,
static int coredump_parse(struct core_name *cn, struct coredump_params *cprm,
			  size_t **argv, int *argc)
{
	const struct cred *cred = current_cred();
@@ -910,7 +911,7 @@ void do_coredump(const kernel_siginfo_t *siginfo)

	old_cred = override_creds(cred);

	retval = format_corename(&cn, &cprm, &argv, &argc);
	retval = coredump_parse(&cn, &cprm, &argv, &argc);
	if (retval < 0) {
		coredump_report_failure("format_corename failed, aborting core");
		goto fail_unlock;