arc: copy_thread(): rename 'arg' argument to 'kthread_arg'
The 'arg' argument to copy_thread() is only ever used when forking a new kernel thread. Hence, rename it to 'kthread_arg' for clarity. Signed-off-by: Alex Dowad <alexinbeijing@gmail.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
This commit is contained in:
parent
e42391cd04
commit
18e1d1b115
1 changed files with 6 additions and 3 deletions
|
@ -49,7 +49,10 @@ void arch_cpu_idle(void)
|
||||||
|
|
||||||
asmlinkage void ret_from_fork(void);
|
asmlinkage void ret_from_fork(void);
|
||||||
|
|
||||||
/* Layout of Child kernel mode stack as setup at the end of this function is
|
/*
|
||||||
|
* Copy architecture-specific thread state
|
||||||
|
*
|
||||||
|
* Layout of Child kernel mode stack as setup at the end of this function is
|
||||||
*
|
*
|
||||||
* | ... |
|
* | ... |
|
||||||
* | ... |
|
* | ... |
|
||||||
|
@ -81,7 +84,7 @@ asmlinkage void ret_from_fork(void);
|
||||||
* ------------------ <===== END of PAGE
|
* ------------------ <===== END of PAGE
|
||||||
*/
|
*/
|
||||||
int copy_thread(unsigned long clone_flags,
|
int copy_thread(unsigned long clone_flags,
|
||||||
unsigned long usp, unsigned long arg,
|
unsigned long usp, unsigned long kthread_arg,
|
||||||
struct task_struct *p)
|
struct task_struct *p)
|
||||||
{
|
{
|
||||||
struct pt_regs *c_regs; /* child's pt_regs */
|
struct pt_regs *c_regs; /* child's pt_regs */
|
||||||
|
@ -112,7 +115,7 @@ int copy_thread(unsigned long clone_flags,
|
||||||
if (unlikely(p->flags & PF_KTHREAD)) {
|
if (unlikely(p->flags & PF_KTHREAD)) {
|
||||||
memset(c_regs, 0, sizeof(struct pt_regs));
|
memset(c_regs, 0, sizeof(struct pt_regs));
|
||||||
|
|
||||||
c_callee->r13 = arg; /* argument to kernel thread */
|
c_callee->r13 = kthread_arg;
|
||||||
c_callee->r14 = usp; /* function */
|
c_callee->r14 = usp; /* function */
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Reference in a new issue