From: Sven Anders <sven@anduras.de>
To: "Tantilov, Emil S" <emil.s.tantilov@intel.com>
Cc: Stefan Assmann <sassmann@redhat.com>,
netdev <netdev@vger.kernel.org>, Andi Kleen <andi@firstfloor.org>
Subject: Re: [PATCH] e1000e: Fix usage under kexec
Date: Fri, 04 Dec 2009 10:10:35 +0100 [thread overview]
Message-ID: <4B18D20B.5070204@anduras.de> (raw)
In-Reply-To: <EA929A9653AAE14F841771FB1DE5A1365FA68EE924@rrsmsx501.amr.corp.intel.com>
[-- Attachment #1.1: Type: text/plain, Size: 2951 bytes --]
Tantilov, Emil S schrieb:
> Stefan Assmann wrote:
>> On 09.11.2009 21:25, Sven Anders wrote:
>>>
>>> We're experiencing the following problem:
>>>
>>> We start a minimal linux system, prepare the system and start the
>>> final system via kexec. On two different systems (one with a 82573
>>> and one with a 82574), the driver cannot initialize the network
>>> hardware, because the PHY is not recognized.
>>>
>>> We get the following error:
>>> e1000e: probe of 0000:02:00.0 failed with error -2
>> Hi Sven,
>>
>> have a look at the following thread, it seems very similar.
>> http://kerneltrap.org/mailarchive/linux-netdev/2009/3/7/5114394
>
> There is already similar code in e1000e:
> http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.git;a=commit;h=4f9de721ab73a5271a79b126f7b5140b01a05c99
Yes it sound similar. We will test this when we upgrade the kernel for
our next OS release...
> Sven, could you provide some additional information about your system and
> kernel/driver verison you used when the issue occurred?
> I have not been able to reproduce it on my setup.
Currently we are using the Linux kernel 2.6.29.6 for our appliances.
Which is/was the first officially released kernel with this patch?
Andi Kleen wrote:
>> We fixed it by adding a
>> >
>> > + /* Reset PHY before initializing it. Allows re-init after kexec. */
>> > + if (!e1000_check_reset_block(hw))
>> > + e1000_phy_hw_reset(hw);
>
> The problem of resetting PHYs in the driver init path is that it tends
> to lose link-state, and if the link takes some time to re-negotiate
> you can significantly slow down the "total time to network access"
> at boot.
>
> Perhaps you could only reset when the message above would trigger
> and try again?
>
> -Andi
Ok, know we are doing the following. But maybe it isn't needed with the
new kernel any more...
@@ -109,6 +109,13 @@ static s32 e1000_init_phy_params_82571(s
/* This can only be done after all function pointers are setup. */
ret_val = e1000_get_phy_id_82571(hw);
+ /* Could not determine PHY id. This can happen when booting
+ via kexec. So reset and try again. */
+ if (ret_val == -E1000_ERR_PHY) {
+ e1000_phy_hw_reset(hw);
+ ret_val = e1000_get_phy_id_82571(hw);
+ }
+
/* Verify phy id */
switch (hw->mac.type) {
case e1000_82571:
Regards
Sven Anders
--
Sven Anders <anders@anduras.de> () Ascii Ribbon Campaign
/\ Support plain text e-mail
ANDURAS service solutions AG
Innstrasse 71 - 94036 Passau - Germany
Web: www.anduras.de - Tel: +49 (0)851-4 90 50-0 - Fax: +49 (0)851-4 90 50-55
Those who would give up essential Liberty, to purchase a little
temporary Safety, deserve neither Liberty nor Safety.
- Benjamin Franklin
[-- Attachment #1.2: sven.vcf --]
[-- Type: text/x-vcard, Size: 307 bytes --]
begin:vcard
fn:Sven Anders
n:Anders;Sven
adr;quoted-printable:;;Weidestra=C3=9Fe 19;Hannover;Niedersachsen;30453;Deutschland
email;internet:sven@anduras.de
tel;home:+49 (0)511 / 2123090
tel;cell:+49 (0)170 / 8091180
x-mozilla-html:FALSE
url:http://staff.anduras.de/anders
version:2.1
end:vcard
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 260 bytes --]
prev parent reply other threads:[~2009-12-04 9:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-09 20:25 [PATCH] e1000e: Fix usage under kexec Sven Anders
2009-11-10 9:35 ` Andi Kleen
2009-11-17 9:21 ` Stefan Assmann
2009-11-17 21:28 ` Tantilov, Emil S
2009-11-17 21:34 ` Tantilov, Emil S
2009-12-04 9:10 ` Sven Anders [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=4B18D20B.5070204@anduras.de \
--to=sven@anduras.de \
--cc=andi@firstfloor.org \
--cc=emil.s.tantilov@intel.com \
--cc=netdev@vger.kernel.org \
--cc=sassmann@redhat.com \
/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).