* [Linux-ia64] [PATCH] set ar.k0 on APs
@ 2002-04-01 23:54 Bjorn Helgaas
2002-04-02 0:15 ` David Mosberger
0 siblings, 1 reply; 2+ messages in thread
From: Bjorn Helgaas @ 2002-04-01 23:54 UTC (permalink / raw)
To: linux-ia64
We currently set ar.k0 on the BP, but not on the APs. The following
patch does it for APs as well.
Apparently Intel firmware sets ar.k0, but HP firmware doesn't.
If the kernel doesn't set ar.k0, X won't start up on APs because
it uses ar.k0 to access I/O port space.
--
Bjorn Helgaas - bjorn_helgaas@hp.com
Linux Systems Operation R&D
Hewlett-Packard
diff -u -r linux-2.4.18-ia64-020226-orig/arch/ia64/kernel/smpboot.c linux-2.4.18-ia64-020226/arch/ia64/kernel/smpboot.c
--- linux-2.4.18-ia64-020226-orig/arch/ia64/kernel/smpboot.c Mon Apr 1 16:43:58 2002
+++ linux-2.4.18-ia64-020226/arch/ia64/kernel/smpboot.c Mon Apr 1 16:44:51 2002
@@ -68,6 +68,7 @@
extern void __init calibrate_delay(void);
extern void start_ap(void);
+extern unsigned long ia64_iobase;
int cpucount;
@@ -343,6 +344,11 @@
* Get our bogomips.
*/
ia64_init_itm();
+
+ /*
+ * Set I/O port base per CPU
+ */
+ ia64_set_kr(IA64_KR_IO_BASE, ia64_iobase & ~PAGE_OFFSET);
#ifdef CONFIG_IA64_MCA
ia64_mca_cmc_vector_setup(); /* Setup vector on AP & enable */
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Linux-ia64] [PATCH] set ar.k0 on APs
2002-04-01 23:54 [Linux-ia64] [PATCH] set ar.k0 on APs Bjorn Helgaas
@ 2002-04-02 0:15 ` David Mosberger
0 siblings, 0 replies; 2+ messages in thread
From: David Mosberger @ 2002-04-02 0:15 UTC (permalink / raw)
To: linux-ia64
>>>>> On Mon, 1 Apr 2002 16:54:20 -0700, Bjorn Helgaas <bjorn_helgaas@hp.com> said:
Bjorn> We currently set ar.k0 on the BP, but not on the APs. The following
Bjorn> patch does it for APs as well.
Bjorn> Apparently Intel firmware sets ar.k0, but HP firmware doesn't.
Bjorn> If the kernel doesn't set ar.k0, X won't start up on APs because
Bjorn> it uses ar.k0 to access I/O port space.
Sounds good.
Bjorn> + /*
Bjorn> + * Set I/O port base per CPU
Bjorn> + */
Bjorn> + ia64_set_kr(IA64_KR_IO_BASE, ia64_iobase & ~PAGE_OFFSET);
But you shouldn't mask anything with PAGE_OFFSET (it's a base-address,
not a mask). __pa() can be used instead. I see that setup.c had the
same problem, so I cleaned that up as well, plus I made it use
ioremap(), instead of hardcoding the formation of an uncachable
mapping).
Thanks,
--david
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-04-02 0:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-01 23:54 [Linux-ia64] [PATCH] set ar.k0 on APs Bjorn Helgaas
2002-04-02 0:15 ` David Mosberger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox