On Wed 23/04, Stefan Sperling wrote:
> On Wed, Apr 23, 2014 at 03:16:52PM +0200, Alessandro DE LAURENZIS wrote:
> > Your patch is still applicable to 5.4 stable (with only minor refinements),
> > but unfortunately it doesn't change anything for this BGE chip...
>
> Thanks, this motivated me to poke a bit further at it.
>
> Just to make sure: Did you try to enable wol with 'ifconfig bge0 wol'?
>
> > Do you think a PCMCIA Eth card with one of the mentioned chips could be
> > a reasonable solution? I mean, my understanding is that the BIOS plays a
> > role in WoL stuff, so I'm wondering if a PCMCIA will stay powered on
> > even when the system is switched off, like the Ethernet port is supposed
> > to be...
>
> I doubt PCMCIA would work. Cards going into PCI slots should work.
> Some have a small power cable coming off the NIC that can be plugged
> into the mainboard. Newer cards use the PCI bus directly for this
> via the PME# signal.
>
> Anyway, I've revised my bge diff a bit. It first checks if ASF is disabled
> and allows WOL if it is disabled. We really don't want to trust ASF.
> http://www.intel.com/content/dam/doc/white-paper/asf-standards-based-systems-management-paper.pdf
> It's a component of AMT. AMT has pretty bad security:
> http://web.it.kth.se/~maguire/DEGREE-PROJECT-REPORTS/100402-Vassilios_Ververis-with-cover.pdf
>
> Not sure if we can trust the EEPROM not to tell lies about ASF
> being disabled. But that can be discussed with others once I know
> whether this diff makes wol work for you. I hope I got the power-down
> sequnce right for all cards, it's based on what Linux does but
> I don't have any hardware to test this.
>
> Diff is against -current from a week ago or so. Might work with 5.5.
>
In order to adapt your code to 5.4-Rel, I did the following
modification:
From:
+ /* Configure 10Mbps, the chip draws too much power in D3cold. */
+ if (!(sc->bge_flags & BGE_FIBER_TBI) &&
+ !(sc->bge_flags & BGE_FIBER_MII)) {
+ sc->bge_ifmedia.ifm_media = IFM_ETHER|IFM_10_T;
+ if_flags = ifp->if_flags;
+ ifp->if_flags |= IFF_UP;
+ bge_ifmedia_upd(ifp);
+ ifp->if_flags = if_flags;
+ }
to:
+ /* Configure 10Mbps, the chip draws too much power in D3cold. */
+ if !(sc->bge_flags) {
+ sc->bge_ifmedia.ifm_media = IFM_ETHER|IFM_10_T;
+ if_flags = ifp->if_flags;
+ ifp->if_flags |= IFF_UP;
+ bge_ifmedia_upd(ifp);
+ ifp->if_flags = if_flags;
+ }
(because BGE_FIBER_TBI and BGE_FIBER_MII are undefined); even if
probably not semantically correct, that gives me a clean compile; in any
case, I do not think this part is related to WoL, right?
Now:
# ifconfig bge0 wol
ifconfig: SIOCSIFXFLAGS: Not supported
and the interface is still powered off after a "halt -p" command.
How can I help in continuing the debug?
Thanks a lot for your efforts.
--
Alessandro DE LAURENZIS
[mailto:[email protected]]
LinkedIn: http://it.linkedin.com/in/delaurenzis