From: Bartosz Golaszewski <brgl@bgdev.pl>
To: Kent Gibson <warthog618@gmail.com>,
Linus Walleij <linus.walleij@linaro.org>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Viresh Kumar <viresh.kumar@linaro.org>
Cc: linux-gpio@vger.kernel.org,
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
Wes Tarro <wes.tarro@azuresummit.com>
Subject: [libgpiod][PATCH] tools: gpiomon: fix setting event clock type
Date: Wed, 15 Mar 2023 09:34:56 +0100 [thread overview]
Message-ID: <20230315083456.27590-1-brgl@bgdev.pl> (raw)
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Fix an inverted logic bug when parsing event clock type in gpiomon.
Fixes: 8ffb6489286f ("tools: line name focussed rework")
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reported-by: Wes Tarro <wes.tarro@azuresummit.com>
---
tools/gpiomon.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/gpiomon.c b/tools/gpiomon.c
index ec177df..c2684c2 100644
--- a/tools/gpiomon.c
+++ b/tools/gpiomon.c
@@ -99,7 +99,7 @@ static int parse_event_clock_or_die(const char *option)
{
if (strcmp(option, "realtime") == 0)
return GPIOD_LINE_CLOCK_REALTIME;
- if (strcmp(option, "hte") != 0)
+ if (strcmp(option, "hte") == 0)
return GPIOD_LINE_CLOCK_HTE;
if (strcmp(option, "monotonic") != 0)
die("invalid event clock: %s", option);
--
2.37.2
next reply other threads:[~2023-03-15 8:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-15 8:34 Bartosz Golaszewski [this message]
2023-03-15 8:44 ` [libgpiod][PATCH] tools: gpiomon: fix setting event clock type Linus Walleij
2023-03-15 14:03 ` Andy Shevchenko
2023-03-15 14:10 ` Bartosz Golaszewski
2023-03-15 14:04 ` Andy Shevchenko
2023-03-15 18:36 ` Bartosz Golaszewski
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=20230315083456.27590-1-brgl@bgdev.pl \
--to=brgl@bgdev.pl \
--cc=andriy.shevchenko@linux.intel.com \
--cc=bartosz.golaszewski@linaro.org \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=viresh.kumar@linaro.org \
--cc=warthog618@gmail.com \
--cc=wes.tarro@azuresummit.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