Lines Matching refs:tb_switch
85 struct tb_switch { struct
131 struct tb_switch *sw;
230 int (*approve_switch)(struct tb *tb, struct tb_switch *sw);
231 int (*add_switch_key)(struct tb *tb, struct tb_switch *sw);
232 int (*challenge_switch_key)(struct tb *tb, struct tb_switch *sw,
258 static inline struct tb_port *tb_upstream_port(struct tb_switch *sw) in tb_upstream_port()
263 static inline u64 tb_route(struct tb_switch *sw) in tb_route()
268 static inline struct tb_port *tb_port_at(u64 route, struct tb_switch *sw) in tb_port_at()
278 static inline int tb_sw_read(struct tb_switch *sw, void *buffer, in tb_sw_read()
290 static inline int tb_sw_write(struct tb_switch *sw, void *buffer, in tb_sw_write()
334 struct tb_switch *__sw = (sw); \
377 int tb_domain_approve_switch(struct tb *tb, struct tb_switch *sw);
378 int tb_domain_approve_switch_key(struct tb *tb, struct tb_switch *sw);
379 int tb_domain_challenge_switch_key(struct tb *tb, struct tb_switch *sw);
390 struct tb_switch *tb_switch_alloc(struct tb *tb, struct device *parent,
392 struct tb_switch *tb_switch_alloc_safe_mode(struct tb *tb,
394 int tb_switch_configure(struct tb_switch *sw);
395 int tb_switch_add(struct tb_switch *sw);
396 void tb_switch_remove(struct tb_switch *sw);
397 void tb_switch_suspend(struct tb_switch *sw);
398 int tb_switch_resume(struct tb_switch *sw);
400 void tb_sw_set_unplugged(struct tb_switch *sw);
401 struct tb_switch *get_switch_at_route(struct tb_switch *sw, u64 route);
402 struct tb_switch *tb_switch_find_by_link_depth(struct tb *tb, u8 link,
404 struct tb_switch *tb_switch_find_by_uuid(struct tb *tb, const uuid_t *uuid);
405 struct tb_switch *tb_switch_find_by_route(struct tb *tb, u64 route);
407 static inline struct tb_switch *tb_switch_get(struct tb_switch *sw) in tb_switch_get()
414 static inline void tb_switch_put(struct tb_switch *sw) in tb_switch_put()
424 static inline struct tb_switch *tb_to_switch(struct device *dev) in tb_to_switch()
427 return container_of(dev, struct tb_switch, dev); in tb_to_switch()
435 int tb_switch_find_vse_cap(struct tb_switch *sw, enum tb_switch_vse_cap vsec);
444 int tb_drom_read(struct tb_switch *sw);
445 int tb_drom_read_uid_only(struct tb_switch *sw, u64 *uid);