Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Aug 2013 08:29:44 +0300
From:      Konstantin Belousov <kostikbel@gmail.com>
To:        David Wolfskill <david@catwhisker.org>
Cc:        Davide Italiano <davide@freebsd.org>, current@freebsd.org
Subject:   Re: Early drop to debugger with DEBUG_MEMGUARD
Message-ID:  <20130813052944.GX4972@kib.kiev.ua>
In-Reply-To: <20130812214435.GH1570@albert.catwhisker.org>
References:  <20130812151314.GE1570@albert.catwhisker.org> <CACYV=-FH6KinGXFkgs6hyuegHtSsMyWusUuv9DHqqgyOQ1_mDg@mail.gmail.com> <20130812160154.GF1570@albert.catwhisker.org> <CACYV=-Fwmvr0c-2rRyfDCJ-G3r_o_qD5tBDn_CGc-sO42Bf=aQ@mail.gmail.com> <20130812214435.GH1570@albert.catwhisker.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--Se0bRJHHDzahbL7F
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Aug 12, 2013 at 02:44:35PM -0700, David Wolfskill wrote:
> On Mon, Aug 12, 2013 at 09:10:55AM -0700, Davide Italiano wrote:
> > ...
> > OK, I'm not sure I can make an immediate guess on where's the problem
> > now (without access to my main workstation), so I think you need to
> > wait tomorrow unless someone beats me to the punch. The best I can say
> > is that maybe r254025 is responsible for this. Try to revert and see
> > if things work again.
> > ....
>=20
> I tried backing out r254025, but there had been enough time that other
> commits had touched the same files.  Ended up backing out r254165,
> r254171, r254172, and r254182 as well (which seemed to go OK), but the
> result didn't build.
>=20
> So I just checked out a new src working copy @r254024, built the world
> and kernel cleanly, verified that it booted OK, then updated the src
> working copy to r254025, built, booted, and ... BANG!
>=20
> Booting...
> GDB: no debug ports present
> KDB: debugger backends: ddb
> KDB: current backend: ddb
> Copyright (c) 1992-2013 The FreeBSD Project.
> Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
>         The Regents of the University of California. All rights reserved.
> FreeBSD is a registered trademark of The FreeBSD Foundation.
> FreeBSD 10.0-CURRENT #3  r254025M/254025:1000041: Mon Aug 12 14:23:48 PDT=
 2013
>     root@freebeast.catwhisker.org:/common/S3/obj/usr/src/sys/MEMGUARD i386
> FreeBSD clang version 3.3 (tags/RELEASE_33/final 183502) 20130610
> WARNING: WITNESS option enabled, expect reduced performance.
> panic: Assertion strat =3D=3D M_BESTFIT || strat =3D=3D M_FIRSTFIT failed=
 at /usr/src/sys/kern/subr_vmem.c:1050
> cpuid =3D 0
> KDB: enter: panic
> [ thread pid 0 tid 0 ]
> Stopped at      kdb_enter+0x3d: movl    $0,kdb_why
> db>=20
>=20
> So I think it's fair to say that r254025 introduced the problem.
>=20
> I'll go ahead and use kernel configs without DEBUG_MEMGUARD on head
> until this is resolved (or I have an opportunity to test patches
> for someone).
>=20
> The r254025 environment is on a "spare" slice of the boot drive of
> the machine, so I can leave it for now.  My more usual (active)
> "head" slice is running:
>=20
> FreeBSD 10.0-CURRENT #1243  r254245M/254246:1000042: Mon Aug 12 05:39:42 =
PDT 2013     root@freebeast.catwhisker.org:/common/S4/obj/usr/src/sys/GENER=
IC  i386
>=20
> I'll be happy to test either or both.

The r254025 indeed introduced the problem, and Davide pointed out you a
workaround for the assertion triggering.

Proper fix for the memguard requires a policy of M_NEXTFIT or like, to
avoid a reuse of the previous allocated range as long as possible.

But, you have some further issue even after the assertion was silenced,
isn't it ?

--Se0bRJHHDzahbL7F
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (FreeBSD)

iQIcBAEBAgAGBQJSCcRHAAoJEJDCuSvBvK1B7ksP/3ZrrWr8wURc3HbHNVhOCZtY
vxhDqfOU0rESVOYdVMTUB174HHlXuEMLGcs7KDggJ4aKHPkBnvMupgJFl44GalSb
Crw3YqNkwYGvl+yDvAmH2ukTYLfZJdvGhGYHNY0hxqRMptUWRCceP2nZIKCXQ8tK
HyWcdtP1KzJc3tCahCad2bTr7cQfYJ4rgEpIfF5KTRKTUxpGoelxi13iTmdFQt8c
bfysKgQaGGWH5Vllf4HTh//tfFaKxrxlFM8J5TobOfhuh8mQgy49vjzVT3kAnd/j
aG/pI+fpkx0MTZWsjK5LUPhZbIJZ44fwEHcfPvsnsxzIA9ielu1vkSh7e5rl53Sh
PCAyvLMHCwXJ+6cZoQleIeIbmd2rF2aNoNlDmKyPHWHfUtIqMX4kbazbw9orYCxl
C82OAhrCkQ7uVySeaKjYm7YVbdFAYrQqaD1EvUL0EJ3GXV36dz0vWvk2bKmQgevd
04MW3KsgW8kdlxE4E1jwCJdvdPVhCfjh+5FbfI1VbZYrYUAAymcGrExW/W5Xr4HC
YCNX+8gg24vFbXs0z6g5uSz6MZ5ly4Uc/15mhhkIS8MGgKVDQVVytzQOtlDnbup+
KiPpUuyOwytBdTmNiYxUEoL8sRTU6XKt0Fe30kCKXCmIf17b6xLAuQCbAwSPcxHA
+4rOvMPXsvSv6DCmmOBB
=6sRT
-----END PGP SIGNATURE-----

--Se0bRJHHDzahbL7F--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130813052944.GX4972>