Deleted Added
full compact
if_ic.c (111119) if_ic.c (111888)
1/*-
2 * Copyright (c) 1998, 2001 Nicolas Souchu
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
1/*-
2 * Copyright (c) 1998, 2001 Nicolas Souchu
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $FreeBSD: head/sys/dev/iicbus/if_ic.c 111119 2003-02-19 05:47:46Z imp $
26 * $FreeBSD: head/sys/dev/iicbus/if_ic.c 111888 2003-03-04 23:19:55Z jlemon $
27 */
28
29/*
30 * I2C bus IP driver
31 */
32
33#include <sys/param.h>
34#include <sys/systm.h>

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

309 len -= ICHDRLEN;
310 sc->ic_if.if_ipackets ++;
311 sc->ic_if.if_ibytes += len;
312
313 BPF_TAP(&sc->ic_if, sc->ic_ifbuf, len + ICHDRLEN);
314
315 top = m_devget(sc->ic_ifbuf + ICHDRLEN, len, 0, &sc->ic_if, 0);
316
27 */
28
29/*
30 * I2C bus IP driver
31 */
32
33#include <sys/param.h>
34#include <sys/systm.h>

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

309 len -= ICHDRLEN;
310 sc->ic_if.if_ipackets ++;
311 sc->ic_if.if_ibytes += len;
312
313 BPF_TAP(&sc->ic_if, sc->ic_ifbuf, len + ICHDRLEN);
314
315 top = m_devget(sc->ic_ifbuf + ICHDRLEN, len, 0, &sc->ic_if, 0);
316
317 if (top) {
318 if (IF_HANDOFF(&ipintrq, top, NULL))
319 schednetisr(NETISR_IP);
320 }
317 if (top)
318 netisr_dispatch(NETISR_IP, top);
321 break;
322
323 err:
324 printf("ic%d: errors (%d)!\n", unit, sc->ic_iferrs);
325
326 sc->ic_iferrs = 0; /* reset error count */
327 sc->ic_if.if_ierrors ++;
328

--- 123 unchanged lines hidden ---
319 break;
320
321 err:
322 printf("ic%d: errors (%d)!\n", unit, sc->ic_iferrs);
323
324 sc->ic_iferrs = 0; /* reset error count */
325 sc->ic_if.if_ierrors ++;
326

--- 123 unchanged lines hidden ---