public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Re: async: make async a command line option for now
       [not found] <200901100002.n0A02qKl010433@hera.kernel.org>
@ 2009-01-10  0:14 ` Randy Dunlap
  2009-01-10  0:30   ` Arjan van de Ven
  0 siblings, 1 reply; 2+ messages in thread
From: Randy Dunlap @ 2009-01-10  0:14 UTC (permalink / raw)
  To: Linux Kernel Mailing List; +Cc: Arjan van de Ven

On Sat, 10 Jan 2009 00:02:52 GMT Linux Kernel Mailing List wrote:

> Gitweb:     http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=cdb80f630be5cbc23d82331f24dc4704f75b64f4
> Commit:     cdb80f630be5cbc23d82331f24dc4704f75b64f4
> Parent:     b32714ba29358a688ef337d5297bf4bdc9f596dc
> Author:     Arjan van de Ven <arjan@linux.intel.com>
> AuthorDate: Fri Jan 9 13:23:45 2009 -0800
> Committer:  Arjan van de Ven <arjan@linux.intel.com>
> CommitDate: Fri Jan 9 13:23:45 2009 -0800
> 
>     async: make async a command line option for now
>     
>     ... and have it default off.
>     This does allow people to work with it for testing.


Is this boot option documented anywhere or did you mean to
keep it hidden to all but inquiring minds?


>     Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
> ---
>  kernel/async.c |   16 ++++++++++++++--
>  1 files changed, 14 insertions(+), 2 deletions(-)
> 
> diff --git a/kernel/async.c b/kernel/async.c
> index 64cc916..f286e9f 100644
> --- a/kernel/async.c
> +++ b/kernel/async.c
> @@ -65,6 +65,8 @@ static LIST_HEAD(async_pending);
>  static LIST_HEAD(async_running);
>  static DEFINE_SPINLOCK(async_lock);
>  
> +static int async_enabled = 0;
> +
>  struct async_entry {
>  	struct list_head list;
>  	async_cookie_t   cookie;
> @@ -169,7 +171,7 @@ static async_cookie_t __async_schedule(async_func_ptr *ptr, void *data, struct l
>  	 * If we're out of memory or if there's too much work
>  	 * pending already, we execute synchronously.
>  	 */
> -	if (!entry || atomic_read(&entry_count) > MAX_WORK) {
> +	if (!async_enabled || !entry || atomic_read(&entry_count) > MAX_WORK) {
>  		kfree(entry);
>  		spin_lock_irqsave(&async_lock, flags);
>  		newcookie = next_cookie++;
> @@ -316,8 +318,18 @@ static int async_manager_thread(void *unused)
>  
>  static int __init async_init(void)
>  {
> -	kthread_run(async_manager_thread, NULL, "async/mgr");
> +	if (async_enabled)
> +		kthread_run(async_manager_thread, NULL, "async/mgr");
>  	return 0;
>  }
>  
> +static int __init setup_async(char *str)
> +{
> +	async_enabled = 1;
> +	return 1;
> +}
> +
> +__setup("fastboot", setup_async);
> +
> +
>  core_initcall(async_init);

---
~Randy

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: async: make async a command line option for now
  2009-01-10  0:14 ` async: make async a command line option for now Randy Dunlap
@ 2009-01-10  0:30   ` Arjan van de Ven
  0 siblings, 0 replies; 2+ messages in thread
From: Arjan van de Ven @ 2009-01-10  0:30 UTC (permalink / raw)
  To: Randy Dunlap; +Cc: Linux Kernel Mailing List

Randy Dunlap wrote:
> On Sat, 10 Jan 2009 00:02:52 GMT Linux Kernel Mailing List wrote:
> 
>> Gitweb:     http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=cdb80f630be5cbc23d82331f24dc4704f75b64f4
>> Commit:     cdb80f630be5cbc23d82331f24dc4704f75b64f4
>> Parent:     b32714ba29358a688ef337d5297bf4bdc9f596dc
>> Author:     Arjan van de Ven <arjan@linux.intel.com>
>> AuthorDate: Fri Jan 9 13:23:45 2009 -0800
>> Committer:  Arjan van de Ven <arjan@linux.intel.com>
>> CommitDate: Fri Jan 9 13:23:45 2009 -0800
>>
>>     async: make async a command line option for now
>>     
>>     ... and have it default off.
>>     This does allow people to work with it for testing.
> 
> 
> Is this boot option documented anywhere or did you mean to
> keep it hidden to all but inquiring minds?
> 
> 

for now low visibility is good;
in fact once the feature stabilizes it'll flip the other way around,
at which point it does need to be documented.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-01-10  0:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <200901100002.n0A02qKl010433@hera.kernel.org>
2009-01-10  0:14 ` async: make async a command line option for now Randy Dunlap
2009-01-10  0:30   ` Arjan van de Ven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox