Lines Matching refs:lookup
1562 struct tb_sw_lookup *lookup = data; in tb_switch_match() local
1566 if (sw->tb != lookup->tb) in tb_switch_match()
1569 if (lookup->uuid) in tb_switch_match()
1570 return !memcmp(sw->uuid, lookup->uuid, sizeof(*lookup->uuid)); in tb_switch_match()
1572 if (lookup->route) { in tb_switch_match()
1573 return sw->config.route_lo == lower_32_bits(lookup->route) && in tb_switch_match()
1574 sw->config.route_hi == upper_32_bits(lookup->route); in tb_switch_match()
1578 if (!lookup->depth) in tb_switch_match()
1581 return sw->link == lookup->link && sw->depth == lookup->depth; in tb_switch_match()
1595 struct tb_sw_lookup lookup; in tb_switch_find_by_link_depth() local
1598 memset(&lookup, 0, sizeof(lookup)); in tb_switch_find_by_link_depth()
1599 lookup.tb = tb; in tb_switch_find_by_link_depth()
1600 lookup.link = link; in tb_switch_find_by_link_depth()
1601 lookup.depth = depth; in tb_switch_find_by_link_depth()
1603 dev = bus_find_device(&tb_bus_type, NULL, &lookup, tb_switch_match); in tb_switch_find_by_link_depth()
1620 struct tb_sw_lookup lookup; in tb_switch_find_by_uuid() local
1623 memset(&lookup, 0, sizeof(lookup)); in tb_switch_find_by_uuid()
1624 lookup.tb = tb; in tb_switch_find_by_uuid()
1625 lookup.uuid = uuid; in tb_switch_find_by_uuid()
1627 dev = bus_find_device(&tb_bus_type, NULL, &lookup, tb_switch_match); in tb_switch_find_by_uuid()
1644 struct tb_sw_lookup lookup; in tb_switch_find_by_route() local
1650 memset(&lookup, 0, sizeof(lookup)); in tb_switch_find_by_route()
1651 lookup.tb = tb; in tb_switch_find_by_route()
1652 lookup.route = route; in tb_switch_find_by_route()
1654 dev = bus_find_device(&tb_bus_type, NULL, &lookup, tb_switch_match); in tb_switch_find_by_route()