From owner-cvs-all Tue Apr 23 15:48:29 2002 Delivered-To: cvs-all@freebsd.org Received: from web21109.mail.yahoo.com (web21109.mail.yahoo.com [216.136.227.111]) by hub.freebsd.org (Postfix) with SMTP id 89D0337B41A for ; Tue, 23 Apr 2002 15:48:19 -0700 (PDT) Message-ID: <20020423224818.41884.qmail@web21109.mail.yahoo.com> Received: from [62.254.0.5] by web21109.mail.yahoo.com via HTTP; Tue, 23 Apr 2002 15:48:18 PDT Date: Tue, 23 Apr 2002 15:48:18 -0700 (PDT) From: Hiten Pandya Reply-To: hiten@uk.FreeBSD.org Subject: Re: cvs commit: src/sys/kern kern_malloc.c To: Garance A Drosihn , Poul-Henning Kamp , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Cc: David Cross In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG [ multilated text left for easy reference. thanks ] --- Garance A Drosihn wrote: > >Does this solve the bug which I told you about caused by > >md devices, and especially when doing mdconfig -d -u x the > >second / third time round.. or am I talking nuts again? :) > > Are you running freebsd-stable, or freebsd-current? > Dave Cross came across some bug with MD that is fixed in > current, but which hasn't been MFC'ed yet. I don't know if > that's the bug you're seeing, though. Hi Garance, I use FreeBSD-CURRENT as of 2 weeks ago. I think I was very quick in describing the bug / defect / problem. Here goes... :) One: First of all, I started playing around with md disks as I found them a versatile way of "emulating" real disks, which is for the purpose of creating temporary JFS memory volumes for testing my ongoing jfsutils port. Two: For doing the above, I make my JFS md disks in the following way: # mdconfig -a -t vnode -f /tmp/jfs.vn.2 -u 2 Lets say if /tmp/jfs.vn.2 was not available, mdconfig (or the driver) would still allocate to make the /dev/md2 entry even though the -f entry has been invalid. (this is the first bug) When I try to remake the md device with the right file: # mdconfig -a -t vnode -f /tmp/jfs.vn -u 2 I get an error saying that "unit 2" is busy i.e. already allocated for some other foo purpose, which is truly a bug. When I destroy the device inorder to make it happen: # mdconfig -d -u 2 It works the first time round. Once, I thought I will just redo the command again to see if it has any effects (such as dropping into the debugger), and nothing happened; the third time I did it, it dropped straight into the debugger (i.e. DDB). My DDB 'trace' showed that it ended up in mddetach, but because I don't have a serial console, I am not able to produce a trace for attachment. I don't know if someone experiences the same problem like me, but I think the problem I have produced above is pretty much straightforward, but I cant find a suitable fix. This problem was also noticed by my friend and fellow porter for JFS4BSD , Martin Faxer (e with excent). I think the problem is either in 'mdconfig' or in the mddetach function call in src/sys/dev/md/md.c, but I am not sure. :) I tried to find it, but didn't get anywhere, as I was hooked with other things to do with my school studies. I would be very greatful if someone can reproduce this problem. It will save me from fsck'ing my disks everytime I get this problem, hehe, and drop into DDB!. :D Regards, -- Hiten __________________________________________________ Do You Yahoo!? Yahoo! Games - play chess, backgammon, pool and more http://games.yahoo.com/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message