LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Qualcomm Atheros AR8171 Wake on LAN issues (https://www.linuxquestions.org/questions/linux-networking-3/qualcomm-atheros-ar8171-wake-on-lan-issues-4175491464/)

dolphs 01-16-2014 03:09 AM

Qualcomm Atheros AR8171 Wake on LAN issues
 
I owe a ASRock H81M-ITX mainboard which has an Qualcomm Atheros AR8171 Ethernet on board:


02:00.0 Ethernet controller: Atheros Communications Inc. Device 10a1 (rev 10)
Subsystem: ASRock Incorporation Device 10a1
Kernel driver in use: alx


I just compiled kernel 3.12.8 and from " ethtool eth0 " it seem wol functionality exists, which is also set ENABLED in BIOS ( PCIE Device Power ON ). However executing " ethtool -s eth0 wol g " gives the following error:

" Cannot get current wake-on-lan settings: Operation not supported
not setting wol "


Settings for eth0:
Supported ports: [ TP ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Supported pause frame use: Symmetric Receive-only
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Advertised pause frame use: Symmetric
Advertised auto-negotiation: Yes
Speed: 100Mb/s
Duplex: Full
Port: Twisted Pair
PHYAD: 0
Transceiver: internal
Auto-negotiation: on
MDI-X: Unknown
Current message level: 0x000060e4 (24804)
link ifup rx_err tx_err hw wol


From this I seem to be missing:

<snip snip>
Port: MII
<snip snip>
Supports Wake-on: pumbg
Wake-on: g


Also inteteresting why it loads twisted pair port instead of "mii" module. Would be great if one can give me a hand with this so it supports "wake on lan" properly

dolphs 01-20-2014 10:48 AM

Hi, a quick test reveals the hardware is capable of WOL, no matter of what OS is used.

This has been tested once " PCI Device Power On " got enabled in BIOS. Once verified the power button got briefly pressed, so the system went into S5-mode.
At this stage the set was ready for WOL and thus after executing " etherwake MAC:ADDRESS:MAC:ADDRESS:MAC:ADDRESS " from another machine the server woke up!

Therefore seems hardware is working fine, just the alx-kernel driver need to be polished as shown above so it will support "wol-g¨ in /etc/network/interfaces ( debian/wheezy )

cybertaf 03-23-2014 06:30 AM

Hi dolphs,

I have exactly the same problem with Qualcomm Atheros AR8171 Ethernet.
Did you solve it ?

Cheers.

buzzone 04-02-2014 07:39 PM

Hey,

same here!

Any progress on this?

I found out WoL was removed from the alx driver. I'm not allowed to post the URL here. But if you look on the github kernel mirror it's commit bc2bebe8de8ed4ba6482c9cc370b0dd72ffe8cd2.

It is stated that "the system will immediately resume after suspending". This wouldn't be any problem for me.
I'm on Sabayon/Gentoo and will try to build a custom kernel reverting that commit.

Cheers...

---------- Post added 04-02-14 at 07:39 PM ----------

https://github.com/torvalds/linux/co...0b0dd72ffe8cd2

buzzone 04-07-2014 08:15 AM

The corresponding ticket on the Linux bug tracker to this issue:
https://bugzilla.kernel.org/show_bug.cgi?id=61651

cybertaf 04-20-2014 12:56 PM

Hi,

I solved the problem by installing 3.10.37 kernel (downloaded here).
WOL with alx drivers works fine for me now.

Cheers

mrksmts 05-16-2014 03:53 PM

@cybertaf, I am pretty much a noob here just done a fresh Ubuntu Server 14.04 install.

And still no WOL... :(

cybertaf 05-16-2014 04:32 PM

Il faut installer le kernel 3.10.37

64bits:
Code:

wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.37-saucy/linux-headers-3.10.37-031037-generic_3.10.37-031037.201404141035_amd64.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.37-saucy/linux-headers-3.10.37-031037_3.10.37-031037.201404141035_all.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.37-saucy/linux-image-3.10.37-031037-generic_3.10.37-031037.201404141035_amd64.deb
dpkg -i *.deb
update-grub
reboot


32bits
Code:

wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.37-saucy/linux-headers-3.10.37-031037-generic_3.10.37-031037.201404141035_i386.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.37-saucy/linux-headers-3.10.37-031037_3.10.37-031037.201404141035_all.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.10.37-saucy/linux-image-3.10.37-031037-generic_3.10.37-031037.201404141035_i386.deb
dpkg -i *.deb
update-grub
reboot

et sélectionner le kernel 3.10.37 dans le grub au démarrage.

rico9999 08-23-2014 07:13 PM

Build old module version under 3.15.10
 
As an alternative to building a whole kernel, I wanted to share that I was able to successfully build the
3.10.53 driver under 3.15.10. I'm using FC20.

Pre-requisites:

$ rpm -qa | grep 3.15.10
kernel-headers-3.15.10-200.fc20.x86_64
kernel-devel-3.15.10-200.fc20.x86_64
kernel-3.15.10-200.fc20.x86_64
kernel-modules-extra-3.15.10-200.fc20.x86_64

Instructions:

1. Download linux-3.10.53.tar.xz from kernel org.

2. Extract alx driver
$ tar xf linux-3.10.53.tar.xz linux-3.10.53/drivers/net/ethernet/atheros/alx

3. Build
$ cd linux-3.10.53/drivers/net/ethernet/atheros/alx
$ make -C /lib/modules/`uname -r`/build M=`pwd` modules

4. Install
# cp /lib/modules/3.15.10-200.fc20.x86_64/kernel/drivers/net/ethernet/atheros/alx/alx.ko /lib/modules/3.15.10-200.fc20.x86_64/kernel/drivers/net/ethernet/atheros/alx/alx.ko.good
# cp alx.ko /lib/modules/3.15.10-200.fc20.x86_64/kernel/drivers/net/ethernet/atheros/alx/alx.ko

5. Reboot

6. Run ethtool (should work now)
# ethtool -s p4p1 wol g

7. Powerdown.
# shutdown

WOL should be working now.

I sure wish we didn't have to choose between laptop users not being able to suspend vs. home-theater users not being able to use WOL!

meigelneit 02-14-2015 04:18 AM

Build old module version under 3.15.10
 
Hi,
@rico9999
I followed your instructions above to build alx, but when i have executed make, i got "make: *** No targets. Stop."
Can you give me a hint, please? It's the first time i try to build a driver.
The used Kernel: 3.16.0-4-amd64
Thanks
MN

meigelneit 02-14-2015 04:19 AM

...

tomrey 02-26-2015 09:56 AM

Hi,
I tried ist as well on WHEEZY but I get a make error:
/alx/main.c:1323:2: error: implicit declaration of function ‘SET_ETHTOOL_OPS’ [-Werror=implicit-function-declaration]

As a newbee to make I cannot find a solution.
pls. help

gon123 07-04-2015 06:01 PM

Hi everyone, I know it's a bit late for this post but...

I tried rico999 solution and I just do it!!
I have had some problems but finally I have my b85m-itx working with OMV and WOL.

I will try to help others telling my experience.

1. First of all, a short class of history. Here is the commit where WOL was removed from alx drivers because PC restarted when you try to suspend:
https://git.kernel.org/cgit/linux/ke...0b0dd72ffe8cd2

If you look at the log: https://git.kernel.org/cgit/linux/ke...et/atheros/alx you can see al the changes have been made to the alx drivers. You can think it's not useful but you will be mistaken.

2. People having troubles with 'SET_ETHTOOL_OPS'. Looking at the log you can see that 2 months ago someone changes the line where the error is coming.
https://git.kernel.org/cgit/linux/ke...c3e30c078b0c3e
All you have to do is to edit the main.c file and change that line manully, it's just one line, don't be lazy.

Later I will try to look if other changes could help too. But for now I will leave the driver and see if it works correctly.

After compiling as rico999:
Code:

make -C /lib/modules/$(uname -r)/build M=$(pwd) modules
make -C /lib/modules/$(uname -r)/build M=$(pwd) modules_install
rmmod alx
insmod alx.ko
rm /lib/modules/$(uname -r)/kernel/drivers/net/ethernet/atheros/alx/alx.ko
cp alx.ko /lib/modules/$(uname -r)/kernel/drivers/net/ethernet/atheros/alx/alx.ko

you have your drivers with WOL.

I almost gave up trying to make my system to get the new drivers on boot. I tried everything but it looked imposible, I follow rico999 steps and it didn't work so I go slowly.
First I saw if the drivers worked deleting actual and inserting new.
rmmod alx
insmod alx.ko #From alx compiled driver folder
Then to test: "ethtool -s eth0 wol g" and no out was given! Before the insert the system said wol wasn't supported.

So drivers works. For now I don't know exactly what I do to make my system get the new drivers, I tried rico999 advice a lot of times, lot of reboots, depmod command, but after all I get it, in one of that probes I poweroff and the ethernet light was on!!

Don't give up and good luck!

puke911 10-14-2015 09:24 PM

Hi gon123! First, I wanna say thank you for your solution.
I tried your solution, and it was really work!!
but I got some error about booting.

Isn't there any other problem such as auto booting that you are not intended?

I got just that one problem.

To be more specific, when I finish your process, I can type ethtool -s eth0 wol g,
and I reboot my system, WOL work, successfully, but after I finish my operation system,
Computer wake on automatically, although I didn't do anything such as sending a magic packet, or press my computer's power button.
so,, hmm Is this problem is just own me?

I'm not good at English, so please understand my bad statement.


All times are GMT -5. The time now is 12:52 AM.