From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754696AbbCMXFF (ORCPT ); Fri, 13 Mar 2015 19:05:05 -0400 Received: from relay4-d.mail.gandi.net ([217.70.183.196]:54848 "EHLO relay4-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753321AbbCMXFC (ORCPT ); Fri, 13 Mar 2015 19:05:02 -0400 Date: Fri, 13 Mar 2015 16:04:58 -0700 From: josh@joshtriplett.org To: Alex Dowad Cc: linux-kernel@vger.kernel.org, Andrew Morton , Oleg Nesterov , Peter Zijlstra , "Kirill A. Shutemov" , Rik van Riel , Vladimir Davydov Subject: Re: [PATCH 01/32] do_fork(): Rename 'stack_size' argument to reflect actual use Message-ID: <20150313230354.GA11522@cloud> References: <1426269888-25600-1-git-send-email-alexinbeijing@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1426269888-25600-1-git-send-email-alexinbeijing@gmail.com> User-Agent: Mutt/1.5.20 (2009-06-14) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 13, 2015 at 08:04:16PM +0200, Alex Dowad wrote: > The 'stack_size' argument is never used to pass a stack size. It's only used when > forking a kernel thread, in which case it is an argument which should be passed > to the 'main' function which the kernel thread executes. Hence, rename it to > 'kthread_arg'. That's not the only use of stack_size. Take a look at the clone2 system call (very minimally documented in the clone manpage) and the implementation of copy_thread on ia64, which does use stack_size in the non-kthread path. - Josh Triplett