I think I found the problem!
https://github.com/openwrt/openwrt/blob/master/target/linux/ipq40xx/patches-5.4/705-net-add-qualcomm-ar40xx-phy.patch#L1882
This line prevents the status change of the port at addr 0. Removing that line makes the WAN port working as it should, but probably this isn't the right way.
Looking into the GPL sources (here), Qualcomm doesn't use the EDIT: WRONG SOURCES!genphy_read_status
function for port 0, but they change the status manually.
What do you think about it? Whe should write to some core developer?
EDIT:
This user had the same problem with a different router: