From: Guenter Roeck <linux@roeck-us.net>
To: lm-sensors@vger.kernel.org
Subject: Re: [lm-sensors] [PATCH 04/15] hwmon: (it87) Introduce feature flag to reflect internal in7 sensor
Date: Tue, 31 Mar 2015 16:22:37 +0000 [thread overview]
Message-ID: <551AC9CD.1010100@roeck-us.net> (raw)
In-Reply-To: <1427697235-23566-5-git-send-email-linux@roeck-us.net>
On 03/31/2015 09:19 AM, Guenter Roeck wrote:
> On 03/31/2015 08:44 AM, Jean Delvare wrote:
>> On Sun, 29 Mar 2015 23:33:44 -0700, Guenter Roeck wrote:
>>> @@ -379,6 +381,7 @@ static const struct it87_devices it87_devices[] = {
>>> #define has_fan16_config(data) ((data)->features & FEAT_FAN16_CONFIG)
>>> #define has_five_fans(data) ((data)->features & FEAT_FIVE_FANS)
>>> #define has_vid(data) ((data)->features & FEAT_VID)
>>> +#define has_in7_internal(data) ((data)->features & FEAT_IN7_INTERNAL)
>>
>> I just noticed that you never actually call this macro. Where you could
>> do so, you open-coded it instead:
>>
>>> @@ -1862,6 +1865,11 @@ static int __init it87_find(unsigned short *address,
>>>
>>> /* in8 (Vbat) is always internal */
>>> sio_data->internal = (1 << 2);
>>> +
>>> + /* in7 (VSB or VCCH5V) is always internal on some chips */
>>> + if (it87_devices[sio_data->type].features & FEAT_IN7_INTERNAL)
>>> + sio_data->internal |= (1 << 1);
>>> +
>>
>
> Good point. The idea was to use the macros on data, but of course they work on
> sio_data as well. I'll rework the patches to do that.
>
Actually, if you are ok with it, I would prefer do that in a separate
(additional) patch. I can do the same for has_vid(), so I'll make those
changes in a single patch.
Thanks,
Guenter
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
next prev parent reply other threads:[~2015-03-31 16:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-30 6:33 [lm-sensors] [PATCH 04/15] hwmon: (it87) Introduce feature flag to reflect internal in7 sensor Guenter Roeck
2015-03-30 20:05 ` Jean Delvare
2015-03-30 21:32 ` Guenter Roeck
2015-03-31 15:44 ` Jean Delvare
2015-03-31 16:19 ` Guenter Roeck
2015-03-31 16:22 ` Guenter Roeck [this message]
2015-03-31 21:09 ` Jean Delvare
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=551AC9CD.1010100@roeck-us.net \
--to=linux@roeck-us.net \
--cc=lm-sensors@vger.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 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.