From owner-freebsd-hackers Tue Jun 13 14:51: 2 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from field.videotron.net (field.videotron.net [205.151.222.108]) by hub.freebsd.org (Postfix) with ESMTP id 0ED4837BFF8 for ; Tue, 13 Jun 2000 14:50:54 -0700 (PDT) (envelope-from bmilekic@dsuper.net) Received: from modemcable009.62-201-24.mtl.mc.videotron.net ([24.201.62.9]) by field.videotron.net (Sun Internet Mail Server sims.3.5.1999.12.14.10.29.p8) with ESMTP id <0FW4007SM4EAXN@field.videotron.net> for hackers@freebsd.org; Tue, 13 Jun 2000 17:44:35 -0400 (EDT) Date: Tue, 13 Jun 2000 17:46:14 -0400 (EDT) From: Bosko Milekic Subject: ether_output() : WIERD PROBLEM X-Sender: bmilekic@jehovah.technokratis.com To: hackers@freebsd.org Message-id: MIME-version: 1.0 Content-type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hello, I've been doing some mbuf-related work on my -CURRENT machine lately. Particularily, I've re-written the allocator and free routines, amongst other things. However, I've encountered a peculiar problem that surfaces in ether_output(). What happens is that one of my daemons, for example, natd, or httpd, etc., performs a system call, which eventually results in a call to ether_output (following tcp_output, ip_output, etc.). At the bottom of ether_output(), after an IF_ENQUEUE, and an splx(s), there is the following check: if (m->m_flags & M_MCAST) ifp->if_omcasts++; The if () part results in a testb $0x2, 0x13(%ebx) IF I REMEMBER correctly. For some wierd reason, when the mbuf in question is at a location: 0xstuffF00 (256 bytes into a page, the second mbuf on a page), there is a page fault. And it's _always_ when the mbuf is at such an address. Where the wierdness begins is when I actually examine the contents of the mbuf... I can actually see them, no page fault, no nothing. In fact, if I `continue' from the debugger, things continue to work fine... until the next 0xstuffF00 mbuf goes through ether_output() and reaches that check. If I move the check of the m_flags to just above the splx(s), but after the IF_ENQUEUE, then the page fault still occurs in the same way, except that I even get a page fault when trying to examine the contents of the mbuf. In other words, I can't even `continue' in this case. If I move the m_flags check before the IF_ENQUEUE, this doesn't happen at all! Furthermore, if I revert my mbuf changes, I don't catch this problem. Anyone got any hints/clues? Regards, Bosko. -- Bosko Milekic * Voice/Mobile: 514.865.7738 * Pager: 514.921.0237 bmilekic@technokratis.com * http://www.technokratis.com/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message