From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Biju Das <biju.das.jz@bp.renesas.com>
Cc: Eric Tremblay <etremblay@distech-controls.com>,
Jean Delvare <jdelvare@suse.com>,
Guenter Roeck <linux@roeck-us.net>,
linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org,
Biju Das <biju.das.au@gmail.com>
Subject: Re: [PATCH v5 1/2] hwmon: tmp513: Add max_channels variable to struct tmp51x_data
Date: Wed, 6 Sep 2023 22:56:44 +0300 [thread overview]
Message-ID: <ZPjZfK7+4jW3AFEB@smile.fi.intel.com> (raw)
In-Reply-To: <20230906180837.284743-2-biju.das.jz@bp.renesas.com>
On Wed, Sep 06, 2023 at 07:08:36PM +0100, Biju Das wrote:
> The tmp512 chip has 3 channels whereas tmp513 has 4 channels. Avoid
> using tmp51x_ids for this HW difference by replacing OF/ID table
> data with maximum channels supported by the device.
>
> Replace id->max_channels variable from struct tmp51x_data and drop the
> macros TMP51{2,3}_TEMP_CONFIG_DEFAULT as it can be derived from the macro
> TMP51X_TEMP_CONFIG_DEFAULT and update the logic in tmp51x_is_visible(),
> tmp51x_read_properties() and tmp51x_init() using max_channels.
>
> While at it, drop enum tmp51x_ids as there is no user and remove
> trailing comma in the terminator entry for OF table.
...
> +#define TMP51X_TEMP_CONFIG_CONV_RATE FIELD_PREP(GENMASK(9, 7), 0x7)
I also commented on this one. Any explanation why you didn't accept recommended
variant?
...
Otherwise looks good to me.
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2023-09-06 19:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-06 18:08 [PATCH v5 0/2] Enhancements for tmp513 driver Biju Das
2023-09-06 18:08 ` [PATCH v5 1/2] hwmon: tmp513: Add max_channels variable to struct tmp51x_data Biju Das
2023-09-06 19:56 ` Andy Shevchenko [this message]
2023-09-07 6:46 ` Biju Das
2023-09-06 18:08 ` [PATCH v5 2/2] hwmon: tmp513: Simplify tmp51x_read_properties() Biju Das
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=ZPjZfK7+4jW3AFEB@smile.fi.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=biju.das.au@gmail.com \
--cc=biju.das.jz@bp.renesas.com \
--cc=etremblay@distech-controls.com \
--cc=jdelvare@suse.com \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.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