All of lore.kernel.org
 help / color / mirror / Atom feed
From: Denis Kenzior <denkenz@gmail.com>
To: ell@lists.01.org
Subject: Re: [PATCH v2 1/3] main: Manually initialize and clean up the main loop
Date: Thu, 09 Jun 2016 10:12:00 -0500	[thread overview]
Message-ID: <57598740.5000900@gmail.com> (raw)
In-Reply-To: <20160608215538.5590-1-mathew.j.martineau@linux.intel.com>

[-- Attachment #1: Type: text/plain, Size: 1117 bytes --]

Hi Mat,

On 06/08/2016 04:55 PM, Mat Martineau wrote:
> Atomatic initialization and cleanup of the main loop created some
> issues with orderly shutdown of an ELL program. If cleanup functions
> were called after the l_main_run() returned, they could indirectly set
> up the epoll file descriptor and associated resources again. Those
> resources were not freed after the cleanup functions ran.
>
> Now, epoll resources are set up by l_main_init() and cleaned up by
> l_main_exit(). If cleanup functions set up any idles or watches
> (including watch-based timeouts, signals, or ios) after l_main_run()
> returns, those will be destroyed by l_main_exit().
>
> l_main_init() must be called before l_main_run() or any other ELL
> function that expects epoll to be set up. l_main_exit() should be
> called after l_main_run() returns to ensure that all resources are
> freed.
> ---
>   ell/main.c | 87 ++++++++++++++++++++++++++++++++++++++------------------------
>   ell/main.h |  4 ++-
>   2 files changed, 57 insertions(+), 34 deletions(-)
>

All three applied, thanks.

Regards,
-Denis


  parent reply	other threads:[~2016-06-09 15:12 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-08 21:55 [PATCH v2 1/3] main: Manually initialize and clean up the main loop Mat Martineau
2016-06-08 21:55 ` [PATCH v2 2/3] examples: Update for new main loop init/exit functions Mat Martineau
2016-06-08 21:55 ` [PATCH v2 3/3] unit: " Mat Martineau
2016-06-09 15:12 ` Denis Kenzior [this message]
2016-06-09 15:58   ` [PATCH v2 1/3] main: Manually initialize and clean up the main loop Mat Martineau
2016-06-09 16:02     ` Denis Kenzior

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=57598740.5000900@gmail.com \
    --to=denkenz@gmail.com \
    --cc=ell@lists.01.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.