Deleted Added
full compact
35c35
< __FBSDID("$FreeBSD: head/sys/dev/bge/if_bge.c 200246 2009-12-08 03:24:29Z yongari $");
---
> __FBSDID("$FreeBSD: head/sys/dev/bge/if_bge.c 200264 2009-12-08 17:54:23Z yongari $");
486,498d485
< /*
< * A common design characteristic for many Broadcom client controllers
< * is that they only support a single outstanding DMA read operation
< * on the PCIe bus. This means that it will take twice as long to fetch
< * a TX frame that is split into header and payload buffers as it does
< * to fetch a single, contiguous TX frame (2 reads vs. 1 read). For
< * these controllers, coalescing buffers to reduce the number of memory
< * reads is effective way to get maximum performance(about 940Mbps).
< * Without collapsing TX buffers the maximum TCP bulk transfer
< * performance is about 850Mbps. However forcing coalescing mbufs
< * consumes a lot of CPU cycles, so leave it off by default.
< */
< static int bge_forced_collapse = 0;
501d487
< TUNABLE_INT("hw.bge.forced_collapse", &bge_forced_collapse);
506,508d491
< SYSCTL_INT(_hw_bge, OID_AUTO, forced_collapse, CTLFLAG_RD, &bge_forced_collapse,
< 0, "Number of fragmented TX buffers of a frame allowed before "
< "forced collapsing");
3940,3941c3923,3924
< bge_forced_collapse > 0 && (sc->bge_flags & BGE_FLAG_PCIE) != 0 &&
< m->m_next != NULL) {
---
> sc->bge_forced_collapse > 0 &&
> (sc->bge_flags & BGE_FLAG_PCIE) != 0 && m->m_next != NULL) {
3947c3930
< if (bge_forced_collapse == 1)
---
> if (sc->bge_forced_collapse == 1)
3950c3933
< m = m_collapse(m, M_DONTWAIT, bge_forced_collapse);
---
> m = m_collapse(m, M_DONTWAIT, sc->bge_forced_collapse);
4877a4861,4880
> /*
> * A common design characteristic for many Broadcom client controllers
> * is that they only support a single outstanding DMA read operation
> * on the PCIe bus. This means that it will take twice as long to fetch
> * a TX frame that is split into header and payload buffers as it does
> * to fetch a single, contiguous TX frame (2 reads vs. 1 read). For
> * these controllers, coalescing buffers to reduce the number of memory
> * reads is effective way to get maximum performance(about 940Mbps).
> * Without collapsing TX buffers the maximum TCP bulk transfer
> * performance is about 850Mbps. However forcing coalescing mbufs
> * consumes a lot of CPU cycles, so leave it off by default.
> */
> SYSCTL_ADD_INT(ctx, children, OID_AUTO, "forced_collapse",
> CTLFLAG_RW, &sc->bge_forced_collapse, 0,
> "Number of fragmented TX buffers of a frame allowed before "
> "forced collapsing");
> resource_int_value(device_get_name(sc->bge_dev),
> device_get_unit(sc->bge_dev), "forced_collapse",
> &sc->bge_forced_collapse);
>