From: "Dumitrescu, Cristian" <cristian.dumitrescu@intel.com>
To: Pawel Wodkowski <pwodkowx@stargo>, "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH 0/2] cmdline: add polling mode for command line
Date: Tue, 12 May 2015 11:36:07 +0000 [thread overview]
Message-ID: <3EB4FA525960D640B5BDFFD6A3D891263236798F@IRSMSX108.ger.corp.intel.com> (raw)
In-Reply-To: <1431429019-21130-1-git-send-email-pawelx.wodkowski@intel.com>
> -----Original Message-----
> From: Pawel Wodkowski [mailto:pwodkowx@stargo]
> Sent: Tuesday, May 12, 2015 12:10 PM
> To: dev@dpdk.org
> Cc: Dumitrescu, Cristian; Jastrzebski, MichalX K
> Subject: [PATCH 0/2] cmdline: add polling mode for command line
>
> This patchset adds the ability to process console input in the same thread
> as packet processing by using poll() function and fixes some minor issues.
>
> Pawel Wodkowski (2):
> cmdline: fix missing include files
> cmdline: add polling mode for command line
>
> lib/librte_cmdline/cmdline.c | 35
> ++++++++++++++++++++++++++++++
> lib/librte_cmdline/cmdline.h | 4 ++++
> lib/librte_cmdline/cmdline_rdline.h | 1 +
> lib/librte_cmdline/cmdline_vt100.h | 2 ++
> lib/librte_cmdline/rte_cmdline_version.map | 1 +
> 5 files changed, 43 insertions(+)
>
> --
> 1.9.1
Acked by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
The existing cmdline API requires a thread to be completely consumed for running the CLI, so it is not possible to push any other tasks (typically slow tasks, control plane related) on the same thread. This is because the cmdline_interact() function implements an infinite loop internally, so once called after initialization, it only returns when the application is terminated (e.g. as result of quit CLI command).
This patch removes this limitation by providing an alternative function called cmdline_poll(), which allows the application to own the thread dispatch loop and work with the CLI in polling mode, hence making it possible for the application to push additional work on the same thread. The thread dispatch loop should be owned by the application, and not by the cmdline library.
next prev parent reply other threads:[~2015-05-12 11:36 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-12 11:10 Pawel Wodkowski
2015-05-12 11:10 ` [dpdk-dev] [PATCH 1/2] cmdline: fix missing include files Pawel Wodkowski
2015-05-12 11:10 ` [dpdk-dev] [PATCH 2/2] cmdline: add polling mode for command line Pawel Wodkowski
2015-05-12 14:36 ` Olivier MATZ
2015-05-12 16:14 ` Pawel Wodkowski
2015-05-12 11:36 ` Dumitrescu, Cristian [this message]
2015-05-12 15:32 ` [dpdk-dev] [PATCH 0/2] " Wodkowski, PawelX
2015-05-13 11:59 ` [dpdk-dev] [PATCH v2 " Pawel Wodkowski
2015-05-13 12:00 ` [dpdk-dev] [PATCH v2 1/2] cmdline: fix missing include files Pawel Wodkowski
2015-05-13 12:00 ` [dpdk-dev] [PATCH v2 2/2] cmdline: add polling mode for command line Pawel Wodkowski
2015-05-13 12:44 ` [dpdk-dev] [PATCH v2 0/2] " Dumitrescu, Cristian
2015-05-13 13:20 ` Olivier MATZ
2015-05-18 13:18 ` Thomas Monjalon
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=3EB4FA525960D640B5BDFFD6A3D891263236798F@IRSMSX108.ger.corp.intel.com \
--to=cristian.dumitrescu@intel.com \
--cc=dev@dpdk.org \
--cc=pwodkowx@stargo \
/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;
as well as URLs for NNTP newsgroup(s).