• Home
  • Raw
  • Download

Lines Matching refs:occ_show

2165 struct occ_show {  struct
2207 static struct occ_show *occ_show_alloc(struct dl *dl) in occ_show_alloc()
2209 struct occ_show *occ_show; in occ_show_alloc() local
2211 occ_show = calloc(1, sizeof(*occ_show)); in occ_show_alloc()
2212 if (!occ_show) in occ_show_alloc()
2214 occ_show->dl = dl; in occ_show_alloc()
2215 INIT_LIST_HEAD(&occ_show->port_list); in occ_show_alloc()
2216 return occ_show; in occ_show_alloc()
2219 static void occ_show_free(struct occ_show *occ_show) in occ_show_free() argument
2223 list_for_each_entry_safe(occ_port, tmp, &occ_show->port_list, list) in occ_show_free()
2227 static struct occ_port *occ_port_get(struct occ_show *occ_show, in occ_port_get() argument
2235 list_for_each_entry_reverse(occ_port, &occ_show->port_list, list) { in occ_port_get()
2242 list_add_tail(&occ_port->list, &occ_show->port_list); in occ_port_get()
2309 static void pr_out_occ_show(struct occ_show *occ_show) in pr_out_occ_show() argument
2311 struct dl *dl = occ_show->dl; in pr_out_occ_show()
2315 list_for_each_entry(occ_port, &occ_show->port_list, list) { in pr_out_occ_show()
2323 static void cmd_sb_occ_port_pool_process(struct occ_show *occ_show, in cmd_sb_occ_port_pool_process() argument
2329 if (occ_show->err || !dl_dump_filter(occ_show->dl, tb)) in cmd_sb_occ_port_pool_process()
2332 occ_port = occ_port_get(occ_show, tb); in cmd_sb_occ_port_pool_process()
2334 occ_show->err = -ENOMEM; in cmd_sb_occ_port_pool_process()
2340 occ_show->err = -ENOMEM; in cmd_sb_occ_port_pool_process()
2351 struct occ_show *occ_show = data; in cmd_sb_occ_port_pool_process_cb() local
2361 cmd_sb_occ_port_pool_process(occ_show, tb); in cmd_sb_occ_port_pool_process_cb()
2365 static void cmd_sb_occ_tc_pool_process(struct occ_show *occ_show, in cmd_sb_occ_tc_pool_process() argument
2372 if (occ_show->err || !dl_dump_filter(occ_show->dl, tb)) in cmd_sb_occ_tc_pool_process()
2375 occ_port = occ_port_get(occ_show, tb); in cmd_sb_occ_tc_pool_process()
2377 occ_show->err = -ENOMEM; in cmd_sb_occ_tc_pool_process()
2383 occ_show->err = -ENOMEM; in cmd_sb_occ_tc_pool_process()
2402 struct occ_show *occ_show = data; in cmd_sb_occ_tc_pool_process_cb() local
2413 cmd_sb_occ_tc_pool_process(occ_show, tb); in cmd_sb_occ_tc_pool_process_cb()
2420 struct occ_show *occ_show; in cmd_sb_occ_show() local
2428 occ_show = occ_show_alloc(dl); in cmd_sb_occ_show()
2429 if (!occ_show) in cmd_sb_occ_show()
2435 cmd_sb_occ_port_pool_process_cb, occ_show); in cmd_sb_occ_show()
2442 cmd_sb_occ_tc_pool_process_cb, occ_show); in cmd_sb_occ_show()
2447 pr_out_occ_show(occ_show); in cmd_sb_occ_show()
2451 occ_show_free(occ_show); in cmd_sb_occ_show()