Lines Matching defs:supplier

83 	link->supplier = sup;
114 link->consumer, link->supplier);
129 link->consumer, link->supplier);
134 * fwnode_links_purge_suppliers - Delete all supplier links of fwnode_handle.
135 * @fwnode: fwnode whose supplier links need to be deleted
137 * Deletes all supplier links connecting directly to @fwnode.
214 * @new_sup: fwnode of new supplier
221 * Otherwise, move its consumers to the new supplier @new_sup.
253 * This function is mainly meant to adjust the supplier/consumer dependencies
409 struct device *supplier)
411 switch (supplier->links.status) {
416 * A consumer driver can create a link to a supplier
418 * knows that the supplier is already functional (for
420 * supplier).
519 output = "supplier unbinding";
537 output = "supplier unbind";
585 * in __driver_probe_device(). In that case, drop the supplier's
590 pm_runtime_put_noidle(link->supplier);
592 pm_request_idle(link->supplier);
595 put_device(link->supplier);
607 * supplier devices get deleted when it runs, so put it into the
638 struct device *sup = link->supplier;
641 ret = sysfs_create_link(&link->link_dev.kobj, &sup->kobj, "supplier");
659 buf_sup = kasprintf(GFP_KERNEL, "supplier:%s:%s", dev_bus_name(sup), dev_name(sup));
676 sysfs_remove_link(&link->link_dev.kobj, "supplier");
685 struct device *sup = link->supplier;
689 sysfs_remove_link(&link->link_dev.kobj, "supplier");
692 buf_sup = kasprintf(GFP_KERNEL, "supplier:%s:%s", dev_bus_name(sup), dev_name(sup));
744 * @supplier: Supplier end of the link.
753 * DL_FLAG_RPM_ACTIVE flag is set in addition to it, the supplier devices will
769 * after unbinding the consumer or supplier driver, respectively, from its
772 * the consumer or the supplier) is unregistered.
778 * driver after successfully binding a driver to the supplier device.
783 * However, if a device link between the given @consumer and @supplier pair
796 * The supplier device is required to be registered when this function is called
801 struct device *supplier, u32 flags)
805 if (!consumer || !supplier || consumer == supplier ||
814 if (pm_runtime_get_sync(supplier) < 0) {
815 pm_runtime_put_noidle(supplier);
831 * If the supplier has not been fully registered yet or there is a
833 * the supplier already in the graph, return NULL. If the link is a
837 if (!device_pm_initialized(supplier)
839 device_is_dependent(consumer, supplier))) {
863 list_for_each_entry(link, &supplier->links.consumers, s_node) {
909 device_link_init_status(link, consumer, supplier);
926 get_device(supplier);
927 link->supplier = supplier;
938 dev_bus_name(supplier), dev_name(supplier),
957 device_link_init_status(link, consumer, supplier);
961 * resume the supplier even without DL_FLAG_RPM_ACTIVE.
965 pm_runtime_resume(supplier);
967 list_add_tail_rcu(&link->s_node, &supplier->links.consumers);
973 dev_name(supplier));
987 dev_dbg(consumer, "Linked as a consumer to %s\n", dev_name(supplier));
994 pm_runtime_put(supplier);
1005 dev_name(link->supplier));
1043 * @supplier: Supplier end of the link.
1048 void device_link_remove(void *consumer, struct device *supplier)
1052 if (WARN_ON(consumer == supplier))
1057 list_for_each_entry(link, &supplier->links.consumers, s_node) {
1076 if (link->supplier->links.status == DL_DEV_DRIVER_BOUND) {
1102 return link->supplier;
1108 * device_links_check_suppliers - Check presence of supplier drivers.
1115 * We need to guarantee that the supplier will not go away after the check has
1118 * mark the link as "consumer probe in progress" to make the supplier removal
1130 * Device waiting for supplier to become available is not allowed to
1140 "wait for supplier %pfwf\n", sup_fw);
1155 !dev_can_match(link->supplier)) {
1162 "supplier %s not ready\n", dev_name(link->supplier));
1328 * supplier before it's bound to the driver. We still want the device link
1332 * supplier device links and checks if the supplier is bound. If it is, then
1381 * device the fallback supplier to the dangling consumers of the child
1401 * probe" state to start with if the supplier is still probing
1422 struct device *supplier;
1427 supplier = link->supplier;
1438 !dev_can_match(link->supplier)) {
1444 * (consumer probed before supplier). So delete it.
1455 * device link that was preventing the supplier from getting a
1459 __device_links_supplier_defer_sync(supplier);
1461 __device_links_queue_sync_state(supplier, &sync_list);
1478 * unless they already are in the "supplier unbind in progress" state in which
1500 if (link->supplier->links.status == DL_DEV_DRIVER_BOUND) {
1503 WARN_ON(link->supplier->links.status != DL_DEV_UNBINDING &&
1597 * state to "supplier unbind" to prevent the consumer from being probed
1637 * If that's not the case, change the status of the link to "supplier unbind"
1820 dev_name(link->supplier));
1827 if (!dev_can_match(link->supplier))
1845 struct device *sup = link->supplier;
1888 * probing because they are waiting on a optional supplier that doesn't have a
1902 * device where the supplier hasn't yet probed successfully because they have to
1909 * waited for their optional supplier to probe (when the supplier's module is
2038 * @sup_handle: Potential supplier's fwnode.
2099 if (__fw_devlink_relax_cycles(con_handle, link->supplier)) {
2133 dev_link->supplier->fwnode)) {
2135 dev_link->supplier->fwnode);
2153 * @sup_handle: fwnode handle of supplier
2157 * @con and the supplier device represented by @sup_handle.
2159 * The supplier has to be provided as a fwnode because incorrect cycles in
2160 * fwnode links can sometimes cause the supplier device to never be created.
2162 * device link from the consumer to a missing supplier.
2182 * In some cases, a device P might also be a supplier to its child node
2194 * supplier of C as that would delay the probe of C.
2228 * supplier device indefinitely.
2240 dev_err(con, "Failed to create device link (0x%x) with supplier %s for %pfwf\n",
2249 * Supplier or supplier's ancestor already initialized without a struct
2270 * links between the consumer device and @dev (supplier).
2273 * SYNC_STATE_ONLY link between @dev (supplier) and the closest ancestor device
2278 * Once device links are created from the real consumer to @dev (supplier), the
2295 * the supplier device. This is necessary to make sure the
2296 * supplier doesn't get a sync_state() callback before the real
2297 * consumer can create a device link to the supplier.
2300 * consumer's parent device is added before the supplier.
2306 * parent of the supplier, don't create a
2307 * consumer-supplier link from the parent to its child
2336 * This function looks at all the supplier fwnodes of fwnode tree rooted at
2338 * supplier devices of the entire fwnode tree at @fwnode.
2352 * between the real consumer and supplier devices.
2363 struct fwnode_handle *sup = link->supplier;
2375 * case where the supplier is added before the consumer's parent device
3742 * this device (supplier) to be added so that they can create a device
3746 * requires the supplier be registered before it's called.
3777 * case the consumer device is able to operate without this supplier.