Lines Matching refs:device

41 static ssize_t size_show(struct device *dev, struct device_attribute *attr,
58 static ssize_t available_show(struct device *dev, struct device_attribute *attr,
75 static ssize_t published_show(struct device *dev, struct device_attribute *attr,
277 * @pdev: the device to add the memory to
360 * Note this function returns the parent PCI device with a
364 static struct pci_dev *find_parent_pci_dev(struct device *dev)
366 struct device *parent;
427 unsigned short device;
449 * If the first device on host's root bus is either devfn 00.0 or a PCIe
453 * (though there is no PCI/PCIe requirement for such a device). On some
454 * platforms, e.g., Intel Skylake, there is no such host bridge device, and
461 * For this to be safe, the caller should hold a reference to a device on the
462 * bridge, which should ensure the host_bridge device will not be freed
489 unsigned short vendor, device;
495 device = root->device;
498 if (vendor != entry->vendor || device != entry->device)
508 vendor, device);
544 * If they are two functions of the same device, return
546 * then one hop back down to another function of the same device).
571 * ports per above. If the device is not in the whitelist, return
593 * device which will already hold a reference to the upstream bridge.
686 int pci_p2pdma_distance_many(struct pci_dev *provider, struct device **clients,
703 "cannot be used for peer-to-peer DMA as it is not a PCI device\n");
729 * pci_has_p2pmem - check if a given PCI device has published any p2pmem
730 * @pdev: PCI device to check
747 * pci_p2pmem_find_many - find a peer-to-peer DMA memory device compatible with
758 * Returns a pointer to the PCI device with a reference taken (use pci_dev_put
759 * to return the reference) or NULL if no compatible device is found. The
762 struct pci_dev *pci_p2pmem_find_many(struct device **clients, int num_clients)
812 * @pdev: the device to allocate memory from
850 * @pdev: the device the memory was allocated from
868 * @pdev: the device the memory was allocated from
893 * @pdev: the device to allocate memory from
927 * @pdev: the device to allocate memory from
948 * @pdev: the device with peer-to-peer DMA memory to publish
951 * Published memory can be used by other PCI device drivers for
953 * exclusive use of the device driver that registers the peer-to-peer
969 struct device *dev)
1003 * @dev: DMA device that's doing the mapping operation
1017 pci_p2pdma_map_segment(struct pci_p2pdma_map_state *state, struct device *dev,
1039 * @p2p_dev: returns the PCI device that was selected to be used
1044 * The value can select a PCI device (using its full BDF device
1047 * to automatically find a compatible device and specifying a PCI device
1058 struct device *dev;
1067 "PCI device has no peer-to-peer memory: %s\n",
1076 * If the user enters a PCI device that doesn't exist
1085 pr_err("No such PCI device: %.*s\n", (int)strcspn(page, "\n"), page);
1094 * @p2p_dev: the selected p2p device (NULL if no device is selected)