Deleted Added
full compact
32c32
< * $FreeBSD: head/sys/pci/if_rl.c 72813 2001-02-21 20:54:22Z wpaul $
---
> * $FreeBSD: head/sys/pci/if_rl.c 78508 2001-06-20 19:48:35Z bmilekic $
136c136
< "$FreeBSD: head/sys/pci/if_rl.c 72813 2001-02-21 20:54:22Z wpaul $";
---
> "$FreeBSD: head/sys/pci/if_rl.c 78508 2001-06-20 19:48:35Z bmilekic $";
1066,1073c1066,1067
< * on a 32-bit boundary. To achieve this, we cheat a bit by copying from
< * the ring buffer starting at an address two bytes before the actual
< * data location. We can then shave off the first two bytes using m_adj().
< * The reason we do this is because m_devget() doesn't let us specify an
< * offset into the mbuf storage space, so we have to artificially create
< * one. The ring is allocated in such a way that there are a few unused
< * bytes of space preceecing it so that it will be safe for us to do the
< * 2-byte backstep even if reading from the ring at offset 0.
---
> * on a 32-bit boundary. To achieve this, we pass RL_ETHER_ALIGN (2 bytes)
> * as the offset argument to m_devget().
1151,1157c1145,1146
< /*
< * Fool m_devget() into thinking we want to copy
< * the whole buffer so we don't end up fragmenting
< * the data.
< */
< m = m_devget(rxbufpos - RL_ETHER_ALIGN,
< total_len + RL_ETHER_ALIGN, 0, ifp, NULL);
---
> m = m_devget(rxbufpos, total_len, RL_ETHER_ALIGN, ifp,
> NULL);
1163d1151
< m_adj(m, RL_ETHER_ALIGN);
1169,1170c1157,1158
< m = m_devget(rxbufpos - RL_ETHER_ALIGN,
< total_len + RL_ETHER_ALIGN, 0, ifp, NULL);
---
> m = m_devget(rxbufpos, total_len, RL_ETHER_ALIGN, ifp,
> NULL);
1175,1176c1163
< } else
< m_adj(m, RL_ETHER_ALIGN);
---
> }