PCI: designware-ep: Read-only registers need DBI_RO_WR_EN to be writable
authorNiklas Cassel <niklas.cassel@axis.com>
Tue, 19 Dec 2017 23:29:24 +0000 (00:29 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 27 Mar 2019 05:13:55 +0000 (14:13 +0900)
commitdd913d610e214b97bba81b1b76883d0f29d63a37
tree33f29a43fc183777c1159b6fa0466e66307e58b3
parenta9d76f59faffc0447701b902ed8322d35c45a983
PCI: designware-ep: Read-only registers need DBI_RO_WR_EN to be writable

commit 1cab826b30c6275d479a6ab1dea1067e15dbec62 upstream.

Certain registers that pcie-designware-ep tries to write to are read-only
registers. However, these registers can become read/write if we first
enable the DBI_RO_WR_EN bit. Set/unset the DBI_RO_WR_EN bit before/after
writing these registers.

Tested-by: Gustavo Pimentel <gustavo.pimentel@synopsys.com>
Signed-off-by: Niklas Cassel <niklas.cassel@axis.com>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Acked-by: Joao Pinto <jpinto@synopsys.com>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/pci/dwc/pcie-designware-ep.c