]> git.baikalelectronics.ru Git - kernel.git/commit
net: broadcom: fix a mistake about ioremap resource
authorDejin Zheng <zhengdejin5@gmail.com>
Tue, 5 May 2020 02:03:29 +0000 (10:03 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 5 May 2020 18:11:12 +0000 (11:11 -0700)
commitac6c80f46ff63142ff78d51667bd6aec24278a10
treea7b420b6af72f8fdb6a962da72933a3f115a9fff
parentedde0c2b6c7c2e96972beab1a9e5007fb5a6cb34
net: broadcom: fix a mistake about ioremap resource

Commit 10b936fdcfe20 ("net: broadcom: convert to
devm_platform_ioremap_resource_byname()") will broke this driver.
idm_base and nicpm_base were optional, after this change, they are
mandatory. it will probe fails with -22 when the dtb doesn't have them
defined. so revert part of this commit and make idm_base and nicpm_base
as optional.

Fixes: 10b936fdcfe206f ("net: broadcom: convert to devm_platform_ioremap_resource_byname()")
Reported-by: Jonathan Richardson <jonathan.richardson@broadcom.com>
Cc: Scott Branden <scott.branden@broadcom.com>
Cc: Ray Jui <ray.jui@broadcom.com>
Cc: Florian Fainelli <f.fainelli@gmail.com>
Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Dejin Zheng <zhengdejin5@gmail.com>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bgmac-platform.c