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
1f02ab4a
Commit
1f02ab4a
authored
Sep 21, 2012
by
Al Viro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
um: switch to generic kernel_thread()
Signed-off-by:
Al Viro
<
viro@zeniv.linux.org.uk
>
parent
6783eaa2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
16 deletions
+4
-16
arch/um/include/asm/processor-generic.h
arch/um/include/asm/processor-generic.h
+0
-2
arch/um/kernel/process.c
arch/um/kernel/process.c
+3
-14
arch/x86/um/Kconfig
arch/x86/um/Kconfig
+1
-0
No files found.
arch/um/include/asm/processor-generic.h
View file @
1f02ab4a
...
...
@@ -63,8 +63,6 @@ static inline void release_thread(struct task_struct *task)
{
}
extern
int
kernel_thread
(
int
(
*
fn
)(
void
*
),
void
*
arg
,
unsigned
long
flags
);
extern
unsigned
long
thread_saved_pc
(
struct
task_struct
*
t
);
static
inline
void
mm_copy_segments
(
struct
mm_struct
*
from_mm
,
...
...
arch/um/kernel/process.c
View file @
1f02ab4a
...
...
@@ -69,18 +69,6 @@ unsigned long alloc_stack(int order, int atomic)
return
page
;
}
int
kernel_thread
(
int
(
*
fn
)(
void
*
),
void
*
arg
,
unsigned
long
flags
)
{
int
pid
;
current
->
thread
.
request
.
u
.
thread
.
proc
=
fn
;
current
->
thread
.
request
.
u
.
thread
.
arg
=
arg
;
pid
=
do_fork
(
CLONE_VM
|
CLONE_UNTRACED
|
flags
,
0
,
&
current
->
thread
.
regs
,
0
,
NULL
,
NULL
);
return
pid
;
}
EXPORT_SYMBOL
(
kernel_thread
);
static
inline
void
set_current
(
struct
task_struct
*
task
)
{
cpu_tasks
[
task_thread_info
(
task
)
->
cpu
]
=
((
struct
cpu_task
)
...
...
@@ -177,7 +165,7 @@ void fork_handler(void)
}
int
copy_thread
(
unsigned
long
clone_flags
,
unsigned
long
sp
,
unsigned
long
stack_top
,
struct
task_struct
*
p
,
unsigned
long
arg
,
struct
task_struct
*
p
,
struct
pt_regs
*
regs
)
{
void
(
*
handler
)(
void
);
...
...
@@ -198,7 +186,8 @@ int copy_thread(unsigned long clone_flags, unsigned long sp,
arch_copy_thread
(
&
current
->
thread
.
arch
,
&
p
->
thread
.
arch
);
}
else
{
get_safe_registers
(
p
->
thread
.
regs
.
regs
.
gp
,
p
->
thread
.
regs
.
regs
.
fp
);
p
->
thread
.
request
.
u
.
thread
=
current
->
thread
.
request
.
u
.
thread
;
p
->
thread
.
request
.
u
.
thread
.
proc
=
(
int
(
*
)(
void
*
))
sp
;
p
->
thread
.
request
.
u
.
thread
.
arg
=
(
void
*
)
arg
;
handler
=
new_thread_handler
;
}
...
...
arch/x86/um/Kconfig
View file @
1f02ab4a
...
...
@@ -13,6 +13,7 @@ endmenu
config UML_X86
def_bool y
select GENERIC_FIND_FIRST_BIT
select GENERIC_KERNEL_THREAD
config 64BIT
bool "64-bit kernel" if SUBARCH = "x86"
...
...
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