]> git.baikalelectronics.ru Git - kernel.git/commit
PCI: xgene: Fix cfg resource mapping
authorDejin Zheng <zhengdejin5@gmail.com>
Sun, 28 Mar 2021 14:41:18 +0000 (22:41 +0800)
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Wed, 31 Mar 2021 09:28:38 +0000 (10:28 +0100)
commit5eb85bcf16c2a4b1582639f5e5d9a83c25bcc28d
tree38aebddc8d32d34e25038b93f39bc688f9a233ab
parent219c9076286fd92026e818ab1375558e5b20649f
PCI: xgene: Fix cfg resource mapping

In commit 69c2bd0dbc09 a change was made to use
devm_platform_ioremap_resource_byname() to simplify code and remove
the res variable; this was wrong since the res variable is still needed
and as an outcome the port->cfg_addr gets an erroneous address.

Revert the change going back to original behaviour.

Link: https://lore.kernel.org/r/20210328144118.305074-1-zhengdejin5@gmail.com
Fixes: 69c2bd0dbc094 ("PCI: controller: Convert to devm_platform_ioremap_resource_byname()")
Reported-by: dann.frazier@canonical.com
Tested-by: dann frazier <dann.frazier@canonical.com>
Signed-off-by: Dejin Zheng <zhengdejin5@gmail.com>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Cc: stable@vger.kernel.org # v5.9+
drivers/pci/controller/pci-xgene.c