diff options
author | Michael Ellerman <michael@ellerman.id.au> | 2007-04-05 03:19:07 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-05-02 22:02:36 -0400 |
commit | 17bbc12acdb23ffb9613e12ca974fafd31bfcb56 (patch) | |
tree | bbeb34a927703ba140ca7c7a10c8fc4e85f243bd | |
parent | 128bc5fced238752d01b5169077f2ec624b3d59b (diff) |
MSI: Rename pci_msi_supported() to pci_msi_check_device()
As pointed out by Eric, the name pci_msi_supported() suggests it should
return a boolean value, however it doesn't. So update the name to be
a bit less confusing and update the doco too.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/pci/msi.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c index b6dc69ef80a7..34087af68833 100644 --- a/drivers/pci/msi.c +++ b/drivers/pci/msi.c | |||
@@ -457,15 +457,15 @@ static int msix_capability_init(struct pci_dev *dev, | |||
457 | } | 457 | } |
458 | 458 | ||
459 | /** | 459 | /** |
460 | * pci_msi_supported - check whether MSI may be enabled on device | 460 | * pci_msi_check_device - check whether MSI may be enabled on a device |
461 | * @dev: pointer to the pci_dev data structure of MSI device function | 461 | * @dev: pointer to the pci_dev data structure of MSI device function |
462 | * @type: are we checking for MSI or MSI-X ? | 462 | * @type: are we checking for MSI or MSI-X ? |
463 | * | 463 | * |
464 | * Look at global flags, the device itself, and its parent busses | 464 | * Look at global flags, the device itself, and its parent busses |
465 | * to return 0 if MSI are supported for the device. | 465 | * to determine if MSI/-X are supported for the device. If MSI/-X is |
466 | * supported return 0, else return an error code. | ||
466 | **/ | 467 | **/ |
467 | static | 468 | static int pci_msi_check_device(struct pci_dev * dev, int type) |
468 | int pci_msi_supported(struct pci_dev * dev, int type) | ||
469 | { | 469 | { |
470 | struct pci_bus *bus; | 470 | struct pci_bus *bus; |
471 | 471 | ||
@@ -503,7 +503,7 @@ int pci_enable_msi(struct pci_dev* dev) | |||
503 | { | 503 | { |
504 | int status; | 504 | int status; |
505 | 505 | ||
506 | if (pci_msi_supported(dev, PCI_CAP_ID_MSI)) | 506 | if (pci_msi_check_device(dev, PCI_CAP_ID_MSI)) |
507 | return -EINVAL; | 507 | return -EINVAL; |
508 | 508 | ||
509 | WARN_ON(!!dev->msi_enabled); | 509 | WARN_ON(!!dev->msi_enabled); |
@@ -601,7 +601,7 @@ int pci_enable_msix(struct pci_dev* dev, struct msix_entry *entries, int nvec) | |||
601 | int i, j; | 601 | int i, j; |
602 | u16 control; | 602 | u16 control; |
603 | 603 | ||
604 | if (!entries || pci_msi_supported(dev, PCI_CAP_ID_MSIX)) | 604 | if (!entries || pci_msi_check_device(dev, PCI_CAP_ID_MSIX)) |
605 | return -EINVAL; | 605 | return -EINVAL; |
606 | 606 | ||
607 | pos = pci_find_capability(dev, PCI_CAP_ID_MSIX); | 607 | pos = pci_find_capability(dev, PCI_CAP_ID_MSIX); |