mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Arjan van de Ven <arjan@infradead.org>
To: Cornelia Huck <cornelia.huck@de.ibm.com>
Cc: tom.leiming@gmail.com, linux-kernel@vger.kernel.org,
	akpm@linux-foundation.org
Subject: Re: [PATCH 1/2] kernel:async function call:introduce async_run_inatomic(v3)
Date: Mon, 18 May 2009 06:58:58 -0700	[thread overview]
Message-ID: <20090518065858.387b7012@infradead.org> (raw)
In-Reply-To: <20090518131054.1ace6885@gondolin>

On Mon, 18 May 2009 13:10:54 +0200
Cornelia Huck <cornelia.huck@de.ibm.com> wrote:

> On Sat, 16 May 2009 21:54:17 +0800,
> tom.leiming@gmail.com wrote:
> 
> > + /**
> > + * async_run_inatomic - in atomic contexts schedule a function for
> > + * 			asynchronous execution
> > + *
> > + * @ptr: function to execute asynchronously
> > + * @data: data pointer to pass to the function
> > + *
> > + * The purpose of this function is to offer a simple way to
> > schedule an
> > + * asynchronous thread from an atomic context.
> > + *
> > + * Return zero one success, !zero on failured
> > + * Note: async_run_inatomic() uses a distinct running list in order
> > + * to avoid slowing down synchronization within the general domain.
> > + * Since it does not return a cookie for checkpointing, it is for
> > callers
> > + * that don't need later synchronization.
> > + */
> > +int async_run_inatomic(async_func_ptr *ptr, void *data)
> > +{
> > +	return !__async_schedule(ptr, data,
> > &async_running_no_sync, 1); +}
> > +EXPORT_SYMBOL_GPL(async_run_inatomic);
> > +
> 
> While we can skip synchronization on cookies, we still need something
> like async_run_synchronize() for module unloading (and possibly
> others).

We don't have this problem if we use the existing naming and existing
standard domain... 
(I don't like the "run" part of the name, rather than schedule.. lets
keep the apis consistent please)


-- 
Arjan van de Ven 	Intel Open Source Technology Centre
For development, discussion and tips for power savings, 
visit http://www.lesswatts.org

      reply	other threads:[~2009-05-18 13:59 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-16 13:54 tom.leiming
2009-05-16 13:54 ` [PATCH 2/2] driver core:firmware:fix request_firmware_nowait tom.leiming
2009-05-18 11:15   ` Cornelia Huck
2009-05-18 11:10 ` [PATCH 1/2] kernel:async function call:introduce async_run_inatomic(v3) Cornelia Huck
2009-05-18 13:58   ` Arjan van de Ven [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090518065858.387b7012@infradead.org \
    --to=arjan@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=cornelia.huck@de.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tom.leiming@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome