All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: "Luck, Tony" <tony.luck@intel.com>
Cc: Andy Whitcroft <apw@canonical.com>, Joe Perches <joe@perches.com>,
	Ingo Molnar <mingo@kernel.org>,
	linux-kernel@vger.kernel.org,
	Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: Re: [PATCH 20/22] tools arch: Sync arch/x86/lib/memcpy_64.S with the kernel
Date: Tue, 25 Apr 2017 11:13:14 -0300	[thread overview]
Message-ID: <20170425141314.GB3517@kernel.org> (raw)
In-Reply-To: <20170424203630.GA18000@intel.com>

Em Mon, Apr 24, 2017 at 01:36:30PM -0700, Luck, Tony escreveu:
> On Mon, Apr 24, 2017 at 04:54:37PM -0300, Arnaldo Carvalho de Melo wrote:
> > From: Arnaldo Carvalho de Melo <acme@redhat.com>

> > Just a minor fix done in:

> >   Fixes: 26a37ab319a2 ("x86/mce: Fix copy/paste error in exception table entries")

<SNIP>

> If we are going to have all these copies of kernel files below
> "tools/...", perhaps checkpatch could warn people touching one
> that the other needs the same update?

So, we have tools/perf/check-headers.sh that will warn, when building
tools/perf/, if some of the files we get from the kernel is out of
synch.

When we see this, we should look to see if the change will entail
changes in tools/, if it will drag some other header we don't need, etc.

Sometimes, like in this case, we don't want to pull extra headers, like
asm/export.h, so we have this in that check-headers.sh script:

[acme@jouet linux]$ tail -5 tools/perf/check-headers.sh
# diff with extra ignore lines
check arch/x86/lib/memcpy_64.S        -B -I "^EXPORT_SYMBOL" -I "^#include <asm/export.h>"
check arch/x86/lib/memset_64.S        -B -I "^EXPORT_SYMBOL" -I "^#include <asm/export.h>"
check include/uapi/asm-generic/mman.h -B -I "^#include <\(uapi/\)*asm-generic/mman-common.h>"
check include/uapi/linux/mman.h       -B -I "^#include <\(uapi/\)*asm/mman.h>"
[acme@jouet linux]$

I.e. we want to get as close to what is in the kernel as possible, but
with some exceptions.

And we don't want to add more work to the kernel developers, who can
continue working as if there is no tools/ in the tree.

For those who want to help tools/, then its just a matter of building
perf when doing changes to kernel headers.

We also want these copies because with:

  [acme@jouet linux]$ make help | grep perf
  perf-tar-src-pkg    - Build perf-4.11.0-rc6.tar source tarball
  perf-targz-src-pkg  - Build perf-4.11.0-rc6.tar.gz source tarball
  perf-tarbz2-src-pkg - Build perf-4.11.0-rc6.tar.bz2 source tarball
  perf-tarxz-src-pkg  - Build perf-4.11.0-rc6.tar.xz source tarball
[acme@jouet linux]$

We can create tarball with just what is needed to build perf, then get
that tarball and move to some other system and build a newer perf to run
in some older environment, older kernel, etc.

- Arnaldo

  parent reply	other threads:[~2017-04-25 14:13 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-24 19:54 [GIT PULL 00/22] perf/core improvements and fixes Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 01/22] perf unwind: Provide only forward declarations for pointer types Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 02/22] perf tools: Add signal.h to places using its definitions Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 03/22] perf tools: Move units conversion/formatting routines to separate object Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 04/22] perf tools: Move timestamp routines from util.h to time-utils.h Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 05/22] perf kvm: Make function only used by 'perf kvm' static Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 06/22] perf debug: Move dump_stack() and sighandler_dump_stack() to debug.h Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 07/22] perf mem: Fix display of data source snoop indication Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 08/22] perf tools: Add compress.h for the *_decompress_to_file() headers Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 09/22] perf callchain: Move callchain specific routines from util.[ch] Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 10/22] perf tools: Include sys/param.h where needed Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 11/22] perf tools: Remove a few more needless includes from util.h Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 12/22] perf tools: Remove sys/ioctl.h " Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 13/22] perf tools: Remove string.h " Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 14/22] perf tools: Remove stale prototypes from builtin.h Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 15/22] perf tools: Remove string.h, unistd.h and sys/stat.h from util.h Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 16/22] perf tools: Remove poll.h and wait.h " Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 17/22] perf tools: Add the right header to obtain PERF_ALIGN() Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 18/22] perf tools: Use just forward declarations for struct thread where possible Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 19/22] tools: Update asm-generic/mman-common.h copy from the kernel Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 20/22] tools arch: Sync arch/x86/lib/memcpy_64.S with " Arnaldo Carvalho de Melo
2017-04-24 20:36   ` Luck, Tony
2017-04-25  2:59     ` Joe Perches
2017-04-25 16:18       ` Luck, Tony
2017-04-25 16:28         ` Joe Perches
2017-04-25 14:13     ` Arnaldo Carvalho de Melo [this message]
2017-04-24 19:54 ` [PATCH 21/22] tools arch x86: Sync cpufeatures.h Arnaldo Carvalho de Melo
2017-04-24 19:54 ` [PATCH 22/22] perf tools: Fix the code to strip command name Arnaldo Carvalho de Melo
2017-04-24 20:08   ` David Ahern
2017-04-24 20:40 ` [GIT PULL 00/22] perf/core improvements and fixes Ingo Molnar

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=20170425141314.GB3517@kernel.org \
    --to=acme@kernel.org \
    --cc=acme@redhat.com \
    --cc=apw@canonical.com \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=tony.luck@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.