ng_gif.c (87599) | ng_gif.c (108172) |
---|---|
1/* 2 * ng_gif.c 3 * 4 * Copyright 2001 The Aerospace Corporation. 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: --- 46 unchanged lines hidden (view full) --- 55 * WITHOUT LIMITATION, ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 56 * PUNITIVE, OR CONSEQUENTIAL DAMAGES, PROCUREMENT OF SUBSTITUTE GOODS OR 57 * SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY 58 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 59 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 60 * THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY 61 * OF SUCH DAMAGE. 62 * | 1/* 2 * ng_gif.c 3 * 4 * Copyright 2001 The Aerospace Corporation. 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: --- 46 unchanged lines hidden (view full) --- 55 * WITHOUT LIMITATION, ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 56 * PUNITIVE, OR CONSEQUENTIAL DAMAGES, PROCUREMENT OF SUBSTITUTE GOODS OR 57 * SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY 58 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 59 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 60 * THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY 61 * OF SUCH DAMAGE. 62 * |
63 * $FreeBSD: head/sys/netgraph/ng_gif.c 87599 2001-12-10 08:09:49Z obrien $ | 63 * $FreeBSD: head/sys/netgraph/ng_gif.c 108172 2002-12-22 05:35:03Z hsu $ |
64 */ 65 66/* 67 * ng_gif(4) netgraph node type 68 */ 69 70#include <sys/param.h> 71#include <sys/systm.h> --- 487 unchanged lines hidden (view full) --- 559 break; 560 } 561 ng_gif_attach_p = ng_gif_attach; 562 ng_gif_detach_p = ng_gif_detach; 563 ng_gif_input_p = ng_gif_input; 564 ng_gif_input_orphan_p = ng_gif_input_orphan; 565 566 /* Create nodes for any already-existing gif interfaces */ | 64 */ 65 66/* 67 * ng_gif(4) netgraph node type 68 */ 69 70#include <sys/param.h> 71#include <sys/systm.h> --- 487 unchanged lines hidden (view full) --- 559 break; 560 } 561 ng_gif_attach_p = ng_gif_attach; 562 ng_gif_detach_p = ng_gif_detach; 563 ng_gif_input_p = ng_gif_input; 564 ng_gif_input_orphan_p = ng_gif_input_orphan; 565 566 /* Create nodes for any already-existing gif interfaces */ |
567 IFNET_RLOCK(); |
|
567 TAILQ_FOREACH(ifp, &ifnet, if_link) { 568 if (ifp->if_type == IFT_GIF) 569 ng_gif_attach(ifp); 570 } | 568 TAILQ_FOREACH(ifp, &ifnet, if_link) { 569 if (ifp->if_type == IFT_GIF) 570 ng_gif_attach(ifp); 571 } |
572 IFNET_RUNLOCK(); |
|
571 break; 572 573 case MOD_UNLOAD: 574 575 /* 576 * Note that the base code won't try to unload us until 577 * all nodes have been removed, and that can't happen 578 * until all gif interfaces are destroyed. In any --- 21 unchanged lines hidden --- | 573 break; 574 575 case MOD_UNLOAD: 576 577 /* 578 * Note that the base code won't try to unload us until 579 * all nodes have been removed, and that can't happen 580 * until all gif interfaces are destroyed. In any --- 21 unchanged lines hidden --- |