mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Michael Neuling <mikey@neuling.org>
Cc: Sonny Rao <sonnyrao@chromium.org>,
	acme@redhat.com, anton@samba.org,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Paul Mackerras <paulus@samba.org>, Ingo Molnar <mingo@elte.hu>,
	Arnaldo Carvalho de Melo <acme@ghostprotocols.net>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] [RFC] perf: robustify proc and debugfs file recording
Date: Wed, 13 Jul 2011 16:38:56 -0400	[thread overview]
Message-ID: <1310589536.3931.25.camel@gandalf.stny.rr.com> (raw)
In-Reply-To: <30671.1310554369@neuling.org>

On Wed, 2011-07-13 at 20:52 +1000, Michael Neuling wrote:

> Actually, here's an updated patch to fix these..
> 
> FYI perf record/annotate/report works fine on my powerpc box here with
> this.  I don't have modules handy so I've not tested that aspect.

Sure it worked for you...


> -static unsigned long get_size(const char *file)
> -{
> -	unsigned long long size = 0;
> -	int fd;
> -
> -	fd = open(file, O_RDONLY);
> -	if (fd < 0)
> -		die("Can't read '%s'", file);
> -	size = get_size_fd(fd);
>  	close(fd);
>  
> -	return size;
> +	/* ugh, handle big-endian hdr_size == 4 */
> +	sizep = (char*)&size;
> +	if (bigendian())
> +		sizep += sizeof(u64) - hdr_sz;
> +
> +	if (pwrite(output_fd, &size, hdr_sz, hdr_pos) < 0)

s/&size/sizep/

-- Steve

> +		die("writing to %s", output_file);
>  }



  parent reply	other threads:[~2011-07-13 20:39 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-12 21:15 Sonny Rao
2011-07-12 21:19 ` Sonny Rao
2011-07-12 22:56 ` Steven Rostedt
2011-07-12 23:01   ` Sonny Rao
2011-07-12 23:29     ` Steven Rostedt
2011-07-13 10:39 ` Michael Neuling
2011-07-13 10:52   ` Michael Neuling
2011-07-13 17:45     ` Sonny Rao
2011-07-13 20:38     ` Steven Rostedt [this message]
2011-07-13 20:49       ` Sonny Rao
2011-07-13 20:58         ` Sonny Rao
2011-07-14  0:18           ` Michael Neuling
2011-07-14  0:40             ` [PATCH] [RFCv2] " Sonny Rao
2011-07-14  2:57               ` Steven Rostedt
2011-07-14  3:34                 ` [PATCH] [RFCv3] " Michael Neuling
2011-07-14 12:45                   ` Steven Rostedt
2011-07-14 12:55                     ` Peter Zijlstra
2011-07-14 13:24                       ` Steven Rostedt
2011-07-14 21:38                     ` Michael Neuling
2011-07-14 21:54                       ` Steven Rostedt
2011-07-14 22:03                         ` Sonny Rao
2011-07-21  9:59                   ` [tip:perf/core] perf: Robustify " tip-bot for Sonny Rao
2011-07-13 16:50 ` [RFC] perf: robustify " Riccardo Magliocchetti

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1310589536.3931.25.camel@gandalf.stny.rr.com \
    --to=rostedt@goodmis.org \
    --cc=a.p.zijlstra@chello.nl \
    --cc=acme@ghostprotocols.net \
    --cc=acme@redhat.com \
    --cc=anton@samba.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mikey@neuling.org \
    --cc=mingo@elte.hu \
    --cc=paulus@samba.org \
    --cc=sonnyrao@chromium.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®