From: Andy Shevchenko <andriy.shevchenko@intel.com>
To: "Nuno Sá" <noname.nuno@gmail.com>
Cc: "Alexis Czezar Torreno" <alexisczezar.torreno@analog.com>,
"Lars-Peter Clausen" <lars@metafoo.de>,
"Michael Hennerich" <Michael.Hennerich@analog.com>,
"Jonathan Cameron" <jic23@kernel.org>,
"David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"Uwe Kleine-König" <ukleinek@kernel.org>,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-pwm@vger.kernel.org
Subject: Re: [PATCH 2/3] iio: dac: ad5706r: Add support for AD5706R DAC
Date: Fri, 20 Feb 2026 18:56:53 +0200 [thread overview]
Message-ID: <aZiSVSvCOS4MvcGt@smile.fi.intel.com> (raw)
In-Reply-To: <a6a2fc3ebb45fa4d7b379d552196d56eb13fa8d3.camel@gmail.com>
On Fri, Feb 20, 2026 at 03:02:37PM +0000, Nuno Sá wrote:
> On Fri, 2026-02-20 at 13:00 +0200, Andy Shevchenko wrote:
> > On Fri, Feb 20, 2026 at 10:48:59AM +0000, Nuno Sá wrote:
> > > On Fri, 2026-02-20 at 16:02 +0800, Alexis Czezar Torreno wrote:
...
> > > > +static void ad5706r_debugs_init(struct iio_dev *indio_dev)
> > > > +{
> > > > + struct dentry *d = iio_get_debugfs_dentry(indio_dev);
> > >
> > > It should have:
> > >
> > > if (!IS_ENABLED(CONFIG_DEBUGFS))
> > > return
> >
> > But why? The debugfs is a stub when disabled, nobody should do that
> > in the cases when the main purpose is not the debugfs code.
>
> Because the compiler can then optimize away all of the above code...
How is it different to the code elimination part that is inside in each of
the below calls?
> > > > + debugfs_create_file_unsafe("streaming_addr", 0600, d,
> > > > + indio_dev, &ad5706r_streaming_addr_fops);
> > > > + debugfs_create_file_unsafe("streaming_len", 0600, d,
> > > > + indio_dev, &ad5706r_streaming_len_fops);
> > > > + debugfs_create_file_unsafe("streaming_data", 0600, d,
> > > > + indio_dev, &ad5706r_streaming_data_fops);
> > > > + debugfs_create_file_unsafe("streaming_reg_access", 0600, d,
> > > > + indio_dev, &ad5706r_streaming_reg_access_fops);
> > > > + debugfs_create_file_unsafe("spi_speed_hz_write", 0600, d,
> > > > + indio_dev, &ad5706r_spi_speed_write_fops);
> > > > + debugfs_create_file_unsafe("spi_speed_hz_read", 0600, d,
> > > > + indio_dev, &ad5706r_spi_speed_read_fops);
> > > > +}
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2026-02-20 16:56 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-20 8:02 [PATCH 0/3] Add support for AD5706R DAC Alexis Czezar Torreno
2026-02-20 8:02 ` [PATCH 1/3] dt-bindings: iio: dac: Add binding for AD5706R Alexis Czezar Torreno
2026-02-21 10:45 ` Krzysztof Kozlowski
2026-02-21 16:05 ` David Lechner
2026-02-20 8:02 ` [PATCH 2/3] iio: dac: ad5706r: Add support for AD5706R DAC Alexis Czezar Torreno
2026-02-20 10:48 ` Nuno Sá
2026-02-20 11:00 ` Andy Shevchenko
2026-02-20 15:02 ` Nuno Sá
2026-02-20 16:56 ` Andy Shevchenko [this message]
2026-02-23 10:10 ` Nuno Sá
2026-02-20 10:51 ` Uwe Kleine-König
2026-02-21 16:19 ` David Lechner
2026-02-22 18:57 ` Jonathan Cameron
2026-02-23 4:49 ` Torreno, Alexis Czezar
2026-02-23 8:47 ` Andy Shevchenko
2026-02-20 8:02 ` [PATCH 3/3] MAINTAINERS: Add entry for AD5706R DAC driver Alexis Czezar Torreno
2026-02-20 10:18 ` Nuno Sá
2026-02-20 10:31 ` [PATCH 0/3] Add support for AD5706R DAC Andy Shevchenko
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=aZiSVSvCOS4MvcGt@smile.fi.intel.com \
--to=andriy.shevchenko@intel.com \
--cc=Michael.Hennerich@analog.com \
--cc=alexisczezar.torreno@analog.com \
--cc=andy@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pwm@vger.kernel.org \
--cc=noname.nuno@gmail.com \
--cc=nuno.sa@analog.com \
--cc=robh@kernel.org \
--cc=ukleinek@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