From: Johan Hedberg <johan.hedberg@gmail.com>
To: Michal Hobot <michal.hobot@silvair.com>
Cc: "linux-bluetooth@vger.kernel.org" <linux-bluetooth@vger.kernel.org>
Subject: Re: [PATCH BlueZ] mesh/onoff-model: Fix msec to sec conversion
Date: Mon, 27 Nov 2017 10:53:25 +0200 [thread overview]
Message-ID: <20171127085325.GA21890@x1c.lan> (raw)
In-Reply-To: <2C0A6DE1-E4B3-4728-B485-0A19BF3419CA@silvair.com>
Hi Michal
On Sat, Nov 25, 2017, Michal Hobot wrote:
> There is an error in meshctl while displaying transition time. 1000 ms
> is being presented as 16 sec, 40 ms. The reason is incorrect
> conversion of milliseconds to seconds. The fix is pretty trivial.
>
> --- ../../bluez/mesh/onoff-model.c 2017-11-21 18:04:57.000000000 +0100
> +++ onoff-model.c 2017-11-21 17:25:14.000000000 +0100
> @@ -77,8 +77,8 @@ static void print_remaining_time(uint8_t
> switch (step) {
> case 0:
> msecs = 100 * count;
> - secs = msecs / 60;
> - msecs -= (secs * 60);
> + secs = msecs / 1000;
> + msecs -= (secs * 1000);
> break;
> case 1:
> secs = 1 * count;
Thanks, the patch has been applied. I had to apply manually however and
fix up the commit message to make sure it adheres to a max 72 line
length. In the future, could you either try send patches using git
send-email, or at least format them with the help of git format-patch,
since what you sent now was unrecognizable to "git am" which is used for
applying patches. Thanks.
Johan
prev parent reply other threads:[~2017-11-27 8:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-25 9:01 [PATCH BlueZ] mesh/onoff-model: Fix msec to sec conversion Michal Hobot
2017-11-27 8:53 ` Johan Hedberg [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=20171127085325.GA21890@x1c.lan \
--to=johan.hedberg@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=michal.hobot@silvair.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;
as well as URLs for NNTP newsgroup(s).