From owner-cvs-all Sun Jun 11 0:19:26 2000 Delivered-To: cvs-all@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 7499937B9D2; Sun, 11 Jun 2000 00:19:21 -0700 (PDT) (envelope-from bde@FreeBSD.org) Received: (from bde@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id AAA82776; Sun, 11 Jun 2000 00:19:21 -0700 (PDT) (envelope-from bde@FreeBSD.org) Message-Id: <200006110719.AAA82776@freefall.freebsd.org> From: Bruce Evans Date: Sun, 11 Jun 2000 00:19:21 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/kern subr_bus.c Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG bde 2000/06/11 00:19:21 PDT Modified files: sys/kern subr_bus.c Log: Fixed allocation of unit numbers. Allocate the amount of space actually required (rounded up a little) instead of twice the previous amount (or a fixed amount for the first allocation). The bug caused memory corruption when a new unit number for a devclass was more than about twice the previous maximum one (or more than 3 for the first one), so it corrupted memory (which happened to be the atkbdc port resource list) in the reporter's configuration with sio unit numbers { 0, 25, 1, 2, ... }. Reviewed by: dfr Reported by: Leonid Lukiyanets Revision Changes Path 1.67 +2 -3 src/sys/kern/subr_bus.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message