ng_async.c (68876) | ng_async.c (69922) |
---|---|
1 2/* 3 * ng_async.c 4 * 5 * Copyright (c) 1996-1999 Whistle Communications, Inc. 6 * All rights reserved. 7 * 8 * Subject to the following obligations and disclaimer of warranty, use and --- 22 unchanged lines hidden (view full) --- 31 * SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY 32 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 33 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 34 * THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY 35 * OF SUCH DAMAGE. 36 * 37 * Author: Archie Cobbs <archie@freebsd.org> 38 * | 1 2/* 3 * ng_async.c 4 * 5 * Copyright (c) 1996-1999 Whistle Communications, Inc. 6 * All rights reserved. 7 * 8 * Subject to the following obligations and disclaimer of warranty, use and --- 22 unchanged lines hidden (view full) --- 31 * SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY 32 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 33 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 34 * THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY 35 * OF SUCH DAMAGE. 36 * 37 * Author: Archie Cobbs <archie@freebsd.org> 38 * |
39 * $FreeBSD: head/sys/netgraph/ng_async.c 68876 2000-11-18 15:17:43Z dwmalone $ | 39 * $FreeBSD: head/sys/netgraph/ng_async.c 69922 2000-12-12 18:52:14Z julian $ |
40 * $Whistle: ng_async.c,v 1.17 1999/11/01 09:24:51 julian Exp $ 41 */ 42 43/* 44 * This node type implements a PPP style sync <-> async converter. 45 * See RFC 1661 for details of how asynchronous encoding works. 46 */ 47 --- 105 unchanged lines hidden (view full) --- 153 NULL, 154 nga_constructor, 155 nga_rcvmsg, 156 nga_shutdown, 157 nga_newhook, 158 NULL, 159 NULL, 160 nga_rcvdata, | 40 * $Whistle: ng_async.c,v 1.17 1999/11/01 09:24:51 julian Exp $ 41 */ 42 43/* 44 * This node type implements a PPP style sync <-> async converter. 45 * See RFC 1661 for details of how asynchronous encoding works. 46 */ 47 --- 105 unchanged lines hidden (view full) --- 153 NULL, 154 nga_constructor, 155 nga_rcvmsg, 156 nga_shutdown, 157 nga_newhook, 158 NULL, 159 NULL, 160 nga_rcvdata, |
161 nga_rcvdata, | |
162 nga_disconnect, 163 nga_cmdlist 164}; 165NETGRAPH_INIT(async, &typestruct); 166 167/* CRC table */ 168static const u_int16_t fcstab[]; 169 --- 57 unchanged lines hidden (view full) --- 227 return (0); 228} 229 230/* 231 * Receive incoming data 232 */ 233static int 234nga_rcvdata(hook_p hook, struct mbuf *m, meta_p meta, | 161 nga_disconnect, 162 nga_cmdlist 163}; 164NETGRAPH_INIT(async, &typestruct); 165 166/* CRC table */ 167static const u_int16_t fcstab[]; 168 --- 57 unchanged lines hidden (view full) --- 226 return (0); 227} 228 229/* 230 * Receive incoming data 231 */ 232static int 233nga_rcvdata(hook_p hook, struct mbuf *m, meta_p meta, |
235 struct mbuf **ret_m, meta_p *ret_meta) | 234 struct mbuf **ret_m, meta_p *ret_meta, struct ng_mesg **resp) |
236{ 237 const sc_p sc = hook->node->private; 238 239 if (hook == sc->sync) 240 return (nga_rcv_sync(sc, m, meta)); 241 if (hook == sc->async) 242 return (nga_rcv_async(sc, m, meta)); 243 panic(__FUNCTION__); --- 371 unchanged lines hidden --- | 235{ 236 const sc_p sc = hook->node->private; 237 238 if (hook == sc->sync) 239 return (nga_rcv_sync(sc, m, meta)); 240 if (hook == sc->async) 241 return (nga_rcv_async(sc, m, meta)); 242 panic(__FUNCTION__); --- 371 unchanged lines hidden --- |