mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: "Nuno Sá" <noname.nuno@gmail.com>
Cc: Trevor Gamblin <tgamblin@baylibre.com>,
	Nuno Sa <nuno.sa@analog.com>,
	Lars-Peter Clausen  <lars@metafoo.de>,
	Michael Hennerich <Michael.Hennerich@analog.com>,
	Angelo Dureghello <adureghello@baylibre.com>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] iio: dac: adi-axi-dac: improve probe() error messaging
Date: Sat, 22 Jun 2024 19:09:39 +0100	[thread overview]
Message-ID: <20240622190939.7ff46d62@jic23-huawei> (raw)
In-Reply-To: <8ba6d78d2cd7f58d1d24e3c32211a8ef0d6864fc.camel@gmail.com>

On Tue, 18 Jun 2024 10:34:34 +0200
Nuno Sá <noname.nuno@gmail.com> wrote:

> On Mon, 2024-06-17 at 11:18 -0400, Trevor Gamblin wrote:
> > The current error handling for calls such as devm_clk_get_enabled() in
> > the adi-axi-dac probe() function means that, if a property such as
> > 'clocks' (for example) is not present in the devicetree when booting a
> > kernel with the driver enabled, the resulting error message will be
> > vague, e.g.:
> >   
> > > adi_axi_dac 44a00000.dac: probe with driver adi_axi_dac failed with error -2  
> > 
> > Change the devm_clk_get_enabled(), devm_regmap_init_mmio(), and
> > devm_iio_backend_register() checks to use dev_err_probe() with some
> > context for easier debugging.
> > 
> > After the change:
> >   
> > > adi_axi_dac 44a00000.dac: error -ENOENT: failed to get clock
> > > adi_axi_dac 44a00000.dac: probe with driver adi_axi_dac failed with error -2  
> > 
> > Suggested-by: Nuno Sa <nuno.sa@analog.com>
> > Tested-by: Angelo Dureghello <adureghello@baylibre.com>
> > Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com>
> > ---
> > Added Angelo as Tested-by since he tested the patch on an internal
> > setup.
> > ---  
> 
> Reviewed-by: Nuno Sa <nuno.sa@analog.com>
> 
Applied,
Thanks,


      reply	other threads:[~2024-06-22 18:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-17 15:18 Trevor Gamblin
2024-06-18  8:34 ` Nuno Sá
2024-06-22 18:09   ` 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=20240622190939.7ff46d62@jic23-huawei \
    --to=jic23@kernel.org \
    --cc=Michael.Hennerich@analog.com \
    --cc=adureghello@baylibre.com \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=noname.nuno@gmail.com \
    --cc=nuno.sa@analog.com \
    --cc=tgamblin@baylibre.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

all inboxes | Powered by JetHome®