Main Page | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals

mips/kernel/irq.c File Reference

#include <linux/errno.h>
#include <linux/init.h>
#include <linux/kernel_stat.h>
#include <linux/module.h>
#include <linux/signal.h>
#include <linux/sched.h>
#include <linux/types.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
#include <linux/timex.h>
#include <linux/malloc.h>
#include <linux/random.h>
#include <asm/bitops.h>
#include <asm/bootinfo.h>
#include <asm/io.h>
#include <asm/irq.h>
#include <asm/mipsregs.h>
#include <asm/system.h>
#include <asm/sni.h>

Include dependency graph for mips/kernel/irq.c:

Go to the source code of this file.

Defines

#define __byte(x, y)   (((unsigned char *)&(y))[x])
#define __word(x, y)   (((unsigned short *)&(y))[x])
#define __long(x, y)   (((unsigned int *)&(y))[x])
#define cached_21   (__byte(0,cached_irq_mask))
#define cached_A1   (__byte(1,cached_irq_mask))

Functions

static void mask_irq (unsigned int irq)
static void unmask_irq (unsigned int irq)
void disable_irq (unsigned int irq_nr)
void enable_irq (unsigned int irq_nr)
int get_irq_list (char *buf)
static void i8259_mask_and_ack_irq (int irq)
asmlinkage void i8259_do_irq (int irq, struct pt_regs *regs)
asmlinkage void do_IRQ (int irq, struct pt_regs *regs)
int i8259_setup_irq (int irq, struct irqaction *new)
int request_irq (unsigned int irq, void(*handler)(int, void *, struct pt_regs *), unsigned long irqflags, const char *devname, void *dev_id)
void free_irq (unsigned int irq, void *dev_id)
unsigned long probe_irq_on (void)
int probe_irq_off (unsigned long irqs)
static int i8259_irq_cannonicalize (int irq)
 __initfunc (static void i8259_init(void))
unsigned long init_IRQ (unsigned long memory)
 EXPORT_SYMBOL (irq_cannonicalize)

Variables

static unsigned int cached_irq_mask = 0xffff
unsigned int local_bh_count [NR_CPUS]
unsigned int local_irq_count [NR_CPUS]
unsigned long spurious_count = 0
static struct irqactionirq_action [NR_IRQS]
atomic_t __mips_bh_counter
int(* irq_cannonicalize )(int irq)


Define Documentation

#define __byte x,
y   )     (((unsigned char *)&(y))[x])
 

Definition at line 40 of file mips/kernel/irq.c.

#define __long x,
y   )     (((unsigned int *)&(y))[x])
 

Definition at line 42 of file mips/kernel/irq.c.

#define __word x,
y   )     (((unsigned short *)&(y))[x])
 

Definition at line 41 of file mips/kernel/irq.c.

#define cached_21   (__byte(0,cached_irq_mask))
 

Definition at line 44 of file mips/kernel/irq.c.

#define cached_A1   (__byte(1,cached_irq_mask))
 

Definition at line 45 of file mips/kernel/irq.c.


Function Documentation

__initfunc static void   i8259_init(void)  ) 
 

Definition at line 359 of file mips/kernel/irq.c.

References cached_21, cached_A1, outb, x00, x01, x02, x04, x08, x11, x20, and xff.

void disable_irq unsigned int  irq_nr  ) 
 

Definition at line 75 of file mips/kernel/irq.c.

References mask_irq, restore_flags, and save_and_cli.

asmlinkage void do_IRQ int  irq,
struct pt_regs regs
 

Definition at line 188 of file mips/kernel/irq.c.

References __cli, __sti, add_interrupt_randomness(), cpu, irqaction::dev_id, irqaction::flags, irqaction::handler, hardirq_enter, hardirq_exit, kernel_stat::irqs, kstat, irqaction::next, SA_INTERRUPT, and smp_processor_id.

Here is the call graph for this function:

void enable_irq unsigned int  irq_nr  ) 
 

Definition at line 84 of file mips/kernel/irq.c.

References restore_flags, save_and_cli, and unmask_irq.

EXPORT_SYMBOL irq_cannonicalize   ) 
 

void free_irq unsigned int  irq,
void *  dev_id
 

Definition at line 290 of file mips/kernel/irq.c.

References irqaction::dev_id, kfree(), mask_irq, irqaction::next, NULL, p, printk, restore_flags, and save_and_cli.

Here is the call graph for this function:

int get_irq_list char *  buf  ) 
 

Definition at line 103 of file mips/kernel/irq.c.

References irqaction::flags, i, kernel_stat::irqs, kstat, len, irqaction::name, irqaction::next, SA_INTERRUPT, and sprintf().

Here is the call graph for this function:

asmlinkage void i8259_do_irq int  irq,
struct pt_regs regs
 

Definition at line 144 of file mips/kernel/irq.c.

References __cli, __sti, add_interrupt_randomness(), cpu, irqaction::dev_id, irqaction::flags, irqaction::handler, hardirq_enter, hardirq_exit, i8259_mask_and_ack_irq(), kernel_stat::irqs, kstat, irqaction::next, out, SA_INTERRUPT, smp_processor_id, and unmask_irq.

Here is the call graph for this function:

static int i8259_irq_cannonicalize int  irq  )  [static]
 

Definition at line 354 of file mips/kernel/irq.c.

Referenced by init_IRQ().

static void i8259_mask_and_ack_irq int  irq  )  [inline, static]
 

Definition at line 128 of file mips/kernel/irq.c.

References cached_21, cached_A1, cached_irq_mask, inb, outb, x20, and x62.

Referenced by i8259_do_irq().

int i8259_setup_irq int  irq,
struct irqaction new
 

Definition at line 217 of file mips/kernel/irq.c.

References EBUSY, irqaction::flags, irqaction::next, NULL, p, rand_initialize_irq(), restore_flags, SA_INTERRUPT, SA_SHIRQ, save_and_cli, and unmask_irq.

Referenced by __initfunc(), and request_irq().

Here is the call graph for this function:

unsigned long init_IRQ unsigned long  memory  ) 
 

Definition at line 379 of file mips/kernel/irq.c.

References i8259_irq_cannonicalize(), irq_cannonicalize, and irq_setup.

Here is the call graph for this function:

static void mask_irq unsigned int  irq  )  [inline, static]
 

Definition at line 55 of file mips/kernel/irq.c.

References cached_21, cached_A1, cached_irq_mask, and outb.

int probe_irq_off unsigned long  irqs  ) 
 

Definition at line 336 of file mips/kernel/irq.c.

References cached_irq_mask, ffz(), i, and printk.

Here is the call graph for this function:

unsigned long probe_irq_on void   ) 
 

Definition at line 315 of file mips/kernel/irq.c.

References cached_irq_mask, delay, enable_irq, HZ, i, irqs, jiffies, and time_before.

int request_irq unsigned int  irq,
void(*)(int, void *, struct pt_regs *)  handler,
unsigned long  irqflags,
const char *  devname,
void *  dev_id
 

Definition at line 260 of file mips/kernel/irq.c.

References irqaction::dev_id, EINVAL, ENOMEM, irqaction::flags, irqaction::handler, i8259_setup_irq(), kfree(), kmalloc(), irqaction::mask, irqaction::name, irqaction::next, and NULL.

Here is the call graph for this function:

static void unmask_irq unsigned int  irq  )  [inline, static]
 

Definition at line 65 of file mips/kernel/irq.c.

References cached_21, cached_A1, cached_irq_mask, and outb.


Variable Documentation

atomic_t __mips_bh_counter
 

Definition at line 126 of file mips/kernel/irq.c.

unsigned int cached_irq_mask = 0xffff [static]
 

Definition at line 38 of file mips/kernel/irq.c.

struct irqaction* irq_action[NR_IRQS] [static]
 

Initial value:

 {
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL
}

Definition at line 92 of file mips/kernel/irq.c.

int(* irq_cannonicalize)(int irq)
 

Definition at line 352 of file mips/kernel/irq.c.

unsigned int local_bh_count[NR_CPUS]
 

Definition at line 47 of file mips/kernel/irq.c.

unsigned int local_irq_count[NR_CPUS]
 

Definition at line 48 of file mips/kernel/irq.c.

unsigned long spurious_count = 0
 

Definition at line 49 of file mips/kernel/irq.c.