Symbol: tnbr
usr.sbin/ldpd/adjacency.c
200
struct tnbr *
usr.sbin/ldpd/adjacency.c
203
struct tnbr *tnbr;
usr.sbin/ldpd/adjacency.c
205
if ((tnbr = calloc(1, sizeof(*tnbr))) == NULL)
usr.sbin/ldpd/adjacency.c
208
tnbr->af = af;
usr.sbin/ldpd/adjacency.c
209
tnbr->addr = *addr;
usr.sbin/ldpd/adjacency.c
210
tnbr->state = TNBR_STA_DOWN;
usr.sbin/ldpd/adjacency.c
211
tnbr->hello_holdtime = (ldp_af_conf_get(xconf, af))->thello_holdtime;
usr.sbin/ldpd/adjacency.c
212
tnbr->hello_interval = (ldp_af_conf_get(xconf, af))->thello_interval;
usr.sbin/ldpd/adjacency.c
214
return (tnbr);
usr.sbin/ldpd/adjacency.c
218
tnbr_del(struct tnbr *tnbr)
usr.sbin/ldpd/adjacency.c
220
tnbr_stop_hello_timer(tnbr);
usr.sbin/ldpd/adjacency.c
221
if (tnbr->adj)
usr.sbin/ldpd/adjacency.c
222
adj_del(tnbr->adj, S_SHUTDOWN);
usr.sbin/ldpd/adjacency.c
223
LIST_REMOVE(tnbr, entry);
usr.sbin/ldpd/adjacency.c
224
free(tnbr);
usr.sbin/ldpd/adjacency.c
227
struct tnbr *
usr.sbin/ldpd/adjacency.c
230
struct tnbr *tnbr;
usr.sbin/ldpd/adjacency.c
232
LIST_FOREACH(tnbr, &xconf->tnbr_list, entry)
usr.sbin/ldpd/adjacency.c
233
if (af == tnbr->af &&
usr.sbin/ldpd/adjacency.c
234
ldp_addrcmp(af, addr, &tnbr->addr) == 0)
usr.sbin/ldpd/adjacency.c
235
return (tnbr);
usr.sbin/ldpd/adjacency.c
240
struct tnbr *
usr.sbin/ldpd/adjacency.c
241
tnbr_check(struct tnbr *tnbr)
usr.sbin/ldpd/adjacency.c
243
if (!(tnbr->flags & (F_TNBR_CONFIGURED|F_TNBR_DYNAMIC)) &&
usr.sbin/ldpd/adjacency.c
244
tnbr->pw_count == 0) {
usr.sbin/ldpd/adjacency.c
245
tnbr_del(tnbr);
usr.sbin/ldpd/adjacency.c
249
return (tnbr);
usr.sbin/ldpd/adjacency.c
253
tnbr_update(struct tnbr *tnbr)
usr.sbin/ldpd/adjacency.c
257
if ((ldp_af_global_get(&global, tnbr->af))->ldp_edisc_socket != -1)
usr.sbin/ldpd/adjacency.c
267
if (tnbr->state == TNBR_STA_DOWN) {
usr.sbin/ldpd/adjacency.c
271
tnbr->state = TNBR_STA_ACTIVE;
usr.sbin/ldpd/adjacency.c
272
send_hello(HELLO_TARGETED, NULL, tnbr);
usr.sbin/ldpd/adjacency.c
274
evtimer_set(&tnbr->hello_timer, tnbr_hello_timer, tnbr);
usr.sbin/ldpd/adjacency.c
275
tnbr_start_hello_timer(tnbr);
usr.sbin/ldpd/adjacency.c
276
} else if (tnbr->state == TNBR_STA_ACTIVE) {
usr.sbin/ldpd/adjacency.c
280
tnbr->state = TNBR_STA_DOWN;
usr.sbin/ldpd/adjacency.c
281
tnbr_stop_hello_timer(tnbr);
usr.sbin/ldpd/adjacency.c
288
struct tnbr *tnbr;
usr.sbin/ldpd/adjacency.c
291
LIST_FOREACH(tnbr, &leconf->tnbr_list, entry)
usr.sbin/ldpd/adjacency.c
292
if (tnbr->af == af || af == AF_UNSPEC)
usr.sbin/ldpd/adjacency.c
293
tnbr_update(tnbr);
usr.sbin/ldpd/adjacency.c
301
struct tnbr *tnbr = arg;
usr.sbin/ldpd/adjacency.c
303
send_hello(HELLO_TARGETED, NULL, tnbr);
usr.sbin/ldpd/adjacency.c
304
tnbr_start_hello_timer(tnbr);
usr.sbin/ldpd/adjacency.c
308
tnbr_start_hello_timer(struct tnbr *tnbr)
usr.sbin/ldpd/adjacency.c
313
tv.tv_sec = tnbr->hello_interval;
usr.sbin/ldpd/adjacency.c
314
if (evtimer_add(&tnbr->hello_timer, &tv) == -1)
usr.sbin/ldpd/adjacency.c
319
tnbr_stop_hello_timer(struct tnbr *tnbr)
usr.sbin/ldpd/adjacency.c
321
if (evtimer_pending(&tnbr->hello_timer, NULL) &&
usr.sbin/ldpd/adjacency.c
322
evtimer_del(&tnbr->hello_timer) == -1)
usr.sbin/ldpd/adjacency.c
33
static void tnbr_del(struct tnbr *);
usr.sbin/ldpd/adjacency.c
35
static void tnbr_start_hello_timer(struct tnbr *);
usr.sbin/ldpd/adjacency.c
36
static void tnbr_stop_hello_timer(struct tnbr *);
usr.sbin/ldpd/hello.c
165
struct tnbr *tnbr = NULL;
usr.sbin/ldpd/hello.c
246
tnbr = tnbr_find(leconf, af, src);
usr.sbin/ldpd/hello.c
249
if (tnbr && (tnbr->flags & F_TNBR_DYNAMIC) &&
usr.sbin/ldpd/hello.c
251
tnbr->flags &= ~F_TNBR_DYNAMIC;
usr.sbin/ldpd/hello.c
252
tnbr = tnbr_check(tnbr);
usr.sbin/ldpd/hello.c
255
if (!tnbr) {
usr.sbin/ldpd/hello.c
261
tnbr = tnbr_new(leconf, af, src);
usr.sbin/ldpd/hello.c
262
tnbr->flags |= F_TNBR_DYNAMIC;
usr.sbin/ldpd/hello.c
263
tnbr_update(tnbr);
usr.sbin/ldpd/hello.c
264
LIST_INSERT_HEAD(&leconf->tnbr_list, tnbr, entry);
usr.sbin/ldpd/hello.c
268
source.target = tnbr;
usr.sbin/ldpd/hello.c
37
send_hello(enum hello_type type, struct iface_af *ia, struct tnbr *tnbr)
usr.sbin/ldpd/hello.c
397
adj->holdtime = min(tnbr->hello_holdtime, holdtime);
usr.sbin/ldpd/hello.c
68
af = tnbr->af;
usr.sbin/ldpd/hello.c
69
holdtime = tnbr->hello_holdtime;
usr.sbin/ldpd/hello.c
71
if ((tnbr->flags & F_TNBR_CONFIGURED) || tnbr->pw_count)
usr.sbin/ldpd/hello.c
76
dst = tnbr->addr;
usr.sbin/ldpd/l2vpn.c
584
struct tnbr *tnbr;
usr.sbin/ldpd/l2vpn.c
586
tnbr = tnbr_find(leconf, pw->af, &pw->addr);
usr.sbin/ldpd/l2vpn.c
587
if (tnbr == NULL) {
usr.sbin/ldpd/l2vpn.c
588
tnbr = tnbr_new(leconf, pw->af, &pw->addr);
usr.sbin/ldpd/l2vpn.c
589
tnbr_update(tnbr);
usr.sbin/ldpd/l2vpn.c
590
LIST_INSERT_HEAD(&leconf->tnbr_list, tnbr, entry);
usr.sbin/ldpd/l2vpn.c
593
tnbr->pw_count++;
usr.sbin/ldpd/l2vpn.c
599
struct tnbr *tnbr;
usr.sbin/ldpd/l2vpn.c
601
tnbr = tnbr_find(leconf, pw->af, &pw->addr);
usr.sbin/ldpd/l2vpn.c
602
if (tnbr) {
usr.sbin/ldpd/l2vpn.c
603
tnbr->pw_count--;
usr.sbin/ldpd/l2vpn.c
604
tnbr_check(tnbr);
usr.sbin/ldpd/lde.c
386
struct tnbr *ntnbr;
usr.sbin/ldpd/lde.c
503
if ((ntnbr = malloc(sizeof(struct tnbr))) == NULL)
usr.sbin/ldpd/lde.c
505
memcpy(ntnbr, imsg.data, sizeof(struct tnbr));
usr.sbin/ldpd/ldpd.c
697
struct tnbr *tnbr;
usr.sbin/ldpd/ldpd.c
720
LIST_FOREACH(tnbr, &xconf->tnbr_list, entry) {
usr.sbin/ldpd/ldpd.c
721
if (main_imsg_compose_both(IMSG_RECONF_TNBR, tnbr,
usr.sbin/ldpd/ldpd.c
722
sizeof(*tnbr)) == -1)
usr.sbin/ldpd/ldpd.c
929
struct tnbr *tnbr, *ttmp, *xt;
usr.sbin/ldpd/ldpd.c
931
LIST_FOREACH_SAFE(tnbr, &conf->tnbr_list, entry, ttmp) {
usr.sbin/ldpd/ldpd.c
932
if (!(tnbr->flags & F_TNBR_CONFIGURED))
usr.sbin/ldpd/ldpd.c
936
if ((xt = tnbr_find(xconf, tnbr->af, &tnbr->addr)) == NULL) {
usr.sbin/ldpd/ldpd.c
938
tnbr->flags &= ~F_TNBR_CONFIGURED;
usr.sbin/ldpd/ldpd.c
939
tnbr_check(tnbr);
usr.sbin/ldpd/ldpd.c
941
LIST_REMOVE(tnbr, entry);
usr.sbin/ldpd/ldpd.c
942
free(tnbr);
usr.sbin/ldpd/ldpd.c
948
if ((tnbr = tnbr_find(conf, xt->af, &xt->addr)) == NULL) {
usr.sbin/ldpd/ldpd.c
958
if (!(tnbr->flags & F_TNBR_CONFIGURED))
usr.sbin/ldpd/ldpd.c
959
tnbr->flags |= F_TNBR_CONFIGURED;
usr.sbin/ldpd/ldpd.c
960
tnbr->hello_holdtime = xt->hello_holdtime;
usr.sbin/ldpd/ldpd.c
961
tnbr->hello_interval = xt->hello_interval;
usr.sbin/ldpd/ldpd.h
291
LIST_ENTRY(tnbr) entry;
usr.sbin/ldpd/ldpd.h
409
LIST_HEAD(, tnbr) tnbr_list;
usr.sbin/ldpd/ldpe.c
217
struct tnbr *ntnbr;
usr.sbin/ldpd/ldpe.c
412
if ((ntnbr = malloc(sizeof(struct tnbr))) == NULL)
usr.sbin/ldpd/ldpe.c
414
memcpy(ntnbr, imsg.data, sizeof(struct tnbr));
usr.sbin/ldpd/ldpe.c
717
struct tnbr *tnbr, *safe;
usr.sbin/ldpd/ldpe.c
719
LIST_FOREACH_SAFE(tnbr, &leconf->tnbr_list, entry, safe) {
usr.sbin/ldpd/ldpe.c
720
if (tnbr->af != af)
usr.sbin/ldpd/ldpe.c
723
tnbr->flags &= ~F_TNBR_DYNAMIC;
usr.sbin/ldpd/ldpe.c
724
tnbr_check(tnbr);
usr.sbin/ldpd/ldpe.h
156
int send_hello(enum hello_type, struct iface_af *, struct tnbr *);
usr.sbin/ldpd/ldpe.h
230
struct tnbr *tnbr_new(struct ldpd_conf *, int, union ldpd_addr *);
usr.sbin/ldpd/ldpe.h
231
struct tnbr *tnbr_find(struct ldpd_conf *, int, union ldpd_addr *);
usr.sbin/ldpd/ldpe.h
232
struct tnbr *tnbr_check(struct tnbr *);
usr.sbin/ldpd/ldpe.h
233
void tnbr_update(struct tnbr *);
usr.sbin/ldpd/ldpe.h
41
struct tnbr *target;
usr.sbin/ldpd/parse.y
106
static struct tnbr *conf_get_tnbr(union ldpd_addr *);
usr.sbin/ldpd/parse.y
128
static struct tnbr *tnbr;
usr.sbin/ldpd/parse.y
1469
static struct tnbr *
usr.sbin/ldpd/parse.y
1472
struct tnbr *t;
usr.sbin/ldpd/parse.y
1596
struct tnbr *t;
usr.sbin/ldpd/parse.y
819
tnbr = conf_get_tnbr(&addr);
usr.sbin/ldpd/parse.y
820
if (tnbr == NULL)
usr.sbin/ldpd/parse.y
826
tnbr->hello_holdtime = defs->thello_holdtime;
usr.sbin/ldpd/parse.y
827
tnbr->hello_interval = defs->thello_interval;
usr.sbin/ldpd/parse.y
828
tnbr = NULL;
usr.sbin/ldpd/printconf.c
112
print_tnbr(struct tnbr *tnbr)
usr.sbin/ldpd/printconf.c
114
printf("\n\ttargeted-neighbor %s {\n", log_addr(tnbr->af, &tnbr->addr));
usr.sbin/ldpd/printconf.c
115
printf("\t\ttargeted-hello-holdtime %u\n", tnbr->hello_holdtime);
usr.sbin/ldpd/printconf.c
116
printf("\t\ttargeted-hello-interval %u\n", tnbr->hello_interval);
usr.sbin/ldpd/printconf.c
35
static void print_tnbr(struct tnbr *);
usr.sbin/ldpd/printconf.c
67
struct tnbr *tnbr;
usr.sbin/ldpd/printconf.c
95
LIST_FOREACH(tnbr, &conf->tnbr_list, entry)
usr.sbin/ldpd/printconf.c
96
if (tnbr->af == af && tnbr->flags & F_TNBR_CONFIGURED)
usr.sbin/ldpd/printconf.c
97
print_tnbr(tnbr);