From: Guenter Roeck <guenter.roeck@ericsson.com>
To: lm-sensors@vger.kernel.org
Subject: Re: [lm-sensors] [PATCH v3] hwmon: (lm90) Add support for
Date: Thu, 07 Oct 2010 14:14:08 +0000 [thread overview]
Message-ID: <20101007141408.GB20342@ericsson.com> (raw)
In-Reply-To: <1286400191-30824-1-git-send-email-guenter.roeck@ericsson.com>
Hi Jean,
On Thu, Oct 07, 2010 at 05:28:03AM -0400, Jean Delvare wrote:
[ ... ]
> This is smart :) I like it a lot. Just not sure why you limited the
> shift to 2 bits, shifting by say 6 bits would guarantee that future
> devices supporting greater values for the conversion rate register
> (up tp 13) would be supported out of the box.
>
I ran test code for all supported values, and found that shift by 2
was sufficient. It can always be changed if someone ever comes up with
a sensor supporting even higher resolution. Call me minimalist ...
> Also note that you may want to use DIV_ROUND_CLOSEST() to make the code
> slightly easier to read.
>
Yes, that would be cleaner for the final interval calculation.
Want me to change it and send out another revision ?
> But anyway, your code works just fine for the devices currently
> supported, so I can apply the patch as is. I tested the resulting
> driver on my ADM1032 evaluation board and everything went fine. Thanks
> for your contribution!
>
Thanks a lot for reviewing it!
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:[~2010-10-07 14:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-06 21:23 [lm-sensors] [PATCH v3] hwmon: (lm90) Add support for Guenter Roeck
2010-10-07 9:28 ` Jean Delvare
2010-10-07 14:14 ` Guenter Roeck [this message]
2010-10-07 14:25 ` Jean Delvare
2010-10-07 14:42 ` Guenter Roeck
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=20101007141408.GB20342@ericsson.com \
--to=guenter.roeck@ericsson.com \
--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.