Wake On LAN not working after power outage

I am the owner of a MSI B450 Mortar Max board and I need to enable the Wake On LAN (WOL) functionality to remotely operate with my PC when I am away from home.
So far I have successfully configured WOL with the following settings:

  • In Realtek driver settings I enabled magic packet recognition and wake up from shutdown
  • In the BIOS I enabled “Power on by PCI-E” and disabled “ErP” to allow to remotely turn the PC on

So far WOL is working, both from sleep mode and after a “soft” shutdown. However, I noticed that in the presence of a power loss the PC cannot turn on via magic packet. Actually, it is only required to “hard” shut down the PC (by pressing the power button) to break the WOL functionality.

Recently, I wanted to find a solution to this annoying problem, so I found the motherboard schematics and made some voltage measurements. I checked the power supply of the Realtek chip (3.3V) and the voltages on all the accessible pins. All the voltages match in both the “soft” and “hard” shutdown situations, so I think it is not a hardware-related issue. Furthermore, I also checked the presence of the 10Mbps link used to catch the magic packet in both situations.

In my opinion what I think it happens is that the chip is able to receive the packet, but it does not produce any interrupt signal and/or the system ignores it and doesn’t allow the PC to turn on.
This note on the RTL8111H datasheet caught my eye:


(note: LANWAKEB is the chip pin reserved to send the interrupt signal)

From what I understand, PME needs to be enabled in BIOS to allow WOL to work. Maybe PME gets enabled when I shut down the PC from Windows, but it gets reset when I press the power button?
I dug a little more in the BIOS but I didn’t find any setting containing PME. Interestingly, the Setup module inside the BIOS file (which can be downloaded here) contains a reference to PME:

However, the IFR extractor tool cannot extract this setting. Perhaps it was never implemented in the BIOS, which is an AMI Aptio V type.

I am asking some help to sort out this problem. Maybe the expert guys here already know how to solve it. Any suggestion is kindly appreciated! :+1:

TL;DR: Wake On LAN stops working when the PC is shut down with the power button or in presence of power outage. Seemingly no way to reset the functionality without a manual power cycle. A software bug in the BIOS is the most probable cause.