Date: Thu, 21 Jan 2010 13:21:06 +0000 (UTC) From: Luigi Rizzo <luigi@FreeBSD.org> To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r202748 - in user/luigi/ipfw3-head: sbin/ipfw sys/netinet sys/netinet/ipfw Message-ID: <201001211321.o0LDL6bc038043@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: luigi Date: Thu Jan 21 13:21:06 2010 New Revision: 202748 URL: http://svn.freebsd.org/changeset/base/202748 Log: Replace the 'pipe' prefix/name with 'link' for objects that only relate to a communication link. Modified: user/luigi/ipfw3-head/sbin/ipfw/dummynet.c user/luigi/ipfw3-head/sys/netinet/ip_dummynet.h user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_io.c user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_private.h user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dummynet.c Modified: user/luigi/ipfw3-head/sbin/ipfw/dummynet.c ============================================================================== --- user/luigi/ipfw3-head/sbin/ipfw/dummynet.c Thu Jan 21 13:15:14 2010 (r202747) +++ user/luigi/ipfw3-head/sbin/ipfw/dummynet.c Thu Jan 21 13:21:06 2010 (r202748) @@ -67,6 +67,7 @@ static struct _s_x dummynet_params[] = { { "bw", TOK_BW }, { "bandwidth", TOK_BW }, { "delay", TOK_DELAY }, + { "link", TOK_PIPE }, { "pipe", TOK_PIPE }, { "queue", TOK_QUEUE }, { "flowset", TOK_FLOWSET }, @@ -271,11 +272,11 @@ flush_buf(char *buf) /* * generic list routine. We expect objects in a specific order, i.e. * PIPES AND SCHEDULERS: - * pipe; scheduler; internal flowset if any; instances + * link; scheduler; internal flowset if any; instances * XXX do we need the queue ? * FLOWSETS: * flowset; queues; - * pipe i (int queue); scheduler i; si(i) { flowsets() : queues } + * link i (int queue); scheduler i; si(i) { flowsets() : queues } * filt is an array of sorted ranges whithin where we list */ static void @@ -310,8 +311,8 @@ list_pipes(struct dn_id *oid, struct dn_ list_queue((struct new_inst *)oid); break; - case DN_PIPE: { - struct new_pipe *p = (struct new_pipe *)oid; + case DN_LINK: { + struct dn_link *p = (struct dn_link *)oid; double b = p->bandwidth; char bwbuf[30]; char burst[5 + 7]; @@ -332,7 +333,7 @@ list_pipes(struct dn_id *oid, struct dn_ "", HN_AUTOSCALE, 0) < 0 || co.verbose) sprintf(burst, "%d", (int)p->burst); sprintf(buf, "%05d: %s %4d ms burst %s", - p->pipe_nr, bwbuf, p->delay, burst); + p->link_nr, bwbuf, p->delay, burst); } break; @@ -366,7 +367,7 @@ list_pipes(struct dn_id *oid, struct dn_ } q = (struct dn_flow_queue *)(fs+1); - sprintf(prefix, "q%05d: weight %d pipe %d ", + sprintf(prefix, "q%05d: weight %d sched %d ", fs->fs_nr, fs->weight, fs->parent_nr); print_flowset_parms(fs, prefix); list_queues(fs, q); @@ -384,7 +385,7 @@ ipfw_delete_pipe(int pipe_or_queue, int uint32_t a[1]; /* more if we want a list */ } cmd; oid_fill((void *)&cmd, sizeof(cmd), DN_CMD_DELETE, DN_API_VERSION); - cmd.oid.subtype = (co.do_pipe == 1) ? DN_PIPE : + cmd.oid.subtype = (co.do_pipe == 1) ? DN_LINK : ( (co.do_pipe == 2) ? DN_FS : DN_SCH); cmd.a[0] = i; i = do_cmd(IP_DUMMYNET3, &cmd, cmd.oid.len); @@ -424,7 +425,7 @@ ipfw_delete_pipe(int pipe_or_queue, int * The empirical curve may have both vertical and horizontal lines. * Vertical lines represent constant delay for a range of * probabilities; horizontal lines correspond to a discontinuty - * in the delay distribution: the pipe will use the largest delay + * in the delay distribution: the link will use the largest delay * for a given probability. * * To pass the curve to dummynet, we must store the parameters @@ -750,7 +751,7 @@ ipfw_config_pipe(int ac, char **av) void *par = NULL; struct dn_id *buf, *base; struct new_sch *sch = NULL; - struct new_pipe *p = NULL; + struct dn_link *p = NULL; struct new_fs *fs = NULL; struct new_profile *pf = NULL; struct ipfw_flow_id *mask = NULL; @@ -759,10 +760,10 @@ ipfw_config_pipe(int ac, char **av) /* * allocate space for 1 header, - * 1 scheduler, 1 pipe, 1 flowset, 1 profile + * 1 scheduler, 1 link, 1 flowset, 1 profile */ lmax = sizeof(struct dn_id); /* command header */ - lmax += sizeof(struct new_sch) + sizeof(struct new_pipe) + + lmax += sizeof(struct new_sch) + sizeof(struct dn_link) + sizeof(struct new_fs) + sizeof(struct new_profile); @@ -775,7 +776,7 @@ ipfw_config_pipe(int ac, char **av) errx(EX_USAGE, "need a pipe/flowset/sched number"); base = buf = calloc(1, lmax); if (buf == NULL) { - errx(1, "no memory for pipe buffer"); + errx(1, "no memory for buffer"); } /* all commands start with a 'CONFIGURE' and a version */ o_next(&buf, sizeof(struct dn_id), DN_CMD_CONFIGURE); @@ -792,10 +793,10 @@ ipfw_config_pipe(int ac, char **av) flags = &sch->flags; /* the FIFO scheduler is created in the kernel from the WFQ one */ - /* the WFQ pipe */ - p = o_next(&buf, sizeof(*p), DN_PIPE); - p->pipe_nr = i; - /* the FIFO pipe is created in the kerne from WFQ pipe */ + /* the WFQ link */ + p = o_next(&buf, sizeof(*p), DN_LINK); + p->link_nr = i; + /* the FIFO link is created in the kernel from WFQ link */ /* * FIFO flowsets N+i are automatically created for @@ -1033,14 +1034,14 @@ end_mask: break; case TOK_BW: - NEED(p, "bw is only for pipe"); + NEED(p, "bw is only for links"); NEED1("bw needs bandwidth or interface\n"); read_bandwidth(av[0], &p->bandwidth, NULL, 0); ac--; av++; break; case TOK_DELAY: - NEED(p, "delay is only for pipes"); + NEED(p, "delay is only for links"); NEED1("delay needs argument 0..10000ms\n"); p->delay = strtoul(av[0], NULL, 0); ac--; av++; @@ -1069,7 +1070,7 @@ end_mask: case TOK_SCHED: case TOK_PIPE: NEED(fs, "pipe/sched"); - NEED1("pipe needs pipe_number\n"); + NEED1("pipe/link/sched needs number\n"); fs->sched_nr = strtoul(av[0], &end, 0); ac--; av++; break; @@ -1237,7 +1238,7 @@ dummynet_list(int ac, char *av[], int sh oid.id = DN_API_VERSION; switch (co.do_pipe) { case 1: - oid.subtype = DN_PIPE; /* list pipe */ + oid.subtype = DN_LINK; /* list pipe */ break; case 2: oid.subtype = DN_FS; /* list queue */ Modified: user/luigi/ipfw3-head/sys/netinet/ip_dummynet.h ============================================================================== --- user/luigi/ipfw3-head/sys/netinet/ip_dummynet.h Thu Jan 21 13:15:14 2010 (r202747) +++ user/luigi/ipfw3-head/sys/netinet/ip_dummynet.h Thu Jan 21 13:21:06 2010 (r202748) @@ -63,7 +63,7 @@ struct dn_id { */ enum { DN_NONE = 0, - DN_PIPE = 1, + DN_LINK = 1, DN_FS, DN_SCH, DN_SCH_I, @@ -92,15 +92,15 @@ enum { /* user flags */ DN_HAVE_MASK = 0x0001, /* fs or sched has a mask */ DN_NOERROR = 0x0002, /* do not report errors */ DN_QSIZE_BYTES = 0x0008, /* queue size is in bytes */ - DN_HAS_PROFILE = 0x0010, /* a pipe has a profile */ + DN_HAS_PROFILE = 0x0010, /* a link has a profile */ DN_IS_RED = 0x0020, DN_IS_GENTLE_RED= 0x0040, }; /* - * pipe template. + * link template. */ -struct new_pipe { +struct dn_link { struct dn_id oid; /* @@ -108,7 +108,7 @@ struct new_pipe { * The kernel converts this back and forth to bits/tick and ticks. * XXX what about burst ? */ - int32_t pipe_nr; + int32_t link_nr; int bandwidth; /* bit/s or bits/tick. */ int delay; /* ms and ticks */ uint64_t burst; /* scaled. bits*Hz XXX */ @@ -170,14 +170,14 @@ struct new_sch { }; -/* A delay profile is attached to a pipe */ +/* A delay profile is attached to a link */ #define ED_MAX_SAMPLES_NO 1024 struct new_profile { struct dn_id oid; /* fields to simulate a delay profile */ #define ED_MAX_NAME_LEN 32 char name[ED_MAX_NAME_LEN]; - int pipe_nr; + int link_nr; int loss_level; int bandwidth; int samples_no; /* actual length of samples[] */ @@ -223,7 +223,7 @@ is no flow_mask, and each scheduler inst There are three data structures definining a pipe and associated queues: - + dn_pipe, which contains the main configuration parameters related + + dn_link, which contains the main configuration parameters related to delay and bandwidth; + dn_flowset, which contains flow masks, weights and queue parameters; Modified: user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_io.c ============================================================================== --- user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_io.c Thu Jan 21 13:15:14 2010 (r202747) +++ user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_io.c Thu Jan 21 13:21:06 2010 (r202748) @@ -69,8 +69,8 @@ __FBSDID("$FreeBSD$"); static uint64_t curr_time = 0; /* current simulation time */ struct dn_parms dn_cfg = { - .pipe_slot_limit = 100, /* Foot shooting limit for pipe queues. */ - .pipe_byte_limit = 1024 * 1024, + .slot_limit = 100, /* Foot shooting limit for queues. */ + .byte_limit = 1024 * 1024, .red_lookup_depth = 256, /* RED - default lookup table depth */ .red_avg_pkt_size = 512, /* RED - default medium packet size */ @@ -110,10 +110,10 @@ SYSCTL_NODE(_net_inet_ip, OID_AUTO, dumm SYSCTL_INT(_net_inet_ip_dummynet, OID_AUTO, hash_size, CTLFLAG_RW, &dn_cfg.hash_size, 0, "Default hash table size"); SYSCTL_LONG(_net_inet_ip_dummynet, OID_AUTO, pipe_slot_limit, - CTLFLAG_RW, &dn_cfg.pipe_slot_limit, 0, + CTLFLAG_RW, &dn_cfg.slot_limit, 0, "Upper limit in slots for pipe queue."); SYSCTL_LONG(_net_inet_ip_dummynet, OID_AUTO, pipe_byte_limit, - CTLFLAG_RW, &dn_cfg.pipe_byte_limit, 0, + CTLFLAG_RW, &dn_cfg.byte_limit, 0, "Upper limit in bytes for pipe queue."); SYSCTL_INT(_net_inet_ip_dummynet, OID_AUTO, io_fast, CTLFLAG_RW, &dn_cfg.io_fast, 0, "Enable fast dummynet io."); @@ -313,7 +313,7 @@ extra_bits(struct mbuf *m, struct new_sc if (!pf || pf->samples_no == 0) return 0; index = random() % pf->samples_no; - bits = div64((uint64_t)pf->samples[index] * s->pipe.bandwidth, 1000); + bits = div64((uint64_t)pf->samples[index] * s->link.bandwidth, 1000); if (index >= pf->loss_level) { struct dn_pkt_tag *dt = dn_tag_get(m); if (dt) @@ -340,7 +340,7 @@ serve_sched(struct mq *q, struct new_sch q->head = NULL; } - bw = s->pipe.bandwidth; + bw = s->link.bandwidth; si->kflags &= ~DN_ACTIVE; if (bw > 0) @@ -356,7 +356,7 @@ serve_sched(struct mq *q, struct new_sch (m->m_pkthdr.len * 8 + extra_bits(m, s)); si->credit -= len_scaled; /* Move packet in the delay line */ - dn_tag_get(m)->output_time += s->pipe.delay ; + dn_tag_get(m)->output_time += s->link.delay ; mq_append(&si->dline.mq, m); } /* @@ -633,7 +633,7 @@ dummynet_io(struct mbuf **m0, int dir, s /* compute the initial allowance */ { - struct new_pipe *p = &fs->sched->pipe; + struct dn_link *p = &fs->sched->link; si->credit = dn_cfg.io_fast ? p->bandwidth : 0; if (p->burst) { uint64_t burst = (curr_time - si->idle_time) * p->bandwidth; Modified: user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_private.h ============================================================================== --- user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_private.h Thu Jan 21 13:15:14 2010 (r202747) +++ user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dn_private.h Thu Jan 21 13:21:06 2010 (r202748) @@ -93,8 +93,8 @@ struct dn_parms { int red_max_pkt_size; int hash_size; int max_hash_size; - long pipe_byte_limit; - long pipe_slot_limit; + long byte_limit; /* max queue sizes */ + long slot_limit; int io_fast; @@ -137,7 +137,7 @@ struct dn_parms { }; /* - * Delay line, contains all packets on output from a pipe. + * Delay line, contains all packets on output from a link. * Every scheduler instance has one. */ struct delay_line { @@ -189,7 +189,7 @@ struct new_queue { /* * The kernel side of a scheduler. Contains the userland config, - * a pipe, pointer to extra config arguments from command line, + * a link, pointer to extra config arguments from command line, * kernel flags, and a pointer to the scheduler methods. * It is stored in a hash table, and holds a list of all * flowsets and scheduler instances. @@ -198,7 +198,7 @@ struct new_queue { struct new_schk { struct new_sch sch; struct dn_sched *fp; /* Pointer to scheduler functions */ - struct new_pipe pipe; /* the pipe is embedded */ + struct dn_link link; /* the link is embedded */ struct new_profile *profile; struct dn_id *cfg; /* extra config arguments */ @@ -225,7 +225,7 @@ struct new_sch_inst { int kflags; /* DN_ACTIVE */ int64_t credit; /* bits I can transmit (more or less). */ - uint64_t sched_time; /* time pipe was scheduled in ready_heap */ + uint64_t sched_time; /* time link was scheduled in ready_heap */ uint64_t idle_time; /* start of scheduler instance idle time */ }; Modified: user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dummynet.c ============================================================================== --- user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dummynet.c Thu Jan 21 13:15:14 2010 (r202747) +++ user/luigi/ipfw3-head/sys/netinet/ipfw/ip_dummynet.c Thu Jan 21 13:21:06 2010 (r202748) @@ -495,7 +495,7 @@ static int si_reset_credit(void *_si, void *arg) { struct new_sch_inst *si = _si; - struct new_pipe *p = &si->sched->pipe; + struct dn_link *p = &si->sched->link; si->credit = p->burst + (dn_cfg.io_fast ? p->bandwidth : 0); return 0; @@ -670,9 +670,9 @@ schk_new(uintptr_t key, int flags, void s = malloc(l, M_DUMMYNET, M_NOWAIT | M_ZERO); if (s == NULL) return NULL; - set_oid(&s->pipe.oid, DN_PIPE, sizeof(s->pipe)); + set_oid(&s->link.oid, DN_LINK, sizeof(s->link)); s->sch = *a->sch; // copy initial values - s->pipe.pipe_nr = s->sch.sched_nr; + s->link.link_nr = s->sch.sched_nr; SLIST_INIT(&s->fsk_list); /* initialize the hash table or create the single instance */ s->fp = a->fp; /* si_new needs this */ @@ -813,16 +813,16 @@ copy_data_helper(void *_o, void *_arg) { struct copy_args *a = _arg; - if (a->type == DN_PIPE || /* pipe show */ + if (a->type == DN_LINK || /* pipe show */ a->type == DN_SCH) { /* sched show */ struct new_schk *s = _o; /* we get only schedulers */ if (a->type == DN_SCH && s->sch.sched_nr >= DN_MAX_ID) return 0; /* not valid scheduler */ - if (a->type == DN_PIPE && s->sch.sched_nr <= DN_MAX_ID) + if (a->type == DN_LINK && s->sch.sched_nr <= DN_MAX_ID) return 0; /* not valid pipe */ if (a->flags & DN_C_PIPE) { - if (copy_obj(a->start, a->end, &s->pipe, - "pipe", s->sch.sched_nr)) + if (copy_obj(a->start, a->end, &s->link, + "link", s->sch.sched_nr)) return DNHT_SCAN_END; if (copy_flowset(a, s->fs, 0)) return DNHT_SCAN_END; @@ -896,7 +896,7 @@ update_fs(struct new_schk *s) /* * Configuration -- to preserve backward compatibility we use * the following scheme (N is 65536) - * NUMBER SCHED PIPE FLOWSET + * NUMBER SCHED LINK FLOWSET * 1 .. N-1 (1)WFQ (2)WFQ (3)queue * N+1 .. 2N-1 (4)FIFO (5)FIFO (6)FIFO for sched 1..N-1 * 2N+1 .. 3N-1 -- -- (7)FIFO for sched N+1..2N-1 @@ -916,10 +916,10 @@ update_fs(struct new_schk *s) */ /* - * configure a pipe (and its FIFO instance) + * configure a link (and its FIFO instance) */ static int -config_pipe(struct new_pipe *p, struct dn_id *arg) +config_link(struct dn_link *p, struct dn_id *arg) { int i; @@ -927,7 +927,7 @@ config_pipe(struct new_pipe *p, struct d D("invalid pipe len %d", p->oid.len); return EINVAL; } - i = p->pipe_nr; + i = p->link_nr; if (i <= 0 || i >= DN_MAX_ID) return EINVAL; /* @@ -942,7 +942,7 @@ config_pipe(struct new_pipe *p, struct d p->burst *= 8 * hz; DN_BH_WLOCK(); - /* do it twice, base pipe and FIFO pipe */ + /* do it twice, base link and FIFO link */ for (; i < 2*DN_MAX_ID; i += DN_MAX_ID) { struct new_schk *s = locate_scheduler(i); if (s == NULL) { @@ -951,11 +951,11 @@ config_pipe(struct new_pipe *p, struct d return EINVAL; } /* copy all parameters */ - s->pipe.oid = p->oid; - s->pipe.pipe_nr = i; - s->pipe.delay = p->delay; - s->pipe.bandwidth = p->bandwidth; - s->pipe.burst = p->burst; + s->link.oid = p->oid; + s->link.link_nr = i; + s->link.delay = p->delay; + s->link.bandwidth = p->bandwidth; + s->link.burst = p->burst; schk_reset_credit(s); } dn_cfg.id++; @@ -982,13 +982,11 @@ config_fs(struct new_fs *nfs, struct dn_ ND("flowset %d", i); /* XXX other sanity checks */ if (nfs->flags & DN_QSIZE_BYTES) { - if (nfs->qsize > dn_cfg.pipe_byte_limit) - nfs->qsize = dn_cfg.pipe_byte_limit; + bound_var(&nfs->qsize, 16384, + 1500, dn_cfg.byte_limit, "queue byte size"); } else { - if (nfs->qsize == 0) - nfs->qsize = 50; - if (nfs->qsize > dn_cfg.pipe_slot_limit) - nfs->qsize = dn_cfg.pipe_slot_limit; + bound_var(&nfs->qsize, 50, + 1, dn_cfg.slot_limit, "queue slot size"); } if (nfs->flags & DN_HAVE_MASK) { /* make sure we have some buckets */ @@ -1046,7 +1044,7 @@ config_fs(struct new_fs *nfs, struct dn_ * For !MULTIQUEUE schedulers, also set up the flowset. * * On reconfigurations (detected because s->fp is set), - * detach existing flowsets preserving traffic, preserve pipe, + * detach existing flowsets preserving traffic, preserve link, * and delete the old scheduler creating a new one. */ static int @@ -1055,7 +1053,7 @@ config_sched(struct new_sch *_nsch, stru struct new_schk *s; struct schk_new_arg a; /* argument for schk_new */ int i; - struct new_pipe p; /* copy of oldpipe */ + struct dn_link p; /* copy of oldlink */ a.sch = _nsch; if (a.sch->oid.len != sizeof(*a.sch)) { @@ -1106,10 +1104,10 @@ again: /* run twice, for wfq and fifo */ D("cannot allocate scheduler %d", i); return ENOMEM; } - /* restore existing pipe if any */ - if (p.pipe_nr) - s->pipe = p; - p.pipe_nr = 0; + /* restore existing link if any */ + if (p.link_nr) + s->link = p; + p.link_nr = 0; if (s->fp == NULL) { D("sched %d new type %s", i, a.fp->name); } else if (s->fp != a.fp || @@ -1120,9 +1118,9 @@ again: /* run twice, for wfq and fifo */ D(" type/sub %d/%d -> %d/%d", s->sch.oid.type, s->sch.oid.subtype, a.sch->oid.type, a.sch->oid.subtype); - if (s->pipe.pipe_nr == 0) - D("XXX WARNING pipe 0 for sched %d", i); - p = s->pipe; /* preserve pipe */ + if (s->link.link_nr == 0) + D("XXX WARNING link 0 for sched %d", i); + p = s->link; /* preserve link */ /* remove from the hash */ dn_ht_find(dn_cfg.schedhash, i, DNHT_REMOVE, NULL); /* Detach flowsets, preserve queues. */ @@ -1174,7 +1172,7 @@ again: /* run twice, for wfq and fifo */ } /* - * attach a profile to a pipe + * attach a profile to a link */ static int config_profile(struct new_profile *pf, struct dn_id *arg) @@ -1186,7 +1184,7 @@ config_profile(struct new_profile *pf, s D("short profile len %d", pf->oid.len); return EINVAL; } - i = pf->pipe_nr; + i = pf->link_nr; if (i <= 0 || i >= DN_MAX_ID) return EINVAL; /* XXX other sanity checks */ @@ -1240,7 +1238,7 @@ static void dummynet_flush(void) { - /* delete all schedulers and related pipes/queues/flowsets */ + /* delete all schedulers and related links/queues/flowsets */ dn_ht_scan(dn_cfg.schedhash, schk_delete_cb, (void *)(uintptr_t)DN_DELETE_FS); /* delete all remaining (unlinked) flowsets */ @@ -1255,7 +1253,7 @@ dummynet_flush(void) * Main handler for configuration. We are guaranteed to be called * with an oid which is at least a dn_id. * - the first object is the command (config, delete, flush, ...) - * - config_pipe must be issued after the corresponding config_sched + * - config_link must be issued after the corresponding config_sched * - parameters (DN_TXT) for an object must preceed the object * processed on a config_sched. */ @@ -1293,7 +1291,7 @@ do_config(void *p, int l) case DN_CMD_DELETE: switch (o->subtype) { - case DN_PIPE: + case DN_LINK: /* delete base and derived schedulers */ DN_BH_WLOCK(); err = delete_schk(o->id); @@ -1325,8 +1323,8 @@ do_config(void *p, int l) prev = NULL; arg = o; break; - case DN_PIPE: - err = config_pipe((struct new_pipe *)o, arg); + case DN_LINK: + err = config_link((struct dn_link *)o, arg); break; case DN_PROFILE: err = config_profile((struct new_profile *)o, arg); @@ -1354,7 +1352,7 @@ compute_space(struct dn_id *cmd, int *to switch (cmd->subtype) { default: return -1; - case DN_PIPE: /* pipe show */ + case DN_LINK: /* pipe show */ x = DN_C_PIPE | DN_C_FS | DN_SCH | DN_C_SCH_INST; break; case DN_SCH: /* sched show */ @@ -1370,7 +1368,7 @@ compute_space(struct dn_id *cmd, int *to if (x & DN_C_FS) need += dn_cfg.fsk_count * sizeof(struct new_fs); if (x & DN_C_PIPE) - need += dn_cfg.schk_count * sizeof(struct new_pipe); + need += dn_cfg.schk_count * sizeof(struct dn_link); /* XXX queue space might be variable */ if (x & DN_C_QUEUE) need += dn_cfg.queue_count * sizeof(struct new_queue); @@ -1422,10 +1420,10 @@ dummynet_get(struct sockopt *sopt) } if (start == NULL) return sooptcopyout(sopt, &cmd, sizeof(cmd)); - ND("have %d:%d sched %d, %d:%d pipes %d, %d:%d flows %d, " + ND("have %d:%d sched %d, %d:%d links %d, %d:%d flows %d, " "%d:%d si %d, %d:%d queues %d", dn_cfg.schk_count, sizeof(struct new_sch), DN_SCH, - dn_cfg.schk_count, sizeof(struct new_pipe), DN_PIPE, + dn_cfg.schk_count, sizeof(struct dn_link), DN_LINK, dn_cfg.fsk_count, sizeof(struct new_fs), DN_FS, dn_cfg.si_count, sizeof(struct new_inst), DN_SCH_I, dn_cfg.queue_count, sizeof(struct new_queue), DN_QUEUE);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001211321.o0LDL6bc038043>