From: Wolfgang Denk <wd@denx.de>
To: zengshuai@sogou.com
Cc: ppc <linuxppc-embedded@ozlabs.org>
Subject: Re: eldk bug?how to fix
Date: Sun, 18 Dec 2005 15:44:53 +0100 [thread overview]
Message-ID: <20051218144453.68024352B33@atlas.denx.de> (raw)
In-Reply-To: Your message of "Sun, 18 Dec 2005 16:20:54 +0800." <4440987.1134894054475.JavaMail.postfix@mx3.mail.sohu.com>
In message <4440987.1134894054475.JavaMail.postfix@mx3.mail.sohu.com> you wrote:
> [root@localhost atmlz]# ppc_6xx-gcc -c -o temp atm_aalx.c
> atm_aalx.c: In function `main':
> atm_aalx.c:201: warning: return type of `main' is not `int'
> /tmp/cciJlehe.s: Assembler messages:
> /tmp/cciJlehe.s:916: Error: unsupported relocation against r3
> /tmp/cciJlehe.s:917: Error: unsupported relocation against r3
> /tmp/cciJlehe.s:917: Error: unsupported relocation against r3
> /tmp/cciJlehe.s:918: Error: unsupported relocation against r3
> /tmp/cciJlehe.s:918: Error: unsupported relocation against r3
> /tmp/cciJlehe.s:919: Error: unsupported relocation against r3
> /tmp/cciJlehe.s:3655: Error: unsupported relocation against r3
Are you by any chance using inline assembler code in your source
file? This is the only explanation I have, since GCC does not
generate "r3" references in it's assembler code.
It would have been a good idea if you had included your source code
so we could see what you are doing...
> [root@localhost atmlz]# ppc_6xx-gcc -S -o temp.s atm_aalx.c
> [root@localhost atmlz]# vi temp.s
> ...................
> stw 0,4(9)
> .L36:
> #APP
> mfmsr r3
> ori r3,r3,0x8000
> andi. r3,r3,0xffbf
> mtmsr r3
> #NO_APP
> lwz 11,0(1)
> ..............................
I see. This is your own assembler code, not something generated from
C source code.
> I must change those "r3" to "3" manually.
> How to fix?
Don't write incorrect assembler code, or use the required header
files (like ppc_asm.tmpl).
And while we are at it: be careful not to try privileged instructions
in user space.
This is your own error, not a problem with ELDK.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
If I had to live my life again, I'd make the same mistakes, only
sooner. -- Tallulah Bankhead
next prev parent reply other threads:[~2005-12-18 14:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-18 8:20 eldk bug?how to fix zengshuai
2005-12-18 14:44 ` Wolfgang Denk [this message]
2005-12-29 21:48 ` Theo Gjaltema
2005-12-30 21:13 ` Wolfgang Denk
-- strict thread matches above, loose matches on Subject: below --
2006-02-09 7:35 S. Egbert
2006-02-09 9:07 ` Wolfgang Denk
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=20051218144453.68024352B33@atlas.denx.de \
--to=wd@denx.de \
--cc=linuxppc-embedded@ozlabs.org \
--cc=zengshuai@sogou.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).