From: "Jan Beulich" <jbeulich@novell.com>
To: <mingo@elte.hu>, "Andi Kleen" <andi@firstfloor.org>,
<tglx@linutronix.de>, <hpa@zytor.com>
Cc: <linux-kernel@vger.kernel.org>
Subject: x86-64: __pa_symbol() vs. __pa()
Date: Tue, 09 Dec 2008 10:05:02 +0000 [thread overview]
Message-ID: <493E50DE.76E4.0078.0@novell.com> (raw)
Can any of you recall the reason for the comment accompanying the
__pa_symbol() definition:
/* __pa_symbol should be used for C visible symbols.
This seems to be the official gcc blessed way to do such arithmetic. */
To me this rather sounds like a compiler problem, and if it indeed
exists then at least a few incorrect use have slipped in recently:
- arch/x86/mm/ioremap.c passes bm_pte to __pa()
- arch/x86/mm/pageattr.c passes _text and __{start,end}_rodata
to __pa()
- arch/x86/mm/pgtable.c and arch/x86/xen/smp.c pass
swapper_pg_dir to __pa()
- arch/x86/xen/enlighten passes level3_user_vsyscall to __pa()
This is only the set where x86-64 (which prior to the merge had
above comment already) is affected, i386 would have a few more.
What would be particularly problematic is the potential indirect use
of __pa(), e.g. through Xen's virt_to_{machine,bus}() as well as
the use in common code (e.g. kernel/kexec.c).
Thanks, Jan
next reply other threads:[~2008-12-09 10:04 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-09 10:05 Jan Beulich [this message]
2008-12-09 11:15 ` Andi Kleen
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=493E50DE.76E4.0078.0@novell.com \
--to=jbeulich@novell.com \
--cc=andi@firstfloor.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®