linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@gmail.com>
To: Stuart Menefy <stuart.menefy@st.com>
Cc: Paul Mundt <lethal@linux-sh.org>,
	"linux-sh@vger.kernel.org" <linux-sh@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] sh: remove RELOC_HIDE on exception handlers and
Date: Tue, 10 Aug 2010 03:09:43 +0000	[thread overview]
Message-ID: <1281409783.1670.14.camel@leonhard> (raw)
In-Reply-To: <4C601ECD.2070503@st.com>

2010-08-09 (ì›”), 16:29 +0100, Stuart Menefy:
> Unfortunately these are necessary, although it is nothing to do with linker
> relocation. These functions take a struct pt_regs as a parameter (not a
> pointer), and modify some of the fields of that structure. We needed a way
> to ensure that gcc didn't optimise away those assignments - to gcc
> they appear to be assignments to a local variable, so quite legitimately
> get optimised away. So we used RELOC_HIDE() as a way of doing that.
> 

Oh, I didn't know that. Thank you for the comments.


> A clearer way to do this would be to pass in a struct pt_regs pointer,
> but that would require going via a stub function which loads up the
> pointer.
> 
> Stuart
> 

So is it worth if I'm gonna work on it?


-- 
Regards,
Namhyung Kim



      reply	other threads:[~2010-08-10  3:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-08 20:53 [PATCH] sh: remove RELOC_HIDE on exception handlers and syscall routines Namhyung Kim
2010-08-09 15:29 ` [PATCH] sh: remove RELOC_HIDE on exception handlers and syscall Stuart Menefy
2010-08-10  3:09   ` Namhyung Kim [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=1281409783.1670.14.camel@leonhard \
    --to=namhyung@gmail.com \
    --cc=lethal@linux-sh.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=stuart.menefy@st.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).