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: <1317156234.26514.39.camel@gandalf.stny.rr.com>
Date:	Tue, 27 Sep 2011 16:43:52 -0400
From:	Steven Rostedt <rostedt@...dmis.org>
To:	"Rafael J. Wysocki" <rjw@...k.pl>
Cc:	tom.leiming@...il.com, stern@...land.harvard.edu,
	linux-pm@...ts.linux-foundation.org, linux-kernel@...r.kernel.org,
	mingo@...hat.com, fweisbec@...il.com,
	Ming Lei <ming.lei@...onical.com>
Subject: Re: [PATCH v1 1/2] PM/runtime: introduce trace points for tracing
 rpm_* functions

On Tue, 2011-09-27 at 22:36 +0200, Rafael J. Wysocki wrote:

> > 	TP_printk("%pS:%s ret=%d", (void *)__entry->ip, __get_str(name),
> > 		__entry->ret)
> > 
> > try that.
> 
> Well, that certainly will work, but is it the right fix?

Hehe, yes!  The pS means to take a pointer and return the string version
of the address. Like "schedule+0x3a". __entry->ip is the address of the
function that called it __THIS_IP__ but we want to convert that into a
string name.

We use ip because both perf and trace-cmd should be smart enough to
parse it too. As they both store the kallsyms into the data file.

The (void *) is used because pS wants a pointer, and we stored the
address as an unsigned long.

-- Steve


--
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