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]
Date:	Tue, 23 Oct 2012 15:57:26 +0200
From:	Andi Kleen <andi@...stfloor.org>
To:	Peter Zijlstra <a.p.zijlstra@...llo.nl>
Cc:	Andi Kleen <andi@...stfloor.org>, x86@...nel.org,
	linux-kernel@...r.kernel.org, acme@...hat.com, eranian@...gle.com,
	Andi Kleen <ak@...ux.intel.com>
Subject: Re: [PATCH 05/34] perf, x86: Report PEBS event in a raw format

On Tue, Oct 23, 2012 at 03:50:50PM +0200, Peter Zijlstra wrote:
> PERF_SAMPLE_RAW has a u32 size header and starts the data after that.
> This means you PERF_SAMPLE_RAW output ends up on a u32 aligned end
> address -- assuming the data is a u64 multiple, this is not good.
> 
> > It appears to work at least.
> 
> It would on x86, I'm fairly sure it'll break on things like SPARC. We
> used to have checks in the userspace code to warn for this on x86 as
> well. Not sure if that's still there.

Ok this is x86 specific code.

> 
> Hmm, so in kernel/events/core.c:perf_prepare_sample() there's a
> WARN_ON_ONCE() in the PERF_SAMPLE_RAW branch that should trigger with
> this.

Haven't seen this this warning so far.

If I added padding the perf userland would need to learn about it too,
I suspect it would need all the ugly macros like NETLINK. I always hated
those.

-Andi
-- 
ak@...ux.intel.com -- Speaking for myself only.
--
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