All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Biju Das <biju.das.jz@bp.renesas.com>
Cc: "Jonathan Cameron" <jic23@kernel.org>,
	"Lars-Peter Clausen" <lars@metafoo.de>,
	"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>,
	"Jean Delvare" <jdelvare@suse.de>,
	"Vladimir Oltean" <olteanv@gmail.com>,
	linux-iio@vger.kernel.org,
	"Geert Uytterhoeven" <geert+renesas@glider.be>,
	linux-renesas-soc@vger.kernel.org
Subject: Re: [PATCH] iio: dac: ti-dac5571: Use i2c_get_match_data()
Date: Tue, 15 Aug 2023 10:18:53 +0300	[thread overview]
Message-ID: <ZNsm3efpkYlL4Gki@smile.fi.intel.com> (raw)
In-Reply-To: <20230812090418.75020-1-biju.das.jz@bp.renesas.com>

On Sat, Aug 12, 2023 at 10:04:18AM +0100, Biju Das wrote:
> Replace device_get_match_data() and id lookup for retrieving match data
> by i2c_get_match_data() by converting enum->pointer for data in the
> match table.

...

> +	{.compatible = "ti,dac5571", .data = &dac5571_spec[single_8bit] },
> +	{.compatible = "ti,dac6571", .data = &dac5571_spec[single_10bit] },
> +	{.compatible = "ti,dac7571", .data = &dac5571_spec[single_12bit] },
> +	{.compatible = "ti,dac5574", .data = &dac5571_spec[quad_8bit] },
> +	{.compatible = "ti,dac6574", .data = &dac5571_spec[quad_10bit] },
> +	{.compatible = "ti,dac7574", .data = &dac5571_spec[quad_12bit] },
> +	{.compatible = "ti,dac5573", .data = &dac5571_spec[quad_8bit] },
> +	{.compatible = "ti,dac6573", .data = &dac5571_spec[quad_10bit] },
> +	{.compatible = "ti,dac7573", .data = &dac5571_spec[quad_12bit] },
> +	{.compatible = "ti,dac121c081", .data = &dac5571_spec[single_12bit] },

I would reorder them a bit.

	{.compatible = "ti,dac121c081", .data = &dac5571_spec[single_12bit] },
	{.compatible = "ti,dac5571", .data = &dac5571_spec[single_8bit] },
	{.compatible = "ti,dac6571", .data = &dac5571_spec[single_10bit] },
	{.compatible = "ti,dac7571", .data = &dac5571_spec[single_12bit] },
	{.compatible = "ti,dac5573", .data = &dac5571_spec[quad_8bit] },
	{.compatible = "ti,dac6573", .data = &dac5571_spec[quad_10bit] },
	{.compatible = "ti,dac7573", .data = &dac5571_spec[quad_12bit] },
	{.compatible = "ti,dac5574", .data = &dac5571_spec[quad_8bit] },
	{.compatible = "ti,dac6574", .data = &dac5571_spec[quad_10bit] },
	{.compatible = "ti,dac7574", .data = &dac5571_spec[quad_12bit] },

Same for I2C ID table.

-- 
With Best Regards,
Andy Shevchenko



  reply	other threads:[~2023-08-15  7:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-12  9:04 [PATCH] iio: dac: ti-dac5571: Use i2c_get_match_data() Biju Das
2023-08-15  7:18 ` Andy Shevchenko [this message]
2023-08-15  7:29   ` Geert Uytterhoeven
2023-08-15 16:50     ` Andy Shevchenko
2023-08-16  8:16       ` Geert Uytterhoeven
2023-08-17 10:22         ` Andy Shevchenko
2023-08-17 11:51           ` Geert Uytterhoeven

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=ZNsm3efpkYlL4Gki@smile.fi.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=biju.das.jz@bp.renesas.com \
    --cc=geert+renesas@glider.be \
    --cc=jdelvare@suse.de \
    --cc=jic23@kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=u.kleine-koenig@pengutronix.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.