PCI: mvebu: increment nports only for registered ports
authorSebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
Tue, 13 Aug 2013 12:25:21 +0000 (14:25 +0200)
committerJason Cooper <jason@lakedaemon.net>
Mon, 30 Sep 2013 14:58:35 +0000 (14:58 +0000)
commitbf09b6ae588f7567bcf31d9eff313d4d9fdc664e
treeeb59c23af7b7a6f5bf8e0e3076f15b4894e13ba7
parentb42285f66f871a9898a0e79e2d74bc7e7a101995
PCI: mvebu: increment nports only for registered ports

The number of ports is probed by counting the number of available child nodes.
Later on, the registration of a port can fail and cause a mismatch between
the ->nports counter and registered ports. This patch modifies the counting
strategy, to make ->nports represent the number of registered ports instead
of the number of available childs.

Signed-off-by: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
drivers/pci/host/pci-mvebu.c