diff --git a/drivers/net/stmmac/Kconfig b/drivers/net/stmmac/Kconfig
index 3c2af7c6a39b7575d700e90902aac544f693f461..7df7df4e79c5cef7b3f6e006a2150d21f882c101 100644
--- a/drivers/net/stmmac/Kconfig
+++ b/drivers/net/stmmac/Kconfig
@@ -3,7 +3,7 @@ config STMMAC_ETH
 	select MII
 	select PHYLIB
 	select CRC32
-	depends on NETDEVICES
+	depends on NETDEVICES && HAS_IOMEM
 	help
 	  This is the driver for the Ethernet IPs are built around a
 	  Synopsys IP Core and only tested on the STMicroelectronics