From: Paul Mundt <lethal@linux-sh.org>
To: Adrian Bunk <bunk@kernel.org>
Cc: Huang Ying <ying.huang@intel.com>,
Vivek Goyal <vgoyal@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
ebiederm@xmission.com, linux-sh@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: sh kexec build error
Date: Mon, 28 Jul 2008 13:14:44 +0000 [thread overview]
Message-ID: <20080728131444.GA15942@linux-sh.org> (raw)
In-Reply-To: <20080728130613.GB30612@cs181140183.pp.htv.fi>
On Mon, Jul 28, 2008 at 04:06:13PM +0300, Adrian Bunk wrote:
> Commit 3ab83521378268044a448113c6aa9a9e245f4d2f (kexec jump)
> causes the following build error on sh:
>
> <-- snip -->
>
> ...
> CC kernel/kexec.o
> {standard input}: Assembler messages:
> {standard input}:1518: Error: offset to unaligned destination
> make[2]: *** [kernel/kexec.o] Error 1
>
> <-- snip -->
>
> If I understand the assembler correctly it fails at
> include/asm-sh/kexec.h:59
>
Indeed. This should fix it:
---
diff --git a/include/asm-sh/processor_32.h b/include/asm-sh/processor_32.h
index c6583f2..0dadd75 100644
--- a/include/asm-sh/processor_32.h
+++ b/include/asm-sh/processor_32.h
@@ -19,7 +19,7 @@
* Default implementation of macro that returns current
* instruction pointer ("program counter").
*/
-#define current_text_addr() ({ void *pc; __asm__("mova 1f, %0\n1:":"=z" (pc)); pc; })
+#define current_text_addr() ({ void *pc; __asm__("mova 1f, %0\n.align 2\n1:":"=z" (pc)); pc; })
/* Core Processor Version Register */
#define CCN_PVR 0xff000030
WARNING: multiple messages have this Message-ID (diff)
From: Paul Mundt <lethal@linux-sh.org>
To: Adrian Bunk <bunk@kernel.org>
Cc: Huang Ying <ying.huang@intel.com>,
Vivek Goyal <vgoyal@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
ebiederm@xmission.com, linux-sh@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: sh kexec build error
Date: Mon, 28 Jul 2008 22:14:44 +0900 [thread overview]
Message-ID: <20080728131444.GA15942@linux-sh.org> (raw)
In-Reply-To: <20080728130613.GB30612@cs181140183.pp.htv.fi>
On Mon, Jul 28, 2008 at 04:06:13PM +0300, Adrian Bunk wrote:
> Commit 3ab83521378268044a448113c6aa9a9e245f4d2f (kexec jump)
> causes the following build error on sh:
>
> <-- snip -->
>
> ...
> CC kernel/kexec.o
> {standard input}: Assembler messages:
> {standard input}:1518: Error: offset to unaligned destination
> make[2]: *** [kernel/kexec.o] Error 1
>
> <-- snip -->
>
> If I understand the assembler correctly it fails at
> include/asm-sh/kexec.h:59
>
Indeed. This should fix it:
---
diff --git a/include/asm-sh/processor_32.h b/include/asm-sh/processor_32.h
index c6583f2..0dadd75 100644
--- a/include/asm-sh/processor_32.h
+++ b/include/asm-sh/processor_32.h
@@ -19,7 +19,7 @@
* Default implementation of macro that returns current
* instruction pointer ("program counter").
*/
-#define current_text_addr() ({ void *pc; __asm__("mova 1f, %0\n1:":"=z" (pc)); pc; })
+#define current_text_addr() ({ void *pc; __asm__("mova 1f, %0\n.align 2\n1:":"=z" (pc)); pc; })
/* Core Processor Version Register */
#define CCN_PVR 0xff000030
next prev parent reply other threads:[~2008-07-28 13:14 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-28 13:06 sh kexec build error Adrian Bunk
2008-07-28 13:06 ` Adrian Bunk
2008-07-28 13:14 ` Paul Mundt [this message]
2008-07-28 13:14 ` Paul Mundt
2008-07-28 16:10 ` Adrian Bunk
2008-07-28 16:10 ` Adrian Bunk
2008-07-28 16:17 ` Paul Mundt
2008-07-28 16:17 ` Paul Mundt
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=20080728131444.GA15942@linux-sh.org \
--to=lethal@linux-sh.org \
--cc=akpm@linux-foundation.org \
--cc=bunk@kernel.org \
--cc=ebiederm@xmission.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sh@vger.kernel.org \
--cc=vgoyal@redhat.com \
--cc=ying.huang@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.