From owner-freebsd-current@FreeBSD.ORG Tue Sep 1 07:31:24 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CE96A106568B for ; Tue, 1 Sep 2009 07:31:24 +0000 (UTC) (envelope-from nick@van-laarhoven.org) Received: from baranao.anywi.com (baranao.anywi.com [213.207.101.176]) by mx1.freebsd.org (Postfix) with ESMTP id 920F18FC1F for ; Tue, 1 Sep 2009 07:31:24 +0000 (UTC) Received: from hind.van-laarhoven.org (ip51cfcfde.direct-adsl.nl [81.207.207.222]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by baranao.anywi.com (Postfix) with ESMTPSA id 85A593F41F; Tue, 1 Sep 2009 09:31:20 +0200 (CEST) From: Nick Hibma To: FreeBSD CURRENT Mailing List Date: Tue, 1 Sep 2009 09:31:16 +0200 User-Agent: KMail/1.12.0 (FreeBSD/7.2-STABLE; KDE/4.3.0; i386; ; ) MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <200909010931.16880.nick@van-laarhoven.org> X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,UNPARSEABLE_RELAY autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on baranao.anywi.com Subject: Reducing noise in dmesg output X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Sep 2009 07:31:25 -0000 Folks, dmesg is getting cluttered with random bits of irrelevant information which either should be behind bootverbose or not at all present. Below two locations where I intend to remove that information. The fact that a module is loaded can be seen in the output of kldstat -v | grep netsmb the amount of stolen memory and aperture size might be interesting when configuring your X server. Then again, most X servers nowadays HAVE no configuration file anymore because of auto-configuration. Any objections? Nick Index: kern/kern_shutdown.c =================================================================== --- kern/kern_shutdown.c (revision 196710) +++ kern/kern_shutdown.c (working copy) @@ -581,6 +581,10 @@ /* * Support for poweroff delay. + * + * Please note that setting this delay too short might power off your machine + * before the write cache on your hard disk has been flushed, leading to + * soft-updates inconsistencies. */ #ifndef POWEROFF_DELAY # define POWEROFF_DELAY 5000 Index: dev/agp/agp_i810.c =================================================================== --- dev/agp/agp_i810.c (revision 196589) +++ dev/agp/agp_i810.c (working copy) @@ -474,12 +474,15 @@ agp_generic_detach(dev); return EINVAL; } - if (sc->stolen > 0) { - device_printf(dev, "detected %dk stolen memory\n", - sc->stolen * 4); + if (bootverbose) { + if (sc->stolen > 0) { + device_printf(dev, + "detected %dk stolen memory\n", + sc->stolen * 4); + } + device_printf(dev, "aperture size is %dM\n", + sc->initial_aperture / 1024 / 1024); } - device_printf(dev, "aperture size is %dM\n", - sc->initial_aperture / 1024 / 1024); /* GATT address is already in there, make sure it's enabled */ pgtblctl = bus_read_4(sc->sc_res[0], AGP_I810_PGTBL_CTL); @@ -664,9 +667,11 @@ gtt_size += 4; sc->stolen = (stolen - gtt_size) * 1024 / 4096; - if (sc->stolen > 0) - device_printf(dev, "detected %dk stolen memory\n", sc->stolen * 4); - device_printf(dev, "aperture size is %dM\n", sc->initial_aperture / 1024 / 1024); + if (bootverbose) { + if (sc->stolen > 0) + device_printf(dev, "detected %dk stolen memory\n", sc->stolen * 4); + device_printf(dev, "aperture size is %dM\n", sc->initial_aperture / 1024 / 1024); + } /* GATT address is already in there, make sure it's enabled */ pgtblctl = bus_read_4(sc->sc_res[0], AGP_I810_PGTBL_CTL); Index: netsmb/smb_dev.c =================================================================== --- netsmb/smb_dev.c (revision 196589) +++ netsmb/smb_dev.c (working copy) @@ -352,7 +352,6 @@ } clone_setup(&nsmb_clones); nsmb_dev_tag = EVENTHANDLER_REGISTER(dev_clone, nsmb_dev_clone, 0, 1000); - printf("netsmb_dev: loaded\n"); break; case MOD_UNLOAD: smb_iod_done(); @@ -363,7 +362,6 @@ drain_dev_clone_events(); clone_cleanup(&nsmb_clones); destroy_dev_drain(&nsmb_cdevsw); - printf("netsmb_dev: unloaded\n"); break; default: error = EINVAL;