linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Ardelean, Alexandru" <alexandru.Ardelean@analog.com>
To: "Popa, Stefan Serban" <StefanSerban.Popa@analog.com>,
	"lkcamp@lists.libreplanetbr.org" <lkcamp@lists.libreplanetbr.org>,
	"linux-iio@vger.kernel.org" <linux-iio@vger.kernel.org>,
	"djunho@gmail.com" <djunho@gmail.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"pmeerw@pmeerw.net" <pmeerw@pmeerw.net>,
	"knaack.h@gmx.de" <knaack.h@gmx.de>,
	"Hennerich, Michael" <Michael.Hennerich@analog.com>,
	"jic23@kernel.org" <jic23@kernel.org>,
	"lars@metafoo.de" <lars@metafoo.de>
Subject: Re: [PATCH v2 1/4] iio: adc: ad7923: Remove the unused defines
Date: Wed, 11 Dec 2019 07:26:07 +0000	[thread overview]
Message-ID: <17193a42835f41b4352855b1cbd1cb5cf74a6d66.camel@analog.com> (raw)
In-Reply-To: <20191210150811.3429-2-djunho@gmail.com>

On Tue, 2019-12-10 at 12:08 -0300, Daniel Junho wrote:
> [External]
> 
> Removes the unused define AD7923_CHANNEL_x from the code.
> 
> Signed-off-by: Daniel Junho <djunho@gmail.com>
> ---
>  drivers/iio/adc/ad7923.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/drivers/iio/adc/ad7923.c b/drivers/iio/adc/ad7923.c
> index 3212eb4c0f25..969c06b7d2b7 100644
> --- a/drivers/iio/adc/ad7923.c
> +++ b/drivers/iio/adc/ad7923.c
> @@ -29,10 +29,6 @@
>  #define AD7923_PM_MODE_AS	(1)		/* auto shutdown */
>  #define AD7923_PM_MODE_FS	(2)		/* full shutdown */
>  #define AD7923_PM_MODE_OPS	(3)		/* normal operation */
> -#define AD7923_CHANNEL_0	(0)		/* analog input 0 */
> -#define AD7923_CHANNEL_1	(1)		/* analog input 1 */
> -#define AD7923_CHANNEL_2	(2)		/* analog input 2 */
> -#define AD7923_CHANNEL_3	(3)		/* analog input 3 */

The fact that is not used, is not a problem really.
This can serve as a "shortcut" for the datasheet.

We can leave this as-is [1], or remove it as you do [2], or an alternative
would be [3]:
#define AD7923_CHANNEL(x)      (x)       /* analog channel input */

I don't mind either of these 3 versions ([1], [2] or [3]).

I'll leave it to Jonathan's preference.

>  #define AD7923_SEQUENCE_OFF	(0)		/* no sequence fonction
> */
>  #define AD7923_SEQUENCE_PROTECT	(2)		/* no interrupt
> write cycle */
>  #define AD7923_SEQUENCE_ON	(3)		/* continuous sequence */

  reply	other threads:[~2019-12-11  7:26 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-10 15:08 [PATCH v2 0/4] Add support for the ad7908/ad7918/ad7928 Daniel Junho
2019-12-10 15:08 ` [PATCH v2 1/4] iio: adc: ad7923: Remove the unused defines Daniel Junho
2019-12-11  7:26   ` Ardelean, Alexandru [this message]
2019-12-15 15:47     ` Jonathan Cameron
2019-12-10 15:08 ` [PATCH v2 2/4] iio: adc: ad7923: Fix checkpatch warning Daniel Junho
2019-12-11  7:26   ` Ardelean, Alexandru
2019-12-10 15:08 ` [PATCH v2 3/4] iio: adc: ad7923: Add of_device_id table Daniel Junho
2019-12-11  7:27   ` Ardelean, Alexandru
2019-12-10 15:08 ` [PATCH v2 4/4] iio: adc: ad7923: Add support for the ad7908/ad7918/ad7928 Daniel Junho
2019-12-11  7:46   ` Ardelean, Alexandru
2019-12-15 15:43     ` Jonathan Cameron
2019-12-16 11:59       ` Daniel Junho

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=17193a42835f41b4352855b1cbd1cb5cf74a6d66.camel@analog.com \
    --to=alexandru.ardelean@analog.com \
    --cc=Michael.Hennerich@analog.com \
    --cc=StefanSerban.Popa@analog.com \
    --cc=djunho@gmail.com \
    --cc=jic23@kernel.org \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkcamp@lists.libreplanetbr.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 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).