All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Peter Meerwald <pmeerw@pmeerw.net>, linux-iio@vger.kernel.org
Subject: Re: [PATCH 2/5] iio:magnetometer:mag3110: Fix output of decimal digits in show_int_plus_micros()
Date: Sat, 11 Jan 2014 12:14:25 +0000	[thread overview]
Message-ID: <52D135A1.1050305@kernel.org> (raw)
In-Reply-To: <1389391163-9622-2-git-send-email-pmeerw@pmeerw.net>

On 10/01/14 21:59, Peter Meerwald wrote:
> need to print leading zeros, hence "%d.%06d"
>
> Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Applied to the fixes-for-3.14new branch of iio.git

Thanks,
> ---
>   drivers/iio/magnetometer/mag3110.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/iio/magnetometer/mag3110.c b/drivers/iio/magnetometer/mag3110.c
> index b88cb44..f66955f 100644
> --- a/drivers/iio/magnetometer/mag3110.c
> +++ b/drivers/iio/magnetometer/mag3110.c
> @@ -106,7 +106,7 @@ static ssize_t mag3110_show_int_plus_micros(char *buf,
>
>   	while (n-- > 0)
>   		len += scnprintf(buf + len, PAGE_SIZE - len,
> -			"%d.%d ", vals[n][0], vals[n][1]);
> +			"%d.%06d ", vals[n][0], vals[n][1]);
>
>   	/* replace trailing space by newline */
>   	buf[len - 1] = '\n';
>

  reply	other threads:[~2014-01-11 12:14 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-10 21:59 [PATCH 1/5] iio:magnetometer:mag3110: Report busy in _read_raw() / write_raw() when buffer is enabled Peter Meerwald
2014-01-10 21:59 ` [PATCH 2/5] iio:magnetometer:mag3110: Fix output of decimal digits in show_int_plus_micros() Peter Meerwald
2014-01-11 12:14   ` Jonathan Cameron [this message]
2014-01-10 21:59 ` [PATCH 3/5] iio:magnetometer:mag3110: Scale factor missing for temperature Peter Meerwald
2014-01-11 16:08   ` Jonathan Cameron
2014-01-10 21:59 ` [PATCH 4/5] iio:magnetometer:mag3110: Fix initialization of ctrl_reg1 Peter Meerwald
2014-01-11 16:09   ` Jonathan Cameron
2014-01-10 21:59 ` [PATCH 5/5] iio:magnetometer:mag3110: Enable user offset calibration Peter Meerwald
2014-01-11 16:10   ` Jonathan Cameron
2014-01-11 12:07 ` [PATCH 1/5] iio:magnetometer:mag3110: Report busy in _read_raw() / write_raw() when buffer is enabled Jonathan Cameron
2014-01-11 12:13   ` Jonathan Cameron

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=52D135A1.1050305@kernel.org \
    --to=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=pmeerw@pmeerw.net \
    /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.