netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ingo Oeser <netdev@axxeo.de>
To: "Michael Chan" <mchan@broadcom.com>
Cc: "Lucas Nussbaum" <lucas.nussbaum@imag.fr>,
	"netdev" <netdev@vger.kernel.org>
Subject: Re: [BUG] tg3 cannot do PXE (loses MAC address) after soft reboot
Date: Fri, 14 Sep 2007 10:14:20 +0200	[thread overview]
Message-ID: <200709141014.20635.netdev@axxeo.de> (raw)
In-Reply-To: <1189716472.9540.106.camel@dell>

Michael Chan schrieb:
> On Thu, 2007-09-13 at 21:28 +0200, Lucas Nussbaum wrote:
> > Erm, Wouldn't it be possible to print a warning when the driver loads,
> > saying that the firmware is outdated ?
> 
> It's possible, but would require the driver to parse the version string.
> The driver currently reports the version string for information and for
> the human to parse it.

Yes, but most humans don't know all valid firmware versions of their 
components.

Is it enough to parse the first number in the firmware via simple_strtoul()?

Then we could do this (pseudo-kernel-code :-)):


firmare_version = simple_strtoul(version_string, NULL, 0);

if (firmware_version < oldest_supported) {
	printk(KERN_WARNING "Please upgrade the firmware (you have %s, we need at least %d)\n", 
		version_string, oldest_supported);
} else if (firmware_version > newest_supported) {
	printk(KERN_INFO "Firmware version %s (latest supported: %d). You might need a newer driver.\n", 
		version_string, oldest_supported);
} else if (firmware_version != newest_supported) {
	dprintk("Firmware version %s (latest supported: %d). You might consider a firmware upgrade.\n", 
		version_string, oldest_supported);
}

Maybe that mechanism should be global somewhere? Having this kind of information available
would help system maintenance in heterogenous hardware environments.

Best regards

Ingo Oeser

  reply	other threads:[~2007-09-14  8:48 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-13  8:39 [BUG] tg3 cannot do PXE (loses MAC address) after soft reboot Lucas Nussbaum
2007-09-13 15:15 ` Michael Chan
2007-09-13 15:41   ` Lucas Nussbaum
2007-09-13 18:05     ` Michael Chan
2007-09-13 19:28       ` Lucas Nussbaum
2007-09-13 20:47         ` Michael Chan
2007-09-14  8:14           ` Ingo Oeser [this message]
2007-09-14 18:52             ` Michael Chan
2007-09-17 11:29               ` Ingo Oeser

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=200709141014.20635.netdev@axxeo.de \
    --to=netdev@axxeo.de \
    --cc=lucas.nussbaum@imag.fr \
    --cc=mchan@broadcom.com \
    --cc=netdev@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).