/* agp_backend_acquire - attempt to acquire an agp backend.  */
struct agp_bridge_data* agp_backend_acquire(struct pci_dev *pdev)
/* agp_backend_acquire - attempt to acquire an agp backend.  */
struct agp_bridge_data* agp_backend_acquire(struct pci_dev *pdev)
{
	struct agp_bridge_data *bridge;
	bridge = agp_find_bridge(pdev);
	if (!bridge)
		return NULL;
	if (atomic_read(&bridge->agp_in_use))
		return NULL;
	atomic_inc(&bridge->agp_in_use);
	return bridge;
}