Deleted Added
full compact
if_llatbl.c (191221) if_llatbl.c (192476)
1/*
2 * Copyright (c) 2004 Luigi Rizzo, Alessandro Cerri. All rights reserved.
3 * Copyright (c) 2004-2008 Qing Li. All rights reserved.
4 * Copyright (c) 2008 Kip Macy. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 11 unchanged lines hidden (view full) ---

20 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25 * SUCH DAMAGE.
26 */
27#include <sys/cdefs.h>
1/*
2 * Copyright (c) 2004 Luigi Rizzo, Alessandro Cerri. All rights reserved.
3 * Copyright (c) 2004-2008 Qing Li. All rights reserved.
4 * Copyright (c) 2008 Kip Macy. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 11 unchanged lines hidden (view full) ---

20 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25 * SUCH DAMAGE.
26 */
27#include <sys/cdefs.h>
28__FBSDID("$FreeBSD: head/sys/net/if_llatbl.c 191221 2009-04-17 18:48:50Z kmacy $");
28__FBSDID("$FreeBSD: head/sys/net/if_llatbl.c 192476 2009-05-20 21:07:15Z qingli $");
29
30#include "opt_inet.h"
31#include "opt_inet6.h"
32
33#include <sys/param.h>
34#include <sys/systm.h>
35#include <sys/malloc.h>
36#include <sys/mbuf.h>

--- 153 unchanged lines hidden (view full) ---

190 lle->la_hold = NULL;
191 }
192 }
193 }
194 }
195 IFNET_RUNLOCK();
196}
197
29
30#include "opt_inet.h"
31#include "opt_inet6.h"
32
33#include <sys/param.h>
34#include <sys/systm.h>
35#include <sys/malloc.h>
36#include <sys/mbuf.h>

--- 153 unchanged lines hidden (view full) ---

190 lle->la_hold = NULL;
191 }
192 }
193 }
194 }
195 IFNET_RUNLOCK();
196}
197
198void
199lltable_prefix_free(int af, struct sockaddr *prefix, struct sockaddr *mask)
200{
201 struct lltable *llt;
202
203 IFNET_RLOCK();
204 SLIST_FOREACH(llt, &lltables, llt_link) {
205 if (llt->llt_af != af)
206 continue;
207
208 llt->llt_prefix_free(llt, prefix, mask);
209 }
210 IFNET_RUNLOCK();
211}
212
213
214
198/*
199 * Create a new lltable.
200 */
201struct lltable *
202lltable_init(struct ifnet *ifp, int af)
203{
204 struct lltable *llt;
205 register int i;

--- 146 unchanged lines hidden ---
215/*
216 * Create a new lltable.
217 */
218struct lltable *
219lltable_init(struct ifnet *ifp, int af)
220{
221 struct lltable *llt;
222 register int i;

--- 146 unchanged lines hidden ---