lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1210606504.5880.32.camel@localhost>
Date:	Mon, 12 May 2008 08:35:04 -0700
From:	Joe Perches <joe@...ches.com>
To:	Vegard Nossum <vegard.nossum@...il.com>
Cc:	linux-kernel@...r.kernel.org,
	Andrew Morton <akpm@...ux-foundation.org>,
	Rob Landley <rob@...dley.net>
Subject: Re: [RFC/PATCH] printk: detect incomplete lines

On Mon, 2008-05-12 at 13:49 +0200, Vegard Nossum wrote:
> So we are now using __builtin_frame_address(). This should work everywhere
> and should not cause any harmful side effects.

Perhaps print an identifier using __builtin_frame_address(0)
to allow an external tool to reassemble complete messages?

> +	if (prev_caller != __builtin_frame_address(0) && !log_level_unknown) {
> +		emit_log_char('.');
> +		emit_log_char('.');
> +		emit_log_char('.');
> +		emit_log_char('\n');
> +		log_level_unknown = 1;
> +	}
> +
> +	prev_caller = __builtin_frame_address(0);
> +

maybe something like:

static void emit_log_id(void *addr)
{
	unsigned int i = 0;
	char id[sizeof(void *) * 2 + 6];
	sprintf(id, "{@%p}", addr);
	while (*id[i])
		emit_log_char(id[i++]);
}
...
	caller = __builtin_frame_address(0);
	if (prev_caller != caller && !log_level_unknown) {
		emit_log_id(caller);
		log_level_unknown = 1;
		prev_caller = caller;
	}


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ