Index: netinet/ip_carp.c =================================================================== RCS file: /cvs/src/sys/netinet/ip_carp.c,v retrieving revision 1.286 diff -u -p -r1.286 ip_carp.c --- netinet/ip_carp.c 21 Jan 2016 11:23:48 -0000 1.286 +++ netinet/ip_carp.c 21 Feb 2016 11:56:17 -0000 @@ -1429,7 +1429,7 @@ carp_input(struct ifnet *ifp0, struct mb if (!(sc->sc_if.if_flags & IFF_UP)) continue; - m0 = m_copym2(m, 0, M_COPYALL, M_DONTWAIT); + m0 = m_dup_pkt(m, ETHER_ALIGN, M_DONTWAIT); if (m0 == NULL) continue; Index: sys/mbuf.h =================================================================== RCS file: /cvs/src/sys/sys/mbuf.h,v retrieving revision 1.207 diff -u -p -r1.207 mbuf.h --- sys/mbuf.h 31 Jan 2016 00:18:07 -0000 1.207 +++ sys/mbuf.h 21 Feb 2016 11:56:17 -0000 @@ -447,6 +447,7 @@ void m_cat(struct mbuf *, struct mbuf *) struct mbuf *m_devget(char *, int, int); int m_apply(struct mbuf *, int, int, int (*)(caddr_t, caddr_t, unsigned int), caddr_t); +struct mbuf *m_dup_pkt(struct mbuf *, unsigned int, int); int m_dup_pkthdr(struct mbuf *, struct mbuf *, int); /* Packet tag routines */ Index: kern/uipc_mbuf.c =================================================================== RCS file: /cvs/src/sys/kern/uipc_mbuf.c,v retrieving revision 1.218 diff -u -p -r1.218 uipc_mbuf.c --- kern/uipc_mbuf.c 31 Jan 2016 00:18:07 -0000 1.218 +++ kern/uipc_mbuf.c 21 Feb 2016 11:56:17 -0000 @@ -1213,6 +1213,40 @@ m_dup_pkthdr(struct mbuf *to, struct mbu return (0); } +struct mbuf * +m_dup_pkt(struct mbuf *m0, unsigned int adj, int wait) +{ + struct mbuf *m; + int len; + + len = m0->m_pkthdr.len + adj; + if (len > MAXMCLBYTES) /* XXX */ + return (NULL); + + m = m_get(m0->m_type, wait); + if (m == NULL) + return (NULL); + + if (m_dup_pkthdr(m, m0, wait) != 0) + goto fail; + + if (len > MHLEN) { + MCLGETI(m, len, NULL, wait); + if (!ISSET(m->m_flags, M_EXT)) + goto fail; + } + + m->m_len = m->m_pkthdr.len = len; + m_adj(m, adj); + m_copydata(m0, 0, m0->m_pkthdr.len, mtod(m, caddr_t)); + + return (m); + +fail: + m_freem(m); + return (NULL); +} + #ifdef DDB void m_print(void *v,