From: Rudolf Marek <rudolf.marek@sysgo.com>
To: lm-sensors@vger.kernel.org
Subject: Re: [lm-sensors] k8temp, BE-2350 CPU
Date: Tue, 04 Sep 2007 18:53:43 +0000 [thread overview]
Message-ID: <46DDA9B7.8000701@sysgo.com> (raw)
In-Reply-To: <46BAABD3.5000103@assembler.cz>
Hi Bernhard,
+static u32 convert_rev_f(u32 val)
+{
+ return (((((val) >> 16) & 0xff) - 49) * 1000);
+}
+
+static u32 convert_rev_g(u32 val)
+{
+ return (((((val) >> 14) & 0x3ff) - 49) * 250);
+}
Are you sure those are correct? The datasheets suggest that you need first
extract the 0.25 degC from two lowest bits and THEN subtract 49.
Your code does it first. Your method will work only if AMD made a mistake in
documentation. Are you sure?
Thanks,
Rudolf
_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
next prev parent reply other threads:[~2007-09-04 18:53 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-09 5:53 [lm-sensors] k8temp, BE-2350 CPU Rudolf Marek
2007-08-09 6:38 ` Alistair John Strachan
2007-09-03 10:36 ` Rudolf Marek
2007-09-03 21:38 ` Bernhard Seibold
2007-09-04 18:53 ` Rudolf Marek [this message]
2007-09-04 20:55 ` Bernhard Seibold
2007-09-04 21:06 ` Rudolf Marek
2007-09-05 19:01 ` Juergen.Bausa
2007-09-06 7:21 ` Rudolf Marek
2007-10-07 23:53 ` Alistair John Strachan
2007-11-25 12:20 ` Jean Delvare
2007-11-25 14:13 ` Moebius
2007-11-25 20:55 ` Gerold Gruber
2007-11-26 14:16 ` Moebius
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=46DDA9B7.8000701@sysgo.com \
--to=rudolf.marek@sysgo.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.