Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
sunhme: Fix qfe parent detection.
sparc64: Fix lost interrupts on sun4u.
sparc64: wait_event_interruptible_timeout may return -ERESTARTSYS
jsflash: stop defining MAJOR_NR

+20 -16
+19 -10
arch/sparc/kernel/irq_64.c
··· 323 323 sun4u_irq_enable(virt_irq); 324 324 } 325 325 326 + /* Don't do anything. The desc->status check for IRQ_DISABLED in 327 + * handler_irq() will skip the handler call and that will leave the 328 + * interrupt in the sent state. The next ->enable() call will hit the 329 + * ICLR register to reset the state machine. 330 + * 331 + * This scheme is necessary, instead of clearing the Valid bit in the 332 + * IMAP register, to handle the case of IMAP registers being shared by 333 + * multiple INOs (and thus ICLR registers). Since we use a different 334 + * virtual IRQ for each shared IMAP instance, the generic code thinks 335 + * there is only one user so it prematurely calls ->disable() on 336 + * free_irq(). 337 + * 338 + * We have to provide an explicit ->disable() method instead of using 339 + * NULL to get the default. The reason is that if the generic code 340 + * sees that, it also hooks up a default ->shutdown method which 341 + * invokes ->mask() which we do not want. See irq_chip_set_defaults(). 342 + */ 326 343 static void sun4u_irq_disable(unsigned int virt_irq) 327 344 { 328 - struct irq_handler_data *data = get_irq_chip_data(virt_irq); 329 - 330 - if (likely(data)) { 331 - unsigned long imap = data->imap; 332 - unsigned long tmp = upa_readq(imap); 333 - 334 - tmp &= ~IMAP_VALID; 335 - upa_writeq(tmp, imap); 336 - } 337 345 } 338 346 339 347 static void sun4u_irq_eoi(unsigned int virt_irq) ··· 754 746 755 747 desc = irq_desc + virt_irq; 756 748 757 - desc->handle_irq(virt_irq, desc); 749 + if (!(desc->status & IRQ_DISABLED)) 750 + desc->handle_irq(virt_irq, desc); 758 751 759 752 bucket_pa = next_pa; 760 753 }
-2
drivers/net/sunhme.c
··· 2649 2649 int err = -ENODEV; 2650 2650 2651 2651 sbus_dp = to_of_device(op->dev.parent)->node; 2652 - if (is_qfe) 2653 - sbus_dp = to_of_device(op->dev.parent->parent)->node; 2654 2652 2655 2653 /* We can match PCI devices too, do not accept those here. */ 2656 2654 if (strcmp(sbus_dp->name, "sbus"))
+1 -1
drivers/sbus/char/bbc_i2c.c
··· 129 129 bp->waiting = 1; 130 130 add_wait_queue(&bp->wq, &wait); 131 131 while (limit-- > 0) { 132 - unsigned long val; 132 + long val; 133 133 134 134 val = wait_event_interruptible_timeout( 135 135 bp->wq,
-3
drivers/sbus/char/jsflash.c
··· 38 38 #include <linux/string.h> 39 39 #include <linux/genhd.h> 40 40 #include <linux/blkdev.h> 41 - 42 - #define MAJOR_NR JSFD_MAJOR 43 - 44 41 #include <asm/uaccess.h> 45 42 #include <asm/pgtable.h> 46 43 #include <asm/io.h>