diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2000-07-21 22:00:56 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2000-07-21 22:00:56 +0000 |
commit | 168660f24dfc46c2702acbe4701a446f42a59578 (patch) | |
tree | f431368afbf6b1b71809cf3fd904d800ea126f4d /arch/alpha | |
parent | 6420f767924fa73b0ea267864d96820815f4ba5a (diff) |
Merge with Linux 2.4.0-test5-pre3.
Diffstat (limited to 'arch/alpha')
-rw-r--r-- | arch/alpha/boot/Makefile | 2 | ||||
-rw-r--r-- | arch/alpha/config.in | 7 | ||||
-rw-r--r-- | arch/alpha/kernel/core_cia.c | 12 | ||||
-rw-r--r-- | arch/alpha/kernel/core_titan.c | 11 | ||||
-rw-r--r-- | arch/alpha/kernel/irq_alpha.c | 2 | ||||
-rw-r--r-- | arch/alpha/kernel/osf_sys.c | 2 | ||||
-rw-r--r-- | arch/alpha/kernel/pci.c | 11 | ||||
-rw-r--r-- | arch/alpha/kernel/setup.c | 2 | ||||
-rw-r--r-- | arch/alpha/kernel/sys_cabriolet.c | 2 | ||||
-rw-r--r-- | arch/alpha/kernel/sys_dp264.c | 12 | ||||
-rw-r--r-- | arch/alpha/kernel/sys_eb64p.c | 9 | ||||
-rw-r--r-- | arch/alpha/kernel/sys_noritake.c | 37 |
12 files changed, 96 insertions, 13 deletions
diff --git a/arch/alpha/boot/Makefile b/arch/alpha/boot/Makefile index 6bd6cb03f..47a472524 100644 --- a/arch/alpha/boot/Makefile +++ b/arch/alpha/boot/Makefile @@ -80,7 +80,7 @@ tools/bootph: bootpheader $(OBJSTRIP) $(OBJSTRIP) -vb bootpheader tools/bootph $(OBJSTRIP): $(OBJSTRIP).c - $(HOSTCC) $(OBJSTRIP).c -o $(OBJSTRIP) + $(HOSTCC) $(HOSTCFLAGS) -I$(HPATH) $(OBJSTRIP).c -o $(OBJSTRIP) tools/mkbb: tools/mkbb.c $(HOSTCC) tools/mkbb.c -o tools/mkbb diff --git a/arch/alpha/config.in b/arch/alpha/config.in index 687994802..ed44cb67c 100644 --- a/arch/alpha/config.in +++ b/arch/alpha/config.in @@ -92,6 +92,10 @@ then define_bool CONFIG_ALPHA_EV4 y define_bool CONFIG_ALPHA_APECS y fi +if [ "$CONFIG_ALPHA_CABRIOLET" = "y" ] +then + define_bool CONFIG_ALPHA_EB64P y +fi if [ "$CONFIG_ALPHA_EB164" = "y" -o "$CONFIG_ALPHA_PC164" = "y" \ -o "$CONFIG_ALPHA_ALCOR" = "y" -o "$CONFIG_ALPHA_TAKARA" = "y" ] then @@ -175,7 +179,8 @@ if [ "$CONFIG_ALPHA_CABRIOLET" = "y" -o "$CONFIG_ALPHA_AVANTI" = "y" \ -o "$CONFIG_ALPHA_EB64P" = "y" -o "$CONFIG_ALPHA_PC164" = "y" \ -o "$CONFIG_ALPHA_TAKARA" = "y" -o "$CONFIG_ALPHA_EB164" = "y" \ -o "$CONFIG_ALPHA_ALCOR" = "y" -o "$CONFIG_ALPHA_MIATA" = "y" \ - -o "$CONFIG_ALPHA_LX164" = "y" -o "$CONFIG_ALPHA_SX164" = "y" ] + -o "$CONFIG_ALPHA_LX164" = "y" -o "$CONFIG_ALPHA_SX164" = "y" \ + -o "$CONFIG_ALPHA_NAUTILUS" = "y" ] then bool 'Use SRM as bootloader' CONFIG_ALPHA_SRM fi diff --git a/arch/alpha/kernel/core_cia.c b/arch/alpha/kernel/core_cia.c index 348bd843f..5aa00254b 100644 --- a/arch/alpha/kernel/core_cia.c +++ b/arch/alpha/kernel/core_cia.c @@ -779,8 +779,16 @@ cia_machine_check(unsigned long vector, unsigned long la_ptr, cia = (void *)(la_ptr + com->sys_offset); if (com->code == 0x202) { - printk(KERN_CRIT "CIA PCI machine check: err0=%08x " - "err1=%08x err2=%08x\n", + printk(KERN_CRIT "CIA PCI machine check: code=%x\n" + " cpu_err0=%08x cpu_err1=%08x cia_err=%08x\n" + " cia_stat=%08x err_mask=%08x cia_syn=%08x\n" + " mem_err0=%08x mem_err1=%08x\n" + " pci_err0=%08x pci_err1=%08x pci_err2=%08x\n", + (int) com->code, + (int) cia->cpu_err0, (int) cia->cpu_err1, + (int) cia->cia_err, (int) cia->cia_stat, + (int) cia->err_mask, (int) cia->cia_syn, + (int) cia->mem_err0, (int) cia->mem_err1, (int) cia->pci_err0, (int) cia->pci_err1, (int) cia->pci_err2); expected = 1; diff --git a/arch/alpha/kernel/core_titan.c b/arch/alpha/kernel/core_titan.c index fac75cab5..5e53d091c 100644 --- a/arch/alpha/kernel/core_titan.c +++ b/arch/alpha/kernel/core_titan.c @@ -284,6 +284,17 @@ titan_init_one_pachip_port(titan_pachip_port *port, int index) hose->io_space = alloc_resource(); hose->mem_space = alloc_resource(); + /* This is for userland consumption. For some reason, the 40-bit + PIO bias that we use in the kernel through KSEG didn't work for + the page table based user mappings. So make sure we get the + 43-bit PIO bias. */ + hose->sparse_mem_base = 0; + hose->sparse_io_base = 0; + hose->dense_mem_base + = (TITAN_MEM(index) & 0xffffffffff) | 0x80000000000; + hose->dense_io_base + = (TITAN_IO(index) & 0xffffffffff) | 0x80000000000; + hose->config_space_base = TITAN_CONF(index); hose->index = index; diff --git a/arch/alpha/kernel/irq_alpha.c b/arch/alpha/kernel/irq_alpha.c index ff1570406..066af7e1e 100644 --- a/arch/alpha/kernel/irq_alpha.c +++ b/arch/alpha/kernel/irq_alpha.c @@ -180,7 +180,7 @@ process_mcheck_info(unsigned long vector, unsigned long la_ptr, case 0x202: reason = "system detected hard error"; break; case 0x203: reason = "system detected uncorrectable ECC error"; break; case 0x204: reason = "SIO SERR occurred on PCI bus"; break; - case 0x205: reason = "parity error detected by CIA"; break; + case 0x205: reason = "parity error detected by core logic"; break; case 0x206: reason = "SIO IOCHK occurred on ISA bus"; break; case 0x207: reason = "non-existent memory error"; break; case 0x208: reason = "MCHK_K_DCSR"; break; diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index fd5c2b5e1..6102f2213 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c @@ -1076,7 +1076,7 @@ osf_select(int n, fd_set *inp, fd_set *outp, fd_set *exp, } ret = -EINVAL; - if (n < 0 || n > KFDS_NR) + if (n < 0 || n > current->files->max_fdset) goto out_nofds; /* diff --git a/arch/alpha/kernel/pci.c b/arch/alpha/kernel/pci.c index 2dc6f00dd..1b83bdfb9 100644 --- a/arch/alpha/kernel/pci.c +++ b/arch/alpha/kernel/pci.c @@ -535,6 +535,12 @@ sys_pciconfig_iobase(long which, unsigned long bus, unsigned long dfn) struct pci_controler *hose; struct pci_dev *dev; + /* from hose or from bus.devfn */ + if (which & IOBASE_FROM_HOSE) { + for(hose = hose_head; hose; hose = hose->next) + if (hose->index == bus) break; + if (!hose) return -ENODEV; + } else { /* Special hook for ISA access. */ if (bus == 0 && dfn == 0) { hose = pci_isa_hose; @@ -544,8 +550,9 @@ sys_pciconfig_iobase(long which, unsigned long bus, unsigned long dfn) return -ENODEV; hose = dev->sysdata; } + } - switch (which) { + switch (which & ~IOBASE_FROM_HOSE) { case IOBASE_HOSE: return hose->index; case IOBASE_SPARSE_MEM: @@ -556,6 +563,8 @@ sys_pciconfig_iobase(long which, unsigned long bus, unsigned long dfn) return hose->sparse_io_base; case IOBASE_DENSE_IO: return hose->dense_io_base; + case IOBASE_ROOT_BUS: + return hose->bus->number; } return -EOPNOTSUPP; diff --git a/arch/alpha/kernel/setup.c b/arch/alpha/kernel/setup.c index 073ee5381..4aded0d6a 100644 --- a/arch/alpha/kernel/setup.c +++ b/arch/alpha/kernel/setup.c @@ -752,7 +752,7 @@ get_sysvec(long type, long variation, long cpu) { &eb64p_mv, &cabriolet_mv, - NULL /* AlphaPCI64 */ + &cabriolet_mv /* AlphaPCI64 */ }; static struct alpha_machine_vector *eb66_vecs[] __initlocaldata = diff --git a/arch/alpha/kernel/sys_cabriolet.c b/arch/alpha/kernel/sys_cabriolet.c index 9b2b39d73..8f456ca54 100644 --- a/arch/alpha/kernel/sys_cabriolet.c +++ b/arch/alpha/kernel/sys_cabriolet.c @@ -323,8 +323,10 @@ struct alpha_machine_vector cabriolet_mv __initmv = { pci_map_irq: cabriolet_map_irq, pci_swizzle: common_swizzle, }; +#ifndef CONFIG_ALPHA_EB64P ALIAS_MV(cabriolet) #endif +#endif #if defined(CONFIG_ALPHA_GENERIC) || defined(CONFIG_ALPHA_EB164) struct alpha_machine_vector eb164_mv __initmv = { diff --git a/arch/alpha/kernel/sys_dp264.c b/arch/alpha/kernel/sys_dp264.c index 88f4afd68..9f9993b6a 100644 --- a/arch/alpha/kernel/sys_dp264.c +++ b/arch/alpha/kernel/sys_dp264.c @@ -545,6 +545,16 @@ monet_init_pci(void) es1888_init(); } +static void __init +webbrick_init_arch(void) +{ + tsunami_init_arch(); + + /* Tsunami caches 4 PTEs at a time; DS10 has only 1 hose. */ + hose_head->sg_isa->align_entry = 4; + hose_head->sg_pci->align_entry = 4; +} + /* * The System Vectors @@ -611,7 +621,7 @@ struct alpha_machine_vector webbrick_mv __initmv = { nr_irqs: 64, device_interrupt: dp264_device_interrupt, - init_arch: tsunami_init_arch, + init_arch: webbrick_init_arch, init_irq: dp264_init_irq, init_rtc: common_init_rtc, init_pci: common_init_pci, diff --git a/arch/alpha/kernel/sys_eb64p.c b/arch/alpha/kernel/sys_eb64p.c index b3e9e3867..6acbef05c 100644 --- a/arch/alpha/kernel/sys_eb64p.c +++ b/arch/alpha/kernel/sys_eb64p.c @@ -26,6 +26,7 @@ #include <asm/pgtable.h> #include <asm/core_apecs.h> #include <asm/core_lca.h> +#include <asm/hwrpb.h> #include "proto.h" #include "irq_impl.h" @@ -108,7 +109,7 @@ eb64p_init_irq(void) { long i; -#ifdef CONFIG_ALPHA_GENERIC +#if defined(CONFIG_ALPHA_GENERIC) || defined(CONFIG_ALPHA_CABRIOLET) /* * CABRIO SRM may not set variation correctly, so here we test * the high word of the interrupt summary register for the RAZ @@ -116,6 +117,12 @@ eb64p_init_irq(void) */ if (inw(0x806) != 0xffff) { extern struct alpha_machine_vector cabriolet_mv; + + printk("Detected Cabriolet: correcting HWRPB.\n"); + + hwrpb->sys_variation |= 2L << 10; + hwrpb_update_checksum(hwrpb); + alpha_mv = cabriolet_mv; alpha_mv.init_irq(); return; diff --git a/arch/alpha/kernel/sys_noritake.c b/arch/alpha/kernel/sys_noritake.c index 8ef79db13..6e777c3ab 100644 --- a/arch/alpha/kernel/sys_noritake.c +++ b/arch/alpha/kernel/sys_noritake.c @@ -40,8 +40,10 @@ static inline void noritake_update_irq_hw(int irq, int mask) { int port = 0x54a; - if (irq >= 16) mask >>= 16; - if (irq >= 16) port = 0x54c; + if (irq >= 32) { + mask >>= 16; + port = 0x54c; + } outw(mask, port); } @@ -260,6 +262,35 @@ noritake_swizzle(struct pci_dev *dev, u8 *pinp) return slot; } +#if defined(CONFIG_ALPHA_GENERIC) || !defined(CONFIG_ALPHA_PRIMO) +static void +noritake_apecs_machine_check(unsigned long vector, unsigned long la_ptr, + struct pt_regs * regs) +{ +#define MCHK_NO_DEVSEL 0x205U +#define MCHK_NO_TABT 0x204U + + struct el_common *mchk_header; + unsigned int code; + + mchk_header = (struct el_common *)la_ptr; + + /* Clear the error before any reporting. */ + mb(); + mb(); /* magic */ + draina(); + apecs_pci_clr_err(); + wrmces(0x7); + mb(); + + code = mchk_header->code; + process_mcheck_info(vector, la_ptr, regs, "NORITAKE APECS", + (mcheck_expected(0) + && (code == MCHK_NO_DEVSEL + || code == MCHK_NO_TABT))); +} +#endif + /* * The System Vectors @@ -272,7 +303,7 @@ struct alpha_machine_vector noritake_mv __initmv = { DO_DEFAULT_RTC, DO_APECS_IO, DO_APECS_BUS, - machine_check: apecs_machine_check, + machine_check: noritake_apecs_machine_check, max_dma_address: ALPHA_MAX_DMA_ADDRESS, min_io_address: EISA_DEFAULT_IO_BASE, min_mem_address: APECS_AND_LCA_DEFAULT_MEM_BASE, |