Commit ed2f05a9 authored by Tom Rini's avatar Tom Rini

Merge kernel.crashing.org:/home/trini/work/kernel/pristine/linux-2.6

into kernel.crashing.org:/home/trini/work/kernel/pristine/for-linus-ppc
parents 7ce42ae1 bcd1182e
...@@ -763,7 +763,7 @@ static void siccuart_change_speed(struct SICC_info *info, struct termios *old_te ...@@ -763,7 +763,7 @@ static void siccuart_change_speed(struct SICC_info *info, struct termios *old_te
cflag = info->tty->termios->c_cflag; cflag = info->tty->termios->c_cflag;
#if DEBUG #ifdef DEBUG
printk("siccuart_set_cflag(0x%x) called\n", cflag); printk("siccuart_set_cflag(0x%x) called\n", cflag);
#endif #endif
/* byte size and parity */ /* byte size and parity */
...@@ -1027,7 +1027,7 @@ static void siccuart_flush_buffer(struct tty_struct *tty) ...@@ -1027,7 +1027,7 @@ static void siccuart_flush_buffer(struct tty_struct *tty)
struct SICC_info *info = tty->driver_data; struct SICC_info *info = tty->driver_data;
unsigned long flags; unsigned long flags;
#if DEBUG #ifdef DEBUG
printk("siccuart_flush_buffer(%d) called\n", tty->index); printk("siccuart_flush_buffer(%d) called\n", tty->index);
#endif #endif
save_flags(flags); cli(); save_flags(flags); cli();
...@@ -1433,7 +1433,7 @@ static void siccuart_close(struct tty_struct *tty, struct file *filp) ...@@ -1433,7 +1433,7 @@ static void siccuart_close(struct tty_struct *tty, struct file *filp)
state = info->state; state = info->state;
#if DEBUG #ifdef DEBUG
//printk("siccuart_close() called\n"); //printk("siccuart_close() called\n");
#endif #endif
...@@ -1544,7 +1544,7 @@ static void siccuart_wait_until_sent(struct tty_struct *tty, int timeout) ...@@ -1544,7 +1544,7 @@ static void siccuart_wait_until_sent(struct tty_struct *tty, int timeout)
timeout = 2 * info->timeout; timeout = 2 * info->timeout;
expire = jiffies + timeout; expire = jiffies + timeout;
#if DEBUG #ifdef DEBUG
printk("siccuart_wait_until_sent(%d), jiff=%lu, expire=%lu char_time=%lu...\n", printk("siccuart_wait_until_sent(%d), jiff=%lu, expire=%lu char_time=%lu...\n",
tty->index, jiffies, tty->index, jiffies,
expire, char_time); expire, char_time);
...@@ -1831,7 +1831,7 @@ static int siccuart_console_read(struct console *co, const char *s, u_int count) ...@@ -1831,7 +1831,7 @@ static int siccuart_console_read(struct console *co, const char *s, u_int count)
unsigned int status; unsigned int status;
char *w; char *w;
int c; int c;
#if DEBUG #ifdef DEBUG
printk("siccuart_console_read() called\n"); printk("siccuart_console_read() called\n");
#endif #endif
......
...@@ -155,7 +155,7 @@ static unsigned long break_pressed; /* break, really ... */ ...@@ -155,7 +155,7 @@ static unsigned long break_pressed; /* break, really ... */
static struct serial_state rs_table[] = { static struct serial_state rs_table[] = {
/* UART CLK PORT IRQ FLAGS NUM */ /* UART CLK PORT IRQ FLAGS NUM */
{ 0, 0, PROFF_SMC1, SIU_INT_SMC1, 0, 0 }, /* SMC1 ttyS0 */ { 0, 0, PROFF_SMC1, SIU_INT_SMC1, 0, 0 }, /* SMC1 ttyS0 */
#if USE_SMC2 #ifdef USE_SMC2
{ 0, 0, PROFF_SMC2, SIU_INT_SMC2, 0, 1 }, /* SMC2 ttyS1 */ { 0, 0, PROFF_SMC2, SIU_INT_SMC2, 0, 1 }, /* SMC2 ttyS1 */
#endif #endif
#ifndef CONFIG_SCC1_ENET #ifndef CONFIG_SCC1_ENET
...@@ -2565,7 +2565,7 @@ static int __init rs_8xx_init(void) ...@@ -2565,7 +2565,7 @@ static int __init rs_8xx_init(void)
io->iop_pdird |= 0x00400000; io->iop_pdird |= 0x00400000;
io->iop_pdird &= ~0x00800000; io->iop_pdird &= ~0x00800000;
io->iop_psord &= ~0x00c00000; io->iop_psord &= ~0x00c00000;
#if USE_SMC2 #ifdef USE_SMC2
io->iop_ppara |= 0x00c00000; io->iop_ppara |= 0x00c00000;
io->iop_pdira |= 0x00400000; io->iop_pdira |= 0x00400000;
io->iop_pdira &= ~0x00800000; io->iop_pdira &= ~0x00800000;
......
...@@ -627,9 +627,14 @@ config EPIC_SERIAL_MODE ...@@ -627,9 +627,14 @@ config EPIC_SERIAL_MODE
depends on 6xx && (LOPEC || SANDPOINT) depends on 6xx && (LOPEC || SANDPOINT)
default y default y
config MPC10X_BRIDGE
bool
depends on PCORE || POWERPMC250 || LOPEC || SANDPOINT
default y
config MPC10X_STORE_GATHERING config MPC10X_STORE_GATHERING
bool "Enable MPC10x store gathering" bool "Enable MPC10x store gathering"
depends on FORCE || SANDPOINT depends on MPC10X_BRIDGE
config CPC710_DATA_GATHERING config CPC710_DATA_GATHERING
bool "Enable CPC710 data gathering" bool "Enable CPC710 data gathering"
......
...@@ -13,7 +13,7 @@ $(obj)/vmlinux.bin: vmlinux FORCE ...@@ -13,7 +13,7 @@ $(obj)/vmlinux.bin: vmlinux FORCE
$(obj)/vmlinux.gz: $(obj)/vmlinux.bin FORCE $(obj)/vmlinux.gz: $(obj)/vmlinux.bin FORCE
$(call if_changed,gzip) $(call if_changed,gzip)
quite_cmd_uimage = UIMAGE $@ quiet_cmd_uimage = UIMAGE $@
cmd_uimage = $(CONFIG_SHELL) $(MKIMAGE) -A ppc -O linux -T kernel \ cmd_uimage = $(CONFIG_SHELL) $(MKIMAGE) -A ppc -O linux -T kernel \
-C gzip -a 00000000 -e 00000000 -n 'Linux-$(KERNELRELEASE)' \ -C gzip -a 00000000 -e 00000000 -n 'Linux-$(KERNELRELEASE)' \
-d $< $@ -d $< $@
......
...@@ -75,7 +75,7 @@ $(obj)/image.initrd.o: $(obj)/image.o $(images)/ramdisk.image.gz FORCE ...@@ -75,7 +75,7 @@ $(obj)/image.initrd.o: $(obj)/image.o $(images)/ramdisk.image.gz FORCE
$(call if_changed,genimage-initrd) $(call if_changed,genimage-initrd)
# Create the note section for New-World PowerMacs. # Create the note section for New-World PowerMacs.
quit_cmd_mknote = MKNOTE $@ quiet_cmd_mknote = MKNOTE $@
cmd_mknote = $(utils)/mknote > $@ cmd_mknote = $(utils)/mknote > $@
targets += note targets += note
$(obj)/note: $(utils)/mknote FORCE $(obj)/note: $(utils)/mknote FORCE
......
...@@ -8,7 +8,6 @@ ...@@ -8,7 +8,6 @@
#include <linux/config.h> #include <linux/config.h>
#include <linux/types.h> #include <linux/types.h>
#include <linux/elf.h>
#include <linux/string.h> #include <linux/string.h>
#include <asm/bootinfo.h> #include <asm/bootinfo.h>
#include <asm/mmu.h> #include <asm/mmu.h>
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
*/ */
#include <linux/types.h> #include <linux/types.h>
#include <linux/elf.h>
#include <linux/config.h> #include <linux/config.h>
#include <linux/string.h> #include <linux/string.h>
......
This diff is collapsed.
This diff is collapsed.
...@@ -273,8 +273,8 @@ void show_regs(struct pt_regs * regs) ...@@ -273,8 +273,8 @@ void show_regs(struct pt_regs * regs)
trap = TRAP(regs); trap = TRAP(regs);
if (trap == 0x300 || trap == 0x600) if (trap == 0x300 || trap == 0x600)
printk("DAR: %08lX, DSISR: %08lX\n", regs->dar, regs->dsisr); printk("DAR: %08lX, DSISR: %08lX\n", regs->dar, regs->dsisr);
printk("TASK = %p[%d] '%s' ", printk("TASK = %p[%d] '%s' THREAD: %p",
current, current->pid, current->comm); current, current->pid, current->comm, current->thread_info);
printk("Last syscall: %ld ", current->thread.last_syscall); printk("Last syscall: %ld ", current->thread.last_syscall);
#if defined(CONFIG_4xx) && defined(DCRN_PLB0_BEAR) #if defined(CONFIG_4xx) && defined(DCRN_PLB0_BEAR)
...@@ -303,6 +303,16 @@ void show_regs(struct pt_regs * regs) ...@@ -303,6 +303,16 @@ void show_regs(struct pt_regs * regs)
break; break;
} }
printk("\n"); printk("\n");
#ifdef CONFIG_KALLSYMS
/*
* Lookup NIP late so we have the best change of getting the
* above info out without failing
*/
printk("NIP [%08lx] ", regs->nip);
print_symbol("%s\n", regs->nip);
printk("LR [%08lx] ", regs->link);
print_symbol("%s\n", regs->link);
#endif
show_stack(current, (unsigned long *) regs->gpr[1]); show_stack(current, (unsigned long *) regs->gpr[1]);
} }
......
...@@ -361,7 +361,7 @@ handle_rt_signal(unsigned long sig, struct k_sigaction *ka, ...@@ -361,7 +361,7 @@ handle_rt_signal(unsigned long sig, struct k_sigaction *ka,
return; return;
badframe: badframe:
#if DEBUG_SIG #ifdef DEBUG_SIG
printk("badframe in handle_rt_signal, regs=%p frame=%p newsp=%lx\n", printk("badframe in handle_rt_signal, regs=%p frame=%p newsp=%lx\n",
regs, frame, newsp); regs, frame, newsp);
#endif #endif
...@@ -513,7 +513,7 @@ handle_signal(unsigned long sig, struct k_sigaction *ka, ...@@ -513,7 +513,7 @@ handle_signal(unsigned long sig, struct k_sigaction *ka,
return; return;
badframe: badframe:
#if DEBUG_SIG #ifdef DEBUG_SIG
printk("badframe in handle_signal, regs=%p frame=%lx newsp=%lx\n", printk("badframe in handle_signal, regs=%p frame=%lx newsp=%lx\n",
regs, frame, *newspp); regs, frame, *newspp);
#endif #endif
......
...@@ -346,9 +346,9 @@ _GLOBAL(create_hpte) ...@@ -346,9 +346,9 @@ _GLOBAL(create_hpte)
rlwimi r5,r5,32-2,31,31 /* _PAGE_USER -> PP lsb */ rlwimi r5,r5,32-2,31,31 /* _PAGE_USER -> PP lsb */
ori r8,r8,0xe14 /* clear out reserved bits and M */ ori r8,r8,0xe14 /* clear out reserved bits and M */
andc r8,r5,r8 /* PP = user? (rw&dirty? 2: 3): 0 */ andc r8,r5,r8 /* PP = user? (rw&dirty? 2: 3): 0 */
#ifdef CONFIG_SMP BEGIN_FTR_SECTION
ori r8,r8,_PAGE_COHERENT /* set M (coherence required) */ ori r8,r8,_PAGE_COHERENT /* set M (coherence required) */
#endif END_FTR_SECTION_IFSET(CPU_FTR_NEED_COHERENT)
/* Construct the high word of the PPC-style PTE (r5) */ /* Construct the high word of the PPC-style PTE (r5) */
#ifndef CONFIG_PPC64BRIDGE #ifndef CONFIG_PPC64BRIDGE
......
...@@ -137,10 +137,10 @@ void __init setbat(int index, unsigned long virt, unsigned long phys, ...@@ -137,10 +137,10 @@ void __init setbat(int index, unsigned long virt, unsigned long phys,
int wimgxpp; int wimgxpp;
union ubat *bat = BATS[index]; union ubat *bat = BATS[index];
#ifdef CONFIG_SMP if (((flags & _PAGE_NO_CACHE) == 0) &&
if ((flags & _PAGE_NO_CACHE) == 0) (cur_cpu_spec[0]->cpu_features & CPU_FTR_NEED_COHERENT))
flags |= _PAGE_COHERENT; flags |= _PAGE_COHERENT;
#endif
bl = (size >> 17) - 1; bl = (size >> 17) - 1;
if (PVR_VER(mfspr(PVR)) != 1) { if (PVR_VER(mfspr(PVR)) != 1) {
/* 603, 604, etc. */ /* 603, 604, etc. */
......
...@@ -35,7 +35,7 @@ obj-$(CONFIG_EV64260) += ev64260_setup.o ...@@ -35,7 +35,7 @@ obj-$(CONFIG_EV64260) += ev64260_setup.o
obj-$(CONFIG_GEMINI) += gemini_pci.o gemini_setup.o gemini_prom.o obj-$(CONFIG_GEMINI) += gemini_pci.o gemini_setup.o gemini_prom.o
obj-$(CONFIG_K2) += k2_setup.o k2_pci.o obj-$(CONFIG_K2) += k2_setup.o k2_pci.o
obj-$(CONFIG_LOPEC) += lopec_setup.o lopec_pci.o obj-$(CONFIG_LOPEC) += lopec_setup.o lopec_pci.o
obj-$(CONFIG_MCPN765) += mcpn765_setup.o mcpn765_pci.o obj-$(CONFIG_MCPN765) += mcpn765.o
obj-$(CONFIG_MENF1) += menf1_setup.o menf1_pci.o obj-$(CONFIG_MENF1) += menf1_setup.o menf1_pci.o
obj-$(CONFIG_MVME5100) += mvme5100_setup.o mvme5100_pci.o obj-$(CONFIG_MVME5100) += mvme5100_setup.o mvme5100_pci.o
obj-$(CONFIG_PAL4) += pal4_setup.o pal4_pci.o obj-$(CONFIG_PAL4) += pal4_setup.o pal4_pci.o
......
...@@ -401,12 +401,12 @@ gemini_set_rtc_time( unsigned long now ) ...@@ -401,12 +401,12 @@ gemini_set_rtc_time( unsigned long now )
to_tm( now, &tm ); to_tm( now, &tm );
reg = gemini_rtc_read(M48T35_RTC_CONTROL); reg = gemini_rtc_read(M48T35_RTC_CONTROL);
#if DEBUG_RTC #ifdef DEBUG_RTC
printk("set rtc: reg = %x\n", reg); printk("set rtc: reg = %x\n", reg);
#endif #endif
gemini_rtc_write((reg|M48T35_RTC_SET), M48T35_RTC_CONTROL); gemini_rtc_write((reg|M48T35_RTC_SET), M48T35_RTC_CONTROL);
#if DEBUG_RTC #ifdef DEBUG_RTC
printk("set rtc: tm vals - sec=%x, min=%x, hour=%x, mon=%x, mday=%x, year=%x\n", printk("set rtc: tm vals - sec=%x, min=%x, hour=%x, mon=%x, mday=%x, year=%x\n",
tm.tm_sec, tm.tm_min, tm.tm_hour, tm.tm_mon, tm.tm_mday, tm.tm_year); tm.tm_sec, tm.tm_min, tm.tm_hour, tm.tm_mon, tm.tm_mday, tm.tm_year);
#endif #endif
......
/*
* arch/ppc/platforms/mcpn765_pci.c
*
* PCI setup routines for the Motorola MCG MCPN765 cPCI board.
*
* Author: Mark A. Greer
* mgreer@mvista.com
*
* 2001 (c) MontaVista, Software, Inc. This file is licensed under
* the terms of the GNU General Public License version 2. This program
* is licensed "as is" without any warranty of any kind, whether express
* or implied.
*/
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/pci.h>
#include <linux/slab.h>
#include <asm/byteorder.h>
#include <asm/io.h>
#include <asm/irq.h>
#include <asm/uaccess.h>
#include <asm/machdep.h>
#include <asm/pci-bridge.h>
#include <asm/pplus.h>
#include "mcpn765.h"
/*
* Motorola MCG MCPN765 interrupt routing.
*/
static inline int
mcpn765_map_irq(struct pci_dev *dev, unsigned char idsel, unsigned char pin)
{
static char pci_irq_table[][4] =
/*
* PCI IDSEL/INTPIN->INTLINE
* A B C D
*/
{
{ 14, 0, 0, 0 }, /* IDSEL 11 - have to manually set */
{ 0, 0, 0, 0 }, /* IDSEL 12 - unused */
{ 0, 0, 0, 0 }, /* IDSEL 13 - unused */
{ 18, 0, 0, 0 }, /* IDSEL 14 - Enet 0 */
{ 0, 0, 0, 0 }, /* IDSEL 15 - unused */
{ 25, 26, 27, 28 }, /* IDSEL 16 - PMC Slot 1 */
{ 28, 25, 26, 27 }, /* IDSEL 17 - PMC Slot 2 */
{ 0, 0, 0, 0 }, /* IDSEL 18 - PMC 2B Connector XXXX */
{ 29, 0, 0, 0 }, /* IDSEL 19 - Enet 1 */
{ 20, 0, 0, 0 }, /* IDSEL 20 - 21554 cPCI bridge */
};
const long min_idsel = 11, max_idsel = 20, irqs_per_slot = 4;
return PCI_IRQ_TABLE_LOOKUP;
}
void __init
mcpn765_find_bridges(void)
{
struct pci_controller *hose;
hose = pcibios_alloc_controller();
if (!hose)
return;
hose->first_busno = 0;
hose->last_busno = 0xff;
hose->pci_mem_offset = MCPN765_PCI_PHY_MEM_OFFSET;
pci_init_resource(&hose->io_resource,
MCPN765_PCI_IO_START,
MCPN765_PCI_IO_END,
IORESOURCE_IO,
"PCI host bridge");
pci_init_resource(&hose->mem_resources[0],
MCPN765_PCI_MEM_START,
MCPN765_PCI_MEM_END,
IORESOURCE_MEM,
"PCI host bridge");
hose->io_space.start = MCPN765_PCI_IO_START;
hose->io_space.end = MCPN765_PCI_IO_END;
hose->mem_space.start = MCPN765_PCI_MEM_START;
hose->mem_space.end = MCPN765_PCI_MEM_END - PPLUS_MPIC_SIZE;
if (pplus_init(hose,
MCPN765_HAWK_PPC_REG_BASE,
MCPN765_PROC_PCI_MEM_START,
MCPN765_PROC_PCI_MEM_END - PPLUS_MPIC_SIZE,
MCPN765_PROC_PCI_IO_START,
MCPN765_PROC_PCI_IO_END,
MCPN765_PCI_MEM_END - PPLUS_MPIC_SIZE + 1) != 0) {
printk("Could not initialize HAWK bridge\n");
}
hose->last_busno = pciauto_bus_scan(hose, hose->first_busno);
ppc_md.pcibios_fixup = NULL;
ppc_md.pcibios_fixup_bus = NULL;
ppc_md.pci_swizzle = common_swizzle;
ppc_md.pci_map_irq = mcpn765_map_irq;
return;
}
...@@ -513,7 +513,7 @@ void __init pplus_find_bridges(void) ...@@ -513,7 +513,7 @@ void __init pplus_find_bridges(void)
hose->mem_space.start = PPLUS_PCI_MEM_START; hose->mem_space.start = PPLUS_PCI_MEM_START;
hose->mem_space.end = PPLUS_PCI_MEM_END - HAWK_MPIC_SIZE; hose->mem_space.end = PPLUS_PCI_MEM_END - HAWK_MPIC_SIZE;
if (pplus_init(hose, PPLUS_HAWK_PPC_REG_BASE, PPLUS_PROC_PCI_MEM_START, if (hawk_init(hose, PPLUS_HAWK_PPC_REG_BASE, PPLUS_PROC_PCI_MEM_START,
PPLUS_PROC_PCI_MEM_END - HAWK_MPIC_SIZE, PPLUS_PROC_PCI_MEM_END - HAWK_MPIC_SIZE,
PPLUS_PROC_PCI_IO_START, PPLUS_PROC_PCI_IO_END, PPLUS_PROC_PCI_IO_START, PPLUS_PROC_PCI_IO_END,
PPLUS_PROC_PCI_MEM_END - HAWK_MPIC_SIZE + 1) PPLUS_PROC_PCI_MEM_END - HAWK_MPIC_SIZE + 1)
...@@ -816,7 +816,7 @@ static unsigned long __init pplus_find_end_of_memory(void) ...@@ -816,7 +816,7 @@ static unsigned long __init pplus_find_end_of_memory(void)
dump_dbats(); dump_dbats();
#endif #endif
total = pplus_get_mem_size(PPLUS_HAWK_SMC_BASE); total = hawk_get_mem_size(PPLUS_HAWK_SMC_BASE);
return (total); return (total);
} }
......
...@@ -64,14 +64,4 @@ ...@@ -64,14 +64,4 @@
#define PPLUS_VGA_MEM_BASE 0xf0000000U #define PPLUS_VGA_MEM_BASE 0xf0000000U
extern int pplus_init(struct pci_controller *hose,
unsigned int ppc_reg_base, unsigned long processor_pci_mem_start,
unsigned long processor_pci_mem_end,
unsigned long processor_pci_io_start,
unsigned long processor_pci_io_end,
unsigned long processor_mpic_base);
extern unsigned long pplus_get_mem_size(unsigned int smc_base);
extern int pplus_mpic_init(unsigned int pci_mem_offset);
#endif /* __PPC_PPLUS_H */ #endif /* __PPC_PPLUS_H */
...@@ -311,11 +311,11 @@ static char Genesis2_pci_IRQ_map[23] __prepdata = ...@@ -311,11 +311,11 @@ static char Genesis2_pci_IRQ_map[23] __prepdata =
0, /* Slot 7 - unused */ 0, /* Slot 7 - unused */
0, /* Slot 8 - unused */ 0, /* Slot 8 - unused */
0, /* Slot 9 - unused */ 0, /* Slot 9 - unused */
0, /* Slot 10 - Ethernet */ 0, /* Slot 10 - unused */
0, /* Slot 11 - Universe PCI - VME Bridge */ 0, /* Slot 11 - IDE */
3, /* Slot 12 - unused */ 3, /* Slot 12 - SCSI */
0, /* Slot 13 - unused */ 5, /* Slot 13 - Universe PCI - VME Bridge */
2, /* Slot 14 - SCSI */ 2, /* Slot 14 - Ethernet */
0, /* Slot 15 - unused */ 0, /* Slot 15 - unused */
9, /* Slot 16 - PMC 1 */ 9, /* Slot 16 - PMC 1 */
12, /* Slot 17 - pci */ 12, /* Slot 17 - pci */
......
...@@ -323,7 +323,7 @@ prep_carolina_cpuinfo(struct seq_file *m) ...@@ -323,7 +323,7 @@ prep_carolina_cpuinfo(struct seq_file *m)
/* L2 size */ /* L2 size */
if ((l2_reg & 0x60) == 0) if ((l2_reg & 0x60) == 0)
seq_printf(m, "256KiB"); seq_printf(m, "256KiB");
else if ((l2_reg & 0x60) == 1) else if ((l2_reg & 0x60) == 0x20)
seq_printf(m, "512KiB"); seq_printf(m, "512KiB");
else else
seq_printf(m, "unknown size"); seq_printf(m, "unknown size");
...@@ -725,6 +725,7 @@ prep_setup_arch(void) ...@@ -725,6 +725,7 @@ prep_setup_arch(void)
case PREP_IBM_CAROLINA_IDE_0: case PREP_IBM_CAROLINA_IDE_0:
case PREP_IBM_CAROLINA_IDE_1: case PREP_IBM_CAROLINA_IDE_1:
case PREP_IBM_CAROLINA_IDE_2: case PREP_IBM_CAROLINA_IDE_2:
case PREP_IBM_CAROLINA_IDE_3:
is_ide = 1; is_ide = 1;
case PREP_IBM_CAROLINA_SCSI_0: case PREP_IBM_CAROLINA_SCSI_0:
case PREP_IBM_CAROLINA_SCSI_1: case PREP_IBM_CAROLINA_SCSI_1:
......
...@@ -42,28 +42,24 @@ obj-$(CONFIG_EV64260) += gt64260_common.o gt64260_pic.o \ ...@@ -42,28 +42,24 @@ obj-$(CONFIG_EV64260) += gt64260_common.o gt64260_pic.o \
obj-$(CONFIG_GEMINI) += open_pic.o i8259.o indirect_pci.o obj-$(CONFIG_GEMINI) += open_pic.o i8259.o indirect_pci.o
obj-$(CONFIG_K2) += i8259.o indirect_pci.o todc_time.o \ obj-$(CONFIG_K2) += i8259.o indirect_pci.o todc_time.o \
pci_auto.o pci_auto.o
obj-$(CONFIG_LOPEC) += mpc10x_common.o indirect_pci.o pci_auto.o \ obj-$(CONFIG_LOPEC) += pci_auto.o open_pic.o i8259.o todc_time.o
open_pic.o i8259.o todc_time.o
obj-$(CONFIG_MCPN765) += todc_time.o indirect_pci.o pci_auto.o \ obj-$(CONFIG_MCPN765) += todc_time.o indirect_pci.o pci_auto.o \
open_pic.o i8259.o pplus_common.o open_pic.o i8259.o hawk_common.o
obj-$(CONFIG_MENF1) += todc_time.o i8259.o mpc10x_common.o \ obj-$(CONFIG_MENF1) += todc_time.o i8259.o mpc10x_common.o \
pci_auto.o indirect_pci.o pci_auto.o indirect_pci.o
obj-$(CONFIG_MVME5100) += open_pic.o todc_time.o indirect_pci.o \ obj-$(CONFIG_MVME5100) += open_pic.o todc_time.o indirect_pci.o \
i8259.o pci_auto.o pplus_common.o i8259.o pci_auto.o hawk_common.o
obj-$(CONFIG_OCOTEA) += indirect_pci.o pci_auto.o todc_time.o obj-$(CONFIG_OCOTEA) += indirect_pci.o pci_auto.o todc_time.o
obj-$(CONFIG_PAL4) += cpc700_pic.o obj-$(CONFIG_PAL4) += cpc700_pic.o
obj-$(CONFIG_PCORE) += mpc10x_common.o todc_time.o i8259.o \ obj-$(CONFIG_PCORE) += todc_time.o i8259.o pci_auto.o
indirect_pci.o pci_auto.o obj-$(CONFIG_POWERPMC250) += open_pic.o pci_auto.o
obj-$(CONFIG_POWERPMC250) += open_pic.o mpc10x_common.o \ obj-$(CONFIG_PPLUS) += hawk_common.o open_pic.o i8259.o \
indirect_pci.o pci_auto.o
obj-$(CONFIG_PPLUS) += pplus_common.o open_pic.o i8259.o \
indirect_pci.o todc_time.o pci_auto.o indirect_pci.o todc_time.o pci_auto.o
obj-$(CONFIG_PRPMC750) += open_pic.o indirect_pci.o pci_auto.o \ obj-$(CONFIG_PRPMC750) += open_pic.o indirect_pci.o pci_auto.o \
pplus_common.o hawk_common.o
obj-$(CONFIG_PRPMC800) += open_pic.o indirect_pci.o pci_auto.o \ obj-$(CONFIG_PRPMC800) += open_pic.o indirect_pci.o pci_auto.o \
pplus_common.o harrier.o hawk_common.o harrier.o
obj-$(CONFIG_SANDPOINT) += i8259.o open_pic.o mpc10x_common.o \ obj-$(CONFIG_SANDPOINT) += i8259.o open_pic.o pci_auto.o todc_time.o
pci_auto.o indirect_pci.o todc_time.o
obj-$(CONFIG_SPRUCE) += cpc700_pic.o indirect_pci.o pci_auto.o \ obj-$(CONFIG_SPRUCE) += cpc700_pic.o indirect_pci.o pci_auto.o \
todc_time.o todc_time.o
obj-$(CONFIG_8260) += m8260_setup.o ppc8260_pic.o obj-$(CONFIG_8260) += m8260_setup.o ppc8260_pic.o
...@@ -72,3 +68,4 @@ obj-$(CONFIG_KGDB) += gen550_kgdb.o gen550_dbg.o ...@@ -72,3 +68,4 @@ obj-$(CONFIG_KGDB) += gen550_kgdb.o gen550_dbg.o
obj-$(CONFIG_SERIAL_TEXT_DEBUG) += gen550_dbg.o obj-$(CONFIG_SERIAL_TEXT_DEBUG) += gen550_dbg.o
endif endif
obj-$(CONFIG_BOOTX_TEXT) += btext.o obj-$(CONFIG_BOOTX_TEXT) += btext.o
obj-$(CONFIG_MPC10X_BRIDGE) += mpc10x_common.o indirect_pci.o
/* /*
* arch/ppc/syslib/pplus_common.c * arch/ppc/syslib/hawk_common.c
* *
* Common Motorola PowerPlus Platform--really Falcon/Raven or HAWK. * Common Motorola PowerPlus Platform--really Falcon/Raven or HAWK.
* *
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
* 'OpenPIC_Addr' will be set correctly by this routine. * 'OpenPIC_Addr' will be set correctly by this routine.
*/ */
int __init int __init
pplus_init(struct pci_controller *hose, hawk_init(struct pci_controller *hose,
uint ppc_reg_base, uint ppc_reg_base,
ulong processor_pci_mem_start, ulong processor_pci_mem_start,
ulong processor_pci_mem_end, ulong processor_pci_mem_end,
...@@ -59,14 +59,14 @@ pplus_init(struct pci_controller *hose, ...@@ -59,14 +59,14 @@ pplus_init(struct pci_controller *hose,
*/ */
if (((processor_pci_mem_start&0xffff0000) != processor_pci_mem_start) || if (((processor_pci_mem_start&0xffff0000) != processor_pci_mem_start) ||
((processor_pci_io_start &0xffff0000) != processor_pci_io_start)) { ((processor_pci_io_start &0xffff0000) != processor_pci_io_start)) {
printk("pplus_init: %s\n", printk("hawk_init: %s\n",
"PPC to PCI mappings must start on 64 KB boundaries"); "PPC to PCI mappings must start on 64 KB boundaries");
return -1; return -1;
} }
if (((processor_pci_mem_end &0x0000ffff) != 0x0000ffff) || if (((processor_pci_mem_end &0x0000ffff) != 0x0000ffff) ||
((processor_pci_io_end &0x0000ffff) != 0x0000ffff)) { ((processor_pci_io_end &0x0000ffff) != 0x0000ffff)) {
printk("pplus_init: PPC to PCI mappings %s\n", printk("hawk_init: PPC to PCI mappings %s\n",
"must end just before a 64 KB boundaries"); "must end just before a 64 KB boundaries");
return -1; return -1;
} }
...@@ -75,19 +75,19 @@ pplus_init(struct pci_controller *hose, ...@@ -75,19 +75,19 @@ pplus_init(struct pci_controller *hose,
(hose->mem_space.end - hose->mem_space.start)) || (hose->mem_space.end - hose->mem_space.start)) ||
((processor_pci_io_end - processor_pci_io_start) != ((processor_pci_io_end - processor_pci_io_start) !=
(hose->io_space.end - hose->io_space.start))) { (hose->io_space.end - hose->io_space.start))) {
printk("pplus_init: %s\n", printk("hawk_init: %s\n",
"PPC and PCI memory or I/O space sizes don't match"); "PPC and PCI memory or I/O space sizes don't match");
return -1; return -1;
} }
if ((processor_mpic_base & 0xfffc0000) != processor_mpic_base) { if ((processor_mpic_base & 0xfffc0000) != processor_mpic_base) {
printk("pplus_init: %s\n", printk("hawk_init: %s\n",
"MPIC address must start on 256 MB boundary"); "MPIC address must start on 256 MB boundary");
return -1; return -1;
} }
if ((pci_dram_offset & 0xffff0000) != pci_dram_offset) { if ((pci_dram_offset & 0xffff0000) != pci_dram_offset) {
printk("pplus_init: %s\n", printk("hawk_init: %s\n",
"pci_dram_offset must be multiple of 64 KB"); "pci_dram_offset must be multiple of 64 KB");
return -1; return -1;
} }
...@@ -226,7 +226,7 @@ static uint hawk_size_table[] __initdata = { ...@@ -226,7 +226,7 @@ static uint hawk_size_table[] __initdata = {
* into virtual memory--too early to use ioremap(). * into virtual memory--too early to use ioremap().
*/ */
unsigned long __init unsigned long __init
pplus_get_mem_size(uint smc_base) hawk_get_mem_size(uint smc_base)
{ {
unsigned long total; unsigned long total;
int i, size_table_entries, reg_limit; int i, size_table_entries, reg_limit;
...@@ -238,7 +238,7 @@ pplus_get_mem_size(uint smc_base) ...@@ -238,7 +238,7 @@ pplus_get_mem_size(uint smc_base)
vend_dev_id = in_be32((uint *)smc_base + PCI_VENDOR_ID); vend_dev_id = in_be32((uint *)smc_base + PCI_VENDOR_ID);
if (((vend_dev_id & 0xffff0000) >> 16) != PCI_VENDOR_ID_MOTOROLA) { if (((vend_dev_id & 0xffff0000) >> 16) != PCI_VENDOR_ID_MOTOROLA) {
printk("pplus_get_mem_size: %s (0x%x)\n", printk("hawk_get_mem_size: %s (0x%x)\n",
"Not a Motorola Memory Controller", vend_dev_id); "Not a Motorola Memory Controller", vend_dev_id);
return 0; return 0;
} }
...@@ -259,7 +259,7 @@ pplus_get_mem_size(uint smc_base) ...@@ -259,7 +259,7 @@ pplus_get_mem_size(uint smc_base)
reg_limit = HAWK_SMC_REG_COUNT; reg_limit = HAWK_SMC_REG_COUNT;
} }
else { else {
printk("pplus_get_mem_size: %s (0x%x)\n", printk("hawk_get_mem_size: %s (0x%x)\n",
"Not a Falcon or HAWK", vend_dev_id); "Not a Falcon or HAWK", vend_dev_id);
return 0; return 0;
} }
...@@ -285,35 +285,3 @@ pplus_get_mem_size(uint smc_base) ...@@ -285,35 +285,3 @@ pplus_get_mem_size(uint smc_base)
return total; return total;
} }
int __init
pplus_mpic_init(unsigned int pci_mem_offset)
{
unsigned short devid;
unsigned int pci_membase;
/* Check the first PCI device to see if it is a Raven or Hawk. */
early_read_config_word(0, 0, 0, PCI_DEVICE_ID, &devid);
switch (devid) {
case PCI_DEVICE_ID_MOTOROLA_RAVEN:
case PCI_DEVICE_ID_MOTOROLA_HAWK:
break;
default:
OpenPIC_Addr = NULL;
return 1;
}
/* Read the memory base register. */
early_read_config_dword(0, 0, 0, PCI_BASE_ADDRESS_1, &pci_membase);
if (pci_membase == 0) {
OpenPIC_Addr = NULL;
return 1;
}
/* Map the MPIC registers to virtual memory. */
OpenPIC_Addr = ioremap(pci_membase + pci_mem_offset, 0x22000);
return 0;
}
...@@ -75,6 +75,7 @@ extern struct cpu_spec *cur_cpu_spec[]; ...@@ -75,6 +75,7 @@ extern struct cpu_spec *cur_cpu_spec[];
#define CPU_FTR_DUAL_PLL_750FX 0x00004000 #define CPU_FTR_DUAL_PLL_750FX 0x00004000
#define CPU_FTR_NO_DPM 0x00008000 #define CPU_FTR_NO_DPM 0x00008000
#define CPU_FTR_HAS_HIGH_BATS 0x00010000 #define CPU_FTR_HAS_HIGH_BATS 0x00010000
#define CPU_FTR_NEED_COHERENT 0x00020000
#ifdef __ASSEMBLY__ #ifdef __ASSEMBLY__
......
...@@ -29,4 +29,4 @@ extern int hawk_init(struct pci_controller *hose, ...@@ -29,4 +29,4 @@ extern int hawk_init(struct pci_controller *hose,
extern unsigned long hawk_get_mem_size(unsigned int smc_base); extern unsigned long hawk_get_mem_size(unsigned int smc_base);
extern int hawk_mpic_init(unsigned int pci_mem_offset); extern int hawk_mpic_init(unsigned int pci_mem_offset);
#endif /* __ASMPPC_PPLUS_H */ #endif /* __ASMPPC_HAWK_H */
...@@ -87,7 +87,7 @@ static inline void *kmap_atomic(struct page *page, enum km_type type) ...@@ -87,7 +87,7 @@ static inline void *kmap_atomic(struct page *page, enum km_type type)
idx = type + KM_TYPE_NR*smp_processor_id(); idx = type + KM_TYPE_NR*smp_processor_id();
vaddr = KMAP_FIX_BEGIN + idx * PAGE_SIZE; vaddr = KMAP_FIX_BEGIN + idx * PAGE_SIZE;
#if HIGHMEM_DEBUG #ifdef HIGHMEM_DEBUG
BUG_ON(!pte_none(*(kmap_pte+idx))); BUG_ON(!pte_none(*(kmap_pte+idx)));
#endif #endif
set_pte(kmap_pte+idx, mk_pte(page, kmap_prot)); set_pte(kmap_pte+idx, mk_pte(page, kmap_prot));
...@@ -98,7 +98,7 @@ static inline void *kmap_atomic(struct page *page, enum km_type type) ...@@ -98,7 +98,7 @@ static inline void *kmap_atomic(struct page *page, enum km_type type)
static inline void kunmap_atomic(void *kvaddr, enum km_type type) static inline void kunmap_atomic(void *kvaddr, enum km_type type)
{ {
#if HIGHMEM_DEBUG #ifdef HIGHMEM_DEBUG
unsigned long vaddr = (unsigned long) kvaddr & PAGE_MASK; unsigned long vaddr = (unsigned long) kvaddr & PAGE_MASK;
unsigned int idx = type + KM_TYPE_NR*smp_processor_id(); unsigned int idx = type + KM_TYPE_NR*smp_processor_id();
......
...@@ -27,7 +27,7 @@ struct rw_semaphore { ...@@ -27,7 +27,7 @@ struct rw_semaphore {
#define RWSEM_ACTIVE_WRITE_BIAS (RWSEM_WAITING_BIAS + RWSEM_ACTIVE_BIAS) #define RWSEM_ACTIVE_WRITE_BIAS (RWSEM_WAITING_BIAS + RWSEM_ACTIVE_BIAS)
spinlock_t wait_lock; spinlock_t wait_lock;
struct list_head wait_list; struct list_head wait_list;
#if RWSEM_DEBUG #ifdef RWSEM_DEBUG
int debug; int debug;
#endif #endif
}; };
...@@ -35,7 +35,7 @@ struct rw_semaphore { ...@@ -35,7 +35,7 @@ struct rw_semaphore {
/* /*
* initialisation * initialisation
*/ */
#if RWSEM_DEBUG #ifdef RWSEM_DEBUG
#define __RWSEM_DEBUG_INIT , 0 #define __RWSEM_DEBUG_INIT , 0
#else #else
#define __RWSEM_DEBUG_INIT /* */ #define __RWSEM_DEBUG_INIT /* */
...@@ -59,7 +59,7 @@ static inline void init_rwsem(struct rw_semaphore *sem) ...@@ -59,7 +59,7 @@ static inline void init_rwsem(struct rw_semaphore *sem)
sem->count = RWSEM_UNLOCKED_VALUE; sem->count = RWSEM_UNLOCKED_VALUE;
spin_lock_init(&sem->wait_lock); spin_lock_init(&sem->wait_lock);
INIT_LIST_HEAD(&sem->wait_list); INIT_LIST_HEAD(&sem->wait_list);
#if RWSEM_DEBUG #ifdef RWSEM_DEBUG
sem->debug = 0; sem->debug = 0;
#endif #endif
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment