All of lore.kernel.org
 help / color / mirror / Atom feed
From: Harald Judt <h.judt@gmx.at>
To: lm-sensors@vger.kernel.org
Subject: Re: [lm-sensors] NCT6776 global registers 0x1c=0 and 0x24=0x5c
Date: Fri, 06 Jan 2012 11:36:15 +0000	[thread overview]
Message-ID: <4F06DCAF.8010105@gmx.at> (raw)
In-Reply-To: <20110410160433.GA22075@localhost>

Am 05.01.2012 15:45, schrieb Jean Delvare:
> On Thu, 5 Jan 2012 15:39:01 +0100, Jean Delvare wrote:
>> On Wed, 21 Dec 2011 23:43:47 +0100, Harald Judt wrote:
>>> Am 21.12.2011 21:55, schrieb Ira W. Snyder:
>>>> I wonder if you could set these register values only on this specific
>>>> motherboard by checking the DMI table to determine the motherboard
>>>> vendor and model number.
>>>
>>> This is what I currently do using dmidecode in /etc/init.d/lm_sensors,
>>> because I too fear to forget about this and accidently wreck a new
>>> mainboard I'm going to buy in the future:
>>>
>>> # We need to do some initialization before loading the module,
>>> # otherwise only 2 of the 5 fans will be shown
>>> init_module_w83627ehf() {
>>>       modprobe -q -r w83627ehf
>>>       # make sure to do this only for the right mainboard
>>>       if /usr/sbin/dmidecode | grep -i 'Base Board Information' -A2 -B1 |
>>> grep -q 'P67 Extreme4' \
>>>           &&  /usr/sbin/dmidecode | grep -i 'BIOS Information' -A3 | grep
>>> -q 'Version: L1.61'&&  \
>>
>> dmidecode -s is your friend ;) Namely -s baseboard-product-name and -s
>> bios-version.

To be honest, I didn't care enough to optimize a one-time call at 
startup, even if it looks terribly ugly.

> Oh, and I almost forgot: the same info is typically available
> from /sys/class/dmi/id/* for even cheaper.

Thanks, that's really helpful! It helps me to get rid of the dmidecode 
dependence and I've learned something new ;-)

Regards,
Harald

-- 
`Experience is the best teacher.'

_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

      parent reply	other threads:[~2012-01-06 11:36 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-10 16:04 [lm-sensors] NCT6776 global registers 0x1c=0 and 0x24=0x5c on Mike Campin
2011-04-12 17:02 ` [lm-sensors] NCT6776 global registers 0x1c=0 and 0x24=0x5c Ian Dobson
2011-04-12 17:09 ` Jean Delvare
2011-12-21 14:50 ` [lm-sensors] NCT6776 global registers 0x1c=0 and 0x24=0x5c onASRock Harald Judt
2011-12-21 17:01 ` [lm-sensors] NCT6776 global registers 0x1c=0 and 0x24=0x5c Guenter Roeck
2011-12-21 17:55 ` Ian Dobson
2011-12-21 20:55 ` Ira W. Snyder
2011-12-21 22:26 ` Guenter Roeck
2011-12-21 22:43 ` Harald Judt
2012-01-05 14:39 ` Jean Delvare
2012-01-05 14:45 ` Jean Delvare
2012-01-06 11:36 ` Harald Judt [this message]

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=4F06DCAF.8010105@gmx.at \
    --to=h.judt@gmx.at \
    --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.