From: Jonathan Cameron <jic23@kernel.org>
To: Alexandru Ardelean <alexandru.ardelean@analog.com>
Cc: <linux-iio@vger.kernel.org>, <lars@metafoo.de>,
<Michael.Hennerich@analog.com>
Subject: Re: [PATCH V2] iio: ad9523: Fix displayed phase
Date: Sat, 30 Jun 2018 19:06:36 +0100 [thread overview]
Message-ID: <20180630190636.599a9b2a@archlinux> (raw)
In-Reply-To: <20180625080307.14754-1-alexandru.ardelean@analog.com>
On Mon, 25 Jun 2018 11:03:07 +0300
Alexandru Ardelean <alexandru.ardelean@analog.com> wrote:
> From: Lars-Peter Clausen <lars@metafoo.de>
>
> Fix the displayed phase for the ad9523 driver. Currently the most
> significant decimal place is dropped and all other digits are shifted one
> to the left. This is due to a multiplication by 10, which is not necessary,
> so remove it.
>
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Marked for stable and a fixes tag added for the original introduction of
the driver.
Applied to the fixes-togreg branch of iio.git
Thanks,
Jonathan
> ---
>
> v1 -> v2:
> * added Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
>
> drivers/iio/frequency/ad9523.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/iio/frequency/ad9523.c b/drivers/iio/frequency/ad9523.c
> index ddb6a334ae68..d5b2c231a661 100644
> --- a/drivers/iio/frequency/ad9523.c
> +++ b/drivers/iio/frequency/ad9523.c
> @@ -642,7 +642,7 @@ static int ad9523_read_raw(struct iio_dev *indio_dev,
> code = (AD9523_CLK_DIST_DIV_PHASE_REV(ret) * 3141592) /
> AD9523_CLK_DIST_DIV_REV(ret);
> *val = code / 1000000;
> - *val2 = (code % 1000000) * 10;
> + *val2 = code % 1000000;
> return IIO_VAL_INT_PLUS_MICRO;
> default:
> return -EINVAL;
prev parent reply other threads:[~2018-06-30 18:06 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-25 8:03 [PATCH V2] iio: ad9523: Fix displayed phase Alexandru Ardelean
2018-06-30 18:06 ` Jonathan Cameron [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=20180630190636.599a9b2a@archlinux \
--to=jic23@kernel.org \
--cc=Michael.Hennerich@analog.com \
--cc=alexandru.ardelean@analog.com \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
/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).