sh: INTC ioremap support

Extend the INTC code with ioremap() support V2.

Support INTC controllers that are not accessible through
a 1:1 virt:phys window. Needed by SH-Mobile ARM INTCS.

The INTC code behaves as usual if the io window resource
is omitted. The slow phys->virt lookup only happens during
setup. The fast path code operates on virtual addresses.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:
Magnus Damm 2010-03-19 16:48:01 +09:00 committed by Paul Mundt
parent 01e9651a21
commit dec710b77c
2 changed files with 78 additions and 10 deletions

View file

@ -1,6 +1,8 @@
#ifndef __SH_INTC_H
#define __SH_INTC_H
#include <linux/ioport.h>
typedef unsigned char intc_enum;
struct intc_vect {
@ -71,6 +73,8 @@ struct intc_hw_desc {
struct intc_desc {
char *name;
struct resource *resource;
unsigned int num_resources;
intc_enum force_enable;
intc_enum force_disable;
struct intc_hw_desc hw;