From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 17:10:28 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id AD7B9236; Fri, 11 Oct 2013 17:10:28 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 9AD8D2493; Fri, 11 Oct 2013 17:10:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BHASVL091877; Fri, 11 Oct 2013 17:10:28 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BHASCn091876; Fri, 11 Oct 2013 17:10:28 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201310111710.r9BHASCn091876@svn.freebsd.org> From: Alexander Motin Date: Fri, 11 Oct 2013 17:10:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256318 - stable/10/sbin/camcontrol X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 17:10:28 -0000 Author: mav Date: Fri Oct 11 17:10:28 2013 New Revision: 256318 URL: http://svnweb.freebsd.org/changeset/base/256318 Log: MFC r256317: Fix mode page length calculation to remove last garbage line from the `camcontrol mode daX -l` output. Approved by: re (gjb) Modified: stable/10/sbin/camcontrol/modeedit.c Directory Properties: stable/10/sbin/camcontrol/ (props changed) Modified: stable/10/sbin/camcontrol/modeedit.c ============================================================================== --- stable/10/sbin/camcontrol/modeedit.c Fri Oct 11 17:00:09 2013 (r256317) +++ stable/10/sbin/camcontrol/modeedit.c Fri Oct 11 17:10:28 2013 (r256318) @@ -886,12 +886,12 @@ mode_list(struct cam_device *device, int timeout, data, sizeof(data)); mh = (struct scsi_mode_header_6 *)data; - len = mh->blk_desc_len; /* Skip block descriptors. */ + len = sizeof(*mh) + mh->blk_desc_len; /* Skip block descriptors. */ /* Iterate through the pages in the reply. */ while (len < mh->data_length) { /* Locate the next mode page header. */ mph = (struct scsi_mode_page_header *) - ((intptr_t)mh + sizeof(*mh) + len); + ((intptr_t)mh + len); mph->page_code &= SMS_PAGE_CODE; nameentry = nameentry_lookup(mph->page_code); From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 17:34:21 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 16242838; Fri, 11 Oct 2013 17:34:21 +0000 (UTC) (envelope-from edavis@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 02B8D260E; Fri, 11 Oct 2013 17:34:21 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BHYKe5005205; Fri, 11 Oct 2013 17:34:20 GMT (envelope-from edavis@svn.freebsd.org) Received: (from edavis@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BHYKb7005201; Fri, 11 Oct 2013 17:34:20 GMT (envelope-from edavis@svn.freebsd.org) Message-Id: <201310111734.r9BHYKb7005201@svn.freebsd.org> From: Eric Davis Date: Fri, 11 Oct 2013 17:34:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256319 - stable/10/sys/dev/bxe X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 17:34:21 -0000 Author: edavis Date: Fri Oct 11 17:34:20 2013 New Revision: 256319 URL: http://svnweb.freebsd.org/changeset/base/256319 Log: Merge r256299 from head. Approved by: re@ (gjb) Approved by: davidch (mentor) Modified: stable/10/sys/dev/bxe/bxe.c stable/10/sys/dev/bxe/bxe_stats.c stable/10/sys/dev/bxe/ecore_sp.h Directory Properties: stable/10/sys/ (props changed) Modified: stable/10/sys/dev/bxe/bxe.c ============================================================================== --- stable/10/sys/dev/bxe/bxe.c Fri Oct 11 17:10:28 2013 (r256318) +++ stable/10/sys/dev/bxe/bxe.c Fri Oct 11 17:34:20 2013 (r256319) @@ -34,7 +34,7 @@ #include __FBSDID("$FreeBSD$"); -#define BXE_DRIVER_VERSION "1.78.17" +#define BXE_DRIVER_VERSION "1.78.18" #include "bxe.h" #include "ecore_sp.h" @@ -936,8 +936,8 @@ bxe_dma_alloc(struct bxe_softc *sc, int rc; if (dma->size > 0) { - BLOGE(sc, "dma block '%s' already has size %lu\n", msg, - (unsigned long) dma->size); + BLOGE(sc, "dma block '%s' already has size %lu\n", msg, + (unsigned long)dma->size); return (1); } @@ -14201,8 +14201,14 @@ bxe_media_detect(struct bxe_softc *sc) uint32_t phy_idx = bxe_get_cur_phy_idx(sc); switch (sc->link_params.phy[phy_idx].media_type) { case ELINK_ETH_PHY_SFPP_10G_FIBER: - case ELINK_ETH_PHY_SFP_1G_FIBER: case ELINK_ETH_PHY_XFP_FIBER: + BLOGI(sc, "Found 10Gb Fiber media.\n"); + sc->media = IFM_10G_SR; + break; + case ELINK_ETH_PHY_SFP_1G_FIBER: + BLOGI(sc, "Found 1Gb Fiber media.\n"); + sc->media = IFM_1000_SX; + break; case ELINK_ETH_PHY_KR: case ELINK_ETH_PHY_CX4: BLOGI(sc, "Found 10GBase-CX4 media.\n"); @@ -14213,8 +14219,14 @@ bxe_media_detect(struct bxe_softc *sc) sc->media = IFM_10G_TWINAX; break; case ELINK_ETH_PHY_BASE_T: - BLOGI(sc, "Found 10GBase-T media.\n"); - sc->media = IFM_10G_T; + if (sc->link_params.speed_cap_mask[0] & + PORT_HW_CFG_SPEED_CAPABILITY_D0_10G) { + BLOGI(sc, "Found 10GBase-T media.\n"); + sc->media = IFM_10G_T; + } else { + BLOGI(sc, "Found 1000Base-T media.\n"); + sc->media = IFM_1000_T; + } break; case ELINK_ETH_PHY_NOT_PRESENT: BLOGI(sc, "Media not present.\n"); Modified: stable/10/sys/dev/bxe/bxe_stats.c ============================================================================== --- stable/10/sys/dev/bxe/bxe_stats.c Fri Oct 11 17:10:28 2013 (r256318) +++ stable/10/sys/dev/bxe/bxe_stats.c Fri Oct 11 17:34:20 2013 (r256319) @@ -263,6 +263,17 @@ bxe_stats_pmf_update(struct bxe_softc *s int loader_idx = PMF_DMAE_C(sc); uint32_t *stats_comp = BXE_SP(sc, stats_comp); + if (sc->devinfo.bc_ver <= 0x06001400) { + /* + * Bootcode v6.0.21 fixed a GRC timeout that occurs when accessing + * BRB registers while the BRB block is in reset. The DMA transfer + * below triggers this issue resulting in the DMAE to stop + * functioning. Skip this initial stats transfer for old bootcode + * versions <= 6.0.20. + */ + return; + } + /* sanity */ if (!sc->port.pmf || !sc->port.port_stx) { BLOGE(sc, "BUG!\n"); Modified: stable/10/sys/dev/bxe/ecore_sp.h ============================================================================== --- stable/10/sys/dev/bxe/ecore_sp.h Fri Oct 11 17:10:28 2013 (r256318) +++ stable/10/sys/dev/bxe/ecore_sp.h Fri Oct 11 17:34:20 2013 (r256319) @@ -77,9 +77,14 @@ struct bxe_softc; typedef bus_addr_t ecore_dma_addr_t; /* expected to be 64 bit wide */ typedef volatile int ecore_atomic_t; -#if __FreeBSD_version < 1000002 -typedef int bool; +#ifndef __bool_true_false_are_defined +#ifndef __cplusplus +#define bool _Bool +#if __STDC_VERSION__ < 199901L && __GNUC__ < 3 && !defined(__INTEL_COMPILER) +typedef _Bool bool; #endif +#endif /* !__cplusplus */ +#endif /* !__bool_true_false_are_defined$ */ #define ETH_ALEN ETHER_ADDR_LEN /* 6 */ From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 17:39:34 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 4349A9B3; Fri, 11 Oct 2013 17:39:34 +0000 (UTC) (envelope-from edavis@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 2FF9D263C; Fri, 11 Oct 2013 17:39:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BHdX1q006543; Fri, 11 Oct 2013 17:39:33 GMT (envelope-from edavis@svn.freebsd.org) Received: (from edavis@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BHdXH6006542; Fri, 11 Oct 2013 17:39:33 GMT (envelope-from edavis@svn.freebsd.org) Message-Id: <201310111739.r9BHdXH6006542@svn.freebsd.org> From: Eric Davis Date: Fri, 11 Oct 2013 17:39:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256320 - stable/10/share/misc X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 17:39:34 -0000 Author: edavis Date: Fri Oct 11 17:39:33 2013 New Revision: 256320 URL: http://svnweb.freebsd.org/changeset/base/256320 Log: Merge r256280 from head. Approved by: re@ (gjb) Approved by: davidch (mentor) Modified: stable/10/share/misc/committers-src.dot Directory Properties: stable/10/share/misc/ (props changed) Modified: stable/10/share/misc/committers-src.dot ============================================================================== --- stable/10/share/misc/committers-src.dot Fri Oct 11 17:34:20 2013 (r256319) +++ stable/10/share/misc/committers-src.dot Fri Oct 11 17:39:33 2013 (r256320) @@ -145,6 +145,7 @@ dumbbell [label="Jean-Sebastien Pedron\n dwmalone [label="David Malone\ndwmalone@FreeBSD.org\n2000/07/11"] eadler [label="Eitan Adler\neadler@FreeBSD.org\n2012/01/18"] ed [label="Ed Schouten\ned@FreeBSD.org\n2008/05/22"] +edavis [label="Eric Davis\nedavis@FreeBSD.org\n2013/10/09"] edwin [label="Edwin Groothuis\nedwin@FreeBSD.org\n2007/06/25"] eivind [label="Eivind Eklund\neivind@FreeBSD.org\n1997/02/02"] emaste [label="Ed Maste\nemaste@FreeBSD.org\n2005/10/04"] From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 18:27:14 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id EE652D0A; Fri, 11 Oct 2013 18:27:13 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id DA376299A; Fri, 11 Oct 2013 18:27:13 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BIRDOS031763; Fri, 11 Oct 2013 18:27:13 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BIRDtL031760; Fri, 11 Oct 2013 18:27:13 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201310111827.r9BIRDtL031760@svn.freebsd.org> From: Peter Grehan Date: Fri, 11 Oct 2013 18:27:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256326 - in stable/10/sys/dev: ata hyperv/stordisengage X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 18:27:14 -0000 Author: grehan Date: Fri Oct 11 18:27:12 2013 New Revision: 256326 URL: http://svnweb.freebsd.org/changeset/base/256326 Log: MFC r256304 Allow the legacy CDROM device to be accessed in a FreeBSD guest, while still using enlightened drivers for other block devices. Approved by: re@ (gjb) Modified: stable/10/sys/dev/ata/ata-all.c stable/10/sys/dev/ata/ata-card.c stable/10/sys/dev/hyperv/stordisengage/hv_ata_pci_disengage.c Directory Properties: stable/10/sys/ (props changed) stable/10/sys/dev/hyperv/ (props changed) Modified: stable/10/sys/dev/ata/ata-all.c ============================================================================== --- stable/10/sys/dev/ata/ata-all.c Fri Oct 11 18:21:05 2013 (r256325) +++ stable/10/sys/dev/ata/ata-all.c Fri Oct 11 18:27:12 2013 (r256326) @@ -92,7 +92,7 @@ FEATURE(ata_cam, "ATA devices are access int ata_probe(device_t dev) { - return 0; + return (BUS_PROBE_DEFAULT); } int Modified: stable/10/sys/dev/ata/ata-card.c ============================================================================== --- stable/10/sys/dev/ata/ata-card.c Fri Oct 11 18:21:05 2013 (r256325) +++ stable/10/sys/dev/ata/ata-card.c Fri Oct 11 18:27:12 2013 (r256326) @@ -140,7 +140,7 @@ ata_pccard_attach(device_t dev) ch-> flags |= ATA_NO_SLAVE; ata_generic_hw(dev); err = ata_probe(dev); - if (err) + if (err > 0) return (err); return (ata_attach(dev)); } Modified: stable/10/sys/dev/hyperv/stordisengage/hv_ata_pci_disengage.c ============================================================================== --- stable/10/sys/dev/hyperv/stordisengage/hv_ata_pci_disengage.c Fri Oct 11 18:21:05 2013 (r256325) +++ stable/10/sys/dev/hyperv/stordisengage/hv_ata_pci_disengage.c Fri Oct 11 18:27:12 2013 (r256326) @@ -92,6 +92,7 @@ static int hv_check_for_hyper_v(void); static int hv_ata_pci_probe(device_t dev) { + device_t parent = device_get_parent(dev); int ata_disk_enable; ata_disk_enable = 0; @@ -102,23 +103,9 @@ hv_ata_pci_probe(device_t dev) if (!hv_check_for_hyper_v()) return (ENXIO); - if (bootverbose) - device_printf(dev, - "hv_ata_pci_probe dev_class/subslcass = %d, %d\n", - pci_get_class(dev), pci_get_subclass(dev)); - - /* is this a storage class device ? */ - if (pci_get_class(dev) != PCIC_STORAGE) + if (device_get_unit(parent) != 0 || device_get_ivars(dev) != 0) return (ENXIO); - /* is this an IDE/ATA type device ? */ - if (pci_get_subclass(dev) != PCIS_STORAGE_IDE) - return (ENXIO); - - if(bootverbose) - device_printf(dev, - "Hyper-V probe for disabling ATA-PCI, emulated driver\n"); - /* * On Hyper-V the default is to use the enlightened driver for * IDE disks. However, if the user wishes to use the native @@ -126,15 +113,14 @@ hv_ata_pci_probe(device_t dev) * hw_ata.disk_enable must be explicitly set to 1. */ if (getenv_int("hw.ata.disk_enable", &ata_disk_enable)) { - if(bootverbose) + if (bootverbose) device_printf(dev, "hw.ata.disk_enable flag is disabling Hyper-V" " ATA driver support\n"); return (ENXIO); } - if (bootverbose) - device_printf(dev, "Hyper-V ATA storage driver enabled.\n"); + device_set_desc(dev, "Hyper-V ATA storage disengage driver"); return (BUS_PROBE_VENDOR); } @@ -193,12 +179,12 @@ static device_method_t hv_ata_pci_method devclass_t hv_ata_pci_devclass; static driver_t hv_ata_pci_disengage_driver = { - "pciata-disable", + "ata", hv_ata_pci_methods, - sizeof(struct ata_pci_controller), + 0, }; -DRIVER_MODULE(atapci_dis, pci, hv_ata_pci_disengage_driver, - hv_ata_pci_devclass, NULL, NULL); +DRIVER_MODULE(atapci_dis, atapci, hv_ata_pci_disengage_driver, + hv_ata_pci_devclass, NULL, NULL); MODULE_VERSION(atapci_dis, 1); MODULE_DEPEND(atapci_dis, ata, 1, 1, 1); From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 19:43:37 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id DFC9B1D5; Fri, 11 Oct 2013 19:43:37 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id B205D2E34; Fri, 11 Oct 2013 19:43:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BJhbIu071395; Fri, 11 Oct 2013 19:43:37 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BJhbDW071393; Fri, 11 Oct 2013 19:43:37 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201310111943.r9BJhbDW071393@svn.freebsd.org> From: Glen Barber Date: Fri, 11 Oct 2013 19:43:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256329 - in stable/10/sys: amd64/conf i386/conf X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 19:43:38 -0000 Author: gjb Date: Fri Oct 11 19:43:37 2013 New Revision: 256329 URL: http://svnweb.freebsd.org/changeset/base/256329 Log: MFC r256328: Document XENHVM and xenpci are mutually inclusive. Approved by: re (delphij) Sponsored by: The FreeBSD Foundation Modified: stable/10/sys/amd64/conf/GENERIC stable/10/sys/i386/conf/GENERIC Directory Properties: stable/10/sys/ (props changed) Modified: stable/10/sys/amd64/conf/GENERIC ============================================================================== --- stable/10/sys/amd64/conf/GENERIC Fri Oct 11 19:40:28 2013 (r256328) +++ stable/10/sys/amd64/conf/GENERIC Fri Oct 11 19:43:37 2013 (r256329) @@ -72,7 +72,6 @@ options KDTRACE_FRAME # Ensure frames options KDTRACE_HOOKS # Kernel DTrace hooks options DDB_CTF # Kernel ELF linker loads CTF data options INCLUDE_CONFIG_FILE # Include this file in kernel -options XENHVM # Include Xen support # Debugging support. Always need this: options KDB # Enable kernel debugger support. @@ -336,8 +335,10 @@ device virtio_balloon # VirtIO Memory B # HyperV drivers device hyperv # HyperV drivers -# Xen support -device xenpci # Generic Xen bus +# Xen HVM Guest Optimizations +# NOTE: XENHVM depends on xenpci. They must be added or removed together. +options XENHVM # Xen HVM kernel infrastructure +device xenpci # Xen HVM Hypervisor services driver # VMware support device vmx # VMware VMXNET3 Ethernet Modified: stable/10/sys/i386/conf/GENERIC ============================================================================== --- stable/10/sys/i386/conf/GENERIC Fri Oct 11 19:40:28 2013 (r256328) +++ stable/10/sys/i386/conf/GENERIC Fri Oct 11 19:43:37 2013 (r256329) @@ -72,7 +72,6 @@ options MAC # TrustedBSD MAC Framewor options KDTRACE_HOOKS # Kernel DTrace hooks options DDB_CTF # Kernel ELF linker loads CTF data options INCLUDE_CONFIG_FILE # Include this file in kernel -options XENHVM # Include Xen support # Debugging support. Always need this: options KDB # Enable kernel debugger support. @@ -347,8 +346,10 @@ device virtio_blk # VirtIO Block device device virtio_scsi # VirtIO SCSI device device virtio_balloon # VirtIO Memory Balloon device -# Xen support -device xenpci # Generic Xen bus +# Xen HVM Guest Optimizations +# NOTE: XENHVM depends on xenpci. They must be added or removed together. +options XENHVM # Xen HVM kernel infrastructure +device xenpci # Xen HVM Hypervisor services driver # VMware support device vmx # VMware VMXNET3 Ethernet From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:14:22 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 2ACE84E9; Fri, 11 Oct 2013 20:14:22 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 17C422094; Fri, 11 Oct 2013 20:14:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BKELhB087336; Fri, 11 Oct 2013 20:14:21 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BKELg9087335; Fri, 11 Oct 2013 20:14:21 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201310112014.r9BKELg9087335@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 11 Oct 2013 20:14:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256336 - stable/10/bin/freebsd-version X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:14:22 -0000 Author: des Date: Fri Oct 11 20:14:21 2013 New Revision: 256336 URL: http://svnweb.freebsd.org/changeset/base/256336 Log: MFH (r256332): remove extraneous \n Approved by: re (gjb) Modified: stable/10/bin/freebsd-version/freebsd-version.sh.in Directory Properties: stable/10/bin/freebsd-version/ (props changed) Modified: stable/10/bin/freebsd-version/freebsd-version.sh.in ============================================================================== --- stable/10/bin/freebsd-version/freebsd-version.sh.in Fri Oct 11 20:12:30 2013 (r256335) +++ stable/10/bin/freebsd-version/freebsd-version.sh.in Fri Oct 11 20:14:21 2013 (r256336) @@ -81,7 +81,7 @@ userland_version() { # Print a usage string and exit. # usage() { - echo "usage: $progname [-ku]\n" >&2 + echo "usage: $progname [-ku]" >&2 exit 1 } From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:15:39 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 62B8862F; Fri, 11 Oct 2013 20:15:39 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4DF4220A5; Fri, 11 Oct 2013 20:15:39 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BKFdEF087838; Fri, 11 Oct 2013 20:15:39 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BKFdnB087837; Fri, 11 Oct 2013 20:15:39 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201310112015.r9BKFdnB087837@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 11 Oct 2013 20:15:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256337 - stable/10 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:15:39 -0000 Author: des Date: Fri Oct 11 20:15:38 2013 New Revision: 256337 URL: http://svnweb.freebsd.org/changeset/base/256337 Log: MFH (r256334): remove extraneous but harmless / Approved by: re (gjb) Modified: stable/10/ObsoleteFiles.inc Directory Properties: stable/10/ (props changed) Modified: stable/10/ObsoleteFiles.inc ============================================================================== --- stable/10/ObsoleteFiles.inc Fri Oct 11 20:14:21 2013 (r256336) +++ stable/10/ObsoleteFiles.inc Fri Oct 11 20:15:38 2013 (r256337) @@ -39,7 +39,7 @@ # done # 20131009: freebsd-version moved from /libexec to /bin -OLD_FILES+=/libexec/freebsd-version +OLD_FILES+=libexec/freebsd-version # 20131001: ar and ranlib from binutils not used OLD_FILES+=usr/bin/gnu-ar OLD_FILES+=usr/bin/gnu-ranlib From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:15:39 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 6DECD630; Fri, 11 Oct 2013 20:15:39 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from mail0.glenbarber.us (mail0.glenbarber.us [IPv6:2607:fc50:1:2300:1001:1001:1001:face]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 3CA3220A2; Fri, 11 Oct 2013 20:15:36 +0000 (UTC) Received: from glenbarber.us (c-71-224-221-174.hsd1.nj.comcast.net [71.224.221.174]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: gjb) by mail0.glenbarber.us (Postfix) with ESMTPSA id 1AD257EB7; Fri, 11 Oct 2013 20:15:35 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.8.3 mail0.glenbarber.us 1AD257EB7 Authentication-Results: mail0.glenbarber.us; dkim=none reason="no signature"; dkim-adsp=none Date: Fri, 11 Oct 2013 16:15:33 -0400 From: Glen Barber To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: Re: svn commit: r256329 - in stable/10/sys: amd64/conf i386/conf Message-ID: <20131011201533.GA44375@glenbarber.us> References: <201310111943.r9BJhbDW071393@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="+BArgJ+dbJ88VxBZ" Content-Disposition: inline In-Reply-To: <201310111943.r9BJhbDW071393@svn.freebsd.org> X-Operating-System: FreeBSD 10.0-ALPHA4 amd64 User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:15:39 -0000 --+BArgJ+dbJ88VxBZ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Oct 11, 2013 at 07:43:37PM +0000, Glen Barber wrote: > Author: gjb > Date: Fri Oct 11 19:43:37 2013 > New Revision: 256329 > URL: http://svnweb.freebsd.org/changeset/base/256329 >=20 > Log: > MFC r256328: > Document XENHVM and xenpci are mutually inclusive. > =20 s/inclusive/dependent/. Glen --+BArgJ+dbJ88VxBZ Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (FreeBSD) iQIcBAEBCAAGBQJSWFxlAAoJELls3eqvi17Q6WkP/3MC9D4+tNKh55sApj6BLwFb uKUpjwlZAC0E20/sZCP2UIig4kpUyAsVkjQ9+wsDZXFMI0NZv08OoSCDuFpstYs0 tyIcN3DaKZ5n+azFGLycHF6QTr5UVifl+IKdS0E1OYDaO1PgU9Dj5N66iMkumRq0 +yNtmVDNKJDtxcngd62+Jk0CdcjNFKr/rtsIF0XMGL1lpwCX7naFWW2PLqbNJZkS G3IN9wCJ//0IfKZahzX7KdgMV2OZt8L0wUPGun09ZYoROt0r3Xu82p9V1uN+nx+k o2UftbnTy2Z7W7S5Zar4U6uV0/u5Bz8u/tdTkBXjuOxs4nv/OiS7CTxr56rjG+3G mhPJQzq4c2DCEi0ICBnU9SvxeNwODXn755AZ30Du0SceGANvzzvkRYLyr4FnhlN0 nuiuI7lJmYKQq+h81Rj2ORJ6H0YStburSmZqKvwB8bev+WOshr4vMu14b/riT0OK WI92NsHVhGLtPovrLXTVXaJ2FQ+/gAkfNYuS5mbvhNwSqszUPzsZQD93qMJIaYZU gxphaq69VEC0Tkj8UNM7xz/OI6GV2xxjeBYv+nGkqjMQCsZjgCLRS4PJ8yoWIEla F2TjtfD+MAoNfl5NCsy0PPyRuV9XCBVVs6YbO30spWcohhrPl6XaCzN0ZdzN2/8J /eMg3HciXIUymT31GwBm =Npu8 -----END PGP SIGNATURE----- --+BArgJ+dbJ88VxBZ-- From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:26:46 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 733EBBB7; Fri, 11 Oct 2013 20:26:46 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4688D2153; Fri, 11 Oct 2013 20:26:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BKQkkh093532; Fri, 11 Oct 2013 20:26:46 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BKQkho093531; Fri, 11 Oct 2013 20:26:46 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201310112026.r9BKQkho093531@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 11 Oct 2013 20:26:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256339 - stable/10 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:26:46 -0000 Author: des Date: Fri Oct 11 20:26:45 2013 New Revision: 256339 URL: http://svnweb.freebsd.org/changeset/base/256339 Log: Move mergeinfo to the right place. Approved by: re (gjb) Modified: Directory Properties: stable/10/ (props changed) stable/10/ObsoleteFiles.inc (props changed) From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:28:32 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 8D5ECE08; Fri, 11 Oct 2013 20:28:32 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 6ADA3216F; Fri, 11 Oct 2013 20:28:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BKSWok094102; Fri, 11 Oct 2013 20:28:32 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BKSV8s094096; Fri, 11 Oct 2013 20:28:31 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201310112028.r9BKSV8s094096@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Fri, 11 Oct 2013 20:28:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256340 - in stable/10/usr.sbin/bsdinstall: . scripts X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:28:32 -0000 Author: des Date: Fri Oct 11 20:28:30 2013 New Revision: 256340 URL: http://svnweb.freebsd.org/changeset/base/256340 Log: MFH (r256338): store some entropy after installation Approved by: re (gjb) Added: stable/10/usr.sbin/bsdinstall/scripts/entropy - copied unchanged from r256338, head/usr.sbin/bsdinstall/scripts/entropy Modified: stable/10/usr.sbin/bsdinstall/bsdinstall.8 stable/10/usr.sbin/bsdinstall/scripts/Makefile stable/10/usr.sbin/bsdinstall/scripts/auto stable/10/usr.sbin/bsdinstall/scripts/jail stable/10/usr.sbin/bsdinstall/scripts/script Directory Properties: stable/10/usr.sbin/bsdinstall/ (props changed) Modified: stable/10/usr.sbin/bsdinstall/bsdinstall.8 ============================================================================== --- stable/10/usr.sbin/bsdinstall/bsdinstall.8 Fri Oct 11 20:26:45 2013 (r256339) +++ stable/10/usr.sbin/bsdinstall/bsdinstall.8 Fri Oct 11 20:28:30 2013 (r256340) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 21, 2013 +.Dd October 6, 2013 .Dt BSDINSTALL 8 .Os .Sh NAME @@ -60,6 +60,10 @@ targets. .Bl -tag -width ".Cm jail Ar destination" .It Cm auto Run the standard interactive installation, including disk partitioning. +.It Cm entropy +Reads a small amount of data from +.Pa /dev/random +and stores it in a file in the new system's root directory. .It Cm jail Ar destination Sets up a new chroot system at .Pa destination , Modified: stable/10/usr.sbin/bsdinstall/scripts/Makefile ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/Makefile Fri Oct 11 20:26:45 2013 (r256339) +++ stable/10/usr.sbin/bsdinstall/scripts/Makefile Fri Oct 11 20:28:30 2013 (r256340) @@ -1,8 +1,8 @@ # $FreeBSD$ -SCRIPTS= auto adduser checksum config docsinstall hostname jail keymap \ - mirrorselect mount netconfig netconfig_ipv4 netconfig_ipv6 rootpass \ - script services time umount wlanconfig +SCRIPTS= auto adduser checksum config docsinstall entropy hostname jail \ + keymap mirrorselect mount netconfig netconfig_ipv4 netconfig_ipv6 \ + rootpass script services time umount wlanconfig BINDIR= /usr/libexec/bsdinstall NO_MAN= true Modified: stable/10/usr.sbin/bsdinstall/scripts/auto ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/auto Fri Oct 11 20:26:45 2013 (r256339) +++ stable/10/usr.sbin/bsdinstall/scripts/auto Fri Oct 11 20:28:30 2013 (r256340) @@ -222,5 +222,8 @@ if [ $? -eq 0 ]; then chroot "$BSDINSTALL_CHROOT" /bin/sh 2>&1 fi +bsdinstall entropy +bsdinstall umount + echo "Installation Completed at $(date)" >> $BSDINSTALL_LOG Copied: stable/10/usr.sbin/bsdinstall/scripts/entropy (from r256338, head/usr.sbin/bsdinstall/scripts/entropy) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/usr.sbin/bsdinstall/scripts/entropy Fri Oct 11 20:28:30 2013 (r256340, copy of r256338, head/usr.sbin/bsdinstall/scripts/entropy) @@ -0,0 +1,29 @@ +#!/bin/sh +#- +# Copyright (c) 2013 Dag-Erling Smørgrav +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $FreeBSD$ + +dd if=/dev/random of=$BSDINSTALL_CHROOT/entropy bs=4096 count=1 Modified: stable/10/usr.sbin/bsdinstall/scripts/jail ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/jail Fri Oct 11 20:26:45 2013 (r256339) +++ stable/10/usr.sbin/bsdinstall/scripts/jail Fri Oct 11 20:28:30 2013 (r256340) @@ -110,5 +110,7 @@ bsdinstall config || error cp /etc/resolv.conf $1/etc cp /etc/localtime $1/etc +bsdinstall entropy + echo "Installation Completed at $(date)" >> $BSDINSTALL_LOG Modified: stable/10/usr.sbin/bsdinstall/scripts/script ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/script Fri Oct 11 20:26:45 2013 (r256339) +++ stable/10/usr.sbin/bsdinstall/scripts/script Fri Oct 11 20:28:30 2013 (r256340) @@ -83,6 +83,7 @@ if [ -f /tmp/bsdinstall-installscript-ab rm $BSDINSTALL_CHROOT/tmp/installscript fi +bsdinstall entropy bsdinstall umount echo "Installation Completed at $(date)" >> $BSDINSTALL_LOG From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:38:04 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id A1AC930A; Fri, 11 Oct 2013 20:38:04 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8E99D2216; Fri, 11 Oct 2013 20:38:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BKc4mZ098787; Fri, 11 Oct 2013 20:38:04 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BKc46H098786; Fri, 11 Oct 2013 20:38:04 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201310112038.r9BKc46H098786@svn.freebsd.org> From: Dimitry Andric Date: Fri, 11 Oct 2013 20:38:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256342 - stable/10/sys/dev/bxe X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:38:04 -0000 Author: dim Date: Fri Oct 11 20:38:04 2013 New Revision: 256342 URL: http://svnweb.freebsd.org/changeset/base/256342 Log: In sys/dev/bxe/bxe.c, print bus_addr_t values using %#jx, to fix several gcc warnings for PAE kernels. Approved by: re (glebius) Reviewed by: davidch, edavis Modified: stable/10/sys/dev/bxe/bxe.c Modified: stable/10/sys/dev/bxe/bxe.c ============================================================================== --- stable/10/sys/dev/bxe/bxe.c Fri Oct 11 20:35:12 2013 (r256341) +++ stable/10/sys/dev/bxe/bxe.c Fri Oct 11 20:38:04 2013 (r256342) @@ -2532,9 +2532,9 @@ bxe_sp_post(struct bxe_softc *sc, atomic_subtract_acq_long(&sc->cq_spq_left, 1); } - BLOGD(sc, DBG_SP, "SPQE -> %p\n", (void *)sc->spq_dma.paddr); - BLOGD(sc, DBG_SP, "FUNC_RDATA -> %p / %p\n", - BXE_SP(sc, func_rdata), (void *)BXE_SP_MAPPING(sc, func_rdata)); + BLOGD(sc, DBG_SP, "SPQE -> %#jx\n", (uintmax_t)sc->spq_dma.paddr); + BLOGD(sc, DBG_SP, "FUNC_RDATA -> %p / %#jx\n", + BXE_SP(sc, func_rdata), (uintmax_t)BXE_SP_MAPPING(sc, func_rdata)); BLOGD(sc, DBG_SP, "SPQE[%x] (%x:%x) (cmd, common?) (%d,%d) hw_cid %x data (%x:%x) type(0x%x) left (CQ, EQ) (%lx,%lx)\n", sc->spq_prod_idx, @@ -6923,11 +6923,11 @@ bxe_alloc_fw_stats_mem(struct bxe_softc sc->fw_stats_data_mapping = (sc->fw_stats_dma.paddr + sc->fw_stats_req_size); - BLOGD(sc, DBG_LOAD, "statistics request base address set to %p\n", - (void *)sc->fw_stats_req_mapping); + BLOGD(sc, DBG_LOAD, "statistics request base address set to %#jx\n", + (uintmax_t)sc->fw_stats_req_mapping); - BLOGD(sc, DBG_LOAD, "statistics data base address set to %p\n", - (void *)sc->fw_stats_data_mapping); + BLOGD(sc, DBG_LOAD, "statistics data base address set to %#jx\n", + (uintmax_t)sc->fw_stats_data_mapping); return (0); } From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 20:43:00 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 343596A2; Fri, 11 Oct 2013 20:43:00 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 06DAB2280; Fri, 11 Oct 2013 20:43:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BKgxvi002709; Fri, 11 Oct 2013 20:42:59 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BKgxab002708; Fri, 11 Oct 2013 20:42:59 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201310112042.r9BKgxab002708@svn.freebsd.org> From: Dimitry Andric Date: Fri, 11 Oct 2013 20:42:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256344 - stable/10/sys X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 20:43:00 -0000 Author: dim Date: Fri Oct 11 20:42:59 2013 New Revision: 256344 URL: http://svnweb.freebsd.org/changeset/base/256344 Log: Fix up the svn mergeinfo which I forgot in r256342. Approved by: re (glebius) Modified: Directory Properties: stable/10/sys/ (props changed) From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 21:47:18 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 39859D18; Fri, 11 Oct 2013 21:47:18 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 0AF5D265B; Fri, 11 Oct 2013 21:47:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BLlH6Q035284; Fri, 11 Oct 2013 21:47:17 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BLlHjW035282; Fri, 11 Oct 2013 21:47:17 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201310112147.r9BLlHjW035282@svn.freebsd.org> From: Peter Grehan Date: Fri, 11 Oct 2013 21:47:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256352 - in stable/10/sys/dev/hyperv: include vmbus X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 21:47:18 -0000 Author: grehan Date: Fri Oct 11 21:47:17 2013 New Revision: 256352 URL: http://svnweb.freebsd.org/changeset/base/256352 Log: MFC r256350 Fix vmbus channel memory leak where incorrect length parameter was being passed to contigfree(). Approved by: re@ (glebius) Modified: stable/10/sys/dev/hyperv/include/hyperv.h stable/10/sys/dev/hyperv/vmbus/hv_channel.c Directory Properties: stable/10/sys/ (props changed) stable/10/sys/dev/hyperv/ (props changed) Modified: stable/10/sys/dev/hyperv/include/hyperv.h ============================================================================== --- stable/10/sys/dev/hyperv/include/hyperv.h Fri Oct 11 21:41:07 2013 (r256351) +++ stable/10/sys/dev/hyperv/include/hyperv.h Fri Oct 11 21:47:17 2013 (r256352) @@ -24,6 +24,8 @@ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ */ /** @@ -669,6 +671,7 @@ typedef struct hv_vmbus_channel { * Allocated memory for ring buffer */ void* ring_buffer_pages; + unsigned long ring_buffer_size; uint32_t ring_buffer_page_count; /* * send to parent Modified: stable/10/sys/dev/hyperv/vmbus/hv_channel.c ============================================================================== --- stable/10/sys/dev/hyperv/vmbus/hv_channel.c Fri Oct 11 21:41:07 2013 (r256351) +++ stable/10/sys/dev/hyperv/vmbus/hv_channel.c Fri Oct 11 21:47:17 2013 (r256352) @@ -104,17 +104,19 @@ hv_vmbus_channel_open( /* Allocate the ring buffer */ out = contigmalloc((send_ring_buffer_size + recv_ring_buffer_size), - M_DEVBUF, M_ZERO, 0UL, BUS_SPACE_MAXADDR, PAGE_SIZE, 0); + M_DEVBUF, M_ZERO, 0UL, BUS_SPACE_MAXADDR, PAGE_SIZE, 0); KASSERT(out != NULL, ("Error VMBUS: contigmalloc failed to allocate Ring Buffer!")); if (out == NULL) - return (ENOMEM); + return (ENOMEM); in = ((uint8_t *) out + send_ring_buffer_size); new_channel->ring_buffer_pages = out; - new_channel->ring_buffer_page_count = (send_ring_buffer_size - + recv_ring_buffer_size) >> PAGE_SHIFT; + new_channel->ring_buffer_page_count = (send_ring_buffer_size + + recv_ring_buffer_size) >> PAGE_SHIFT; + new_channel->ring_buffer_size = send_ring_buffer_size + + recv_ring_buffer_size; hv_vmbus_ring_buffer_init( &new_channel->outbound, @@ -539,10 +541,8 @@ hv_vmbus_channel_close(hv_vmbus_channel hv_ring_buffer_cleanup(&channel->outbound); hv_ring_buffer_cleanup(&channel->inbound); - contigfree( - channel->ring_buffer_pages, - channel->ring_buffer_page_count, - M_DEVBUF); + contigfree(channel->ring_buffer_pages, channel->ring_buffer_size, + M_DEVBUF); free(info, M_DEVBUF); From owner-svn-src-stable-10@FreeBSD.ORG Fri Oct 11 23:12:07 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id E3598782; Fri, 11 Oct 2013 23:12:07 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id CEE432A64; Fri, 11 Oct 2013 23:12:07 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9BNC7cu080406; Fri, 11 Oct 2013 23:12:07 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9BNC5ri080353; Fri, 11 Oct 2013 23:12:05 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201310112312.r9BNC5ri080353@svn.freebsd.org> From: Devin Teske Date: Fri, 11 Oct 2013 23:12:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256361 - in stable/10/usr.sbin: bsdconfig/include bsdconfig/share bsdinstall bsdinstall/scripts X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2013 23:12:08 -0000 Author: dteske Date: Fri Oct 11 23:12:05 2013 New Revision: 256361 URL: http://svnweb.freebsd.org/changeset/base/256361 Log: MFC revisions 256321-256323,256331,256333,256335,256343: Bring in a new zfsboot auto script for performing automatic setup of a boot pool (optionally encrypted) with many other options, validations, features. Originally submitted by Allan Jude; modified in collaboration. MFC revisions 256325,256330,256345: Rewrite the keymap selection menu to display keymaps and provide a test mechanism. Test mechanism originally submitted by Warren Block; modified. MFC r256347: Prominently display "Wireless" for each wireless network interface. Part of PR bin/161547; submitted by Warren Block; slightly modified. MFC r256348: Remove the dumpdev configuration dialog, merge it into the regular services configuration and enable it by default. Originally submitted by Allan Jude; slightly modified. PR: bin/161547 Submitted by: Allan Jude, Warren Block In collaboration with: Allan Jude Approved by: re (glebius) Added: stable/10/usr.sbin/bsdconfig/share/keymap.subr - copied unchanged from r256325, head/usr.sbin/bsdconfig/share/keymap.subr stable/10/usr.sbin/bsdinstall/scripts/zfsboot - copied unchanged from r256343, head/usr.sbin/bsdinstall/scripts/zfsboot Modified: stable/10/usr.sbin/bsdconfig/include/messages.subr stable/10/usr.sbin/bsdconfig/share/Makefile stable/10/usr.sbin/bsdconfig/share/device.subr stable/10/usr.sbin/bsdconfig/share/dialog.subr stable/10/usr.sbin/bsdconfig/share/strings.subr stable/10/usr.sbin/bsdconfig/share/variable.subr stable/10/usr.sbin/bsdinstall/bsdinstall stable/10/usr.sbin/bsdinstall/scripts/Makefile stable/10/usr.sbin/bsdinstall/scripts/auto stable/10/usr.sbin/bsdinstall/scripts/config stable/10/usr.sbin/bsdinstall/scripts/keymap stable/10/usr.sbin/bsdinstall/scripts/netconfig stable/10/usr.sbin/bsdinstall/scripts/services Directory Properties: stable/10/usr.sbin/bsdconfig/ (props changed) stable/10/usr.sbin/bsdinstall/ (props changed) Modified: stable/10/usr.sbin/bsdconfig/include/messages.subr ============================================================================== --- stable/10/usr.sbin/bsdconfig/include/messages.subr Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdconfig/include/messages.subr Fri Oct 11 23:12:05 2013 (r256361) @@ -201,6 +201,7 @@ msg_lithuania="Lithuania" msg_loading_of_dependent_package_failed="Loading of dependent package %s failed" msg_located_index_now_reading_package_data_from_it="Located INDEX, now reading package data from it..." msg_logging_in_to_user_at_host="Logging in to %s@%s.." +msg_looking_for_keymap_files="Looking for keymap files..." msg_looking_up_host="Looking up host %s" msg_mail_desc="Electronic mail packages and utilities." msg_main_menu="Main Menu" Modified: stable/10/usr.sbin/bsdconfig/share/Makefile ============================================================================== --- stable/10/usr.sbin/bsdconfig/share/Makefile Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdconfig/share/Makefile Fri Oct 11 23:12:05 2013 (r256361) @@ -5,8 +5,9 @@ NO_OBJ= SUBDIR= media packages FILESDIR= ${SHAREDIR}/bsdconfig -FILES= common.subr device.subr dialog.subr mustberoot.subr \ - script.subr strings.subr struct.subr sysrc.subr variable.subr +FILES= common.subr device.subr dialog.subr keymap.subr \ + mustberoot.subr script.subr strings.subr struct.subr \ + sysrc.subr variable.subr beforeinstall: mkdir -p ${DESTDIR}${FILESDIR} Modified: stable/10/usr.sbin/bsdconfig/share/device.subr ============================================================================== --- stable/10/usr.sbin/bsdconfig/share/device.subr Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdconfig/share/device.subr Fri Oct 11 23:12:05 2013 (r256361) @@ -49,6 +49,7 @@ f_struct_define DEVICE \ desc \ devname \ type \ + capacity \ enabled \ init \ get \ @@ -114,7 +115,7 @@ f_device_try() } # f_device_register $name $desc $devname $type $enabled $init_function \ -# $get_function $shutdown_function $private +# $get_function $shutdown_function $private $capacity # # Register a device. A `structure' (see struct.subr) is created with the name # device_$name (so make sure $name contains only alpha-numeric characters or @@ -128,6 +129,7 @@ f_device_register() { local name="$1" desc="$2" devname="$3" type="$4" enabled="$5" local init_func="$6" get_func="$7" shutdown_func="$8" private="$9" + local capacity="${10}" f_struct_new DEVICE "device_$name" || return $FAILURE device_$name set name "$name" @@ -139,6 +141,7 @@ f_device_register() device_$name set get "$get_func" device_$name set shutdown "$shutdown_func" device_$name set private "$private" + device_$name set capacity "$capacity" # Scan our global register to see if it needs ammending local dev found= @@ -196,7 +199,7 @@ f_device_get_all() f_dprintf "Found a network device named %s" "$devname" f_device_register $devname \ "$desc" "$devname" $DEVICE_TYPE_NETWORK 1 \ - f_media_init_network "" f_media_shutdown_network "" + f_media_init_network "" f_media_shutdown_network "" -1 done # Next, try to find all the types of devices one might use @@ -208,6 +211,10 @@ f_device_get_all() n=$(( $n + 1 )) # Get the desc, type, and max (with debugging disabled) # NOTE: Bypassing f_device_name_get() for efficiency + # ASIDE: This would be equivalent to the following: + # debug= f_device_name_get $dev desc + # debug= f_device_name_get $dev type + # debug= f_device_name_get $dev max debug= f_getvar _device_desc$n desc debug= f_getvar _device_type$n type debug= f_getvar _device_max$n max @@ -222,7 +229,8 @@ f_device_get_all() f_device_register "${devname##*/}" "$desc" \ "$devname" $DEVICE_TYPE_CDROM 1 \ f_media_init_cdrom f_media_get_cdrom \ - f_media_shutdown_cdrom "" + f_media_shutdown_cdrom "" \ + "$( f_device_capacity "$devname" )" f_dprintf "Found a CDROM device for %s" \ "$devname" ;; @@ -232,7 +240,8 @@ f_device_get_all() "$devname" $DEVICE_TYPE_FLOPPY 1 \ f_media_init_floppy \ f_media_get_floppy \ - f_media_shutdown_floppy "" + f_media_shutdown_floppy "" \ + "$( f_device_capacity "$devname" )" f_dprintf "Found a floppy device for %s" \ "$devname" ;; @@ -241,7 +250,8 @@ f_device_get_all() f_device_register "${devname##*/}" "$desc" \ "$devname" $DEVICE_TYPE_USB 1 \ f_media_init_usb f_media_get_usb \ - f_media_shutdown_usb "" + f_media_shutdown_usb "" \ + "$( f_device_capacity "$devname" )" f_dprintf "Found a USB disk for %s" "$devname" ;; esac @@ -254,7 +264,8 @@ f_device_get_all() f_device_register "${devname##*/}" "ISO9660 file system" \ "$devname" $DEVICE_TYPE_CDROM 1 \ f_media_init_cdrom f_media_get_cdrom \ - f_media_shutdown_cdrom "" + f_media_shutdown_cdrom "" \ + "$( f_device_capacity "$devname" )" f_dprintf "Found a CDROM device for %s" "$devname" done @@ -281,7 +292,8 @@ f_device_get_all() "md(4) vnode file system" \ "$devname" $DEVICE_TYPE_CDROM 1 \ f_media_init_cdrom f_media_get_cdrom \ - f_media_shutdown_cdrom "" + f_media_shutdown_cdrom "" \ + "$( f_device_capacity "$devname" )" f_dprintf "Found a CDROM device for %s" "$devname" ;; esac @@ -313,8 +325,13 @@ f_device_get_all() continue fi - f_device_register "$diskname" "" \ - "/dev/$diskname" $DEVICE_TYPE_DISK 0 + # Try and find its description + f_device_desc "$diskname" $DEVICE_TYPE_DISK desc + + f_device_register "$diskname" "$desc" \ + "/dev/$diskname" $DEVICE_TYPE_DISK 0 \ + "" "" "" "" \ + "$( f_device_capacity "$diskname" )" f_dprintf "Found a disk device named %s" "$diskname" # Look for existing partitions to register @@ -327,7 +344,8 @@ f_device_get_all() f_device_register "$slice" "" \ "/dev/$slice" $DEVICE_TYPE_DOS 1 \ f_media_init_dos f_media_get_dos \ - f_media_shutdown_dos "" + f_media_shutdown_dos "" \ + "$( f_device_capacity "/dev/$slice" )" f_dprintf "Found a DOS partition %s" "$slice" ;; 0xa5) # FreeBSD partition @@ -347,7 +365,9 @@ f_device_get_all() $DEVICE_TYPE_UFS 1 \ f_media_init_ufs \ f_media_get_ufs \ - f_media_shutdown_ufs "" + f_media_shutdown_ufs "" \ + "$( f_device_capacity \ + "$/dev/$part" )" f_dprintf "Found a UFS partition %s" \ "$part" done # parts @@ -379,10 +399,27 @@ f_device_name_get() case "$__prop" in type|desc|max) : good ;; *) return $FAILURE; esac + # + # Attempt to create an alternate-form of $__name that contains the + # first contiguous string of numbers replaced with `%d' for comparison + # against stored pattern names (see MAIN). + # + local __left="${__name%%[0-9]*}" __right="${__name#*[0-9]}" __dname= + if [ "$__left" != "$__name" ]; then + # Chop leading digits from right 'til we hit first non-digit + while :; do + case "$__right" in + [0-9]*) __right="${__right#[0-9]}" ;; + *) break + esac + done + __dname="${__left}%d$__right" + fi + [ "$__type" = "$DEVICE_TYPE_ANY" ] && __type= for __dev in $DEVICE_NAMES; do __n=$(( $__n + 1 )) - [ "$__dev" = "$__name" ] || continue + [ "$__dev" = "$__name" -o "$__dev" = "$__dname" ] || continue f_getvar _device_type$__n __devtype [ "${__type:-$__devtype}" = "$__devtype" ] || continue f_getvar _device_$__prop$__n $__var_to_set @@ -463,6 +500,39 @@ f_device_desc() fi fi + # + # For disks, attempt to return camcontrol(8) descriptions. + # Otherwise fall through to below static list. + # + f_have camcontrol && + [ "${__type:-$DEVICE_TYPE_DISK}" = "$DEVICE_TYPE_DISK" ] && + __cp=$( camcontrol devlist 2> /dev/null | awk -v disk="$__name" ' + $0~"(\\(|,)"disk"(,|\\))" { + if (!match($0, "<[^>]+>")) next + print substr($0, RSTART+1, RLENGTH-2) + found = 1 + exit + } + END { exit ! found } + ' ) && setvar "$__var_to_set" "$__cp" && return $SUCCESS + + # + # Attempt to create an alternate-form of $__name that contains the + # first contiguous string of numbers replaced with `%d' for comparison + # against stored pattern names (see MAIN). + # + local __left="${__name%%[0-9]*}" __right="${__name#*[0-9]}" __dname= + if [ "$__left" != "$__name" ]; then + # Chop leading digits from right 'til we hit first non-digit + while :; do + case "$__right" in + [0-9]*) __right="${__right#[0-9]}" ;; + *) break + esac + done + __dname="${__left}%d$__right" + fi + local __dev __devtype __n=0 for __dev in $DEVICE_NAMES; do __n=$(( $__n + 1 )) @@ -472,11 +542,8 @@ f_device_desc() __devname=$( f_substr "$__name" 0 ${#__dev} ) [ "$__devname" = "$__dev" ] || continue else - __devname="${__name%%[0-9]*}" - __devunit="${__name#$__devname}" - __devunit="${__devunit%%[!0-9]*}" - __devname=$( printf "$__dev" $__devunit ) - [ "$__devname" = "$__name" ] || continue + [ "$__dev" = "$__name" -o "$__dev" = "$__dname" ] || + continue fi debug= f_getvar _device_desc$__n $__var_to_set return $? @@ -655,6 +722,25 @@ f_device_menu() return $retval } +# f_device_capacity $device [$var_to_set] +# +# Return the capacity of $device in bytes. +# +f_device_capacity() +{ + local __dev="$1" __var_to_set="$2" + local __bytes + + __bytes=$( diskinfo -v "$__dev" 2> /dev/null | + awk '/# mediasize in bytes/{print $1}' ) || __bytes=-1 + + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" "$__bytes" + else + echo "$__bytes" + fi +} + # # Short-hand # @@ -680,6 +766,7 @@ f_disk "ipsd%d" "IBM ServeRAID RAID ar f_disk "mfid%d" "LSI MegaRAID SAS array" 4 f_disk "mlxd%d" "Mylex RAID disk" 4 f_disk "twed%d" "3ware ATA RAID array" 4 +f_disk "vtbd%d" "VirtIO Block Device" 16 f_floppy "fd%d" "Floppy Drive unit A" 4 f_serial "cuau%d" "%s on device %s (COM%d)" 16 f_usb "da%da" "USB Mass Storage Device" 16 Modified: stable/10/usr.sbin/bsdconfig/share/dialog.subr ============================================================================== --- stable/10/usr.sbin/bsdconfig/share/dialog.subr Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdconfig/share/dialog.subr Fri Oct 11 23:12:05 2013 (r256361) @@ -415,8 +415,8 @@ f_dialog_size_constrain() if [ "$debug" ]; then # Print final constrained values to debugging - f_quietly f_getvar "$__var_height" - f_quietly f_getvar "$__var_width" + [ "$__var_height" ] && f_quietly f_getvar "$__var_height" + [ "$__var_width" ] && f_quietly f_getvar "$__var_width" fi return $__retval # success if no debug warnings were printed @@ -532,10 +532,10 @@ f_dialog_menu_constrain() fi if [ "$debug" ]; then - # Print final constrained values to debuggin - f_quietly f_getvar "$__var_height" - f_quietly f_getvar "$__var_width" - f_quietly f_getvar "$__var_rows" + # Print final constrained values to debugging + [ "$__var_height" ] && f_quietly f_getvar "$__var_height" + [ "$__var_width" ] && f_quietly f_getvar "$__var_width" + [ "$__var_rows" ] && f_quietly f_getvar "$__var_rows" fi return $__retval # success if no debug warnings were printed @@ -2044,6 +2044,7 @@ f_dialog_menutag2index_with_help() f_dialog_init() { DIALOG_SELF_INITIALIZE= + USE_DIALOG=1 # # Clone terminal stdout so we can redirect to it from within sub-shells @@ -2087,7 +2088,7 @@ f_dialog_init() # # Process `-X' command-line option # - [ "$USE_XDIALOG" ] && DIALOG=Xdialog + [ "$USE_XDIALOG" ] && DIALOG=Xdialog USE_DIALOG= # # Sanity check, or die gracefully Copied: stable/10/usr.sbin/bsdconfig/share/keymap.subr (from r256325, head/usr.sbin/bsdconfig/share/keymap.subr) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/usr.sbin/bsdconfig/share/keymap.subr Fri Oct 11 23:12:05 2013 (r256361, copy of r256325, head/usr.sbin/bsdconfig/share/keymap.subr) @@ -0,0 +1,262 @@ +if [ ! "$_KEYMAP_SUBR" ]; then _KEYMAP_SUBR=1 +# +# Copyright (c) 2013 Devin Teske +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $FreeBSD$ +# +############################################################ INCLUDES + +BSDCFG_SHARE="/usr/share/bsdconfig" +. $BSDCFG_SHARE/common.subr || exit 1 +f_dprintf "%s: loading includes..." keymap.subr +f_include $BSDCFG_SHARE/struct.subr + +############################################################ CONFIGURATION + +# +# Defaults taken from usr.sbin/kbdmap/kbdmap.h +# +: ${DEFAULT_LANG:=en} +: ${DEFAULT_KEYMAP_DIR:=/usr/share/syscons/keymaps} + +############################################################ GLOBALS + +KEYMAPS= + +# A "keymap" from kbdmap's point of view +f_struct_define KEYMAP \ + desc \ + keym \ + mark + +# +# Default behavior is to call f_keymap_get_all() automatically when loaded. +# +: ${KEYMAP_SELF_SCAN_ALL=1} + +############################################################ FUNCTIONS + +# f_keymap_register $name $desc $keym $mark +# +# Register a keymap. A `structure' (see struct.subr) is created with the name +# keymap_$name (so make sure $name contains only alpha-numeric characters or +# the underscore, `_'). The remaining arguments after $name correspond to the +# propertise of the `KEYMAP' structure-type (defined above). +# +# If not already registered, the keymap is then appended to the KEYMAPS +# environment variable, a space-separated list of all registered keymaps. +# +f_keymap_register() +{ + local name="$1" desc="$2" keym="$3" mark="$4" + + f_struct_new KEYMAP "keymap_$name" || return $FAILURE + keymap_$name set desc "$desc" + keymap_$name set keym "$keym" + keymap_$name set mark "$mark" + + # Scan our global register to see if needs ammending + local k found= + for k in $KEYMAPS; do + [ "$k" = "$name" ] || continue + found=1 && break + done + [ "$found" ] || KEYMAPS="$KEYMAPS $name" + + return $SUCCESS +} + +# f_keymap_checkfile $keymap +# +# Check that $keymap is a readable kbdmap(5) file. Returns success if $keymap +# is a file, is readable, and exists in $DEFAULT_KEYMAP_DIR; otherwise failure. +# If debugging is enabled, an appropriate debug error message is printed if +# $keymap is not available. +# +f_keymap_checkfile() +{ + local keym="$1" + + # Fixup keymap if it doesn't already contain at least one `/' + [ "${keym#*/}" = "$keym" ] && keym="$DEFAULT_KEYMAP_DIR/$keym" + + # Short-cuts + [ -f "$keym" -a -r "$keym" ] && return $SUCCESS + f_debugging || return $FAILURE + + # Print an appropriate debug error message + if [ ! -e "$keym" ]; then + f_dprintf "%s: No such file or directory" "$keym" + elif [ ! -f "$keym" ]; then + f_dprintf "%s: Not a file!" "$keym" + elif [ ! -r "$keym" ]; then + f_dprintf "%s: Permission denied" "$keym" + fi + + return $FAILURE +} + +# f_keymap_get_all +# +# Get all keymap information for kbdmap(5) entries both in the database and +# loosely existing in $DEFAULT_KEYMAP_DIR. +# +f_keymap_get_all() +{ + local fname=f_keymap_get_all + local lang="${LC_ALL:-${LC_CTYPE:-${LANG:-$DEFAULT_LANG}}}" + [ "$lang" = "C" ] && lang="$DEFAULT_LANG" + + f_dprintf "%s: Looking for keymap files..." $fname + f_dialog_info "$msg_looking_for_keymap_files" + f_dprintf "DEFAULT_LANG=[%s]" "$DEFAULT_LANG" + + eval "$( awk -F: -v lang="$lang" -v lang_default="$DEFAULT_LANG" ' + BEGIN { + # en_US.ISO8859-1 -> en_..\.ISO8859-1 + dialect = lang + if (length(dialect) >= 6 && + substr(dialect, 3, 1) == "_") + dialect = substr(dialect, 1, 3) ".." \ + substr(dialect, 6) + printf "f_dprintf \"dialect=[%%s]\" \"%s\";\n", dialect + + # en_US.ISO8859-1 -> en + lang_abk = lang + if (length(lang_abk) >= 3 && + substr(lang_abk, 3, 1) == "_") + lang_abk = substr(lang_abk, 1, 2) + printf "f_dprintf \"lang_abk=[%%s]\" \"%s\";\n", + lang_abk + } + function find_token(buffer, token) + { + if (split(buffer, tokens, /,/) == 0) return 0 + found = 0 + for (t in tokens) + if (token == tokens[t]) { found = 1; break } + return found + } + function add_keymap(desc,mark,keym) + { + marks[keym] = mark + name = keym + gsub(/[^[:alnum:]_]/, "_", name) + gsub(/'\''/, "'\''\\'\'''\''", desc); + printf "f_keymap_checkfile %s && " \ + "f_keymap_register %s '\'%s\'' %s %u\n", + keym, name, desc, keym, mark + } + !/^[[:space:]]*(#|$)/ { + sub(/^[[:space:]]*/, "", $0) + keym = $1 + if (keym ~ /^(MENU|FONT)$/) next + lg = ($2 == "" ? lang_default : $2) + + # Match the entry and store the type of match we made + # as the mark value (so that if we make a better match + # later on with a higher mark, it overwrites previous) + + mark = marks[keym]; + if (find_token(lg, lang)) + add_keymap($3, 4, keym) # Best match + else if (mark <= 3 && find_token(lg, dialect)) + add_keymap($3, 3, keym) + else if (mark <= 2 && find_token(lg, lang_abk)) + add_keymap($3, 2, keym) + else if (mark <= 1 && find_token(lg, lang_default)) + add_keymap($3, 1, keym) + else if (mark <= 0) + add_keymap($3, 0, keym) + } + ' "$DEFAULT_KEYMAP_DIR/INDEX.${DEFAULT_KEYMAP_DIR##*/}" )" + + + # + # Look for keymaps not in database + # + local direntry keym name + set +f # glob + for direntry in "$DEFAULT_KEYMAP_DIR"/*; do + [ "${direntry##*.}" = ".kbd" ] || continue + keym="${direntry##*/}" + f_str2varname "$keym" name + f_struct keymap_$name && continue + f_keymap_checkfile "$keym" && + f_keymap_register $name "${keym%.*}" "$keym" 0 + f_dprintf "%s: not in kbdmap(5) database" "$keym" + done + + # + # Sort the items by their descriptions + # + f_dprintf "%s: Sorting keymap entries by description..." $fname + KEYMAPS=$( + for k in $KEYMAPS; do + echo -n "$k " + # NOTE: Translate '8x8' to '8x08' before sending to + # sort(1) so that things work out as we might expect. + debug= keymap_$k get desc | sed -e 's/8x8/8x08/g' + done | sort -k2 | awk '{ + printf "%s%s", (started ? " " : ""), $1; started = 1 + }' + ) + + return $SUCCESS +} + +# f_keymap_kbdcontrol $keymap +# +# Install keyboard map file from $keymap. +# +f_keymap_kbdcontrol() +{ + local keymap="$1" + + [ "$keymap" ] || return $SUCCESS + + # Fixup keymap if it doesn't already contain at least one `/' + [ "${keymap#*/}" = "$keymap" ] && keymap="$DEFAULT_KEYMAP_DIR/$keymap" + + [ "$USE_XDIALOG" ] || kbdcontrol -l "$keymap" +} + +############################################################ MAIN + +# +# Scan for keymaps unless requeted otherwise +# +f_dprintf "%s: KEYMAP_SELF_SCAN_ALL=[%s]" keymap.subr "$KEYMAP_SELF_SCAN_ALL" +case "$KEYMAP_SELF_SCAN_ALL" in +""|0|[Nn][Oo]|[Oo][Ff][Ff]|[Ff][Aa][Ll][Ss][Ee]) : do nothing ;; +*) f_keymap_get_all +esac + +f_dprintf "%s: Found %u keymap file(s)." keymap.subr \ + "$( set -- $KEYMAPS; echo $# )" + +f_dprintf "%s: Successfully loaded." keymap.subr + +fi # ! $_KEYMAP_SUBR Modified: stable/10/usr.sbin/bsdconfig/share/strings.subr ============================================================================== --- stable/10/usr.sbin/bsdconfig/share/strings.subr Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdconfig/share/strings.subr Fri Oct 11 23:12:05 2013 (r256361) @@ -26,6 +26,11 @@ if [ ! "$_STRINGS_SUBR" ]; then _STRINGS # # $FreeBSD$ # +############################################################ INCLUDES + +BSDCFG_SHARE="/usr/share/bsdconfig" +. $BSDCFG_SHARE/common.subr || exit 1 + ############################################################ GLOBALS # @@ -319,6 +324,112 @@ f_shell_unescape() f_replaceall "$__string" "'\\''" "'" "$__var_to_set" } +# f_expand_number $string [$var_to_set] +# +# Unformat $string into a number, optionally to be stored in $var_to_set. This +# function follows the SI power of two convention. +# +# The prefixes are: +# +# Prefix Description Multiplier +# k kilo 1024 +# M mega 1048576 +# G giga 1073741824 +# T tera 1099511627776 +# P peta 1125899906842624 +# E exa 1152921504606846976 +# +# NOTE: Prefixes are case-insensitive. +# +# Upon successful completion, the value 0 is returned (or stored to +# $var_to_set); otherwise -1. Reasons for a -1 return include: +# +# Given $string contains no digits. +# An unrecognized prefix was given. +# Result too large to calculate. +# +f_expand_number() +{ + local __string="$1" __var_to_set="$2" + local __cp __num + + # Remove any leading non-digits + while :; do + __cp="$__string" + __string="${__cp#[!0-9]}" + [ "$__string" = "$__cp" ] && break + done + + # Return `-1' if string didn't contain any digits + if [ ! "$__string" ]; then + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" -1 + else + echo -1 + fi + return $FAILURE + fi + + # Store the numbers + __num="${__string%%[!0-9]*}" + + # Shortcut + if [ $__num -eq 0 ]; then + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" 0 + else + echo 0 + fi + return $SUCCESS + fi + + # Remove all the leading numbers from the string to get at the prefix + while :; do + __cp="$__string" + __string="${__cp#[0-9]}" + [ "$__string" = "$__cp" ] && break + done + + # Test for invalid prefix + case "$__string" in + ""|[KkMmGgTtPpEe]*) : known prefix ;; + *) + # Unknown prefix + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" -1 + else + echo -1 + fi + return $FAILURE + esac + + # Multiply the number out + case "$__string" in + [Kk]) __num=$(( $__num * 1024 )) ;; + [Mm]) __num=$(( $__num * 1048576 )) ;; + [Gg]) __num=$(( $__num * 1073741824 )) ;; + [Tt]) __num=$(( $__num * 1099511627776 )) ;; + [Pp]) __num=$(( $__num * 1125899906842624 )) ;; + [Ee]) __num=$(( $__num * 1152921504606846976 )) ;; + esac + if [ $__num -le 0 ]; then + # Arithmetic overflow + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" -1 + else + echo -1 + fi + return $FAILURE + fi + + # Return the number + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" $__num + else + echo $__num + fi +} + ############################################################ MAIN f_dprintf "%s: Successfully loaded." strings.subr Modified: stable/10/usr.sbin/bsdconfig/share/variable.subr ============================================================================== --- stable/10/usr.sbin/bsdconfig/share/variable.subr Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdconfig/share/variable.subr Fri Oct 11 23:12:05 2013 (r256361) @@ -205,6 +205,21 @@ f_netinteractive() f_getvar $VAR_NETINTERACTIVE value && [ "$value" ] } +# f_zfsinteractive() +# +# Has the user specifically requested the ZFS-portion of configuration and +# setup to be performed interactively? Returns success if the user has asked +# for the ZFS configuration to be done interactively even if perhaps overall +# non-interactive mode has been requested (by setting nonInteractive). +# +# Returns success if $zfsInteractive is set and non-NULL. +# +f_zfsinteractive() +{ + local value + f_getvar $VAR_ZFSINTERACTIVE value && [ "$value" ] +} + ############################################################ MAIN # @@ -240,6 +255,7 @@ f_variable_new VAR_IFCONFIG ifconfig_ f_variable_new VAR_IPADDR ipaddr f_variable_new VAR_IPV6ADDR ipv6addr f_variable_new VAR_IPV6_ENABLE ipv6_activate_all_interfaces +f_variable_new VAR_KEYMAP keymap f_variable_new VAR_MEDIA_TIMEOUT MEDIA_TIMEOUT f_variable_new VAR_MEDIA_TYPE mediaType f_variable_new VAR_NAMESERVER nameserver @@ -263,6 +279,7 @@ f_variable_new VAR_SLOW_ETHER slowEther f_variable_new VAR_TRY_DHCP tryDHCP f_variable_new VAR_TRY_RTSOL tryRTSOL f_variable_new VAR_UFS_PATH ufs +f_variable_new VAR_ZFSINTERACTIVE zfsInteractive # # Self-initialize unless requested otherwise Modified: stable/10/usr.sbin/bsdinstall/bsdinstall ============================================================================== --- stable/10/usr.sbin/bsdinstall/bsdinstall Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdinstall/bsdinstall Fri Oct 11 23:12:05 2013 (r256361) @@ -28,6 +28,7 @@ : ${BSDINSTALL_LOG="/tmp/bsdinstall_log"}; export BSDINSTALL_LOG : ${BSDINSTALL_TMPETC="/tmp/bsdinstall_etc"}; export BSDINSTALL_TMPETC +: ${BSDINSTALL_TMPBOOT="/tmp/bsdinstall_boot"}; export BSDINSTALL_TMPBOOT : ${PATH_FSTAB="$BSDINSTALL_TMPETC/fstab"}; export PATH_FSTAB : ${BSDINSTALL_DISTDIR="/usr/freebsd-dist"}; export BSDINSTALL_DISTDIR : ${BSDINSTALL_CHROOT="/mnt"}; export BSDINSTALL_CHROOT @@ -35,5 +36,6 @@ VERB=${1:-auto}; shift [ -d "$BSDINSTALL_TMPETC" ] || mkdir -p "$BSDINSTALL_TMPETC" +[ -d "$BSDINSTALL_TMPBOOT" ] || mkdir -p "$BSDINSTALL_TMPBOOT" echo "Running installation step: $VERB $@" >> "$BSDINSTALL_LOG" exec "/usr/libexec/bsdinstall/$VERB" "$@" 2>> "$BSDINSTALL_LOG" Modified: stable/10/usr.sbin/bsdinstall/scripts/Makefile ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/Makefile Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdinstall/scripts/Makefile Fri Oct 11 23:12:05 2013 (r256361) @@ -2,7 +2,7 @@ SCRIPTS= auto adduser checksum config docsinstall entropy hostname jail \ keymap mirrorselect mount netconfig netconfig_ipv4 netconfig_ipv6 \ - rootpass script services time umount wlanconfig + rootpass script services time umount wlanconfig zfsboot BINDIR= /usr/libexec/bsdinstall NO_MAN= true Modified: stable/10/usr.sbin/bsdinstall/scripts/auto ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/auto Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdinstall/scripts/auto Fri Oct 11 23:12:05 2013 (r256361) @@ -93,24 +93,46 @@ fi rm $PATH_FSTAB touch $PATH_FSTAB -dialog --backtitle "FreeBSD Installer" --title "Partitioning" --extra-button \ - --extra-label "Manual" --ok-label "Guided" --cancel-label "Shell" \ - --yesno "Would you like to use the guided partitioning tool (recommended for beginners) or to set up partitions manually (experts)? You can also open a shell and set up partitions entirely by hand." 0 0 +PMODES="\ +Guided \"Partitioning Tool (Recommended for Beginners)\" \ +Manual \"Manually Configure Partitions (Expert)\" \ +Shell \"Open a shell and partition by hand\"" + +CURARCH=$( uname -m ) +case $CURARCH in + amd64|i386) # Booting ZFS Supported + PMODES="$PMODES ZFS \"Automatic Root-on-ZFS (Experimental)\"" + ;; + *) # Booting ZFS Unspported + ;; +esac -case $? in -0) # Guided +exec 3>&1 +PARTMODE=`echo $PMODES | xargs dialog --backtitle "FreeBSD Installer" \ + --title "Partitioning" \ + --menu "How would you like to partition your disk?" \ + 0 0 0 2>&1 1>&3` +if [ $? -eq $DIALOG_CANCEL ]; then exit 1; fi +exec 3>&- + +case "$PARTMODE" in +"Guided") # Guided bsdinstall autopart || error bsdinstall mount || error ;; -1) # Shell +"Shell") # Shell clear echo "Use this shell to set up partitions for the new system. When finished, mount the system at $BSDINSTALL_CHROOT and place an fstab file for the new system at $PATH_FSTAB. Then type 'exit'. You can also enter the partition editor at any time by entering 'bsdinstall partedit'." sh 2>&1 ;; -3) # Manual +"Manual") # Manual bsdinstall partedit || error bsdinstall mount || error ;; +"ZFS") # ZFS + bsdinstall zfsboot || error + bsdinstall mount || error + ;; *) error ;; Modified: stable/10/usr.sbin/bsdinstall/scripts/config ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/config Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdinstall/scripts/config Fri Oct 11 23:12:05 2013 (r256361) @@ -31,6 +31,11 @@ rm $BSDINSTALL_TMPETC/rc.conf.* cp $BSDINSTALL_TMPETC/* $BSDINSTALL_CHROOT/etc +cat $BSDINSTALL_TMPBOOT/loader.conf.* >> $BSDINSTALL_TMPBOOT/loader.conf +rm $BSDINSTALL_TMPBOOT/loader.conf.* + +cp $BSDINSTALL_TMPBOOT/* $BSDINSTALL_CHROOT/boot + # Set up other things from installed config chroot $BSDINSTALL_CHROOT /usr/bin/newaliases Modified: stable/10/usr.sbin/bsdinstall/scripts/keymap ============================================================================== --- stable/10/usr.sbin/bsdinstall/scripts/keymap Fri Oct 11 23:11:33 2013 (r256360) +++ stable/10/usr.sbin/bsdinstall/scripts/keymap Fri Oct 11 23:12:05 2013 (r256361) @@ -1,6 +1,7 @@ #!/bin/sh #- # Copyright (c) 2011 Nathan Whitehorn +# Copyright (c) 2013 Devin Teske # All rights reserved. # # Redistribution and use in source and binary forms, with or without @@ -25,11 +26,212 @@ # SUCH DAMAGE. # # $FreeBSD$ +# +############################################################ INCLUDES + +BSDCFG_SHARE="/usr/share/bsdconfig" +. $BSDCFG_SHARE/common.subr || exit 1 +f_dprintf "%s: loading includes..." "$0" +f_include $BSDCFG_SHARE/dialog.subr +f_include $BSDCFG_SHARE/keymap.subr +f_include $BSDCFG_SHARE/sysrc.subr + +############################################################ CONFIGURATION + +# +# Default file to store keymap selection in +# +: ${KEYMAPFILE:=$BSDINSTALL_TMPETC/rc.conf.keymap} + +# +# Default path to keymap INDEX containing descriptions +# +: ${MAPDESCFILE:=/usr/share/syscons/keymaps/INDEX.keymaps} + +############################################################ GLOBALS + +# +# Strings that should be moved to an i18n file and loaded with f_include_lang() +# +hline_arrows_tab_enter="Press arrows, TAB or ENTER" +msg_continue_with_keymap="Continue with %s keymap" +msg_default="default" +msg_error="Error" +msg_freebsd_installer="FreeBSD Installer" +msg_keymap_menu_text="The system console driver for FreeBSD defaults to standard \"US\"\nkeyboard map. Other keymaps can be chosen below." +msg_keymap_selection="Keymap Selection" +msg_ok="OK" +msg_select="Select" +msg_test_keymap="Test %s keymap" +msg_test_the_currently_selected_keymap="Test the currently selected keymap" +msg_test_the_keymap_by_typing="Test the keymap by typing letters, numbers, and symbols. Characters\nshould match labels on the keyboard keys. Press Enter to stop testing." + +############################################################ FUNCTIONS + +# dialog_keymap_test $keymap +# +# Activate $keymap and display an input box (without cancel button) for the +# user to test keyboard input and return. Always returns success. +# +dialog_keymap_test() +{ + local keym="$1" + local title= # Calculated below + local btitle= # Calculated below + local prompt="$msg_test_the_keymap_by_typing" + local hline= + + # Attempt to activate the keymap + if [ "$keym" ]; then + local err + err=$( f_keymap_kbdcontrol "$keym" 2>&1 > /dev/null ) + if [ "$err" ]; then + f_dialog_title "$msg_error" + f_dialog_msgbox "$err" + f_dialog_title_restore + return $FAILURE + fi + fi + + f_dialog_title "$( printf "$msg_test_keymap" "${keym:-$msg_default}" )" + title="$DIALOG_TITLE" + btitle="$DIALOG_BACKTITLE" + f_dialog_title_restore + + local height width + f_dialog_inputbox_size height width \ + "$title" "$btitle" "$prompt" "" "$hline" + + $DIALOG \ + --title "$title" \ + --backtitle "$btitle" \ + --hline "$hline" \ + --ok-label "$msg_ok" \ + --no-cancel \ + --inputbox "$prompt" \ + $height $width \ + 2>/dev/null >&$DIALOG_TERMINAL_PASSTHRU_FD -kbdcontrol -d >/dev/null 2>&1 -if [ $? -eq 0 ]; then - dialog --backtitle "FreeBSD Installer" --title "Keymap Selection" \ - --yesno "Would you like to set a non-default key mapping for your keyboard?" 0 0 || exit 0 - exec 3>&1 - kbdmap 2>&1 1>&3 | grep 'keymap=' > $BSDINSTALL_TMPETC/rc.conf.keymap + return $DIALOG_OK +} + +############################################################ MAIN + +# +# Initialize +# +f_dialog_title "$msg_keymap_selection" +f_dialog_backtitle "$msg_freebsd_installer" + +# +# Die immediately if we can't dump the current keyboard map +# +#error=$( kbdcontrol -d 2>&1 > /dev/null ) || f_die $FAILURE "%s" "$error" + +# Capture Ctrl-C for clean-up +trap 'rm -f $KEYMAPFILE; exit $FAILURE' SIGINT + +# Get a value from rc.conf(5) as initial value (if not being scripted) +f_getvar $VAR_KEYMAP keymap +if [ ! "$keymap" ]; then + keymap=$( f_sysrc_get keymap ) + case "$keymap" in [Nn][Oo]) keymap="";; esac fi + +# +# Loop until the user has finalized their selection (by clicking the +# [relabeled] Cancel button). +# +width=67 first_pass=1 back_from_testing= +[ "$USE_XDIALOG" ] && width=70 +prompt="$msg_keymap_menu_text" +hline="$hline_arrows_tab_enter" +while :; do + # *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 00:42:42 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id A0CBF8F2; Sat, 12 Oct 2013 00:42:42 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8E8312E4D; Sat, 12 Oct 2013 00:42:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9C0ggPd029651; Sat, 12 Oct 2013 00:42:42 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9C0ggGn029649; Sat, 12 Oct 2013 00:42:42 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201310120042.r9C0ggGn029649@svn.freebsd.org> From: Peter Grehan Date: Sat, 12 Oct 2013 00:42:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256363 - stable/10/sys/dev/hyperv/netvsc X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 00:42:42 -0000 Author: grehan Date: Sat Oct 12 00:42:41 2013 New Revision: 256363 URL: http://svnweb.freebsd.org/changeset/base/256363 Log: MFC r256362 Fix a lock-order reversal in the net driver by dropping the lock and holding a reference prior to calling further into the hyperv stack. Added missing FreeBSD idents. Approved by: re@ (gjb) Modified: stable/10/sys/dev/hyperv/netvsc/hv_net_vsc.h stable/10/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Directory Properties: stable/10/sys/ (props changed) stable/10/sys/dev/hyperv/ (props changed) Modified: stable/10/sys/dev/hyperv/netvsc/hv_net_vsc.h ============================================================================== --- stable/10/sys/dev/hyperv/netvsc/hv_net_vsc.h Sat Oct 12 00:32:34 2013 (r256362) +++ stable/10/sys/dev/hyperv/netvsc/hv_net_vsc.h Sat Oct 12 00:42:41 2013 (r256363) @@ -24,6 +24,8 @@ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ */ /* @@ -970,6 +972,8 @@ typedef struct hn_softc { int hn_if_flags; struct mtx hn_lock; int hn_initdone; + /* See hv_netvsc_drv_freebsd.c for rules on how to use */ + int temp_unusable; struct hv_device *hn_dev_obj; netvsc_dev *net_dev; } hn_softc_t; Modified: stable/10/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c ============================================================================== --- stable/10/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Sat Oct 12 00:32:34 2013 (r256362) +++ stable/10/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Sat Oct 12 00:42:41 2013 (r256363) @@ -52,6 +52,9 @@ * SUCH DAMAGE. */ +#include +__FBSDID("$FreeBSD$"); + #include #include #include @@ -702,6 +705,17 @@ netvsc_recv(struct hv_device *device_ctx } /* + * Rules for using sc->temp_unusable: + * 1. sc->temp_unusable can only be read or written while holding NV_LOCK() + * 2. code reading sc->temp_unusable under NV_LOCK(), and finding + * sc->temp_unusable set, must release NV_LOCK() and exit + * 3. to retain exclusive control of the interface, + * sc->temp_unusable must be set by code before releasing NV_LOCK() + * 4. only code setting sc->temp_unusable can clear sc->temp_unusable + * 5. code setting sc->temp_unusable must eventually clear sc->temp_unusable + */ + +/* * Standard ioctl entry point. Called when the user wants to configure * the interface. */ @@ -713,7 +727,8 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, netvsc_device_info device_info; struct hv_device *hn_dev; int mask, error = 0; - + int retry_cnt = 500; + switch(cmd) { case SIOCSIFADDR: @@ -723,38 +738,80 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, case SIOCSIFMTU: hn_dev = vmbus_get_devctx(sc->hn_dev); - NV_LOCK(sc); + /* Check MTU value change */ + if (ifp->if_mtu == ifr->ifr_mtu) + break; if (ifr->ifr_mtu > NETVSC_MAX_CONFIGURABLE_MTU) { error = EINVAL; - NV_UNLOCK(sc); break; } + /* Obtain and record requested MTU */ ifp->if_mtu = ifr->ifr_mtu; + + do { + NV_LOCK(sc); + if (!sc->temp_unusable) { + sc->temp_unusable = TRUE; + retry_cnt = -1; + } + NV_UNLOCK(sc); + if (retry_cnt > 0) { + retry_cnt--; + DELAY(5 * 1000); + } + } while (retry_cnt > 0); - /* - * We must remove and add back the device to cause the new + if (retry_cnt == 0) { + error = EINVAL; + break; + } + + /* We must remove and add back the device to cause the new * MTU to take effect. This includes tearing down, but not * deleting the channel, then bringing it back up. */ error = hv_rf_on_device_remove(hn_dev, HV_RF_NV_RETAIN_CHANNEL); if (error) { + NV_LOCK(sc); + sc->temp_unusable = FALSE; NV_UNLOCK(sc); break; } error = hv_rf_on_device_add(hn_dev, &device_info); if (error) { + NV_LOCK(sc); + sc->temp_unusable = FALSE; NV_UNLOCK(sc); break; } hn_ifinit_locked(sc); + NV_LOCK(sc); + sc->temp_unusable = FALSE; NV_UNLOCK(sc); break; case SIOCSIFFLAGS: - NV_LOCK(sc); + do { + NV_LOCK(sc); + if (!sc->temp_unusable) { + sc->temp_unusable = TRUE; + retry_cnt = -1; + } + NV_UNLOCK(sc); + if (retry_cnt > 0) { + retry_cnt--; + DELAY(5 * 1000); + } + } while (retry_cnt > 0); + + if (retry_cnt == 0) { + error = EINVAL; + break; + } + if (ifp->if_flags & IFF_UP) { /* * If only the state of the PROMISC flag changed, @@ -766,21 +823,14 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, */ #ifdef notyet /* Fixme: Promiscuous mode? */ - /* No promiscuous mode with Xen */ if (ifp->if_drv_flags & IFF_DRV_RUNNING && ifp->if_flags & IFF_PROMISC && !(sc->hn_if_flags & IFF_PROMISC)) { /* do something here for Hyper-V */ - ; -/* XN_SETBIT(sc, XN_RX_MODE, */ -/* XN_RXMODE_RX_PROMISC); */ } else if (ifp->if_drv_flags & IFF_DRV_RUNNING && - !(ifp->if_flags & IFF_PROMISC) && - sc->hn_if_flags & IFF_PROMISC) { + !(ifp->if_flags & IFF_PROMISC) && + sc->hn_if_flags & IFF_PROMISC) { /* do something here for Hyper-V */ - ; -/* XN_CLRBIT(sc, XN_RX_MODE, */ -/* XN_RXMODE_RX_PROMISC); */ } else #endif hn_ifinit_locked(sc); @@ -789,8 +839,10 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, hn_stop(sc); } } - sc->hn_if_flags = ifp->if_flags; + NV_LOCK(sc); + sc->temp_unusable = FALSE; NV_UNLOCK(sc); + sc->hn_if_flags = ifp->if_flags; error = 0; break; case SIOCSIFCAP: @@ -838,7 +890,6 @@ hn_stop(hn_softc_t *sc) int ret; struct hv_device *device_ctx = vmbus_get_devctx(sc->hn_dev); - NV_LOCK_ASSERT(sc); ifp = sc->hn_ifp; printf(" Closing Device ...\n"); @@ -859,6 +910,10 @@ hn_start(struct ifnet *ifp) sc = ifp->if_softc; NV_LOCK(sc); + if (sc->temp_unusable) { + NV_UNLOCK(sc); + return; + } hn_start_locked(ifp); NV_UNLOCK(sc); } @@ -873,8 +928,6 @@ hn_ifinit_locked(hn_softc_t *sc) struct hv_device *device_ctx = vmbus_get_devctx(sc->hn_dev); int ret; - NV_LOCK_ASSERT(sc); - ifp = sc->hn_ifp; if (ifp->if_drv_flags & IFF_DRV_RUNNING) { @@ -902,7 +955,17 @@ hn_ifinit(void *xsc) hn_softc_t *sc = xsc; NV_LOCK(sc); + if (sc->temp_unusable) { + NV_UNLOCK(sc); + return; + } + sc->temp_unusable = TRUE; + NV_UNLOCK(sc); + hn_ifinit_locked(sc); + + NV_LOCK(sc); + sc->temp_unusable = FALSE; NV_UNLOCK(sc); } From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 06:08:23 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id E43F3B95; Sat, 12 Oct 2013 06:08:22 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id B4CAE2BDD; Sat, 12 Oct 2013 06:08:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9C68MnM097155; Sat, 12 Oct 2013 06:08:22 GMT (envelope-from rpaulo@svn.freebsd.org) Received: (from rpaulo@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9C68Jqr097129; Sat, 12 Oct 2013 06:08:19 GMT (envelope-from rpaulo@svn.freebsd.org) Message-Id: <201310120608.r9C68Jqr097129@svn.freebsd.org> From: Rui Paulo Date: Sat, 12 Oct 2013 06:08:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256366 - in stable/10: . etc etc/atf etc/mtree lib/libcrypt/tests share share/atf share/examples share/examples/atf share/man/man5 share/man/man7 share/mk share/xml share/xsl tools/bui... X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 06:08:23 -0000 Author: rpaulo Date: Sat Oct 12 06:08:18 2013 New Revision: 256366 URL: http://svnweb.freebsd.org/changeset/base/256366 Log: MFC 256365 Remove most of the ATF tools and the _atf user. Approved by: re Deleted: stable/10/etc/atf/ stable/10/share/atf/ stable/10/share/examples/atf/ stable/10/share/xml/ stable/10/share/xsl/ stable/10/usr.bin/atf/atf-config/ stable/10/usr.bin/atf/atf-report/ stable/10/usr.bin/atf/atf-run/ stable/10/usr.bin/atf/atf-version/ Modified: stable/10/ObsoleteFiles.inc (contents, props changed) stable/10/etc/Makefile stable/10/etc/ftpusers stable/10/etc/group stable/10/etc/master.passwd stable/10/etc/mtree/BSD.root.dist stable/10/etc/mtree/BSD.usr.dist stable/10/lib/libcrypt/tests/crypt_tests.c stable/10/share/Makefile stable/10/share/examples/Makefile stable/10/share/man/man5/Makefile stable/10/share/man/man7/Makefile stable/10/share/mk/atf.test.mk stable/10/tools/build/mk/OptionalObsoleteFiles.inc stable/10/usr.bin/atf/Makefile stable/10/usr.bin/atf/Makefile.inc Directory Properties: stable/10/ (props changed) Modified: stable/10/ObsoleteFiles.inc ============================================================================== --- stable/10/ObsoleteFiles.inc Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/ObsoleteFiles.inc Sat Oct 12 06:08:18 2013 (r256366) @@ -38,6 +38,25 @@ # xargs -n1 | sort | uniq -d; # done +# 20131013: Removal of the ATF tools +OLD_FILES+=etc/atf/FreeBSD.conf +OLD_FILES+=etc/atf/atf-run.hooks +OLD_FILES+=etc/atf/common.conf +OLD_FILES+=usr/bin/atf-config +OLD_FILES+=usr/bin/atf-report +OLD_FILES+=usr/bin/atf-run +OLD_FILES+=usr/bin/atf-version +OLD_FILES+=usr/share/atf/atf-run.hooks +OLD_FILES+=usr/share/examples/atf/atf-run.hooks +OLD_FILES+=usr/share/examples/atf/tests-results.css +OLD_FILES+=usr/share/man/man1/atf-config.1.gz +OLD_FILES+=usr/share/man/man1/atf-report.1.gz +OLD_FILES+=usr/share/man/man1/atf-run.1.gz +OLD_FILES+=usr/share/man/man1/atf-version.1.gz +OLD_FILES+=usr/share/man/man5/atf-formats.5.gz +OLD_FILES+=usr/share/man/man7/atf.7.gz +OLD_FILES+=usr/share/xml/atf/tests-results.dtd +OLD_FILES+=usr/share/xsl/atf/tests-results.xsl # 20131009: freebsd-version moved from /libexec to /bin OLD_FILES+=libexec/freebsd-version # 20131001: ar and ranlib from binutils not used @@ -6093,6 +6112,13 @@ OLD_LIBS+=usr/lib/libkse.so.1 OLD_LIBS+=usr/lib/liblwres.so.3 OLD_LIBS+=usr/lib/pam_ftp.so.2 +# 20131013: Removal of the ATF tools +OLD_DIRS+=etc/atf +OLD_DIRS+=usr/share/examples/atf +OLD_DIRS+=usr/share/xml/atf +OLD_DIRS+=usr/share/xml +OLD_DIRS+=usr/share/xsl/atf +OLD_DIRS+=usr/share/xsl # 20040925: bind9 import OLD_DIRS+=usr/share/doc/bind/html OLD_DIRS+=usr/share/doc/bind/misc Modified: stable/10/etc/Makefile ============================================================================== --- stable/10/etc/Makefile Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/etc/Makefile Sat Oct 12 06:08:18 2013 (r256366) @@ -215,9 +215,6 @@ distribution: echo "./etc/spwd.db type=file mode=0600 uname=root gname=wheel"; \ ) | ${METALOG.add} .endif -.if ${MK_ATF} != "no" - ${_+_}cd ${.CURDIR}/atf; ${MAKE} install -.endif .if ${MK_BLUETOOTH} != "no" ${_+_}cd ${.CURDIR}/bluetooth; ${MAKE} install .endif Modified: stable/10/etc/ftpusers ============================================================================== --- stable/10/etc/ftpusers Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/etc/ftpusers Sat Oct 12 06:08:18 2013 (r256366) @@ -15,7 +15,6 @@ man sshd smmsp mailnull -_atf bind unbound proxy Modified: stable/10/etc/group ============================================================================== --- stable/10/etc/group Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/etc/group Sat Oct 12 06:08:18 2013 (r256366) @@ -16,7 +16,6 @@ staff:*:20: sshd:*:22: smmsp:*:25: mailnull:*:26: -_atf:*:27: guest:*:31: bind:*:53: unbound:*:59: Modified: stable/10/etc/master.passwd ============================================================================== --- stable/10/etc/master.passwd Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/etc/master.passwd Sat Oct 12 06:08:18 2013 (r256366) @@ -13,7 +13,6 @@ man:*:9:9::0:0:Mister Man Pages:/usr/sha sshd:*:22:22::0:0:Secure Shell Daemon:/var/empty:/usr/sbin/nologin smmsp:*:25:25::0:0:Sendmail Submission User:/var/spool/clientmqueue:/usr/sbin/nologin mailnull:*:26:26::0:0:Sendmail Default User:/var/spool/mqueue:/usr/sbin/nologin -_atf:*:27:27::0:0:& pseudo-user:/nonexistent:/usr/sbin/nologin bind:*:53:53::0:0:Bind Sandbox:/:/usr/sbin/nologin unbound:*:59:59::0:0:Unbound DNS Resolver:/var/unbound:/usr/sbin/nologin proxy:*:62:62::0:0:Packet Filter pseudo-user:/nonexistent:/usr/sbin/nologin Modified: stable/10/etc/mtree/BSD.root.dist ============================================================================== --- stable/10/etc/mtree/BSD.root.dist Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/etc/mtree/BSD.root.dist Sat Oct 12 06:08:18 2013 (r256366) @@ -24,8 +24,6 @@ etc X11 .. - atf - .. bluetooth .. defaults Modified: stable/10/etc/mtree/BSD.usr.dist ============================================================================== --- stable/10/etc/mtree/BSD.usr.dist Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/etc/mtree/BSD.usr.dist Sat Oct 12 06:08:18 2013 (r256366) @@ -299,8 +299,6 @@ .. IPv6 .. - atf - .. bhyve .. bootforth @@ -1410,14 +1408,6 @@ catalog .. .. - xml - atf - .. - .. - xsl - atf - .. - .. zoneinfo Africa .. Modified: stable/10/lib/libcrypt/tests/crypt_tests.c ============================================================================== --- stable/10/lib/libcrypt/tests/crypt_tests.c Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/lib/libcrypt/tests/crypt_tests.c Sat Oct 12 06:08:18 2013 (r256366) @@ -43,7 +43,7 @@ ATF_TC_BODY(invalid, tc) /* * This function must not do anything except enumerate - * the test cases, else atf-run is likely to be upset. + * the test cases, per atf-c-api(3). */ ATF_TP_ADD_TCS(tp) { Modified: stable/10/share/Makefile ============================================================================== --- stable/10/share/Makefile Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/share/Makefile Sat Oct 12 06:08:18 2013 (r256366) @@ -5,8 +5,7 @@ # Do not include `info' in the SUBDIR list, it is handled separately. -SUBDIR= ${_atf} \ - ${_colldef} \ +SUBDIR= ${_colldef} \ ${_dict} \ ${_doc} \ dtrace \ @@ -27,16 +26,10 @@ SUBDIR= ${_atf} \ tabset \ termcap \ ${_timedef} \ - xml \ - xsl \ ${_zoneinfo} # NB: keep these sorted by MK_* knobs -.if ${MK_ATF} != "no" -_atf= atf -.endif - .if ${MK_BSNMP} != "no" _snmp= snmp .endif Modified: stable/10/share/examples/Makefile ============================================================================== --- stable/10/share/examples/Makefile Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/share/examples/Makefile Sat Oct 12 06:08:18 2013 (r256366) @@ -241,9 +241,6 @@ etc-examples: .if ${SHARED} != "symlinks" SUBDIR= smbfs -.if ${MK_ATF} != "no" -SUBDIR+=atf -.endif .if ${MK_IPFILTER} != "no" SUBDIR+=ipfilter .endif Modified: stable/10/share/man/man5/Makefile ============================================================================== --- stable/10/share/man/man5/Makefile Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/share/man/man5/Makefile Sat Oct 12 06:08:18 2013 (r256366) @@ -6,7 +6,6 @@ #MISSING: dump.5 plot.5 MAN= acct.5 \ ar.5 \ - ${_atf_formats.5} \ a.out.5 \ bluetooth.device.conf.5 \ bluetooth.hosts.5 \ @@ -80,12 +79,6 @@ MLINKS+=quota.user.5 quota.group.5 MLINKS+=rc.conf.5 rc.conf.local.5 MLINKS+=resolver.5 resolv.conf.5 -.if ${MK_ATF} != "no" -ATF= ${.CURDIR}/../../../contrib/atf -.PATH: ${ATF}/doc -_atf_formats.5= atf-formats.5 -.endif - .if ${MK_FREEBSD_UPDATE} != "no" MAN+= freebsd-update.conf.5 .endif Modified: stable/10/share/man/man7/Makefile ============================================================================== --- stable/10/share/man/man7/Makefile Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/share/man/man7/Makefile Sat Oct 12 06:08:18 2013 (r256366) @@ -36,17 +36,4 @@ MLINKS+= c99.7 c78.7 MLINKS+= c99.7 c89.7 MLINKS+= c99.7 c90.7 -.if ${MK_ATF} != "no" -ATF= ${.CURDIR}/../../../contrib/atf -.PATH: ${ATF}/doc -MAN+= atf.7 - -CLEANFILES+= atf.7 atf.7.tmp -atf.7: atf.7.in - sed -e 's,__DOCDIR__,${DOCDIR}/atf,g' \ - -e 's,__TESTSDIR__,${TESTSBASE},g' \ - < ${.ALLSRC} > ${.TARGET}.tmp - mv ${.TARGET}.tmp ${.TARGET} -.endif - .include Modified: stable/10/share/mk/atf.test.mk ============================================================================== --- stable/10/share/mk/atf.test.mk Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/share/mk/atf.test.mk Sat Oct 12 06:08:18 2013 (r256366) @@ -51,98 +51,4 @@ ${_T}: ${TESTS_SH_SRC_${_T}} .endfor .endif -ATFFILE?= auto - -.if ${ATFFILE:tl} != "no" -FILES+= Atffile -FILESDIR_Atffile= ${TESTSDIR} - -.if ${ATFFILE:tl} == "auto" -CLEANFILES+= Atffile Atffile.tmp - -Atffile: Makefile - @{ echo 'Content-Type: application/X-atf-atffile; version="1"'; \ - echo; \ - echo '# Automatically generated by atf-test.mk.'; \ - echo; \ - echo 'prop: test-suite = "'`uname -o`'"'; \ - echo; \ - for tp in ${ATF_TESTS}; do \ - echo "tp: $${tp}"; \ - done; } >Atffile.tmp - @mv Atffile.tmp Atffile -.endif -.endif - -# Generate support variables for atf-test. -# -# atf-test can only work for native builds, i.e. a build host of a particular -# OS building a release for the same OS version and architecture. The target -# runs ATF, which is on the build host, and the tests execute code built for -# the target host. -# -# Due to the dependencies of the binaries built by the source tree and how they -# are used by tests, it is highly possible for a execution of "make test" to -# report bogus results unless the new binaries are put in place. - -# XXX (gcooper): Executing ATF from outside the source tree is improper; it -# should be built as part of the OS toolchain build for the host OS and -# executed from there. -ATF_PATH+= ${DESTDIR}/bin ${DESTDIR}/sbin ${DESTDIR}/usr/bin ${DESTDIR}/usr/sbin -TESTS_ENV+= PATH=${ATF_PATH:ts:}:${PATH} - -ATF_BUILD_CC?= ${DESTDIR}/usr/bin/cc -ATF_BUILD_CPP?= ${DESTDIR}/usr/bin/cpp -ATF_BUILD_CXX?= ${DESTDIR}/usr/bin/c++ -ATF_CONFDIR?= ${DESTDIR}/etc -ATF_INCLUDEDIR?= ${DESTDIR}/usr/include -ATF_LIBDIR?= ${DESTDIR}/usr/lib -ATF_LIBEXECDIR?= ${DESTDIR}/usr/libexec -ATF_PKGDATADIR?= ${DESTDIR}/usr/share/atf -ATF_SHELL?= ${DESTDIR}/bin/sh -LD_LIBRARY_PATH?= ${TESTS_LD_LIBRARY_PATH:tW:S/ /:/g} - -ATF_ENV_VARS= \ - ATF_BUILD_CC \ - ATF_BUILD_CPP \ - ATF_BUILD_CXX \ - ATF_CONFDIR \ - ATF_INCLUDEDIR \ - ATF_LIBDIR \ - ATF_LIBEXECDIR \ - ATF_PKGDATADIR \ - ATF_SHELL \ - -.for v in ${ATF_ENV_VARS} -.if !empty($v) -TESTS_ENV+= $v=${$v} -.endif -.endfor - -_TESTS_FIFO= ${.OBJDIR}/atf-run.fifo -_TESTS_LOG= ${.OBJDIR}/atf-run.log -CLEANFILES+= ${_TESTS_FIFO} ${_TESTS_LOG} - -ATF_BIN?= ${DESTDIR}/usr/bin -ATF_REPORT?= ${ATF_BIN}/atf-report -ATF_RUN?= ${ATF_BIN}/atf-run - -.PHONY: realtest -realtest: -.if defined(TESTSDIR) - @set -e; \ - cd ${DESTDIR}${TESTSDIR}; \ - rm -f ${_TESTS_FIFO}; \ - mkfifo ${_TESTS_FIFO}; \ - tee ${_TESTS_LOG} < ${_TESTS_FIFO} | ${TESTS_ENV} ${ATF_REPORT} & \ - set +e; \ - ${TESTS_ENV} ${ATF_RUN} >> ${_TESTS_FIFO}; \ - result=$${?}; \ - wait; \ - rm -f ${_TESTS_FIFO}; \ - echo; \ - echo "*** The verbatim output of atf-run has been saved to ${_TESTS_LOG}"; \ - exit $${result} -.endif - .include Modified: stable/10/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- stable/10/tools/build/mk/OptionalObsoleteFiles.inc Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/tools/build/mk/OptionalObsoleteFiles.inc Sat Oct 12 06:08:18 2013 (r256366) @@ -69,15 +69,7 @@ OLD_FILES+=usr/share/man/man8/atrun.8.gz .endif .if ${MK_ATF} == no -OLD_DIRS+=etc/atf -OLD_FILES+=etc/atf/FreeBSD.conf -OLD_FILES+=etc/atf/atf-run.hooks -OLD_FILES+=etc/atf/common.conf -OLD_FILES+=usr/bin/atf-config -OLD_FILES+=usr/bin/atf-report -OLD_FILES+=usr/bin/atf-run OLD_FILES+=usr/bin/atf-sh -OLD_FILES+=usr/bin/atf-version OLD_DIRS+=usr/include/atf-c OLD_FILES+=usr/include/atf-c/build.h OLD_FILES+=usr/include/atf-c/check.h @@ -110,34 +102,20 @@ OLD_FILES+=usr/lib/libatf-c++.so OLD_FILES+=usr/lib/libatf-c.a OLD_FILES+=usr/libexec/atf-check OLD_DIRS+=usr/share/atf -OLD_FILES+=usr/share/atf/atf-run.hooks OLD_FILES+=usr/share/atf/libatf-sh.subr OLD_DIRS+=usr/share/doc/atf OLD_FILES+=usr/share/doc/atf/AUTHORS OLD_FILES+=usr/share/doc/atf/COPYING OLD_FILES+=usr/share/doc/atf/NEWS OLD_FILES+=usr/share/doc/atf/README -OLD_DIRS+=usr/share/examples/atf -OLD_FILES+=usr/share/examples/atf/atf-run.hooks -OLD_FILES+=usr/share/examples/atf/tests-results.css OLD_FILES+=usr/share/man/man1/atf-check.1.gz -OLD_FILES+=usr/share/man/man1/atf-config.1.gz -OLD_FILES+=usr/share/man/man1/atf-report.1.gz -OLD_FILES+=usr/share/man/man1/atf-run.1.gz OLD_FILES+=usr/share/man/man1/atf-sh.1.gz OLD_FILES+=usr/share/man/man1/atf-test-program.1.gz -OLD_FILES+=usr/share/man/man1/atf-version.1.gz OLD_FILES+=usr/share/man/man3/atf-c-api.3.gz OLD_FILES+=usr/share/man/man3/atf-c++-api.3.gz OLD_FILES+=usr/share/man/man3/atf-sh-api.3.gz OLD_FILES+=usr/share/man/man4/atf-test-case.4.gz -OLD_FILES+=usr/share/man/man5/atf-formats.5.gz -OLD_FILES+=usr/share/man/man7/atf.7.gz OLD_FILES+=usr/share/mk/atf.test.mk -OLD_DIRS+=usr/share/xml/atf -OLD_FILES+=usr/share/xml/atf/tests-results.dtd -OLD_DIRS+=usr/share/xsl/atf -OLD_FILES+=usr/share/xsl/atf/tests-results.xsl .endif .if ${MK_ATM} == no Modified: stable/10/usr.bin/atf/Makefile ============================================================================== --- stable/10/usr.bin/atf/Makefile Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/usr.bin/atf/Makefile Sat Oct 12 06:08:18 2013 (r256366) @@ -25,10 +25,6 @@ # # $FreeBSD$ -SUBDIR= atf-config \ - atf-report \ - atf-run \ - atf-sh \ - atf-version +SUBDIR= atf-sh .include Modified: stable/10/usr.bin/atf/Makefile.inc ============================================================================== --- stable/10/usr.bin/atf/Makefile.inc Sat Oct 12 06:06:53 2013 (r256365) +++ stable/10/usr.bin/atf/Makefile.inc Sat Oct 12 06:08:18 2013 (r256366) @@ -2,7 +2,5 @@ ATF= ${.CURDIR}/../../../contrib/atf -CFLAGS+= -DGDB=\"gdb\" - BINDIR?= /usr/bin WARNS?= 3 From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 07:39:24 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id C4CD97DB; Sat, 12 Oct 2013 07:39:24 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id B1F6A2ED9; Sat, 12 Oct 2013 07:39:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9C7dOau043890; Sat, 12 Oct 2013 07:39:24 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9C7dOlY043889; Sat, 12 Oct 2013 07:39:24 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201310120739.r9C7dOlY043889@svn.freebsd.org> From: Eitan Adler Date: Sat, 12 Oct 2013 07:39:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256368 - stable/10/share/misc X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 07:39:24 -0000 Author: eadler Date: Sat Oct 12 07:39:24 2013 New Revision: 256368 URL: http://svnweb.freebsd.org/changeset/base/256368 Log: MFC r256327: Fix NetBSD release number Approved by: re (glebius) Modified: stable/10/share/misc/bsd-family-tree Directory Properties: stable/10/share/ (props changed) stable/10/share/misc/ (props changed) Modified: stable/10/share/misc/bsd-family-tree ============================================================================== --- stable/10/share/misc/bsd-family-tree Sat Oct 12 07:00:51 2013 (r256367) +++ stable/10/share/misc/bsd-family-tree Sat Oct 12 07:39:24 2013 (r256368) @@ -275,7 +275,7 @@ FreeBSD 5.2 | | | | | | | | 6.0.2 | | | | | | | | | OpenBSD 5.3 DragonFly 3.4.1 | | | | | | NetBSD | | - | | | | | | 6.0.2 | | + | | | | | | 6.0.3 | | | | | | | | | | | | | | | |`-NetBSD 6.1 | | | | FreeBSD | | | | | From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 07:50:15 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 9A18794D; Sat, 12 Oct 2013 07:50:15 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 85C392F2E; Sat, 12 Oct 2013 07:50:15 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9C7oFWZ049235; Sat, 12 Oct 2013 07:50:15 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9C7oFfs049234; Sat, 12 Oct 2013 07:50:15 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201310120750.r9C7oFfs049234@svn.freebsd.org> From: Eitan Adler Date: Sat, 12 Oct 2013 07:50:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256369 - stable/10/share/syscons/keymaps X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 07:50:15 -0000 Author: eadler Date: Sat Oct 12 07:50:15 2013 New Revision: 256369 URL: http://svnweb.freebsd.org/changeset/base/256369 Log: MFC r256367: Fix the formatting for the danish keymap. Approved by: re (glebius) Modified: stable/10/share/syscons/keymaps/INDEX.keymaps Directory Properties: stable/10/share/syscons/ (props changed) Modified: stable/10/share/syscons/keymaps/INDEX.keymaps ============================================================================== --- stable/10/share/syscons/keymaps/INDEX.keymaps Sat Oct 12 07:39:24 2013 (r256368) +++ stable/10/share/syscons/keymaps/INDEX.keymaps Sat Oct 12 07:50:15 2013 (r256369) @@ -117,7 +117,7 @@ danish.cp865.kbd:fr:Danois Code page 865 danish.cp865.kbd:pt:Dinamarquês Codepage 865 danish.cp865.kbd:es:Danés Codepage 865 -danish.iso.macbook.kbd:Danish ISO-8859-1 (macbook) +danish.iso.macbook.kbd:da:Danish ISO-8859-1 (macbook) dutch.iso.acc.kbd:en:Dutch ISO keymap (accent keys) From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 15:31:40 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 5AEC0223; Sat, 12 Oct 2013 15:31:40 +0000 (UTC) (envelope-from markm@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 443AD22D9; Sat, 12 Oct 2013 15:31:40 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9CFVeBI088369; Sat, 12 Oct 2013 15:31:40 GMT (envelope-from markm@svn.freebsd.org) Received: (from markm@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9CFVa86088259; Sat, 12 Oct 2013 15:31:36 GMT (envelope-from markm@svn.freebsd.org) Message-Id: <201310121531.r9CFVa86088259@svn.freebsd.org> From: Mark Murray Date: Sat, 12 Oct 2013 15:31:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256381 - in stable/10: etc/defaults etc/rc.d share/examples/kld/random_adaptor share/man/man4 sys/boot/forth sys/conf sys/dev/glxsb sys/dev/hifn sys/dev/random sys/dev/rndtest sys/dev/... X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 15:31:40 -0000 Author: markm Date: Sat Oct 12 15:31:36 2013 New Revision: 256381 URL: http://svnweb.freebsd.org/changeset/base/256381 Log: Merge from project branch via main. Uninteresting commits are trimmed. Refactor of /dev/random device. Main points include: * Userland seeding is no longer used. This auto-seeds at boot time on PC/Desktop setups; this may need some tweeking and intelligence from those folks setting up embedded boxes, but the work is believed to be minimal. * An entropy cache is written to /entropy (even during installation) and the kernel uses this at next boot. * An entropy file written to /boot/entropy can be loaded by loader(8) * Hardware sources such as rdrand are fed into Yarrow, and are no longer available raw. ------------------------------------------------------------------------ r256240 | des | 2013-10-09 21:14:16 +0100 (Wed, 09 Oct 2013) | 4 lines Add a RANDOM_RWFILE option and hide the entropy cache code behind it. Rename YARROW_RNG and FORTUNA_RNG to RANDOM_YARROW and RANDOM_FORTUNA. Add the RANDOM_* options to LINT. ------------------------------------------------------------------------ r256239 | des | 2013-10-09 21:12:59 +0100 (Wed, 09 Oct 2013) | 2 lines Define RANDOM_PURE_RNDTEST for rndtest(4). ------------------------------------------------------------------------ r256204 | des | 2013-10-09 18:51:38 +0100 (Wed, 09 Oct 2013) | 2 lines staticize struct random_hardware_source ------------------------------------------------------------------------ r256203 | markm | 2013-10-09 18:50:36 +0100 (Wed, 09 Oct 2013) | 2 lines Wrap some policy-rich code in 'if NOTYET' until we can thresh out what it really needs to do. ------------------------------------------------------------------------ r256184 | des | 2013-10-09 10:13:12 +0100 (Wed, 09 Oct 2013) | 2 lines Re-add /dev/urandom for compatibility purposes. ------------------------------------------------------------------------ r256182 | des | 2013-10-09 10:11:14 +0100 (Wed, 09 Oct 2013) | 3 lines Add missing include guards and move the existing ones out of the implementation namespace. ------------------------------------------------------------------------ r256168 | markm | 2013-10-08 23:14:07 +0100 (Tue, 08 Oct 2013) | 10 lines Fix some just-noticed problems: o Allow this to work with "nodevice random" by fixing where the MALLOC pool is defined. o Fix the explicit reseed code. This was correct as submitted, but in the project branch doesn't need to set the "seeded" bit as this is done correctly in the "unblock" function. o Remove some debug ifdeffing. o Adjust comments. ------------------------------------------------------------------------ r256159 | markm | 2013-10-08 19:48:11 +0100 (Tue, 08 Oct 2013) | 6 lines Time to eat crow for me. I replaced the sx_* locks that Arthur used with regular mutexes; this turned out the be the wrong thing to do as the locks need to be sleepable. Revert this folly. # Submitted by: Arthur Mesh (In original diff) ------------------------------------------------------------------------ r256138 | des | 2013-10-08 12:05:26 +0100 (Tue, 08 Oct 2013) | 10 lines Add YARROW_RNG and FORTUNA_RNG to sys/conf/options. Add a SYSINIT that forces a reseed during proc0 setup, which happens fairly late in the boot process. Add a RANDOM_DEBUG option which enables some debugging printf()s. Add a new RANDOM_ATTACH entropy source which harvests entropy from the get_cyclecount() delta across each call to a device attach method. ------------------------------------------------------------------------ r256135 | markm | 2013-10-08 07:54:52 +0100 (Tue, 08 Oct 2013) | 8 lines Debugging. My attempt at EVENTHANDLER(multiuser) was a failure; use EVENTHANDLER(mountroot) instead. This means we can't count on /var being present, so something will need to be done about harvesting /var/db/entropy/... . Some policy now needs to be sorted out, and a pre-sync cache needs to be written, but apart from that we are now ready to go. Over to review. ------------------------------------------------------------------------ r256094 | markm | 2013-10-06 23:45:02 +0100 (Sun, 06 Oct 2013) | 8 lines Snapshot. Looking pretty good; this mostly works now. New code includes: * Read cached entropy at startup, both from files and from loader(8) preloaded entropy. Failures are soft, but announced. Untested. * Use EVENTHANDLER to do above just before we go multiuser. Untested. ------------------------------------------------------------------------ r256088 | markm | 2013-10-06 14:01:42 +0100 (Sun, 06 Oct 2013) | 2 lines Fix up the man page for random(4). This mainly removes no-longer-relevant details about HW RNGs, reseeding explicitly and user-supplied entropy. ------------------------------------------------------------------------ r256087 | markm | 2013-10-06 13:43:42 +0100 (Sun, 06 Oct 2013) | 6 lines As userland writing to /dev/random is no more, remove the "better than nothing" bootstrap mode. Add SWI harvesting to the mix. My box seeds Yarrow by itself in a few seconds! YMMV; more to follow. ------------------------------------------------------------------------ r256086 | markm | 2013-10-06 13:40:32 +0100 (Sun, 06 Oct 2013) | 11 lines Debug run. This now works, except that the "live" sources haven't been tested. With all sources turned on, this unlocks itself in a couple of seconds! That is no my box, and there is no guarantee that this will be the case everywhere. * Cut debug prints. * Use the same locks/mutexes all the way through. * Be a tad more conservative about entropy estimates. ------------------------------------------------------------------------ r256084 | markm | 2013-10-06 13:35:29 +0100 (Sun, 06 Oct 2013) | 5 lines Don't use the "real" assembler mnemonics; older compilers may not understand them (like when building CURRENT on 9.x). # Submitted by: Konstantin Belousov ------------------------------------------------------------------------ r256081 | markm | 2013-10-06 10:55:28 +0100 (Sun, 06 Oct 2013) | 12 lines SNAPSHOT. Simplify the malloc pools; We only need one for this device. Simplify the harvest queue. Marginally improve the entropy pool hashing, making it a bit faster in the process. Connect up the hardware "live" source harvesting. This is simplistic for now, and will need to be made rate-adaptive. All of the above passes a compile test but needs to be debugged. ------------------------------------------------------------------------ r256042 | markm | 2013-10-04 07:55:06 +0100 (Fri, 04 Oct 2013) | 25 lines Snapshot. This passes the build test, but has not yet been finished or debugged. Contains: * Refactor the hardware RNG CPU instruction sources to feed into the software mixer. This is unfinished. The actual harvesting needs to be sorted out. Modified by me (see below). * Remove 'frac' parameter from random_harvest(). This was never used and adds extra code for no good reason. * Remove device write entropy harvesting. This provided a weak attack vector, was not very good at bootstrapping the device. To follow will be a replacement explicit reseed knob. * Separate out all the RANDOM_PURE sources into separate harvest entities. This adds some secuity in the case where more than one is present. * Review all the code and fix anything obviously messy or inconsistent. Address som review concerns while I'm here, like rename the pseudo-rng to 'dummy'. # Submitted by: Arthur Mesh (the first item) ------------------------------------------------------------------------ r255319 | markm | 2013-09-06 18:51:52 +0100 (Fri, 06 Sep 2013) | 4 lines Yarrow wants entropy estimations to be conservative; the usual idea is that if you are certain you have N bits of entropy, you declare N/2. ------------------------------------------------------------------------ r255075 | markm | 2013-08-30 18:47:53 +0100 (Fri, 30 Aug 2013) | 4 lines Remove short-lived idea; thread to harvest (eg) RDRAND enropy into the usual harvest queues. It was a nifty idea, but too heavyweight. # Submitted by: Arthur Mesh ------------------------------------------------------------------------ r255071 | markm | 2013-08-30 12:42:57 +0100 (Fri, 30 Aug 2013) | 4 lines Separate out the Software RNG entropy harvesting queue and thread into its own files. # Submitted by: Arthur Mesh ------------------------------------------------------------------------ r254934 | markm | 2013-08-26 20:07:03 +0100 (Mon, 26 Aug 2013) | 2 lines Remove the short-lived namei experiment. ------------------------------------------------------------------------ r254928 | markm | 2013-08-26 19:35:21 +0100 (Mon, 26 Aug 2013) | 2 lines Snapshot; Do some running repairs on entropy harvesting. More needs to follow. ------------------------------------------------------------------------ r254927 | markm | 2013-08-26 19:29:51 +0100 (Mon, 26 Aug 2013) | 15 lines Snapshot of current work; 1) Clean up namespace; only use "Yarrow" where it is Yarrow-specific or close enough to the Yarrow algorithm. For the rest use a neutral name. 2) Tidy up headers; put private stuff in private places. More could be done here. 3) Streamline the hashing/encryption; no need for a 256-bit counter; 128 bits will last for long enough. There are bits of debug code lying around; these will be removed at a later stage. ------------------------------------------------------------------------ r254784 | markm | 2013-08-24 14:54:56 +0100 (Sat, 24 Aug 2013) | 39 lines 1) example (partially humorous random_adaptor, that I call "EXAMPLE") * It's not meant to be used in a real system, it's there to show how the basics of how to create interfaces for random_adaptors. Perhaps it should belong in a manual page 2) Move probe.c's functionality in to random_adaptors.c * rename random_ident_hardware() to random_adaptor_choose() 3) Introduce a new way to choose (or select) random_adaptors via tunable "rngs_want" It's a list of comma separated names of adaptors, ordered by preferences. I.e.: rngs_want="yarrow,rdrand" Such setting would cause yarrow to be preferred to rdrand. If neither of them are available (or registered), then system will default to something reasonable (currently yarrow). If yarrow is not present, then we fall back to the adaptor that's first on the list of registered adaptors. 4) Introduce a way where RNGs can play a role of entropy source. This is mostly useful for HW rngs. The way I envision this is that every HW RNG will use this functionality by default. Functionality to disable this is also present. I have an example of how to use this in random_adaptor_example.c (see modload event, and init function) 5) fix kern.random.adaptors from kern.random.adaptors: yarrowpanicblock to kern.random.adaptors: yarrow,panic,block 6) add kern.random.active_adaptor to indicate currently selected adaptor: root@freebsd04:~ # sysctl kern.random.active_adaptor kern.random.active_adaptor: yarrow # Submitted by: Arthur Mesh Submitted by: Dag-Erling Smørgrav , Arthur Mesh Reviewed by: des@FreeBSD.org Approved by: re (delphij) Approved by: secteam (des,delphij) Added: stable/10/sys/dev/random/dummy_rng.c (contents, props changed) stable/10/sys/dev/random/live_entropy_sources.c (contents, props changed) stable/10/sys/dev/random/live_entropy_sources.h (contents, props changed) stable/10/sys/dev/random/rwfile.c (contents, props changed) stable/10/sys/dev/random/rwfile.h (contents, props changed) Deleted: stable/10/sys/dev/random/pseudo_rng.c Modified: stable/10/etc/defaults/rc.conf stable/10/etc/rc.d/initrandom stable/10/share/examples/kld/random_adaptor/random_adaptor_example.c stable/10/share/man/man4/random.4 stable/10/sys/boot/forth/loader.conf stable/10/sys/conf/NOTES stable/10/sys/conf/files stable/10/sys/conf/files.amd64 stable/10/sys/conf/files.i386 stable/10/sys/conf/options stable/10/sys/dev/glxsb/glxsb.c stable/10/sys/dev/hifn/hifn7751.c stable/10/sys/dev/random/harvest.c stable/10/sys/dev/random/hash.h stable/10/sys/dev/random/ivy.c stable/10/sys/dev/random/nehemiah.c stable/10/sys/dev/random/random_adaptors.c stable/10/sys/dev/random/random_adaptors.h stable/10/sys/dev/random/random_harvestq.c stable/10/sys/dev/random/random_harvestq.h stable/10/sys/dev/random/randomdev.c stable/10/sys/dev/random/randomdev.h stable/10/sys/dev/random/randomdev_soft.c stable/10/sys/dev/random/randomdev_soft.h stable/10/sys/dev/random/yarrow.c stable/10/sys/dev/random/yarrow.h stable/10/sys/dev/rndtest/rndtest.c stable/10/sys/dev/safe/safe.c stable/10/sys/dev/syscons/scmouse.c stable/10/sys/dev/syscons/syscons.c stable/10/sys/dev/ubsec/ubsec.c stable/10/sys/kern/kern_intr.c stable/10/sys/kern/subr_bus.c stable/10/sys/mips/cavium/octeon_rnd.c stable/10/sys/modules/random/Makefile stable/10/sys/net/if_ethersubr.c stable/10/sys/net/if_tun.c stable/10/sys/netgraph/ng_iface.c stable/10/sys/sys/random.h Modified: stable/10/etc/defaults/rc.conf ============================================================================== --- stable/10/etc/defaults/rc.conf Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/etc/defaults/rc.conf Sat Oct 12 15:31:36 2013 (r256381) @@ -651,6 +651,7 @@ entropy_save_num="8" # Number of entropy harvest_interrupt="YES" # Entropy device harvests interrupt randomness harvest_ethernet="YES" # Entropy device harvests ethernet randomness harvest_p_to_p="YES" # Entropy device harvests point-to-point randomness +harvest_swi="YES" # Entropy device harvests internal SWI randomness dmesg_enable="YES" # Save dmesg(8) to /var/run/dmesg.boot watchdogd_enable="NO" # Start the software watchdog daemon watchdogd_flags="" # Flags to watchdogd (if enabled) Modified: stable/10/etc/rc.d/initrandom ============================================================================== --- stable/10/etc/rc.d/initrandom Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/etc/rc.d/initrandom Sat Oct 12 15:31:36 2013 (r256381) @@ -14,26 +14,6 @@ name="initrandom" start_cmd="initrandom_start" stop_cmd=":" -feed_dev_random() -{ - if [ -f "${1}" -a -r "${1}" -a -s "${1}" ]; then - cat "${1}" | dd of=/dev/random bs=8k 2>/dev/null - fi -} - -better_than_nothing() -{ - # XXX temporary until we can improve the entropy - # harvesting rate. - # Entropy below is not great, but better than nothing. - # This unblocks the generator at startup - # Note: commands are ordered to cause the most variance across reboots. - ( kenv; dmesg; df -ib; ps -fauxww; date; sysctl -a ) \ - | dd of=/dev/random bs=8k 2>/dev/null - /sbin/sha256 -q `sysctl -n kern.bootfile` \ - | dd of=/dev/random bs=8k 2>/dev/null -} - initrandom_start() { soft_random_generator=`sysctl kern.random 2>/dev/null` @@ -63,23 +43,15 @@ initrandom_start() else ${SYSCTL} kern.random.sys.harvest.point_to_point=0 >/dev/null fi - fi - # First pass at reseeding /dev/random. - # - case ${entropy_file} in - [Nn][Oo] | '') - ;; - *) - if [ -w /dev/random ]; then - feed_dev_random "${entropy_file}" + if checkyesno harvest_swi; then + ${SYSCTL} kern.random.sys.harvest.swi=1 >/dev/null + echo -n ' swi' + else + ${SYSCTL} kern.random.sys.harvest.swi=0 >/dev/null fi - ;; - esac - - better_than_nothing + fi - echo -n ' kickstart' fi echo '.' Modified: stable/10/share/examples/kld/random_adaptor/random_adaptor_example.c ============================================================================== --- stable/10/share/examples/kld/random_adaptor/random_adaptor_example.c Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/share/examples/kld/random_adaptor/random_adaptor_example.c Sat Oct 12 15:31:36 2013 (r256381) @@ -30,32 +30,29 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include -#include +#include #include +#include #include #include -#define RNG_NAME "example" - static int random_example_read(void *, int); struct random_adaptor random_example = { .ident = "Example RNG", - .init = (random_init_func_t *)random_null_func, - .deinit = (random_deinit_func_t *)random_null_func, + .source = RANDOM_PURE_BOGUS, /* Make sure this is in + * sys/random.h and is unique */ .read = random_example_read, - .write = (random_write_func_t *)random_null_func, - .reseed = (random_reseed_func_t *)random_null_func, - .seeded = 1, }; /* * Used under the license provided @ http://xkcd.com/221/ * http://creativecommons.org/licenses/by-nc/2.5/ */ -static u_char +static uint8_t getRandomNumber(void) { return 4; /* chosen by fair dice roll, guaranteed to be random */ @@ -64,14 +61,13 @@ getRandomNumber(void) static int random_example_read(void *buf, int c) { - u_char *b; + uint8_t *b; int count; b = buf; - for (count = 0; count < c; count++) { + for (count = 0; count < c; count++) b[count] = getRandomNumber(); - } printf("returning %d bytes of pure randomness\n", c); return (c); @@ -80,15 +76,26 @@ random_example_read(void *buf, int c) static int random_example_modevent(module_t mod, int type, void *unused) { + int error = 0; switch (type) { case MOD_LOAD: - random_adaptor_register(RNG_NAME, &random_example); - EVENTHANDLER_INVOKE(random_adaptor_attach, &random_example); - return (0); + live_entropy_source_register(&random_example); + break; + + case MOD_UNLOAD: + live_entropy_source_deregister(&random_example); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; } - return (EINVAL); + return (error); } -RANDOM_ADAPTOR_MODULE(random_example, random_example_modevent, 1); +LIVE_ENTROPY_SRC_MODULE(live_entropy_source_example, random_example_modevent, 1); Modified: stable/10/share/man/man4/random.4 ============================================================================== --- stable/10/share/man/man4/random.4 Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/share/man/man4/random.4 Sat Oct 12 15:31:36 2013 (r256381) @@ -1,4 +1,4 @@ -.\" Copyright (c) 2001 Mark R V Murray. All rights reserved. +.\" Copyright (c) 2001-2013 Mark R V Murray. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions @@ -23,7 +23,7 @@ .\" .\" $FreeBSD$ .\" -.Dd August 7, 2013 +.Dd October 12, 2013 .Dt RANDOM 4 .Os .Sh NAME @@ -43,35 +43,48 @@ The device will probe for certain hardware entropy sources, and use these in preference to the fallback, which is a generator implemented in software. -If the kernel environment MIB's -.Va hw.nehemiah_rng_enable -or -.Va hw.ivy_rng_enable -are set to -.Dq Li 0 , -the associated hardware entropy source will be ignored. -.Pp -If the device is using -the software generator, -writing data to -.Nm -would perturb the internal state. -This perturbation of the internal state -is the only userland method of introducing -extra entropy into the device. -If the writer has superuser privilege, -then closing the device after writing -will make the software generator reseed itself. -This can be used for extra security, -as it immediately introduces any/all new entropy -into the PRNG. -The hardware generators will generate -sufficient quantities of entropy, -and will therefore ignore user-supplied input. -The software -.Nm -device may be controlled with -.Xr sysctl 8 . +.Pp +The software generator will start in an +.Em unseeded +state, and will block reads until +it is (re)seeded. +This may cause trouble at system boot +when keys and the like +are generated from +/dev/random +so steps should be taken to ensure a +reseed as soon as possible. +The +.Xr sysctl 8 +controlling the +.Em seeded +status (see below) may be used +if security is not an issue +or for convenience +during setup or development. +.Pp +This initial seeding +of random number generators +is a bootstrapping problem +that needs very careful attention. +In some cases, +it may be difficult +to find enough randomness +to seed a random number generator +until a system is fully operational, +but the system requires random numbers +to become fully operational. +It is (or more accurately should be) +critically important that the +.Nm +device is seeded +before the first time it is used. +In the case where a dummy or "blocking-only" +device is used, +it is the responsibility +of the system architect +to ensure that no blocking reads +hold up critical processes. .Pp To see the current settings of the software .Nm @@ -81,22 +94,20 @@ device, use the command line: .Pp which results in something like: .Bd -literal -offset indent -kern.random.adaptors: yarrow +kern.random.adaptors: yarrow,dummy +kern.random.active_adaptor: yarrow +kern.random.yarrow.gengateinterval: 10 +kern.random.yarrow.bins: 10 +kern.random.yarrow.fastthresh: 96 +kern.random.yarrow.slowthresh: 128 +kern.random.yarrow.slowoverthresh: 2 kern.random.sys.seeded: 1 kern.random.sys.harvest.ethernet: 1 kern.random.sys.harvest.point_to_point: 1 kern.random.sys.harvest.interrupt: 1 -kern.random.sys.harvest.swi: 0 -kern.random.yarrow.gengateinterval: 10 -kern.random.yarrow.bins: 10 -kern.random.yarrow.fastthresh: 192 -kern.random.yarrow.slowthresh: 256 -kern.random.yarrow.slowoverthresh: 2 +kern.random.sys.harvest.swi: 1 .Ed .Pp -(These would not be seen if a -hardware generator is present.) -.Pp Other than .Dl kern.random.adaptors all settings are read/write. @@ -107,9 +118,10 @@ variable indicates whether or not the .Nm device is in an acceptably secure state as a result of reseeding. -If set to 0, the device will block (on read) until the next reseed -(which can be from an explicit write, -or as a result of entropy harvesting). +If set to 0, +the device will block (on read) +until the next reseed +as a result of entropy harvesting. A reseed will set the value to 1 (non-blocking). .Pp The @@ -276,19 +288,6 @@ the generator produce independent sequen However, the guessability or reproducibility of the sequence is unimportant, unlike the previous cases. .Pp -One final consideration for the seeding of random number generators -is a bootstrapping problem. -In some cases, it may be difficult to find enough randomness to -seed a random number generator until a system is fully operational, -but the system requires random numbers to become fully operational. -There is no substitute for careful thought here, -but the -.Fx -.Nm -device, -which is based on the Yarrow system, -should be of some help in this area. -.Pp .Fx does also provide the traditional .Xr rand 3 @@ -325,17 +324,7 @@ and is an implementation of the .Em Yarrow algorithm by Bruce Schneier, .Em et al . -The only hardware implementations -currently are for the -.Tn VIA C3 Nehemiah -(stepping 3 or greater) -CPU -and the -.Tn Intel -.Dq Bull Mountain -.Em RdRand -instruction and underlying random number generator (RNG). -More will be added in the future. +Significant infrastructure work was done by Arthur Mesh. .Pp The author gratefully acknowledges significant assistance from VIA Technologies, Inc. Modified: stable/10/sys/boot/forth/loader.conf ============================================================================== --- stable/10/sys/boot/forth/loader.conf Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/boot/forth/loader.conf Sat Oct 12 15:31:36 2013 (r256381) @@ -39,6 +39,17 @@ bitmap_type="splash_image_data" # and pl ############################################################## +### Random number generator configuration ################### +############################################################## + +entropy_cache_load="NO" # Set this to YES to load entropy at boot time +entropy_cache_name="/boot/entropy" # Set this to the name of the file +entropy_cache_type="/boot/entropy" +#kern.random.sys.seeded="0" # Set this to 1 to start /dev/random + # without waiting for a (re)seed. + + +############################################################## ### Loader settings ######################################## ############################################################## Modified: stable/10/sys/conf/NOTES ============================================================================== --- stable/10/sys/conf/NOTES Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/conf/NOTES Sat Oct 12 15:31:36 2013 (r256381) @@ -2962,3 +2962,8 @@ options RCTL options BROOKTREE_ALLOC_PAGES=(217*4+1) options MAXFILES=999 +# Random number generator +options RANDOM_YARROW # Yarrow RNG +##options RANDOM_FORTUNA # Fortuna RNG - not yet implemented +options RANDOM_DEBUG # Debugging messages +options RANDOM_RWFILE # Read and write entropy cache Modified: stable/10/sys/conf/files ============================================================================== --- stable/10/sys/conf/files Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/conf/files Sat Oct 12 15:31:36 2013 (r256381) @@ -2043,13 +2043,15 @@ rt2860.fw optional rt2860fw | ralfw \ no-obj no-implicit-rule \ clean "rt2860.fw" dev/random/harvest.c standard -dev/random/hash.c optional random -dev/random/pseudo_rng.c standard +dev/random/dummy_rng.c standard dev/random/random_adaptors.c standard -dev/random/random_harvestq.c standard +dev/random/live_entropy_sources.c optional random +dev/random/random_harvestq.c optional random dev/random/randomdev.c optional random dev/random/randomdev_soft.c optional random dev/random/yarrow.c optional random +dev/random/hash.c optional random +dev/random/rwfile.c optional random dev/rc/rc.c optional rc dev/re/if_re.c optional re dev/rndtest/rndtest.c optional rndtest Modified: stable/10/sys/conf/files.amd64 ============================================================================== --- stable/10/sys/conf/files.amd64 Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/conf/files.amd64 Sat Oct 12 15:31:36 2013 (r256381) @@ -259,8 +259,8 @@ dev/nvme/nvme_sysctl.c optional nvme dev/nvme/nvme_test.c optional nvme dev/nvme/nvme_util.c optional nvme dev/nvram/nvram.c optional nvram isa -dev/random/ivy.c optional random rdrand_rng -dev/random/nehemiah.c optional random padlock_rng +dev/random/ivy.c optional rdrand_rng +dev/random/nehemiah.c optional padlock_rng dev/qlxge/qls_dbg.c optional qlxge pci dev/qlxge/qls_dump.c optional qlxge pci dev/qlxge/qls_hw.c optional qlxge pci Modified: stable/10/sys/conf/files.i386 ============================================================================== --- stable/10/sys/conf/files.i386 Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/conf/files.i386 Sat Oct 12 15:31:36 2013 (r256381) @@ -257,8 +257,8 @@ dev/nvme/nvme_test.c optional nvme dev/nvme/nvme_util.c optional nvme dev/nvram/nvram.c optional nvram isa dev/pcf/pcf_isa.c optional pcf -dev/random/ivy.c optional random rdrand_rng -dev/random/nehemiah.c optional random padlock_rng +dev/random/ivy.c optional rdrand_rng +dev/random/nehemiah.c optional padlock_rng dev/sbni/if_sbni.c optional sbni dev/sbni/if_sbni_isa.c optional sbni isa dev/sbni/if_sbni_pci.c optional sbni pci Modified: stable/10/sys/conf/options ============================================================================== --- stable/10/sys/conf/options Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/conf/options Sat Oct 12 15:31:36 2013 (r256381) @@ -904,3 +904,9 @@ RACCT opt_global.h # Resource Limits RCTL opt_global.h + +# Random number generator(s) +RANDOM_YARROW opt_random.h +RANDOM_FORTUNA opt_random.h +RANDOM_DEBUG opt_random.h +RANDOM_RWFILE opt_random.h Modified: stable/10/sys/dev/glxsb/glxsb.c ============================================================================== --- stable/10/sys/dev/glxsb/glxsb.c Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/dev/glxsb/glxsb.c Sat Oct 12 15:31:36 2013 (r256381) @@ -476,7 +476,7 @@ glxsb_rnd(void *v) if (status & SB_RNS_TRNG_VALID) { value = bus_read_4(sc->sc_sr, SB_RANDOM_NUM); /* feed with one uint32 */ - random_harvest(&value, 4, 32/2, 0, RANDOM_PURE); + random_harvest(&value, 4, 32/2, RANDOM_PURE_GLXSB); } callout_reset(&sc->sc_rngco, sc->sc_rnghz, glxsb_rnd, sc); Modified: stable/10/sys/dev/hifn/hifn7751.c ============================================================================== --- stable/10/sys/dev/hifn/hifn7751.c Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/dev/hifn/hifn7751.c Sat Oct 12 15:31:36 2013 (r256381) @@ -258,7 +258,7 @@ hifn_partname(struct hifn_softc *sc) static void default_harvest(struct rndtest_state *rsp, void *buf, u_int count) { - random_harvest(buf, count, count*NBBY/2, 0, RANDOM_PURE); + random_harvest(buf, count, count*NBBY/2, RANDOM_PURE_HIFN); } static u_int Added: stable/10/sys/dev/random/dummy_rng.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/sys/dev/random/dummy_rng.c Sat Oct 12 15:31:36 2013 (r256381) @@ -0,0 +1,123 @@ +/*- + * Copyright (c) 2013 Arthur Mesh + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer + * in this position and unchanged. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +static struct mtx dummy_random_mtx; + +/* Used to fake out unused random calls in random_adaptor */ +static void +random_null_func(void) +{ +} + +static int +dummy_random_poll(int events __unused, struct thread *td __unused) +{ + + return (0); +} + +static int +dummy_random_block(int flag) +{ + int error = 0; + + mtx_lock(&dummy_random_mtx); + + /* Blocking logic */ + while (!error) { + if (flag & O_NONBLOCK) + error = EWOULDBLOCK; + else { + printf("random: dummy device blocking on read.\n"); + error = msleep(&dummy_random_block, + &dummy_random_mtx, + PUSER | PCATCH, "block", 0); + } + } + mtx_unlock(&dummy_random_mtx); + + return (error); +} + +static void +dummy_random_init(void) +{ + + mtx_init(&dummy_random_mtx, "sleep mtx for dummy_random", + NULL, MTX_DEF); +} + +static void +dummy_random_deinit(void) +{ + + mtx_destroy(&dummy_random_mtx); +} + +struct random_adaptor dummy_random = { + .ident = "Dummy entropy device that always blocks", + .init = dummy_random_init, + .deinit = dummy_random_deinit, + .block = dummy_random_block, + .poll = dummy_random_poll, + .read = (random_read_func_t *)random_null_func, + .reseed = (random_reseed_func_t *)random_null_func, + .seeded = 0, /* This device can never be seeded */ +}; + +static int +dummy_random_modevent(module_t mod __unused, int type, void *unused __unused) +{ + + switch (type) { + case MOD_LOAD: + random_adaptor_register("dummy", &dummy_random); + EVENTHANDLER_INVOKE(random_adaptor_attach, + &dummy_random); + + return (0); + } + + return (EINVAL); +} + +RANDOM_ADAPTOR_MODULE(dummy, dummy_random_modevent, 1); Modified: stable/10/sys/dev/random/harvest.c ============================================================================== --- stable/10/sys/dev/random/harvest.c Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/dev/random/harvest.c Sat Oct 12 15:31:36 2013 (r256381) @@ -48,20 +48,20 @@ __FBSDID("$FreeBSD$"); static int read_random_phony(void *, int); /* Structure holding the desired entropy sources */ -struct harvest_select harvest = { 1, 1, 1, 0 }; +struct harvest_select harvest = { 1, 1, 1, 1 }; static int warned = 0; /* hold the address of the routine which is actually called if * the randomdev is loaded */ -static void (*reap_func)(u_int64_t, const void *, u_int, u_int, u_int, +static void (*reap_func)(u_int64_t, const void *, u_int, u_int, enum esource) = NULL; static int (*read_func)(void *, int) = read_random_phony; /* Initialise the harvester at load time */ void randomdev_init_harvester(void (*reaper)(u_int64_t, const void *, u_int, - u_int, u_int, enum esource), int (*reader)(void *, int)) + u_int, enum esource), int (*reader)(void *, int)) { reap_func = reaper; read_func = reader; @@ -86,12 +86,10 @@ randomdev_deinit_harvester(void) * read which can be quite expensive. */ void -random_harvest(void *entropy, u_int count, u_int bits, u_int frac, - enum esource origin) +random_harvest(void *entropy, u_int count, u_int bits, enum esource origin) { if (reap_func) - (*reap_func)(get_cyclecount(), entropy, count, bits, frac, - origin); + (*reap_func)(get_cyclecount(), entropy, count, bits, origin); } /* Userland-visible version of read_random */ Modified: stable/10/sys/dev/random/hash.h ============================================================================== --- stable/10/sys/dev/random/hash.h Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/dev/random/hash.h Sat Oct 12 15:31:36 2013 (r256381) @@ -26,6 +26,9 @@ * $FreeBSD$ */ +#ifndef SYS_DEV_RANDOM_HASH_H_INCLUDED +#define SYS_DEV_RANDOM_HASH_H_INCLUDED + #define KEYSIZE 32 /* (in bytes) == 256 bits */ #define BLOCKSIZE 16 /* (in bytes) == 128 bits */ @@ -43,3 +46,5 @@ void randomdev_hash_iterate(struct rando void randomdev_hash_finish(struct randomdev_hash *, void *); void randomdev_encrypt_init(struct randomdev_key *, void *); void randomdev_encrypt(struct randomdev_key *context, void *, void *, unsigned); + +#endif Modified: stable/10/sys/dev/random/ivy.c ============================================================================== --- stable/10/sys/dev/random/ivy.c Sat Oct 12 14:54:25 2013 (r256380) +++ stable/10/sys/dev/random/ivy.c Sat Oct 12 15:31:36 2013 (r256381) @@ -30,38 +30,35 @@ __FBSDID("$FreeBSD$"); #include -#include #include #include +#include #include -#include +#include #include #include #include #include -#include #include +#include +#include +#include +#include #define RETRY_COUNT 10 -static void random_ivy_init(void); -static void random_ivy_deinit(void); static int random_ivy_read(void *, int); -struct random_adaptor random_ivy = { +static struct random_hardware_source random_ivy = { .ident = "Hardware, Intel IvyBridge+ RNG", - .init = random_ivy_init, - .deinit = random_ivy_deinit, - .read = random_ivy_read, - .write = (random_write_func_t *)random_null_func, - .reseed = (random_reseed_func_t *)random_null_func, - .seeded = 1, + .source = RANDOM_PURE_RDRAND, + .read = random_ivy_read }; static inline int -ivy_rng_store(long *tmp) +ivy_rng_store(uint64_t *tmp) { #ifdef __GNUCLIKE_ASM uint32_t count; @@ -86,34 +83,26 @@ ivy_rng_store(long *tmp) #endif } -static void -random_ivy_init(void) -{ -} - -void -random_ivy_deinit(void) -{ -} - static int random_ivy_read(void *buf, int c) { - char *b; - long tmp; - int count, res, retry; + uint8_t *b; + int count, ret, retry; + uint64_t tmp; - for (count = c, b = buf; count > 0; count -= res, b += res) { + b = buf; + for (count = c; count > 0; count -= ret) { for (retry = 0; retry < RETRY_COUNT; retry++) { - res = ivy_rng_store(&tmp); - if (res != 0) + ret = ivy_rng_store(&tmp); + if (ret != 0) break; } - if (res == 0) + if (ret == 0) break; - if (res > count) - res = count; - memcpy(b, &tmp, res); + if (ret > count) + ret = count; + memcpy(b, &tmp, ret); + b += ret; } return (c - count); } @@ -121,25 +110,35 @@ random_ivy_read(void *buf, int c) static int rdrand_modevent(module_t mod, int type, void *unused) { + int error = 0; switch (type) { case MOD_LOAD: - if (cpu_feature2 & CPUID2_RDRAND) { - random_adaptor_register("rdrand", &random_ivy); - EVENTHANDLER_INVOKE(random_adaptor_attach, &random_ivy); - return (0); - } else { + if (cpu_feature2 & CPUID2_RDRAND) + live_entropy_source_register(&random_ivy); + else #ifndef KLD_MODULE if (bootverbose) #endif - printf( - "%s: RDRAND feature is not present on this CPU\n", + printf("%s: RDRAND is not present\n", random_ivy.ident); - return (0); - } + break; + + case MOD_UNLOAD: + if (cpu_feature2 & CPUID2_RDRAND) + live_entropy_source_deregister(&random_ivy); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + } - return (EINVAL); + return (error); } -RANDOM_ADAPTOR_MODULE(random_rdrand, rdrand_modevent, 1); +LIVE_ENTROPY_SRC_MODULE(random_rdrand, rdrand_modevent, 1); Added: stable/10/sys/dev/random/live_entropy_sources.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/sys/dev/random/live_entropy_sources.c Sat Oct 12 15:31:36 2013 (r256381) @@ -0,0 +1,195 @@ +/*- + * Copyright (c) 2013 Arthur Mesh + * Copyright (c) 2013 Mark R V Murray + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer + * in this position and unchanged. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include +#include +#include +#include + +#include "live_entropy_sources.h" + +LIST_HEAD(les_head, live_entropy_sources); +static struct les_head sources = LIST_HEAD_INITIALIZER(sources); + +/* + * The live_lock protects the consistency of the "struct les_head sources" + */ +static struct sx les_lock; /* need a sleepable lock */ + +void +live_entropy_source_register(struct random_hardware_source *rsource) +{ + struct live_entropy_sources *les; + + KASSERT(rsource != NULL, ("invalid input to %s", __func__)); + + les = malloc(sizeof(struct live_entropy_sources), M_ENTROPY, M_WAITOK); + les->rsource = rsource; + + sx_xlock(&les_lock); + LIST_INSERT_HEAD(&sources, les, entries); + sx_xunlock(&les_lock); +} + +void +live_entropy_source_deregister(struct random_hardware_source *rsource) +{ + struct live_entropy_sources *les = NULL; + + KASSERT(rsource != NULL, ("invalid input to %s", __func__)); + + sx_xlock(&les_lock); + LIST_FOREACH(les, &sources, entries) + if (les->rsource == rsource) { + LIST_REMOVE(les, entries); + break; + } + sx_xunlock(&les_lock); + if (les != NULL) + free(les, M_ENTROPY); +} + +static int +live_entropy_source_handler(SYSCTL_HANDLER_ARGS) +{ + struct live_entropy_sources *les; + int error, count; + + count = error = 0; + + sx_slock(&les_lock); + + if (LIST_EMPTY(&sources)) + error = SYSCTL_OUT(req, "", 0); + else { + LIST_FOREACH(les, &sources, entries) { + + error = SYSCTL_OUT(req, ",", count++ ? 1 : 0); + if (error) + break; + + error = SYSCTL_OUT(req, les->rsource->ident, strlen(les->rsource->ident)); + if (error) + break; + } + } + + sx_sunlock(&les_lock); + + return (error); +} + +static void +live_entropy_sources_init(void *unused) +{ + + SYSCTL_PROC(_kern_random, OID_AUTO, live_entropy_sources, + CTLTYPE_STRING | CTLFLAG_RD | CTLFLAG_MPSAFE, + NULL, 0, live_entropy_source_handler, "", + "List of Active Live Entropy Sources"); + + sx_init(&les_lock, "live_entropy_sources"); +} + +/* + * Run through all "live" sources reading entropy for the given + * number of rounds, which should be a multiple of the number + * of entropy accumulation pools in use; 2 for Yarrow and 32 + * for Fortuna. + * + * BEWARE!!! + * This function runs inside the RNG thread! Don't do anything silly! + * Remember that we are NOT holding harvest_mtx on entry! + */ +void +live_entropy_sources_feed(int rounds, event_proc_f entropy_processor) +{ + static struct harvest event; + static uint8_t buf[HARVESTSIZE]; + struct live_entropy_sources *les; + int i, n; + + sx_slock(&les_lock); + + /* + * Walk over all of live entropy sources, and feed their output + * to the system-wide RNG. + */ + LIST_FOREACH(les, &sources, entries) { + + for (i = 0; i < rounds; i++) { + /* + * This should be quick, since it's a live entropy + * source. + */ + /* FIXME: Whine loudly if this didn't work. */ + n = les->rsource->read(buf, sizeof(buf)); + n = MIN(n, HARVESTSIZE); + + event.somecounter = get_cyclecount(); + event.size = n; + event.bits = (n*8)/2; + event.source = les->rsource->source; + memcpy(event.entropy, buf, n); + + /* Do the actual entropy insertion */ + entropy_processor(&event); + } + + } + + sx_sunlock(&les_lock); +} + +static void +live_entropy_sources_deinit(void *unused) +{ + + sx_destroy(&les_lock); +} + +SYSINIT(random_adaptors, SI_SUB_DRIVERS, SI_ORDER_FIRST, + live_entropy_sources_init, NULL); +SYSUNINIT(random_adaptors, SI_SUB_DRIVERS, SI_ORDER_FIRST, + live_entropy_sources_deinit, NULL); Added: stable/10/sys/dev/random/live_entropy_sources.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/sys/dev/random/live_entropy_sources.h Sat Oct 12 15:31:36 2013 (r256381) @@ -0,0 +1,60 @@ +/*- + * Copyright (c) 2013 Arthur Mesh + * Copyright (c) 2013 Mark R V Murray + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer + * in this position and unchanged. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 17:46:15 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 691133B7; Sat, 12 Oct 2013 17:46:15 +0000 (UTC) (envelope-from hrs@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4765028D9; Sat, 12 Oct 2013 17:46:15 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9CHkF6r058107; Sat, 12 Oct 2013 17:46:15 GMT (envelope-from hrs@svn.freebsd.org) Received: (from hrs@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9CHkDbU058100; Sat, 12 Oct 2013 17:46:13 GMT (envelope-from hrs@svn.freebsd.org) Message-Id: <201310121746.r9CHkDbU058100@svn.freebsd.org> From: Hiroki Sato Date: Sat, 12 Oct 2013 17:46:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256387 - in stable/10: etc/rc.d share/man/man5 usr.sbin/jail X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 17:46:15 -0000 Author: hrs Date: Sat Oct 12 17:46:13 2013 New Revision: 256387 URL: http://svnweb.freebsd.org/changeset/base/256387 Log: MFC 256385: - Add mount.fdescfs parameter to jail(8). This is similar to mount.devfs but mounts fdescfs. The mount happens just after mount.devfs. - rc.d/jail now displays whole error message from jail(8) when a jail fails to start. Approved by: re (gjb) Modified: stable/10/etc/rc.d/jail stable/10/share/man/man5/rc.conf.5 stable/10/usr.sbin/jail/command.c stable/10/usr.sbin/jail/config.c stable/10/usr.sbin/jail/jail.8 stable/10/usr.sbin/jail/jail.c stable/10/usr.sbin/jail/jailp.h Directory Properties: stable/10/etc/rc.d/ (props changed) stable/10/share/man/man5/ (props changed) stable/10/usr.sbin/jail/ (props changed) Modified: stable/10/etc/rc.d/jail ============================================================================== --- stable/10/etc/rc.d/jail Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/etc/rc.d/jail Sat Oct 12 17:46:13 2013 (r256387) @@ -226,8 +226,7 @@ parse_options() eval : \${jail_${_j}_fdescfs_enable:=${jail_fdescfs_enable:-NO}} if checkyesno jail_${_j}_fdescfs_enable; then - echo " mount += " \ - "\"fdescfs ${_rootdir%/}/dev/fd fdescfs rw 0 0\";" + echo " mount.fdescfs;" fi eval : \${jail_${_j}_procfs_enable:=${jail_procfs_enable:-NO}} if checkyesno jail_${_j}_procfs_enable; then @@ -438,7 +437,7 @@ jail_start() echo -n " ${_hostname:-${_jail}}" else echo " cannot start jail \"${_hostname:-${jail}}\": " - tail +2 $_tmp + cat $_tmp fi rm -f $_tmp done Modified: stable/10/share/man/man5/rc.conf.5 ============================================================================== --- stable/10/share/man/man5/rc.conf.5 Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/share/man/man5/rc.conf.5 Sat Oct 12 17:46:13 2013 (r256387) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 10, 2013 +.Dd October 12, 2013 .Dt RC.CONF 5 .Os .Sh NAME @@ -3992,9 +3992,7 @@ set from .Va jail_ Ns Ao Ar jname Ac Ns Va _fstab .It Li mount set from -.Va jail_ Ns Ao Ar jname Ac Ns Va _fdescfs_enable -or -.Va jail_ Ns Ao Ar jname Ac Ns Va _procfs_enable. +.Va jail_ Ns Ao Ar jname Ac Ns Va _procfs_enable . .It Li exec.fib set from .Va jail_ Ns Ao Ar jname Ac Ns Va _fib @@ -4042,6 +4040,9 @@ set from .Va jail_ Ns Ao Ar jname Ac Ns Va _devfs_ruleset . This must be an integer, not a string. +.It Li mount.fdescfs +set from +.Va jail_ Ns Ao Ar jname Ac Ns Va _fdescfs_enable .It Li allow.set_hostname set from .Va jail_ Ns Ao Ar jname Ac Ns Va _set_hostname_allow Modified: stable/10/usr.sbin/jail/command.c ============================================================================== --- stable/10/usr.sbin/jail/command.c Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/usr.sbin/jail/command.c Sat Oct 12 17:46:13 2013 (r256387) @@ -106,7 +106,12 @@ next_command(struct cfjail *j) case IP_MOUNT_DEVFS: if (!bool_param(j->intparams[IP_MOUNT_DEVFS])) continue; - /* FALLTHROUGH */ + j->comstring = &dummystring; + break; + case IP_MOUNT_FDESCFS: + if (!bool_param(j->intparams[IP_MOUNT_FDESCFS])) + continue; + j->comstring = &dummystring; case IP__OP: case IP_STOP_TIMEOUT: j->comstring = &dummystring; @@ -452,6 +457,32 @@ run_command(struct cfjail *j) } break; + case IP_MOUNT_FDESCFS: + argv = alloca(7 * sizeof(char *)); + path = string_param(j->intparams[KP_PATH]); + if (path == NULL) { + jail_warnx(j, "mount.fdescfs: no path"); + return -1; + } + devpath = alloca(strlen(path) + 8); + sprintf(devpath, "%s/dev/fd", path); + if (check_path(j, "mount.fdescfs", devpath, 0, + down ? "fdescfs" : NULL) < 0) + return -1; + if (down) { + *(const char **)&argv[0] = "/sbin/umount"; + argv[1] = devpath; + argv[2] = NULL; + } else { + *(const char **)&argv[0] = _PATH_MOUNT; + *(const char **)&argv[1] = "-t"; + *(const char **)&argv[2] = "fdescfs"; + *(const char **)&argv[3] = "."; + argv[4] = devpath; + argv[5] = NULL; + } + break; + case IP_COMMAND: if (j->name != NULL) goto default_command; Modified: stable/10/usr.sbin/jail/config.c ============================================================================== --- stable/10/usr.sbin/jail/config.c Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/usr.sbin/jail/config.c Sat Oct 12 17:46:13 2013 (r256387) @@ -83,6 +83,7 @@ static const struct ipspec intparams[] = #endif [IP_MOUNT] = {"mount", PF_INTERNAL | PF_REV}, [IP_MOUNT_DEVFS] = {"mount.devfs", PF_INTERNAL | PF_BOOL}, + [IP_MOUNT_FDESCFS] = {"mount.fdescfs", PF_INTERNAL | PF_BOOL}, [IP_MOUNT_FSTAB] = {"mount.fstab", PF_INTERNAL}, [IP_STOP_TIMEOUT] = {"stop.timeout", PF_INTERNAL | PF_INT}, [IP_VNET_INTERFACE] = {"vnet.interface", PF_INTERNAL}, Modified: stable/10/usr.sbin/jail/jail.8 ============================================================================== --- stable/10/usr.sbin/jail/jail.8 Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/usr.sbin/jail/jail.8 Sat Oct 12 17:46:13 2013 (r256387) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd August 23, 2013 +.Dd October 12, 2013 .Dt JAIL 8 .Os .Sh NAME @@ -682,7 +682,7 @@ to. An alias for each address will be added to the interface before the prison is created, and will be removed from the interface after the prison is removed. -.It Op Va ip4.addr +.It Va ip4.addr In addition to the IP addresses that are passed to the kernel, and interface and/or a netmask may also be specified, in the form .Dq Ar interface Ns | Ns Ar ip-address Ns / Ns Ar netmask . @@ -691,7 +691,7 @@ will be added to that interface, as it i .Va interface parameter. If a netmask in either dotted-quad or CIDR form is given after IP address, it will be used when adding the IP alias. -.It Op Va ip6.addr +.It Va ip6.addr In addition to the IP addresses that are passed to the kernel, and interface and/or a prefix may also be specified, in the form .Dq Ar interface Ns | Ns Ar ip-address Ns / Ns Ar prefix . @@ -722,11 +722,19 @@ An format file containing filesystems to mount before creating a jail. .It Va mount.devfs Mount a -.Xr devfs -filesystem on the chrooted /dev directory, and apply the ruleset in the +.Xr devfs 5 +filesystem on the chrooted +.Pa /dev +directory, and apply the ruleset in the .Va devfs_ruleset parameter (or a default of ruleset 4: devfsrules_jail) to restrict the devices visible inside the prison. +.It Va mount.fdescfs +Mount a +.Xr fdescfs 5 +filesystem on the chrooted +.Pa /dev/fd +directory. .It Va allow.dying Allow making changes to a .Va dying @@ -1165,6 +1173,8 @@ environment of the first jail. .Xr ps 1 , .Xr quota 1 , .Xr jail_set 2 , +.Xr devfs 5 , +.Xr fdescfs 5 , .Xr jail.conf 5 , .Xr procfs 5 , .Xr rc.conf 5 , Modified: stable/10/usr.sbin/jail/jail.c ============================================================================== --- stable/10/usr.sbin/jail/jail.c Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/usr.sbin/jail/jail.c Sat Oct 12 17:46:13 2013 (r256387) @@ -92,6 +92,7 @@ static const enum intparam startcommands IP_MOUNT, IP__MOUNT_FROM_FSTAB, IP_MOUNT_DEVFS, + IP_MOUNT_FDESCFS, IP_EXEC_PRESTART, IP__OP, IP_VNET_INTERFACE, @@ -108,6 +109,7 @@ static const enum intparam stopcommands[ IP_STOP_TIMEOUT, IP__OP, IP_EXEC_POSTSTOP, + IP_MOUNT_FDESCFS, IP_MOUNT_DEVFS, IP__MOUNT_FROM_FSTAB, IP_MOUNT, Modified: stable/10/usr.sbin/jail/jailp.h ============================================================================== --- stable/10/usr.sbin/jail/jailp.h Sat Oct 12 17:31:21 2013 (r256386) +++ stable/10/usr.sbin/jail/jailp.h Sat Oct 12 17:46:13 2013 (r256387) @@ -95,6 +95,7 @@ enum intparam { #endif IP_MOUNT, /* Mount points in fstab(5) form */ IP_MOUNT_DEVFS, /* Mount /dev under prison root */ + IP_MOUNT_FDESCFS, /* Mount /dev/fd under prison root */ IP_MOUNT_FSTAB, /* A standard fstab(5) file */ IP_STOP_TIMEOUT, /* Time to wait after sending SIGTERM */ IP_VNET_INTERFACE, /* Assign interface(s) to vnet jail */ From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 19:41:36 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 7688FF0A; Sat, 12 Oct 2013 19:41:36 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 61F752DBE; Sat, 12 Oct 2013 19:41:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9CJfanL019671; Sat, 12 Oct 2013 19:41:36 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9CJfaCk019670; Sat, 12 Oct 2013 19:41:36 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201310121941.r9CJfaCk019670@svn.freebsd.org> From: Peter Grehan Date: Sat, 12 Oct 2013 19:41:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256390 - stable/10/usr.sbin/bhyve X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 19:41:36 -0000 Author: grehan Date: Sat Oct 12 19:41:35 2013 New Revision: 256390 URL: http://svnweb.freebsd.org/changeset/base/256390 Log: MFC r256389 Implement the virtio block 'get-ident' operation. This eliminates the annoying verbose boot error of the form g_handleattr: vtbd0 bio_length 24 len 28 -> EFAULT The ident returned by bhyve is a text string 'BHYVE-XXXX-XXXX', where the X's are the first bytes of the md5 hash of the backing filename. Approved by: re (gjb) Modified: stable/10/usr.sbin/bhyve/pci_virtio_block.c Directory Properties: stable/10/usr.sbin/bhyve/ (props changed) Modified: stable/10/usr.sbin/bhyve/pci_virtio_block.c ============================================================================== --- stable/10/usr.sbin/bhyve/pci_virtio_block.c Sat Oct 12 19:31:19 2013 (r256389) +++ stable/10/usr.sbin/bhyve/pci_virtio_block.c Sat Oct 12 19:41:35 2013 (r256390) @@ -46,17 +46,25 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include "bhyverun.h" #include "pci_emul.h" #include "virtio.h" +#ifndef min +#define min(a, b) ((a) < (b) ? (a) : (b)) +#endif + #define VTBLK_RINGSZ 64 #define VTBLK_MAXSEGS 32 #define VTBLK_S_OK 0 #define VTBLK_S_IOERR 1 +#define VTBLK_S_UNSUPP 2 + +#define VTBLK_BLK_ID_BYTES 20 /* * Host capabilities @@ -85,6 +93,7 @@ struct vtblk_config { struct virtio_blk_hdr { #define VBH_OP_READ 0 #define VBH_OP_WRITE 1 +#define VBH_OP_IDENT 8 #define VBH_FLAG_BARRIER 0x80000000 /* OR'ed into vbh_type */ uint32_t vbh_type; uint32_t vbh_ioprio; @@ -106,6 +115,7 @@ struct pci_vtblk_softc { struct vqueue_info vbsc_vq; int vbsc_fd; struct vtblk_config vbsc_cfg; + char vbsc_ident[VTBLK_BLK_ID_BYTES]; }; static void pci_vtblk_reset(void *); @@ -180,7 +190,7 @@ pci_vtblk_proc(struct pci_vtblk_softc *s for (i = 1; i < n; i++) { /* * - write op implies read-only descriptor, - * - read op implies write-only descriptor, + * - read/ident op implies write-only descriptor, * therefore test the inverse of the descriptor bit * to the op. */ @@ -189,14 +199,34 @@ pci_vtblk_proc(struct pci_vtblk_softc *s } DPRINTF(("virtio-block: %s op, %d bytes, %d segs, offset %ld\n\r", - writeop ? "write" : "read", iolen, i - 1, offset)); + writeop ? "write" : "read/ident", iolen, i - 1, offset)); - if (writeop) + switch (type) { + case VBH_OP_WRITE: err = pwritev(sc->vbsc_fd, iov + 1, i - 1, offset); - else + break; + case VBH_OP_READ: err = preadv(sc->vbsc_fd, iov + 1, i - 1, offset); + break; + case VBH_OP_IDENT: + /* Assume a single buffer */ + strlcpy(iov[1].iov_base, sc->vbsc_ident, + min(iov[1].iov_len, sizeof(sc->vbsc_ident))); + err = 0; + break; + default: + err = -ENOSYS; + break; + } - *status = err < 0 ? VTBLK_S_IOERR : VTBLK_S_OK; + /* convert errno into a virtio block error return */ + if (err < 0) { + if (err == -ENOSYS) + *status = VTBLK_S_UNSUPP; + else + *status = VTBLK_S_IOERR; + } else + *status = VTBLK_S_OK; /* * Return the descriptor back to the host. @@ -220,6 +250,8 @@ static int pci_vtblk_init(struct vmctx *ctx, struct pci_devinst *pi, char *opts) { struct stat sbuf; + MD5_CTX mdctx; + u_char digest[16]; struct pci_vtblk_softc *sc; off_t size; int fd; @@ -274,6 +306,16 @@ pci_vtblk_init(struct vmctx *ctx, struct sc->vbsc_vq.vq_qsize = VTBLK_RINGSZ; /* sc->vbsc_vq.vq_notify = we have no per-queue notify */ + /* + * Create an identifier for the backing file. Use parts of the + * md5 sum of the filename + */ + MD5Init(&mdctx); + MD5Update(&mdctx, opts, strlen(opts)); + MD5Final(digest, &mdctx); + sprintf(sc->vbsc_ident, "BHYVE-%02X%02X-%02X%02X-%02X%02X", + digest[0], digest[1], digest[2], digest[3], digest[4], digest[5]); + /* setup virtio block config space */ sc->vbsc_cfg.vbc_capacity = size / sectsz; sc->vbsc_cfg.vbc_seg_max = VTBLK_MAXSEGS; From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 19:54:12 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id B3F99555; Sat, 12 Oct 2013 19:54:12 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id A07E72E4D; Sat, 12 Oct 2013 19:54:12 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9CJsC2v025754; Sat, 12 Oct 2013 19:54:12 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9CJsCwV025753; Sat, 12 Oct 2013 19:54:12 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201310121954.r9CJsCwV025753@svn.freebsd.org> From: Devin Teske Date: Sat, 12 Oct 2013 19:54:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256392 - stable/10/usr.sbin/bsdconfig/share X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 19:54:12 -0000 Author: dteske Date: Sat Oct 12 19:54:12 2013 New Revision: 256392 URL: http://svnweb.freebsd.org/changeset/base/256392 Log: MFC r256391: Fix signed integer overflow detection in f_expand_number() of strings.subr. Approved by: re (glebius) Modified: stable/10/usr.sbin/bsdconfig/share/strings.subr Directory Properties: stable/10/usr.sbin/bsdconfig/ (props changed) Modified: stable/10/usr.sbin/bsdconfig/share/strings.subr ============================================================================== --- stable/10/usr.sbin/bsdconfig/share/strings.subr Sat Oct 12 19:52:27 2013 (r256391) +++ stable/10/usr.sbin/bsdconfig/share/strings.subr Sat Oct 12 19:54:12 2013 (r256392) @@ -341,17 +341,19 @@ f_shell_unescape() # # NOTE: Prefixes are case-insensitive. # -# Upon successful completion, the value 0 is returned (or stored to -# $var_to_set); otherwise -1. Reasons for a -1 return include: +# Upon successful completion, success status is returned; otherwise the number +# -1 is produced ($var_to_set set to -1 or if $var_to_set is NULL or missing) +# on standard output. In the case of failure, the error status will be one of: # -# Given $string contains no digits. -# An unrecognized prefix was given. -# Result too large to calculate. +# Status Reason +# 1 Given $string contains no digits +# 2 An unrecognized prefix was given +# 3 Result too large to calculate # f_expand_number() { local __string="$1" __var_to_set="$2" - local __cp __num + local __cp __num __bshift __maxinput # Remove any leading non-digits while :; do @@ -360,14 +362,14 @@ f_expand_number() [ "$__string" = "$__cp" ] && break done - # Return `-1' if string didn't contain any digits + # Produce `-1' if string didn't contain any digits if [ ! "$__string" ]; then if [ "$__var_to_set" ]; then setvar "$__var_to_set" -1 else echo -1 fi - return $FAILURE + return 1 # 1 = "Given $string contains no digits" fi # Store the numbers @@ -390,9 +392,23 @@ f_expand_number() [ "$__string" = "$__cp" ] && break done - # Test for invalid prefix + # + # Test for invalid prefix (and determine bitshift length) + # case "$__string" in - ""|[KkMmGgTtPpEe]*) : known prefix ;; + ""|[[:space:]]*) # Shortcut + if [ "$__var_to_set" ]; then + setvar "$__var_to_set" $__num + else + echo $__num + fi + return $SUCCESS ;; + [Kk]*) __bshift=10 ;; + [Mm]*) __bshift=20 ;; + [Gg]*) __bshift=30 ;; + [Tt]*) __bshift=40 ;; + [Pp]*) __bshift=50 ;; + [Ee]*) __bshift=60 ;; *) # Unknown prefix if [ "$__var_to_set" ]; then @@ -400,29 +416,23 @@ f_expand_number() else echo -1 fi - return $FAILURE + return 2 # 2 = "An unrecognized prefix was given" esac - # Multiply the number out - case "$__string" in - [Kk]) __num=$(( $__num * 1024 )) ;; - [Mm]) __num=$(( $__num * 1048576 )) ;; - [Gg]) __num=$(( $__num * 1073741824 )) ;; - [Tt]) __num=$(( $__num * 1099511627776 )) ;; - [Pp]) __num=$(( $__num * 1125899906842624 )) ;; - [Ee]) __num=$(( $__num * 1152921504606846976 )) ;; - esac - if [ $__num -le 0 ]; then - # Arithmetic overflow + # Determine if the wheels fall off + __maxinput=$(( 0x7fffffffffffffff >> $__bshift )) + if [ $__num -gt $__maxinput ]; then + # Input (before expanding) would exceed 64-bit signed int if [ "$__var_to_set" ]; then setvar "$__var_to_set" -1 else echo -1 fi - return $FAILURE + return 3 # 3 = "Result too large to calculate" fi - # Return the number + # Shift the number out and produce it + __num=$(( $__num << $__bshift )) if [ "$__var_to_set" ]; then setvar "$__var_to_set" $__num else From owner-svn-src-stable-10@FreeBSD.ORG Sat Oct 12 20:01:36 2013 Return-Path: Delivered-To: svn-src-stable-10@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id AFEDB72C; Sat, 12 Oct 2013 20:01:36 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 9B7782E9B; Sat, 12 Oct 2013 20:01:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9CK1aG3029932; Sat, 12 Oct 2013 20:01:36 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9CK1a4e029929; Sat, 12 Oct 2013 20:01:36 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201310122001.r9CK1a4e029929@svn.freebsd.org> From: Glen Barber Date: Sat, 12 Oct 2013 20:01:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r256393 - stable/10/sys/conf X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Oct 2013 20:01:36 -0000 Author: gjb Date: Sat Oct 12 20:01:36 2013 New Revision: 256393 URL: http://svnweb.freebsd.org/changeset/base/256393 Log: Update stable/10 to -BETA1 as part of the 10.0-RELEASE cycle. Approved by: re (implicit) Sponsored by: The FreeBSD Foundation Modified: stable/10/sys/conf/newvers.sh Modified: stable/10/sys/conf/newvers.sh ============================================================================== --- stable/10/sys/conf/newvers.sh Sat Oct 12 19:54:12 2013 (r256392) +++ stable/10/sys/conf/newvers.sh Sat Oct 12 20:01:36 2013 (r256393) @@ -32,7 +32,7 @@ TYPE="FreeBSD" REVISION="10.0" -BRANCH="ALPHA6" +BRANCH="BETA1" if [ "X${BRANCH_OVERRIDE}" != "X" ]; then BRANCH=${BRANCH_OVERRIDE} fi