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
09a82a9e
Commit
09a82a9e
authored
Jan 11, 2005
by
Russell King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ARM] Add synchronize_irq() support.
parent
5a1b817d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
0 deletions
+25
-0
arch/arm/kernel/irq.c
arch/arm/kernel/irq.c
+25
-0
No files found.
arch/arm/kernel/irq.c
View file @
09a82a9e
...
@@ -85,6 +85,23 @@ static struct irqdesc bad_irq_desc = {
...
@@ -85,6 +85,23 @@ static struct irqdesc bad_irq_desc = {
.
disable_depth
=
1
,
.
disable_depth
=
1
,
};
};
#ifdef CONFIG_SMP
void
synchronize_irq
(
unsigned
int
irq
)
{
struct
irqdesc
*
desc
=
irq_desc
+
irq
;
while
(
desc
->
running
)
barrier
();
}
EXPORT_SYMBOL
(
synchronize_irq
);
#define smp_set_running(desc) do { desc->running = 1; } while (0)
#define smp_clear_running(desc) do { desc->running = 0; } while (0)
#else
#define smp_set_running(desc) do { } while (0)
#define smp_clear_running(desc) do { } while (0)
#endif
/**
/**
* disable_irq_nosync - disable an irq without waiting
* disable_irq_nosync - disable an irq without waiting
* @irq: Interrupt to disable
* @irq: Interrupt to disable
...
@@ -338,12 +355,16 @@ do_simple_IRQ(unsigned int irq, struct irqdesc *desc, struct pt_regs *regs)
...
@@ -338,12 +355,16 @@ do_simple_IRQ(unsigned int irq, struct irqdesc *desc, struct pt_regs *regs)
kstat_cpu
(
cpu
).
irqs
[
irq
]
++
;
kstat_cpu
(
cpu
).
irqs
[
irq
]
++
;
smp_set_running
(
desc
);
action
=
desc
->
action
;
action
=
desc
->
action
;
if
(
action
)
{
if
(
action
)
{
int
ret
=
__do_irq
(
irq
,
action
,
regs
);
int
ret
=
__do_irq
(
irq
,
action
,
regs
);
if
(
ret
!=
IRQ_HANDLED
)
if
(
ret
!=
IRQ_HANDLED
)
report_bad_irq
(
irq
,
regs
,
desc
,
ret
);
report_bad_irq
(
irq
,
regs
,
desc
,
ret
);
}
}
smp_clear_running
(
desc
);
}
}
/*
/*
...
@@ -429,6 +450,8 @@ do_level_IRQ(unsigned int irq, struct irqdesc *desc, struct pt_regs *regs)
...
@@ -429,6 +450,8 @@ do_level_IRQ(unsigned int irq, struct irqdesc *desc, struct pt_regs *regs)
if
(
likely
(
!
desc
->
disable_depth
))
{
if
(
likely
(
!
desc
->
disable_depth
))
{
kstat_cpu
(
cpu
).
irqs
[
irq
]
++
;
kstat_cpu
(
cpu
).
irqs
[
irq
]
++
;
smp_set_running
(
desc
);
/*
/*
* Return with this interrupt masked if no action
* Return with this interrupt masked if no action
*/
*/
...
@@ -443,6 +466,8 @@ do_level_IRQ(unsigned int irq, struct irqdesc *desc, struct pt_regs *regs)
...
@@ -443,6 +466,8 @@ do_level_IRQ(unsigned int irq, struct irqdesc *desc, struct pt_regs *regs)
!
check_irq_lock
(
desc
,
irq
,
regs
)))
!
check_irq_lock
(
desc
,
irq
,
regs
)))
desc
->
chip
->
unmask
(
irq
);
desc
->
chip
->
unmask
(
irq
);
}
}
smp_clear_running
(
desc
);
}
}
}
}
...
...
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