All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alistair John Strachan <alistair@devzero.co.uk>
To: lm-sensors@vger.kernel.org
Subject: Re: [lm-sensors] [PATCH] hwmon: (abituguru3) Support multiple DMI
Date: Sun, 06 Sep 2009 13:55:08 +0000	[thread overview]
Message-ID: <200909061455.08450.alistair@devzero.co.uk> (raw)
In-Reply-To: <1252170780-4141-1-git-send-email-alistair@devzero.co.uk>

Hi Jean,

On Sunday 06 September 2009 13:03:51 Jean Delvare wrote:
> On Sun,  6 Sep 2009 10:15:53 +0100, Alistair John Strachan wrote:
> >  #ifdef CONFIG_DMI
> > -	if (!abituguru3_motherboards[i].dmi_name) {
> > +	if (!abituguru3_motherboards[i].dmi_name[0]) {
> >  		printk(KERN_WARNING ABIT_UGURU3_NAME ": this motherboard was "
> >  			"not detected using DMI. Please send the output of "
> >  			"\"dmidecode\" to the abituguru3 maintainer "
> 
> This test is no longer as perfect as it used to be. Now that you admit
> that each ID can correspond to more than one board model, it is
> possible that the board was _not_ detected using DMI but this message
> will not show (because another board with this ID is already known.)
> While this is not a blocker, I still think it would be worth improving.

You're right. I think the message should go in abituguru3_init() after 
abituguru3_detect() (legacy probing) succeeds. Because..

> Maybe I am missing something obvious, but why isn't this message
> printed in abituguru3_dmi_detect() directly? This would be more
> efficient and more elegant too IMHO.

I don't think it would be correct though. I assume we don't want to print 
anything out if somebody loads the driver on truly unsupported hardware. In 
this case abituguru3_dmi_detect() will fail (rightfully) and then the legacy 
probe method will also fail (hopefully) and modprobe will fail. Nothing would 
be printed.

There's the unfortunate case where DMI match can fail (due to incomplete 
cataloguing of strings) and the legacy probe can also fail (due to it being 
rubbish) and this can also result in no messages being printed for supported 
hardware. However, I don't think there's much we can do about that.

-- 
Cheers,
Alistair.

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

  parent reply	other threads:[~2009-09-06 13:55 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-05 17:13 [lm-sensors] [PATCH] hwmon: (abituguru3) Support multiple DMI Alistair John Strachan
2009-09-06  7:23 ` Hans de Goede
2009-09-06  9:15 ` Alistair John Strachan
2009-09-06  9:37 ` Hans de Goede
2009-09-06 12:03 ` Jean Delvare
2009-09-06 13:55 ` Alistair John Strachan [this message]
2009-09-06 14:06 ` Jean Delvare
2009-09-06 14:15 ` Rune Svendsen
2009-09-06 14:30 ` Alistair John Strachan
2009-09-06 14:41 ` Alistair John Strachan
2009-09-06 15:05 ` Rune Svendsen
2009-09-06 16:23 ` 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=200909061455.08450.alistair@devzero.co.uk \
    --to=alistair@devzero.co.uk \
    --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.