mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Namhyung Kim <namhyung@gmail.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>,
	x86@kernel.org, linux-kernel@vger.kernel.org,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Rusty Russell <rusty@rustcorp.com.au>
Subject: Re: [PATCH] x86: remove __phys_reloc_hide
Date: Mon, 09 Aug 2010 11:56:48 -0700	[thread overview]
Message-ID: <4C604F70.1040902@zytor.com> (raw)
In-Reply-To: <20100809080723.GD24221@elte.hu>

On 08/09/2010 01:07 AM, Ingo Molnar wrote:
> 
> * Namhyung Kim <namhyung@gmail.com> wrote:
> 
>> remove unnecessary use of RELOC_HIDE(). It only does simple addition of ptr
>> and offset, and in this case, offset 0, does nothing. It does NOT do anything
>> with linker relocation things. I could find no reason to use it.
>>
>> The only user of __phys_reloc_hide() was __pa_symbol() so it can be removed
>> safely here.
>>
>> Signed-off-by: Namhyung Kim <namhyung@gmail.com>
>> ---
>>  arch/x86/include/asm/page.h          |    5 ++---
>>  arch/x86/include/asm/page_32.h       |    1 -
>>  arch/x86/include/asm/page_64_types.h |    1 -
>>  3 files changed, 2 insertions(+), 5 deletions(-)
> 
> We do this as a general Voodoo barrier against GCC miscompilations.
> 
> You are right that it's largely moot by today (and especially so on x86 - i 
> only remember a single instance of miscompilation that Rusty mentioned few 
> years ago, and that was on powerpc), but the wrapper is simple enough, so 
> unless there's some real tangible improvement in the binary output we might as 
> well keep it.
> 
> Peter, what do you think?
> 

I agree... I suspect it might make some difference for gcc 3 stragglers.

	-hpa


      reply	other threads:[~2010-08-09 18:57 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-08 21:38 Namhyung Kim
2010-08-09  6:22 ` Andi Kleen
2010-08-09  6:40   ` Namhyung Kim
2010-08-09  6:44     ` Andi Kleen
2010-08-09  7:04       ` Namhyung Kim
2010-08-09  7:22         ` Andi Kleen
2010-08-09  7:47           ` Namhyung Kim
2010-08-09 18:56           ` H. Peter Anvin
2010-08-10  7:05             ` Ingo Molnar
2010-08-10 10:46               ` Namhyung Kim
2010-08-11  5:44                 ` Namhyung Kim
2010-08-11 19:09                   ` H. Peter Anvin
2010-08-11  6:37               ` [PATCH] x86: add a comment to __pa_symbol Namhyung Kim
2010-08-11  7:44                 ` [tip:x86/urgent] x86: Document __phys_reloc_hide() usage in __pa_symbol() tip-bot for Namhyung Kim
2018-06-19 23:00   ` [PATCH] x86: remove __phys_reloc_hide Thomas Gleixner
2010-08-09  8:07 ` Ingo Molnar
2010-08-09 18:56   ` H. Peter Anvin [this message]

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=4C604F70.1040902@zytor.com \
    --to=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=mingo@redhat.com \
    --cc=namhyung@gmail.com \
    --cc=rusty@rustcorp.com.au \
    --cc=tglx@linutronix.de \
    --cc=torvalds@linux-foundation.org \
    --cc=x86@kernel.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

Powered by JetHome