aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/hatm
diff options
context:
space:
mode:
authorHartmut Brandt <harti@FreeBSD.org>2003-11-05 11:15:47 +0000
committerHartmut Brandt <harti@FreeBSD.org>2003-11-05 11:15:47 +0000
commit0144e71085707720c31fa77d4a453d4a26d47c8a (patch)
treec2514e78475b533ada9332ba911a134a0c509ad3 /sys/dev/hatm
parentadcdb48eb57a4feaf0fceabfeac5a76185be601f (diff)
downloadsrc-0144e71085707720c31fa77d4a453d4a26d47c8a.tar.gz
src-0144e71085707720c31fa77d4a453d4a26d47c8a.zip
Initialize the USED flag in new external receive buffers to 0, not to 1.
We put them directly onto the free list instead of calling the external mbuf free routine (that routine would have cleaned the flag). This fixes a bug which manifests itself in falsely reporting a lot of used buffers when configuring the interface down.
Notes
Notes: svn path=/head/; revision=122111
Diffstat (limited to 'sys/dev/hatm')
-rw-r--r--sys/dev/hatm/if_hatm_intr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/hatm/if_hatm_intr.c b/sys/dev/hatm/if_hatm_intr.c
index bcc42d6ee83e..4e9582a69e58 100644
--- a/sys/dev/hatm/if_hatm_intr.c
+++ b/sys/dev/hatm/if_hatm_intr.c
@@ -231,7 +231,7 @@ hatm_mbuf_page_alloc(struct hatm_softc *sc, u_int group)
for (i = 0; i < MBUF0_PER_PAGE; i++, c++) {
c->hdr.pageno = sc->mbuf_npages;
c->hdr.chunkno = i;
- c->hdr.flags = MBUF_USED;
+ c->hdr.flags = 0;
hatm_ext_free(&sc->mbuf_list[0],
(struct mbufx_free *)c);
}
@@ -246,7 +246,7 @@ hatm_mbuf_page_alloc(struct hatm_softc *sc, u_int group)
for (i = 0; i < MBUF1_PER_PAGE; i++, c++) {
c->hdr.pageno = sc->mbuf_npages;
c->hdr.chunkno = i;
- c->hdr.flags = MBUF_USED;
+ c->hdr.flags = 0;
hatm_ext_free(&sc->mbuf_list[1],
(struct mbufx_free *)c);
}