From 045e4bb2bafb7aa8141c2f8332ce31b224ac3bb0 Mon Sep 17 00:00:00 2001 From: Kyungmin Park Date: Fri, 10 Aug 2007 14:00:21 -0700 Subject: [MIPS] i8259: Add disable method. After 76d2160147f43f982dfe881404cfde9fd0a9da21, the qemu NE2000 was frequently producing WATCHDOG timeouts. Signed-off-by: Kyungmin Park Cc: Ralf Baechle Cc: Ingo Molnar Signed-off-by: Andrew Morton Signed-off-by: Ralf Baechle --- arch/mips/kernel/i8259.c | 1 + 1 file changed, 1 insertion(+) (limited to 'arch') diff --git a/arch/mips/kernel/i8259.c b/arch/mips/kernel/i8259.c index 2345160e63f..b6c30800c66 100644 --- a/arch/mips/kernel/i8259.c +++ b/arch/mips/kernel/i8259.c @@ -36,6 +36,7 @@ void mask_and_ack_8259A(unsigned int); static struct irq_chip i8259A_chip = { .name = "XT-PIC", .mask = disable_8259A_irq, + .disable = disable_8259A_irq, .unmask = enable_8259A_irq, .mask_ack = mask_and_ack_8259A, }; -- cgit v1.2.3 From 28e18a0f691b3737f73ab9033ded6a4da6c31b2f Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Wed, 29 Aug 2007 00:38:13 +0100 Subject: [MIPS] BCM1480: Fix computation of interrupt mask address register. CC arch/mips/sibyte/bcm1480/irq.o arch/mips/sibyte/bcm1480/irq.c: In function 'bcm1480_mask_irq': arch/mips/sibyte/bcm1480/irq.c:112: warning: cast to pointer from integer of different size arch/mips/sibyte/bcm1480/irq.c:114: warning: cast to pointer from integer of different size arch/mips/sibyte/bcm1480/irq.c: In function 'bcm1480_unmask_irq': arch/mips/sibyte/bcm1480/irq.c:130: warning: cast to pointer from integer of different size arch/mips/sibyte/bcm1480/irq.c:132: warning: cast to pointer from integer of different size Signed-off-by: Ralf Baechle --- arch/mips/sibyte/bcm1480/irq.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'arch') diff --git a/arch/mips/sibyte/bcm1480/irq.c b/arch/mips/sibyte/bcm1480/irq.c index 79ae6ef979b..e729b5f3026 100644 --- a/arch/mips/sibyte/bcm1480/irq.c +++ b/arch/mips/sibyte/bcm1480/irq.c @@ -100,8 +100,8 @@ DEFINE_SPINLOCK(bcm1480_imr_lock); void bcm1480_mask_irq(int cpu, int irq) { - unsigned long flags; - u64 cur_ints,hl_spacing; + unsigned long flags, hl_spacing; + u64 cur_ints; spin_lock_irqsave(&bcm1480_imr_lock, flags); hl_spacing = 0; @@ -117,8 +117,8 @@ void bcm1480_mask_irq(int cpu, int irq) void bcm1480_unmask_irq(int cpu, int irq) { - unsigned long flags; - u64 cur_ints,hl_spacing; + unsigned long flags, hl_spacing; + u64 cur_ints; spin_lock_irqsave(&bcm1480_imr_lock, flags); hl_spacing = 0; -- cgit v1.2.3 From 41f9c78c2e599d3a50cf092eda2d1c2d5962bda8 Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Wed, 29 Aug 2007 08:34:39 +0100 Subject: [MIPS] PCI: Set need_domain_info if controller domain index is non-zero. This fixes this little funny: bigsur:/proc/bus/pci# ls -l total 0 dr-xr-xr-x 2 root root 0 Aug 28 19:31 00 dr-xr-xr-x 2 root root 0 Aug 28 19:31 00 dr-xr-xr-x 2 root root 0 Aug 28 19:31 01 dr-xr-xr-x 2 root root 0 Aug 28 19:31 03 -r--r--r-- 1 root root 0 Aug 28 19:31 devices Signed-off-by: Ralf Baechle --- arch/mips/pci/pci.c | 1 + 1 file changed, 1 insertion(+) (limited to 'arch') diff --git a/arch/mips/pci/pci.c b/arch/mips/pci/pci.c index 6c5c684d142..589b745d822 100644 --- a/arch/mips/pci/pci.c +++ b/arch/mips/pci/pci.c @@ -141,6 +141,7 @@ static int __init pcibios_init(void) bus = pci_scan_bus(next_busno, hose->pci_ops, hose); hose->bus = bus; + need_domain_info = need_domain_info || hose->index; hose->need_domain_info = need_domain_info; if (bus) { next_busno = bus->subordinate + 1; -- cgit v1.2.3 From ad015f41e1ea7c64bb8b25c46c33bb049ec54f71 Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Wed, 29 Aug 2007 14:21:45 +0100 Subject: [MIPS] Kconfig: whitespace cleanup. Signed-off-by: Ralf Baechle --- arch/mips/Kconfig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'arch') diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index 04797b289c2..4a54d21ee17 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -80,10 +80,10 @@ config MACH_DECSTATION If you have one of the following DECstation Models you definitely want to choose R4xx0 for the CPU Type: - DECstation 5000/50 - DECstation 5000/150 - DECstation 5000/260 - DECsystem 5900/260 + DECstation 5000/50 + DECstation 5000/150 + DECstation 5000/260 + DECsystem 5900/260 otherwise choose R3000. -- cgit v1.2.3 From 76e7f79950b54eb17f4041d020811331b7ae1a9e Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Thu, 30 Aug 2007 00:58:53 +0100 Subject: [MIPS] Sibyte: Remove broken dependency on EXPERIMENTAL from SIBYTE_SB1xxx_SOC. Otherwise Kconfig will produce a nonsenical .config for a kernel that is neither 32-bit nor 64-bit. Signed-off-by: Ralf Baechle --- arch/mips/sibyte/Kconfig | 1 - 1 file changed, 1 deletion(-) (limited to 'arch') diff --git a/arch/mips/sibyte/Kconfig b/arch/mips/sibyte/Kconfig index e6b003ec671..fdd7bd98fb4 100644 --- a/arch/mips/sibyte/Kconfig +++ b/arch/mips/sibyte/Kconfig @@ -48,7 +48,6 @@ config SIBYTE_BCM1x55 config SIBYTE_SB1xxx_SOC bool - depends on EXPERIMENTAL select DMA_COHERENT select SIBYTE_CFE select SWAP_IO_SPACE -- cgit v1.2.3 From 8bce4e9de113e2957c74cc4ce36fbd6eff47d24d Mon Sep 17 00:00:00 2001 From: Maxime Bizon Date: Fri, 31 Aug 2007 11:03:14 +0200 Subject: [MIPS] R10000: Fix wrong test in dma-default.c Signed-off-by: Maxime Bizon Signed-off-by: Ralf Baechle --- arch/mips/mm/dma-default.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch') diff --git a/arch/mips/mm/dma-default.c b/arch/mips/mm/dma-default.c index 76903c72764..f60b3dc0fc6 100644 --- a/arch/mips/mm/dma-default.c +++ b/arch/mips/mm/dma-default.c @@ -35,7 +35,7 @@ static inline unsigned long dma_addr_to_virt(dma_addr_t dma_addr) static inline int cpu_is_noncoherent_r10000(struct device *dev) { return !plat_device_is_coherent(dev) && - (current_cpu_data.cputype == CPU_R10000 && + (current_cpu_data.cputype == CPU_R10000 || current_cpu_data.cputype == CPU_R12000); } -- cgit v1.2.3 From d6698a2cd6ba23f5f73b0115c277dca8341af4a0 Mon Sep 17 00:00:00 2001 From: Thiemo Seufer Date: Wed, 5 Sep 2007 12:11:22 +0100 Subject: [MIPS] TLB: Fix instruction bitmasks Signed-Off-By: Thiemo Seufer Signed-off-by: Ralf Baechle --- arch/mips/mm/tlbex.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'arch') diff --git a/arch/mips/mm/tlbex.c b/arch/mips/mm/tlbex.c index 4ec0964b839..9cb39644b6f 100644 --- a/arch/mips/mm/tlbex.c +++ b/arch/mips/mm/tlbex.c @@ -78,7 +78,7 @@ enum fields SET = 0x200 }; -#define OP_MASK 0x2f +#define OP_MASK 0x3f #define OP_SH 26 #define RS_MASK 0x1f #define RS_SH 21 @@ -92,7 +92,7 @@ enum fields #define IMM_SH 0 #define JIMM_MASK 0x3ffffff #define JIMM_SH 0 -#define FUNC_MASK 0x2f +#define FUNC_MASK 0x3f #define FUNC_SH 0 #define SET_MASK 0x7 #define SET_SH 0 -- cgit v1.2.3 From 98f9085405b059d1e1915fbb9b861d9efcd7c597 Mon Sep 17 00:00:00 2001 From: Yoichi Yuasa Date: Thu, 6 Sep 2007 21:32:57 +0900 Subject: [MIPS] Ocelot: remove remaining bits Signed-off-by: Yoichi Yuasa Signed-off-by: Ralf Baechle --- arch/mips/Kconfig | 14 -------------- 1 file changed, 14 deletions(-) (limited to 'arch') diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index 4a54d21ee17..3b807b4bc7c 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -818,20 +818,6 @@ config EMMA2RH config SERIAL_RM9000 bool -# -# Unfortunately not all GT64120 systems run the chip at the same clock. -# As the user for the clock rate and try to minimize the available options. -# -choice - prompt "Galileo Chip Clock" - depends on MOMENCO_OCELOT - default SYSCLK_100 if MOMENCO_OCELOT - -config SYSCLK_100 - bool "100" if MOMENCO_OCELOT - -endchoice - config ARC32 bool -- cgit v1.2.3 From 0ba8bc60ca482d678fcc63af44b243de6555dab5 Mon Sep 17 00:00:00 2001 From: Thomas Bogendoerfer Date: Tue, 11 Sep 2007 12:46:03 +0200 Subject: [MIPS] IP22: Fix wrong check for second HPC Wrong check for the second hpc on fullhouse machines, caused DBEs on SGI Indys Signed-off-by: Thomas Bogendoerfer Signed-off-by: Ralf Baechle --- arch/mips/sgi-ip22/ip22-platform.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'arch') diff --git a/arch/mips/sgi-ip22/ip22-platform.c b/arch/mips/sgi-ip22/ip22-platform.c index 78b608d2d4e..28ffec8e5d1 100644 --- a/arch/mips/sgi-ip22/ip22-platform.c +++ b/arch/mips/sgi-ip22/ip22-platform.c @@ -150,8 +150,8 @@ static int __init sgiseeq_devinit(void) return res; /* Second HPC is missing? */ - if (ip22_is_fullhouse() || - !get_dbe(tmp, (unsigned int *)&hpc3c1->pbdma[1])) + if (!ip22_is_fullhouse() || + get_dbe(tmp, (unsigned int *)&hpc3c1->pbdma[1])) return 0; sgimc->giopar |= SGIMC_GIOPAR_MASTEREXP1 | SGIMC_GIOPAR_EXP164 | -- cgit v1.2.3 From 01e9943c79ad4edb2c0b76c99029e34d704223ce Mon Sep 17 00:00:00 2001 From: Thomas Bogendoerfer Date: Tue, 11 Sep 2007 12:43:55 +0200 Subject: [MIPS] IP22: fix wrong argument order Fix wrong argument order; this is just a minimal fix for the half baked redadb/writeb() conversion. Signed-off-by: Thomas Bogendoerfer Signed-off-by: Ralf Baechle --- arch/mips/sgi-ip22/ip22-time.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'arch') diff --git a/arch/mips/sgi-ip22/ip22-time.c b/arch/mips/sgi-ip22/ip22-time.c index 8e88a442b22..de3d01823ad 100644 --- a/arch/mips/sgi-ip22/ip22-time.c +++ b/arch/mips/sgi-ip22/ip22-time.c @@ -114,8 +114,8 @@ static unsigned long dosample(void) } while (msb); /* Stop the counter. */ - writeb(sgint->tcword, (SGINT_TCWORD_CNT2 | SGINT_TCWORD_CALL | - SGINT_TCWORD_MSWST)); + writeb(SGINT_TCWORD_CNT2 | SGINT_TCWORD_CALL | SGINT_TCWORD_MSWST, + &sgint->tcword); /* * Return the difference, this is how far the r4k counter increments * for every 1/HZ seconds. We round off the nearest 1 MHz of master -- cgit v1.2.3 From b868868ae0f7272228c95cc760338ffe35bb739d Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Tue, 11 Sep 2007 18:05:33 +0100 Subject: [MIPS] Fix aliasing bug in copy_user_highpage. Copy_user_highpage was written assuming it was only being called for breaking COW pages in which case the source page isn't cached as in marked cachable under it kernel virtual address. If it is called anyway the aliasing avoidance strategy implemented by kmap_coherent will fail. Avoid the use of kmap_coherent for pages marked dirty and to avoid another instance of this sort of bug, place a BUG_ON in kmap_coherent. Signed-off-by: Ralf Baechle --- arch/mips/mm/init.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'arch') diff --git a/arch/mips/mm/init.c b/arch/mips/mm/init.c index 09d91505b90..5240432e6d1 100644 --- a/arch/mips/mm/init.c +++ b/arch/mips/mm/init.c @@ -8,6 +8,7 @@ * Kevin D. Kissell, kevink@mips.com and Carsten Langgaard, carstenl@mips.com * Copyright (C) 2000 MIPS Technologies, Inc. All rights reserved. */ +#include #include #include #include @@ -132,6 +133,8 @@ void *kmap_coherent(struct page *page, unsigned long addr) pte_t pte; int tlbidx; + BUG_ON(Page_dcache_dirty(page)); + inc_preempt_count(); idx = (addr >> PAGE_SHIFT) & (FIX_N_COLOURS - 1); #ifdef CONFIG_MIPS_MT_SMTC @@ -208,7 +211,7 @@ void copy_user_highpage(struct page *to, struct page *from, void *vfrom, *vto; vto = kmap_atomic(to, KM_USER1); - if (cpu_has_dc_aliases) { + if (cpu_has_dc_aliases && !Page_dcache_dirty(from)) { vfrom = kmap_coherent(from, vaddr); copy_page(vto, vfrom); kunmap_coherent(); -- cgit v1.2.3