From: dgoulet@efficios.com (David Goulet)
Subject: [lttng-dev] [PATCH lttng-tools] Fix: Warn that kernel loglevels are unsupported
Date: Wed, 13 Nov 2013 16:59:51 -0500 [thread overview]
Message-ID: <20131113215951.GF7694@dalia> (raw)
In-Reply-To: <1384375438-5095-1-git-send-email-jeremie.galarneau@efficios.com>
Merged!
On 13 Nov (15:43:58), J?r?mie Galarneau wrote:
> Warn the user when the log level option is used when the kernel domain
> is selected. Also, don't show the log level in the confirmation message
> when kernel events are selected.
>
> Fixes Bug #645
>
> Signed-off-by: J?r?mie Galarneau <jeremie.galarneau at efficios.com>
> ---
> src/bin/lttng/commands/enable_events.c | 14 +++++---------
> 1 file changed, 5 insertions(+), 9 deletions(-)
>
> diff --git a/src/bin/lttng/commands/enable_events.c b/src/bin/lttng/commands/enable_events.c
> index a7b70c3..2dff63b 100644
> --- a/src/bin/lttng/commands/enable_events.c
> +++ b/src/bin/lttng/commands/enable_events.c
> @@ -346,6 +346,9 @@ static int enable_events(char *session_name)
> ret = CMD_ERROR;
> goto error;
> }
> + if (opt_loglevel) {
> + WARN("Kernel loglevels are not supported.");
> + }
> }
>
> /* Create lttng domain */
> @@ -419,7 +422,7 @@ static int enable_events(char *session_name)
>
> switch (opt_event_type) {
> case LTTNG_EVENT_TRACEPOINT:
> - if (opt_loglevel) {
> + if (opt_loglevel && dom.type != LTTNG_DOMAIN_KERNEL) {
> MSG("All %s tracepoints are enabled in channel %s for loglevel %s",
> get_domain_str(dom.type),
> print_channel_name(channel_name),
> @@ -428,7 +431,6 @@ static int enable_events(char *session_name)
> MSG("All %s tracepoints are enabled in channel %s",
> get_domain_str(dom.type),
> print_channel_name(channel_name));
> -
> }
> break;
> case LTTNG_EVENT_SYSCALL:
> @@ -438,7 +440,7 @@ static int enable_events(char *session_name)
> }
> break;
> case LTTNG_EVENT_ALL:
> - if (opt_loglevel) {
> + if (opt_loglevel && dom.type != LTTNG_DOMAIN_KERNEL) {
> MSG("All %s events are enabled in channel %s for loglevel %s",
> get_domain_str(dom.type),
> print_channel_name(channel_name),
> @@ -533,12 +535,6 @@ static int enable_events(char *session_name)
> goto error;
> }
>
> - if (opt_loglevel) {
> - MSG("Kernel loglevels are not supported.");
> - ret = CMD_UNSUPPORTED;
> - goto error;
> - }
> -
> /* kernel loglevels not implemented */
> ev.loglevel_type = LTTNG_EVENT_LOGLEVEL_ALL;
> } else if (opt_userspace) { /* User-space tracer action */
> --
> 1.8.4.2
>
>
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: Digital signature
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20131113/4b3a42df/attachment.pgp>
prev parent reply other threads:[~2013-11-13 21:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-13 20:43 Jérémie Galarneau
2013-11-13 21:59 ` David Goulet [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=20131113215951.GF7694@dalia \
--to=dgoulet@efficios.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