diff options
| author | Gavin Shan <gwshan@linux.vnet.ibm.com> | 2016-05-03 01:41:42 -0400 |
|---|---|---|
| committer | Michael Ellerman <mpe@ellerman.id.au> | 2016-05-11 07:54:25 -0400 |
| commit | cdddc577d956d55a62581ba3681f8ba66eca3873 (patch) | |
| tree | 59c307cc289f2c4aff0a48fba962c51f63cb9448 /arch/powerpc/platforms/pseries | |
| parent | de5a28ac5a2d9619dc82286b08dadca577133bbe (diff) | |
powerpc/pci: Export pci_traverse_device_nodes()
This renames traverse_pci_devices() to pci_traverse_device_nodes().
The function traverses all subordinate device nodes of the specified
one. Also, below cleanup applied to the function. No logical changes
introduced.
* Rename "pre" to "fn".
* Avoid assignment in if condition reported from checkpatch.pl.
Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/platforms/pseries')
| -rw-r--r-- | arch/powerpc/platforms/pseries/msi.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/powerpc/platforms/pseries/msi.c b/arch/powerpc/platforms/pseries/msi.c index 272e9ec1ab54..543a6386f3eb 100644 --- a/arch/powerpc/platforms/pseries/msi.c +++ b/arch/powerpc/platforms/pseries/msi.c | |||
| @@ -305,7 +305,7 @@ static int msi_quota_for_device(struct pci_dev *dev, int request) | |||
| 305 | memset(&counts, 0, sizeof(struct msi_counts)); | 305 | memset(&counts, 0, sizeof(struct msi_counts)); |
| 306 | 306 | ||
| 307 | /* Work out how many devices we have below this PE */ | 307 | /* Work out how many devices we have below this PE */ |
| 308 | traverse_pci_devices(pe_dn, count_non_bridge_devices, &counts); | 308 | pci_traverse_device_nodes(pe_dn, count_non_bridge_devices, &counts); |
| 309 | 309 | ||
| 310 | if (counts.num_devices == 0) { | 310 | if (counts.num_devices == 0) { |
| 311 | pr_err("rtas_msi: found 0 devices under PE for %s\n", | 311 | pr_err("rtas_msi: found 0 devices under PE for %s\n", |
| @@ -320,7 +320,7 @@ static int msi_quota_for_device(struct pci_dev *dev, int request) | |||
| 320 | /* else, we have some more calculating to do */ | 320 | /* else, we have some more calculating to do */ |
| 321 | counts.requestor = pci_device_to_OF_node(dev); | 321 | counts.requestor = pci_device_to_OF_node(dev); |
| 322 | counts.request = request; | 322 | counts.request = request; |
| 323 | traverse_pci_devices(pe_dn, count_spare_msis, &counts); | 323 | pci_traverse_device_nodes(pe_dn, count_spare_msis, &counts); |
| 324 | 324 | ||
| 325 | /* If the quota isn't an integer multiple of the total, we can | 325 | /* If the quota isn't an integer multiple of the total, we can |
| 326 | * use the remainder as spare MSIs for anyone that wants them. */ | 326 | * use the remainder as spare MSIs for anyone that wants them. */ |
