Lines Matching refs:dl
290 struct dsa_link *dl; in dsa_link_touch() local
294 list_for_each_entry(dl, &dst->rtable, list) in dsa_link_touch()
295 if (dl->dp == dp && dl->link_dp == link_dp) in dsa_link_touch()
296 return dl; in dsa_link_touch()
298 dl = kzalloc(sizeof(*dl), GFP_KERNEL); in dsa_link_touch()
299 if (!dl) in dsa_link_touch()
302 dl->dp = dp; in dsa_link_touch()
303 dl->link_dp = link_dp; in dsa_link_touch()
305 INIT_LIST_HEAD(&dl->list); in dsa_link_touch()
306 list_add_tail(&dl->list, &dst->rtable); in dsa_link_touch()
308 return dl; in dsa_link_touch()
318 struct dsa_link *dl; in dsa_port_setup_routing_table() local
328 dl = dsa_link_touch(dp, link_dp); in dsa_port_setup_routing_table()
329 if (!dl) { in dsa_port_setup_routing_table()
506 struct devlink *dl = dp->ds->devlink; in dsa_port_devlink_setup() local
535 err = devlink_port_register(dl, dlp, dp->index); in dsa_port_devlink_setup()
628 static int dsa_devlink_info_get(struct devlink *dl, in dsa_devlink_info_get() argument
632 struct dsa_switch *ds = dsa_devlink_to_ds(dl); in dsa_devlink_info_get()
640 static int dsa_devlink_sb_pool_get(struct devlink *dl, in dsa_devlink_sb_pool_get() argument
644 struct dsa_switch *ds = dsa_devlink_to_ds(dl); in dsa_devlink_sb_pool_get()
653 static int dsa_devlink_sb_pool_set(struct devlink *dl, unsigned int sb_index, in dsa_devlink_sb_pool_set() argument
658 struct dsa_switch *ds = dsa_devlink_to_ds(dl); in dsa_devlink_sb_pool_set()
732 static int dsa_devlink_sb_occ_snapshot(struct devlink *dl, in dsa_devlink_sb_occ_snapshot() argument
735 struct dsa_switch *ds = dsa_devlink_to_ds(dl); in dsa_devlink_sb_occ_snapshot()
743 static int dsa_devlink_sb_occ_max_clear(struct devlink *dl, in dsa_devlink_sb_occ_max_clear() argument
746 struct dsa_switch *ds = dsa_devlink_to_ds(dl); in dsa_devlink_sb_occ_max_clear()
1110 struct dsa_link *dl, *next; in dsa_tree_teardown() local
1125 list_for_each_entry_safe(dl, next, &dst->rtable, list) { in dsa_tree_teardown()
1126 list_del(&dl->list); in dsa_tree_teardown()
1127 kfree(dl); in dsa_tree_teardown()