linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Ellerman <patch-notifications@ellerman.id.au>
To: Michael Ellerman <mpe@ellerman.id.au>, linuxppc-dev@ozlabs.org
Cc: oohall@gmail.com
Subject: Re: [v2] powerpc/64: Fix flush_(d|i)cache_range() called from modules
Date: Thu,  6 Apr 2017 23:09:05 +1000 (AEST)	[thread overview]
Message-ID: <3vzNMQ0Jcwz9s8S@ozlabs.org> (raw)
In-Reply-To: <1491392949-6879-1-git-send-email-mpe@ellerman.id.au>

On Wed, 2017-04-05 at 11:49:09 UTC, Michael Ellerman wrote:
> From: Oliver O'Halloran <oohall@gmail.com>
> 
> When the kernel is compiled to use 64bit ABIv2 the _GLOBAL() macro does
> not include a global entry point. A function's global entry point is
> used when the function is called from a different TOC context and in the
> kernel this typically means a call from a module into the vmlinux (or
> vice-versa).
> 
> There are a few exported asm functions declared with _GLOBAL() and
> calling them from a module will likely crash the kernel since any TOC
> relative load will yield garbage.
> 
> flush_icache_range() and flush_dcache_range() are both exported to
> modules, and use the TOC, so must use _GLOBAL_TOC().
> 
> Fixes: 721aeaa9fdf3 ("powerpc: Build little endian ppc64 kernel with ABIv2")
> Cc: stable@vger.kernel.org # v3.16+
> Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>

Applied to powerpc fixes.

https://git.kernel.org/powerpc/c/8f5f525d5b83f7d76a6baf9c4e94d4

cheers

      reply	other threads:[~2017-04-06 13:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-05 11:49 [PATCH v2] powerpc/64: Fix flush_(d|i)cache_range() called from modules Michael Ellerman
2017-04-06 13:09 ` Michael Ellerman [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=3vzNMQ0Jcwz9s8S@ozlabs.org \
    --to=patch-notifications@ellerman.id.au \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=oohall@gmail.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).