Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
9972ab81
Commit
9972ab81
authored
Oct 04, 2003
by
Russell King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ARM] Add sysdev model for Integrator/AP.
parent
9e91a0ab
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
46 additions
and
0 deletions
+46
-0
arch/arm/mach-integrator/integrator_ap.c
arch/arm/mach-integrator/integrator_ap.c
+46
-0
No files found.
arch/arm/mach-integrator/integrator_ap.c
View file @
9972ab81
...
@@ -24,6 +24,7 @@
...
@@ -24,6 +24,7 @@
#include <linux/device.h>
#include <linux/device.h>
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/string.h>
#include <linux/sysdev.h>
#include <asm/hardware.h>
#include <asm/hardware.h>
#include <asm/io.h>
#include <asm/io.h>
...
@@ -133,6 +134,51 @@ static void __init ap_init_irq(void)
...
@@ -133,6 +134,51 @@ static void __init ap_init_irq(void)
}
}
}
}
#ifdef CONFIG_PM
static
unsigned
long
ic_irq_enable
;
static
int
irq_suspend
(
struct
sys_device
*
dev
,
u32
state
)
{
ic_irq_enable
=
readl
(
VA_IC_BASE
+
IRQ_ENABLE
);
return
0
;
}
static
int
irq_resume
(
struct
sys_device
*
dev
)
{
/* disable all irq sources */
writel
(
-
1
,
VA_CMIC_BASE
+
IRQ_ENABLE_CLEAR
);
writel
(
-
1
,
VA_IC_BASE
+
IRQ_ENABLE_CLEAR
);
writel
(
-
1
,
VA_IC_BASE
+
FIQ_ENABLE_CLEAR
);
writel
(
ic_irq_enable
,
VA_IC_BASE
+
IRQ_ENABLE_SET
);
return
0
;
}
#else
#define irq_suspend NULL
#define irq_resume NULL
#endif
static
struct
sysdev_class
irq_class
=
{
set_kset_name
(
"irq"
),
.
suspend
=
irq_suspend
,
.
resume
=
irq_resume
,
};
static
struct
sys_device
irq_device
=
{
.
id
=
0
,
.
cls
=
&
irq_class
,
};
static
int
__init
irq_init_sysfs
(
void
)
{
int
ret
=
sysdev_class_register
(
&
irq_class
);
if
(
ret
==
0
)
ret
=
sys_device_register
(
&
irq_device
);
return
ret
;
}
device_initcall
(
irq_init_sysfs
);
/*
/*
* Flash handling.
* Flash handling.
*/
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment