-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
yaml --- r: 181130 b: refs/heads/master c: 5f24071 h: refs/heads/master v: v3
- Loading branch information
Paul Mundt
committed
Jan 20, 2010
1 parent
e02abbc
commit 3b81b91
Showing
5 changed files
with
60 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
--- | ||
refs/heads/master: efd590d57a5edddabaaf4cfaf532c0f674193b81 | ||
refs/heads/master: 5f240718b475dcddee86b138b624f24c681dbb29 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
obj-y := setup.o fpga.o | ||
obj-y := setup.o fpga.o irq.o |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/* | ||
* SDK7786 FPGA IRQ Controller Support. | ||
* | ||
* Copyright (C) 2010 Matt Fleming | ||
* Copyright (C) 2010 Paul Mundt | ||
* | ||
* This file is subject to the terms and conditions of the GNU General Public | ||
* License. See the file "COPYING" in the main directory of this archive | ||
* for more details. | ||
*/ | ||
#include <linux/irq.h> | ||
#include <mach/fpga.h> | ||
#include <mach/irq.h> | ||
|
||
enum { | ||
ATA_IRQ_BIT = 1, | ||
SPI_BUSY_BIT = 2, | ||
LIRQ5_BIT = 3, | ||
LIRQ6_BIT = 4, | ||
LIRQ7_BIT = 5, | ||
LIRQ8_BIT = 6, | ||
KEY_IRQ_BIT = 7, | ||
PEN_IRQ_BIT = 8, | ||
ETH_IRQ_BIT = 9, | ||
RTC_ALARM_BIT = 10, | ||
CRYSTAL_FAIL_BIT = 12, | ||
ETH_PME_BIT = 14, | ||
}; | ||
|
||
void __init sdk7786_init_irq(void) | ||
{ | ||
unsigned int tmp; | ||
|
||
/* Enable priority encoding for all IRLs */ | ||
fpga_write_reg(fpga_read_reg(INTMSR) | 0x0303, INTMSR); | ||
|
||
/* Clear FPGA interrupt status registers */ | ||
fpga_write_reg(0x0000, INTASR); | ||
fpga_write_reg(0x0000, INTBSR); | ||
|
||
/* Unmask FPGA interrupts */ | ||
tmp = fpga_read_reg(INTAMR); | ||
tmp &= ~(1 << ETH_IRQ_BIT); | ||
fpga_write_reg(tmp, INTAMR); | ||
|
||
plat_irq_setup_pins(IRQ_MODE_IRL7654_MASK); | ||
plat_irq_setup_pins(IRQ_MODE_IRL3210_MASK); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#ifndef __MACH_SDK7786_IRQ_H | ||
#define __MACH_SDK7786_IRQ_H | ||
|
||
/* arch/sh/boards/mach-sdk7786/irq.c */ | ||
extern void sdk7786_init_irq(void); | ||
|
||
#endif /* __MACH_SDK7786_IRQ_H */ |