Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e98bae75 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-next-2.6: (28 commits)
  sparc32: fix build, fix missing cpu_relax declaration
  SCHED_TTWU_QUEUE is not longer needed since sparc32 now implements IPI
  sparc32,leon: Remove unnecessary page_address calls in LEON DMA API.
  sparc: convert old cpumask API into new one
  sparc32, sun4d: Implemented SMP IPIs support for SUN4D machines
  sparc32, sun4m: Implemented SMP IPIs support for SUN4M machines
  sparc32,leon: Implemented SMP IPIs for LEON CPU
  sparc32: implement SMP IPIs using the generic functions
  sparc32,leon: SMP power down implementation
  sparc32,leon: added some SMP comments
  sparc: add {read,write}*_be routines
  sparc32,leon: don't rely on bootloader to mask IRQs
  sparc32,leon: operate on boot-cpu IRQ controller registers
  sparc32: always define boot_cpu_id
  sparc32: removed unused code, implemented by generic code
  sparc32: avoid build warning at mm/percpu.c:1647
  sparc32: always register a PROM based early console
  sparc32: probe for cpu info only during startup
  sparc: consolidate show_cpuinfo in cpu.c
  sparc32,leon: implement genirq CPU affinity
  ...
parents 4b382d06 f400bdb1
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -25,6 +25,10 @@ config SPARC
	select HAVE_DMA_ATTRS
	select HAVE_DMA_API_DEBUG
	select HAVE_ARCH_JUMP_LABEL
	select HAVE_GENERIC_HARDIRQS
	select GENERIC_HARDIRQS_NO_DEPRECATED
	select GENERIC_IRQ_SHOW
	select USE_GENERIC_SMP_HELPERS if SMP

config SPARC32
	def_bool !64BIT
@@ -43,15 +47,12 @@ config SPARC64
	select HAVE_DYNAMIC_FTRACE
	select HAVE_FTRACE_MCOUNT_RECORD
	select HAVE_SYSCALL_TRACEPOINTS
	select USE_GENERIC_SMP_HELPERS if SMP
	select RTC_DRV_CMOS
	select RTC_DRV_BQ4802
	select RTC_DRV_SUN4V
	select RTC_DRV_STARFIRE
	select HAVE_PERF_EVENTS
	select PERF_USE_VMALLOC
	select HAVE_GENERIC_HARDIRQS
	select GENERIC_IRQ_SHOW
	select IRQ_PREFLOW_FASTEOI

config ARCH_DEFCONFIG
+5 −0
Original line number Diff line number Diff line
@@ -16,6 +16,10 @@ typedef struct {
	unsigned long clock_tick;
	unsigned int multiplier;
	unsigned int counter;
#ifdef CONFIG_SMP
	unsigned int irq_resched_count;
	unsigned int irq_call_count;
#endif
	int prom_node;
	int mid;
	int next;
@@ -23,5 +27,6 @@ typedef struct {

DECLARE_PER_CPU(cpuinfo_sparc, __cpu_data);
#define cpu_data(__cpu) per_cpu(__cpu_data, (__cpu))
#define local_cpu_data() __get_cpu_var(__cpu_data)

#endif /* _SPARC_CPUDATA_H */
+29 −11
Original line number Diff line number Diff line
@@ -281,28 +281,27 @@ static inline void sun_fd_enable_dma(void)
	pdma_areasize = pdma_size;
}

/* Our low-level entry point in arch/sparc/kernel/entry.S */
extern int sparc_floppy_request_irq(int irq, unsigned long flags,
extern int sparc_floppy_request_irq(unsigned int irq,
                                    irq_handler_t irq_handler);

static int sun_fd_request_irq(void)
{
	static int once = 0;
	int error;

	if (!once) {
		once = 1;
		error = sparc_floppy_request_irq(FLOPPY_IRQ,
						 IRQF_DISABLED,
						 floppy_interrupt);
		return ((error == 0) ? 0 : -1);
	} else return 0;
		return sparc_floppy_request_irq(FLOPPY_IRQ, floppy_interrupt);
	} else {
		return 0;
	}
}

static struct linux_prom_registers fd_regs[2];

static int sun_floppy_init(void)
{
	struct platform_device *op;
	struct device_node *dp;
	char state[128];
	phandle tnode, fd_node;
	int num_regs;
@@ -310,7 +309,6 @@ static int sun_floppy_init(void)

	use_virtual_dma = 1;

	FLOPPY_IRQ = 11;
	/* Forget it if we aren't on a machine that could possibly
	 * ever have a floppy drive.
	 */
@@ -349,6 +347,26 @@ static int sun_floppy_init(void)
	sun_fdc = (struct sun_flpy_controller *)
	    of_ioremap(&r, 0, fd_regs[0].reg_size, "floppy");

	/* Look up irq in platform_device.
	 * We try "SUNW,fdtwo" and "fd"
	 */
	for_each_node_by_name(dp, "SUNW,fdtwo") {
		op = of_find_device_by_node(dp);
		if (op)
			break;
	}
	if (!op) {
		for_each_node_by_name(dp, "fd") {
			op = of_find_device_by_node(dp);
			if (op)
				break;
		}
	}
	if (!op)
		goto no_sun_fdc;

	FLOPPY_IRQ = op->archdata.irqs[0];

	/* Last minute sanity check... */
	if(sun_fdc->status_82072 == 0xff) {
		sun_fdc = NULL;
+13 −0
Original line number Diff line number Diff line
@@ -5,4 +5,17 @@
#else
#include <asm/io_32.h>
#endif

/*
 * Defines used for both SPARC32 and SPARC64
 */

/* Big endian versions of memory read/write routines */
#define readb_be(__addr)	__raw_readb(__addr)
#define readw_be(__addr)	__raw_readw(__addr)
#define readl_be(__addr)	__raw_readl(__addr)
#define writeb_be(__b, __addr)	__raw_writeb(__b, __addr)
#define writel_be(__w, __addr)	__raw_writel(__w, __addr)
#define writew_be(__l, __addr)	__raw_writew(__l, __addr)

#endif
+5 −1
Original line number Diff line number Diff line
@@ -6,7 +6,11 @@
#ifndef _SPARC_IRQ_H
#define _SPARC_IRQ_H

#define NR_IRQS    16
/* Allocated number of logical irq numbers.
 * sun4d boxes (ss2000e) should be OK with ~32.
 * Be on the safe side and make room for 64
 */
#define NR_IRQS    64

#include <linux/interrupt.h>

Loading