提交 31ec9c27 编写于 作者: R Ryder Lee 提交者: Lorenzo Pieralisi

PCI: mediatek: Configure FC and FTS for functions other than 0

"PCI_FUNC(port->slot << 3)" is always 0, so previously
mtk_pcie_startup_port() only configured FC credits and FTs for function
0.

Compute "func" correctly so we also configure functions other than
0. This affects MT2701 and MT7623.

Link: https://lore.kernel.org/r/c529dbfc066f4bda9b87edbdbf771f207e69b84e.1604510053.git.ryder.lee@mediatek.comSigned-off-by: NRyder Lee <ryder.lee@mediatek.com>
Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: NKrzysztof Wilczyński <kw@linux.com>
上级 a38fd874
...@@ -760,7 +760,7 @@ static struct pci_ops mtk_pcie_ops = { ...@@ -760,7 +760,7 @@ static struct pci_ops mtk_pcie_ops = {
static int mtk_pcie_startup_port(struct mtk_pcie_port *port) static int mtk_pcie_startup_port(struct mtk_pcie_port *port)
{ {
struct mtk_pcie *pcie = port->pcie; struct mtk_pcie *pcie = port->pcie;
u32 func = PCI_FUNC(port->slot << 3); u32 func = PCI_FUNC(port->slot);
u32 slot = PCI_SLOT(port->slot << 3); u32 slot = PCI_SLOT(port->slot << 3);
u32 val; u32 val;
int err; int err;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册