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
6b5738f2
Commit
6b5738f2
authored
Nov 25, 2002
by
Dave Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] CONFIG_DEBUG_SPINLOCK_SLEEP
This makes the sleep-under-spinlock-held check a CONFIG_ option.
parent
cebce9d8
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
3 deletions
+9
-3
arch/i386/Kconfig
arch/i386/Kconfig
+6
-0
include/linux/kernel.h
include/linux/kernel.h
+1
-1
kernel/ksyms.c
kernel/ksyms.c
+1
-1
kernel/sched.c
kernel/sched.c
+1
-1
No files found.
arch/i386/Kconfig
View file @
6b5738f2
...
@@ -1612,6 +1612,12 @@ config KALLSYMS
...
@@ -1612,6 +1612,12 @@ config KALLSYMS
symbolic stack backtraces. This increases the size of the kernel
symbolic stack backtraces. This increases the size of the kernel
somewhat, as all symbols have to be loaded into the kernel image.
somewhat, as all symbols have to be loaded into the kernel image.
config DEBUG_SPINLOCK_SLEEP
bool "Sleep-inside-spinlock checking"
help
If you say Y here, various routines which may sleep will become very
noisy if they are called with a spinlock held.
config X86_EXTRA_IRQS
config X86_EXTRA_IRQS
bool
bool
depends on X86_LOCAL_APIC
depends on X86_LOCAL_APIC
...
...
include/linux/kernel.h
View file @
6b5738f2
...
@@ -40,7 +40,7 @@
...
@@ -40,7 +40,7 @@
struct
completion
;
struct
completion
;
#ifdef CONFIG_DEBUG_
KERNEL
#ifdef CONFIG_DEBUG_
SPINLOCK_SLEEP
void
__might_sleep
(
char
*
file
,
int
line
);
void
__might_sleep
(
char
*
file
,
int
line
);
#define might_sleep() __might_sleep(__FILE__, __LINE__)
#define might_sleep() __might_sleep(__FILE__, __LINE__)
#else
#else
...
...
kernel/ksyms.c
View file @
6b5738f2
...
@@ -481,7 +481,7 @@ EXPORT_SYMBOL(jiffies_64);
...
@@ -481,7 +481,7 @@ EXPORT_SYMBOL(jiffies_64);
EXPORT_SYMBOL
(
xtime
);
EXPORT_SYMBOL
(
xtime
);
EXPORT_SYMBOL
(
do_gettimeofday
);
EXPORT_SYMBOL
(
do_gettimeofday
);
EXPORT_SYMBOL
(
do_settimeofday
);
EXPORT_SYMBOL
(
do_settimeofday
);
#ifdef CONFIG_DEBUG_
KERNEL
#ifdef CONFIG_DEBUG_
SPINLOCK_SLEEP
EXPORT_SYMBOL
(
__might_sleep
);
EXPORT_SYMBOL
(
__might_sleep
);
#endif
#endif
#if !defined(__ia64__)
#if !defined(__ia64__)
...
...
kernel/sched.c
View file @
6b5738f2
...
@@ -2253,7 +2253,7 @@ void __init sched_init(void)
...
@@ -2253,7 +2253,7 @@ void __init sched_init(void)
enter_lazy_tlb
(
&
init_mm
,
current
,
smp_processor_id
());
enter_lazy_tlb
(
&
init_mm
,
current
,
smp_processor_id
());
}
}
#ifdef CONFIG_DEBUG_
KERNEL
#ifdef CONFIG_DEBUG_
SPINLOCK_SLEEP
void
__might_sleep
(
char
*
file
,
int
line
)
void
__might_sleep
(
char
*
file
,
int
line
)
{
{
#if defined(in_atomic)
#if defined(in_atomic)
...
...
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