lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1426269888-25600-8-git-send-email-alexinbeijing@gmail.com>
Date:	Fri, 13 Mar 2015 20:04:23 +0200
From:	Alex Dowad <alexinbeijing@...il.com>
To:	linux-kernel@...t.kernel.org
Cc:	Mark Salter <msalter@...hat.com>,
	Aurelien Jacquiot <a-jacquiot@...com>,
	linux-c6x-dev@...ux-c6x.org (open list:C6X ARCHITECTURE),
	linux-kernel@...r.kernel.org (open list)
Subject: [PATCH 08/32] c6x: copy_thread(): rename 'ustk_size' argument to 'kthread_arg'

'ustk_size' is a misnomer: it is never used for the size of the user stack. It is
only used when forking a new kernel thread, as the argument passed to the kthread's
main function.

Signed-off-by: Alex Dowad <alexinbeijing@...il.com>
---
 arch/c6x/kernel/process.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/c6x/kernel/process.c b/arch/c6x/kernel/process.c
index 57d2ea8..b519377 100644
--- a/arch/c6x/kernel/process.c
+++ b/arch/c6x/kernel/process.c
@@ -109,10 +109,10 @@ void start_thread(struct pt_regs *regs, unsigned int pc, unsigned long usp)
 }
 
 /*
- * Copy a new thread context in its stack.
+ * Copy architecture-specific thread state
  */
 int copy_thread(unsigned long clone_flags, unsigned long usp,
-		unsigned long ustk_size,
+		unsigned long kthread_arg,
 		struct task_struct *p)
 {
 	struct pt_regs *childregs;
@@ -125,9 +125,9 @@ int copy_thread(unsigned long clone_flags, unsigned long usp,
 		childregs->sp = (unsigned long)(childregs + 1);
 		p->thread.pc = (unsigned long) ret_from_kernel_thread;
 		childregs->a0 = usp;		/* function */
-		childregs->a1 = ustk_size;	/* argument */
+		childregs->a1 = kthread_arg;
 	} else {
-		/* Otherwise use the given stack */
+		/* user thread: use the given stack */
 		*childregs = *current_pt_regs();
 		if (usp)
 			childregs->sp = usp;
-- 
2.0.0.GIT

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ