1 From: Mathias Kresin <dev@kresin.me>
2 Date: Sun, 26 Mar 2017 19:05:36 +0200
3 Subject: MIPS: PCI: add controllers before the specified head
5 With commit 23dac14d058f ("MIPS: PCI: Use struct list_head lists") new
6 controllers are added after the specified head where they were added
7 before the specified head previously.
9 Use list_add_tail to restore the former order.
11 This patches fixes the following PCI error on lantiq:
13 pci 0000:01:00.0: BAR 0: error updating (0x1c000004 != 0x000000)
15 Fixes: 23dac14d058f ("MIPS: PCI: Use struct list_head lists")
16 Signed-off-by: Mathias Kresin <dev@kresin.me>
18 arch/mips/pci/pci-legacy.c | 2 +-
19 1 file changed, 1 insertion(+), 1 deletion(-)
21 --- a/arch/mips/pci/pci-legacy.c
22 +++ b/arch/mips/pci/pci-legacy.c
23 @@ -190,7 +190,7 @@ void register_pci_controller(struct pci_
26 INIT_LIST_HEAD(&hose->list);
27 - list_add(&hose->list, &controllers);
28 + list_add_tail(&hose->list, &controllers);
31 * Do not panic here but later - this might happen before console init.