x86/PCI: Export find_cap() to be used in early PCI code

This patch exports (and renames) the function find_cap() to be used
in the early PCI quirk code, by the next patch.

This is being moved out from AGP code to generic early-PCI code
since it's not AGP-specific and can be used for any PCI device.
No functional changes intended.

Signed-off-by: Guilherme G. Piccoli <gpiccoli@canonical.com>

BUG=b/160734277
TEST=presubmit and validation
RELEASE_NOTE=x86/PCI: Export find_cap() to be used in early PCI code
SOURCE=FROMLIST(https://lore.kernel.org/linux-pci/20181018183721.27467-2-gpiccoli@canonical.com/)

Change-Id: Ia27dafbe74243745a3ef59f9e3cf22cfc73d556c
Reviewed-on: https://cos-review.googlesource.com/c/third_party/kernel/+/29402
Tested-by: Cusky Presubmit Bot <presubmit@cos-infra-prod.iam.gserviceaccount.com>
Reviewed-by: Oleksandr Tymoshenko <ovt@google.com>
Reviewed-on: https://cos-review.googlesource.com/c/third_party/kernel/+/41522
Tested-by: Varsha Teratipally <teratipally@google.com>
3 files changed