Linux IIO development
 help / color / mirror / Atom feed
From: "Nuno Sá" <noname.nuno@gmail.com>
To: Cosmin Tanislav <demonsingur@gmail.com>
Cc: Cosmin Tanislav <cosmin.tanislav@analog.com>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Michael Hennerich <Michael.Hennerich@analog.com>,
	 Jonathan Cameron <jic23@kernel.org>,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	 linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] iio: adc: ad4130: zero-initialize clock init data
Date: Thu, 08 Feb 2024 09:15:08 +0100	[thread overview]
Message-ID: <fd81a6127a9b7abb6eae0785281836a238af8b57.camel@gmail.com> (raw)
In-Reply-To: <20240207132007.253768-1-demonsingur@gmail.com>

On Wed, 2024-02-07 at 15:20 +0200, Cosmin Tanislav wrote:
> The clk_init_data struct does not have all its members
> initialized, causing issues when trying to expose the internal
> clock on the CLK pin.
> 
> Fix this by zero-initializing the clk_init_data struct.
> 
> Fixes: 62094060cf3a ("iio: adc: ad4130: add AD4130 driver")
> Signed-off-by: Cosmin Tanislav <demonsingur@gmail.com>
> ---

Reviewed-by: Nuno Sa <nuno.sa@analog.com>

>  drivers/iio/adc/ad4130.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/adc/ad4130.c b/drivers/iio/adc/ad4130.c
> index 53e19a863198..c7df499f9775 100644
> --- a/drivers/iio/adc/ad4130.c
> +++ b/drivers/iio/adc/ad4130.c
> @@ -1794,7 +1794,7 @@ static int ad4130_setup_int_clk(struct ad4130_state *st)
>  {
>  	struct device *dev = &st->spi->dev;
>  	struct device_node *of_node = dev_of_node(dev);
> -	struct clk_init_data init;
> +	struct clk_init_data init = {};
>  	const char *clk_name;
>  	int ret;
>  


  parent reply	other threads:[~2024-02-08  8:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-07 13:20 [PATCH 1/2] iio: adc: ad4130: zero-initialize clock init data Cosmin Tanislav
2024-02-07 13:20 ` [PATCH 2/2] iio: adc: ad4130: only set GPIO_CTRL if pin is unused Cosmin Tanislav
2024-02-08  8:16   ` Nuno Sá
2024-02-08  8:15 ` Nuno Sá [this message]
2024-02-10 16:53   ` [PATCH 1/2] iio: adc: ad4130: zero-initialize clock init data 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=fd81a6127a9b7abb6eae0785281836a238af8b57.camel@gmail.com \
    --to=noname.nuno@gmail.com \
    --cc=Michael.Hennerich@analog.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=cosmin.tanislav@analog.com \
    --cc=demonsingur@gmail.com \
    --cc=jic23@kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@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