From owner-p4-projects@FreeBSD.ORG Thu May 1 00:59:31 2003 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3DD6737B404; Thu, 1 May 2003 00:59:31 -0700 (PDT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F30C337B401 for ; Thu, 1 May 2003 00:59:30 -0700 (PDT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5CF4C43FA3 for ; Thu, 1 May 2003 00:59:29 -0700 (PDT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.6/8.12.6) with ESMTP id h417xT0U027872 for ; Thu, 1 May 2003 00:59:29 -0700 (PDT) (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.12.6/8.12.6/Submit) id h417xSjx027869 for perforce@freebsd.org; Thu, 1 May 2003 00:59:28 -0700 (PDT) Date: Thu, 1 May 2003 00:59:28 -0700 (PDT) Message-Id: <200305010759.h417xSjx027869@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to marcel@freebsd.org using -f From: Marcel Moolenaar To: Perforce Change Reviews Subject: PERFORCE change 30295 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 May 2003 07:59:32 -0000 http://perforce.freebsd.org/chv.cgi?CH=30295 Change 30295 by marcel@marcel_pluto1 on 2003/05/01 00:59:08 IFia64: this integ did not take the EPC related cleanups on the ia64 branch. This increases the diff between the two branches. Affected files ... .. //depot/projects/ia64_epc/Makefile#4 integrate .. //depot/projects/ia64_epc/bin/pax/tar.1#2 integrate .. //depot/projects/ia64_epc/lib/libc/ia64/sys/brk.S#4 integrate .. //depot/projects/ia64_epc/lib/libc/ia64/sys/sbrk.S#4 integrate .. //depot/projects/ia64_epc/lib/libthr/arch/ia64/Makefile.inc#3 integrate .. //depot/projects/ia64_epc/lib/libthr/arch/ia64/ia64/_curthread.c#3 integrate .. //depot/projects/ia64_epc/sbin/vinum/commands.c#4 integrate .. //depot/projects/ia64_epc/sbin/vinum/list.c#4 integrate .. //depot/projects/ia64_epc/sbin/vinum/v.c#2 integrate .. //depot/projects/ia64_epc/sbin/vinum/vext.h#3 integrate .. //depot/projects/ia64_epc/sys/amd64/Makefile#1 branch .. //depot/projects/ia64_epc/sys/amd64/acpica/OsdEnvironment.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/acpica/acpi_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/acpica/acpi_wakeup.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/atomic.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/autoconf.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/busdma_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/critical.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/dump_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/elf_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/exception.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/genassym.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/identcpu.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/in_cksum.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/initcpu.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/legacy.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/locore.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/mem.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/nexus.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/pmap.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/sigtramp.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/support.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/swtch.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/sys_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/trap.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/tsc.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/amd64/vm_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/conf/GENERIC#1 branch .. //depot/projects/ia64_epc/sys/amd64/conf/GENERIC.hints#1 branch .. //depot/projects/ia64_epc/sys/amd64/conf/Makefile#1 branch .. //depot/projects/ia64_epc/sys/amd64/conf/gethints.awk#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/_inttypes.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/_types.h#2 integrate .. //depot/projects/ia64_epc/sys/amd64/include/asm.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/asmacros.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/atomic.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/bus.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/bus_at386.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/bus_dma.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/bus_memio.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/bus_pio.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/clock.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/cpu.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/cpufunc.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/cputypes.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/critical.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/db_machdep.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/elf.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/endian.h#2 integrate .. //depot/projects/ia64_epc/sys/amd64/include/exec.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/float.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/floatingpoint.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/frame.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/in_cksum.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/kse.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/legacyvar.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/md_var.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/metadata.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/mutex.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/npx.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/param.h#2 integrate .. //depot/projects/ia64_epc/sys/amd64/include/pc/display.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/pcb.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/pcb_ext.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/pci_cfgreg.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/pcpu.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/pmap.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/proc.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/profile.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/psl.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/ptrace.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/reg.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/reloc.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/resource.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/runq.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/segments.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/setjmp.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/sigframe.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/signal.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/smp.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/specialreg.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/sysarch.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/trap.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/tss.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/ucontext.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/varargs.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/include/vmparam.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/clock.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/icu.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/icu_ipl.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/icu_vector.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/intr_machdep.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/intr_machdep.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/isa.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/isa.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/isa_dma.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/isa_dma.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/ithread.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/npx.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/timerreg.h#1 branch .. //depot/projects/ia64_epc/sys/amd64/isa/vector.s#1 branch .. //depot/projects/ia64_epc/sys/amd64/pci/pci_bus.c#1 branch .. //depot/projects/ia64_epc/sys/amd64/pci/pci_cfgreg.c#1 branch .. //depot/projects/ia64_epc/sys/boot/alpha/libalpha/elf_freebsd.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/arc/lib/elf_freebsd.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/common/Makefile.inc#2 integrate .. //depot/projects/ia64_epc/sys/boot/common/bootstrap.h#3 integrate .. //depot/projects/ia64_epc/sys/boot/common/load_elf.c#3 integrate .. //depot/projects/ia64_epc/sys/boot/common/load_elf32.c#1 branch .. //depot/projects/ia64_epc/sys/boot/common/load_elf64.c#1 branch .. //depot/projects/ia64_epc/sys/boot/efi/libefi/elf_freebsd.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/i386/libi386/Makefile#2 integrate .. //depot/projects/ia64_epc/sys/boot/i386/libi386/amd64_tramp.S#1 branch .. //depot/projects/ia64_epc/sys/boot/i386/libi386/biossmap.c#1 branch .. //depot/projects/ia64_epc/sys/boot/i386/libi386/bootinfo.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/i386/libi386/bootinfo32.c#1 branch .. //depot/projects/ia64_epc/sys/boot/i386/libi386/bootinfo64.c#1 branch .. //depot/projects/ia64_epc/sys/boot/i386/libi386/elf32_freebsd.c#1 branch .. //depot/projects/ia64_epc/sys/boot/i386/libi386/elf64_freebsd.c#1 branch .. //depot/projects/ia64_epc/sys/boot/i386/libi386/elf_freebsd.c#3 delete .. //depot/projects/ia64_epc/sys/boot/i386/libi386/libi386.h#2 integrate .. //depot/projects/ia64_epc/sys/boot/i386/loader/conf.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/i386/loader/main.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/ia64/libski/elf_freebsd.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/ofw/libofw/elf_freebsd.c#2 integrate .. //depot/projects/ia64_epc/sys/boot/sparc64/loader/main.c#2 integrate .. //depot/projects/ia64_epc/sys/cam/scsi/scsi_da.c#9 integrate .. //depot/projects/ia64_epc/sys/conf/Makefile.amd64#2 integrate .. //depot/projects/ia64_epc/sys/conf/files.amd64#2 integrate .. //depot/projects/ia64_epc/sys/conf/files.ia64#12 integrate .. //depot/projects/ia64_epc/sys/conf/ldscript.amd64#2 integrate .. //depot/projects/ia64_epc/sys/conf/ldscript.ia64#2 integrate .. //depot/projects/ia64_epc/sys/conf/options.amd64#2 integrate .. //depot/projects/ia64_epc/sys/dev/ata/ata-chipset.c#8 integrate .. //depot/projects/ia64_epc/sys/dev/ata/ata-disk.c#6 integrate .. //depot/projects/ia64_epc/sys/dev/ata/ata-pci.h#6 integrate .. //depot/projects/ia64_epc/sys/dev/fb/fbreg.h#5 integrate .. //depot/projects/ia64_epc/sys/dev/fb/vga.c#5 integrate .. //depot/projects/ia64_epc/sys/dev/firewire/sbp.c#13 integrate .. //depot/projects/ia64_epc/sys/dev/kbd/atkbdc.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinum.c#4 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumconfig.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumext.h#4 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumio.c#3 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumioctl.c#3 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumkw.h#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumlock.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinummemory.c#3 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumparser.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumraid5.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumrequest.c#3 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumrevive.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumutil.c#2 integrate .. //depot/projects/ia64_epc/sys/dev/vinum/vinumvar.h#2 integrate .. //depot/projects/ia64_epc/sys/geom/geom_gpt.c#6 integrate .. //depot/projects/ia64_epc/sys/i386/include/elf.h#2 integrate .. //depot/projects/ia64_epc/sys/i386/include/metadata.h#1 branch .. //depot/projects/ia64_epc/sys/i386/include/specialreg.h#2 integrate .. //depot/projects/ia64_epc/sys/i386/include/vmparam.h#4 integrate .. //depot/projects/ia64_epc/sys/ia64/ia64/exception.s#18 integrate .. //depot/projects/ia64_epc/sys/ia64/ia64/machdep.c#20 integrate .. //depot/projects/ia64_epc/sys/ia64/ia64/mp_machdep.c#9 integrate .. //depot/projects/ia64_epc/sys/ia64/ia64/pmap.c#8 integrate .. //depot/projects/ia64_epc/sys/ia64/include/asm.h#5 integrate .. //depot/projects/ia64_epc/sys/ia64/include/cpu.h#7 integrate .. //depot/projects/ia64_epc/sys/isa/vga_isa.c#5 integrate .. //depot/projects/ia64_epc/sys/kern/vfs_default.c#8 integrate .. //depot/projects/ia64_epc/sys/kern/vfs_subr.c#11 integrate .. //depot/projects/ia64_epc/sys/powerpc/include/metadata.h#2 integrate .. //depot/projects/ia64_epc/sys/powerpc/powerpc/machdep.c#6 integrate .. //depot/projects/ia64_epc/sys/sparc64/include/metadata.h#2 integrate .. //depot/projects/ia64_epc/sys/sparc64/sparc64/machdep.c#10 integrate .. //depot/projects/ia64_epc/sys/sys/linker.h#2 integrate .. //depot/projects/ia64_epc/sys/vm/vm_object.c#13 integrate .. //depot/projects/ia64_epc/sys/x86_64/compile/.cvsignore#2 delete .. //depot/projects/ia64_epc/sys/x86_64/include/_limits.h#3 delete .. //depot/projects/ia64_epc/sys/x86_64/include/_stdint.h#2 delete .. //depot/projects/ia64_epc/sys/x86_64/include/_types.h#3 delete .. //depot/projects/ia64_epc/sys/x86_64/include/endian.h#2 delete .. //depot/projects/ia64_epc/sys/x86_64/include/limits.h#3 delete .. //depot/projects/ia64_epc/sys/x86_64/include/param.h#2 delete .. //depot/projects/ia64_epc/sys/x86_64/include/stdarg.h#2 delete .. //depot/projects/ia64_epc/usr.bin/m4/eval.c#2 integrate Differences ... ==== //depot/projects/ia64_epc/Makefile#4 (text+ko) ==== @@ -62,9 +62,7 @@ cleandepend cleandir depend distribute distributeworld everything \ hierarchy install installcheck installkernel \ reinstallkernel installmost installworld libraries lint maninstall \ - mk most obj objlink regress rerelease tags update \ - _worldtmp _bootstrap-tools _cleanobj _obj _build-tools \ - _cross-tools _includes _libraries _depend + mk most obj objlink regress rerelease tags update BITGTS= files includes BITGTS:=${BITGTS} ${BITGTS:S/^/build/} ${BITGTS:S/^/install/} ==== //depot/projects/ia64_epc/bin/pax/tar.1#2 (text+ko) ==== @@ -27,7 +27,7 @@ .\" (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: src/bin/pax/tar.1,v 1.6 2002/10/06 07:56:27 tjr Exp $ +.\" $FreeBSD: src/bin/pax/tar.1,v 1.7 2003/05/01 02:37:46 tjr Exp $ .\" $OpenBSD: tar.1,v 1.33 2001/05/01 17:58:01 aaron Exp $ .\" .Dd February 7, 2001 @@ -41,7 +41,7 @@ .Sm off .Op Fl .Brq Cm crtux -.Op Cm befhmopqsvwzHLOPXZ014578 +.Op Cm befhjmopqsvwyzHLOPXZ014578 .Sm on .Op Ar blocksize .Op Ar archive ==== //depot/projects/ia64_epc/lib/libc/ia64/sys/brk.S#4 (text+ko) ==== ==== //depot/projects/ia64_epc/lib/libc/ia64/sys/sbrk.S#4 (text+ko) ==== ==== //depot/projects/ia64_epc/lib/libthr/arch/ia64/Makefile.inc#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libthr/arch/ia64/Makefile.inc,v 1.1 2003/04/20 03:06:42 marcel Exp $ .PATH: ${.CURDIR}/sys ${.CURDIR}/arch/${MACHINE_ARCH}/${MACHINE_ARCH} ==== //depot/projects/ia64_epc/lib/libthr/arch/ia64/ia64/_curthread.c#3 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD$"); +__FBSDID("$FreeBSD: src/lib/libthr/arch/ia64/ia64/_curthread.c,v 1.1 2003/04/20 03:06:42 marcel Exp $"); #include #include ==== //depot/projects/ia64_epc/sbin/vinum/commands.c#4 (text+ko) ==== @@ -36,31 +36,11 @@ * otherwise) arising in any way out of the use of this software, even if * advised of the possibility of such damage. * - * $Id: commands.c,v 1.15 2001/05/22 08:40:21 grog Exp grog $ - * $FreeBSD: src/sbin/vinum/commands.c,v 1.46 2003/03/15 20:49:38 phk Exp $ + * $Id: commands.c,v 1.22 2003/04/28 06:19:06 grog Exp $ + * $FreeBSD: src/sbin/vinum/commands.c,v 1.47 2003/05/01 01:39:49 grog Exp $ */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include #include "vext.h" -#include -#include -#include -#include -#include -#include -#include #include static void dorename(struct vinum_rename_msg *msg, const char *oldname, const char *name, int maxlen); @@ -122,8 +102,8 @@ char *configline; configline = fgets(buffer, BUFSIZE, dfd); - if (history) - fprintf(history, "%s", buffer); + if (History) + fprintf(History, "%s", buffer); if (configline == NULL) { if (ferror(dfd)) @@ -268,6 +248,9 @@ } } checkupdates(); /* make sure we're updating */ + /* Arguably we should be cleverer about this. */ + if (no_devfs) + make_devices(); } } @@ -277,28 +260,31 @@ char reply[32]; int error; - printf(" WARNING! This command will completely wipe out your vinum configuration.\n" - " All data will be lost. If you really want to do this, enter the text\n\n" - " NO FUTURE\n" - " Enter text -> "); - fgets(reply, sizeof(reply), stdin); - if (strcmp(reply, "NO FUTURE\n")) /* changed his mind */ - printf("\n No change\n"); - else { - error = ioctl(superdev, VINUM_RESETCONFIG, NULL); /* trash config on disk */ - if (error) { - if (errno == EBUSY) - fprintf(stderr, "Can't reset configuration: objects are in use\n"); - else - perror("Can't find vinum config"); - } else { - if (no_devfs) - make_devices(); /* recreate the /dev/vinum hierarchy */ - printf("\b Vinum configuration obliterated\n"); - start_daemon(); /* then restart the daemon */ + if (isatty(STDIN_FILENO)) { + printf(" WARNING! This command will completely wipe out your vinum configuration.\n" + " All data will be lost. If you really want to do this, enter the text\n\n" + " NO FUTURE\n" + " Enter text -> "); + fgets(reply, sizeof(reply), stdin); + if (strcmp(reply, "NO FUTURE\n")) /* changed his mind */ + printf("\n No change\n"); + else { + error = ioctl(superdev, VINUM_RESETCONFIG, NULL); /* trash config on disk */ + if (error) { + if (errno == EBUSY) + fprintf(stderr, "Can't reset configuration: objects are in use\n"); + else + perror("Can't find vinum config"); + } else { + if (no_devfs) + make_devices(); /* recreate the /dev/vinum hierarchy */ + printf("\b Vinum configuration obliterated\n"); + start_daemon(); /* then restart the daemon */ + } } - } - checkupdates(); /* make sure we're updating */ + checkupdates(); /* make sure we're updating */ + } else + fprintf(stderr, "Please enter this command from a terminal\n"); } /* Initialize subdisks */ @@ -310,8 +296,8 @@ int objno; enum objecttype type; /* type returned */ - if (history) - fflush(history); /* don't let all the kids do it. */ + if (History) + fflush(History); /* don't let all the kids do it. */ for (objindex = 0; objindex < argc; objindex++) { objno = find_object(argv[objindex], &type); /* find the object */ if (objno < 0) @@ -399,13 +385,6 @@ } } if (failed == 0) { -#if 0 - message->index = plexno; /* pass object number */ - message->type = plex_object; /* and type of object */ - message->state = object_up; - message->force = 1; /* insist */ - ioctl(superdev, VINUM_SETSTATE, message); -#endif syslog(LOG_INFO | LOG_KERN, "plex %s initialized", plex.name); } else syslog(LOG_ERR | LOG_KERN, "couldn't initialize plex %s, %d processes died", @@ -545,10 +524,11 @@ for (i = 0; i < devs; i++) { struct devstat *stat = &statinfo.dinfo->devices[i]; + /* Submitted by Pete Carah */ if ((((stat->device_type & DEVSTAT_TYPE_MASK) == DEVSTAT_TYPE_DIRECT) /* disk device */ - || ((stat->device_type & DEVSTAT_TYPE_MASK) == DEVSTAT_TYPE_STORARRAY)) /* storage array */ - &&((stat->device_type & DEVSTAT_TYPE_PASS) == 0) /* and not passthrough */ - &&((stat->device_name[0] != '\0'))) { /* and it has a name */ + ||((stat->device_type & DEVSTAT_TYPE_MASK) == DEVSTAT_TYPE_STORARRAY)) /* storage array */ + &&((stat->device_type & DEVSTAT_TYPE_PASS) == 0) /* and not passthrough */ + &&((stat->device_name[0] != '\0'))) { /* and it has a name */ sprintf(enamelist, _PATH_DEV "%s%d", stat->device_name, stat->unit_number); token[tokens] = enamelist; /* point to it */ tokens++; /* one more token */ @@ -2098,7 +2078,8 @@ /* * First, check our drives. */ - if (argc & 1) { + if ((argc < 2) + || (argc & 1)) { fprintf(stderr, "You need an even number of drives to create a mirrored volume\n"); return; } ==== //depot/projects/ia64_epc/sbin/vinum/list.c#4 (text+ko) ==== @@ -39,27 +39,13 @@ * otherwise) arising in any way out of the use of this software, even if * advised of the possibility of such damage. * - * $Id: list.c,v 1.25 2000/12/20 03:38:43 grog Exp grog $ - * $FreeBSD: src/sbin/vinum/list.c,v 1.37 2003/03/15 20:49:38 phk Exp $ + * $Id: list.c,v 1.32 2003/04/28 06:19:06 grog Exp $ + * $FreeBSD: src/sbin/vinum/list.c,v 1.38 2003/05/01 01:38:55 grog Exp $ */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include "vext.h" #include -#include -#include "vext.h" #include -/* #include */ #include /* @@ -599,6 +585,8 @@ (long long) sd.sectors * DEV_BSIZE, (long long) sd.sectors / (MEGABYTE / DEV_BSIZE), sd_state(sd.state)); + if (sd.flags & VF_RETRYERRORS) + printf("\t\tretryerrors\n"); if (sd.plexno >= 0) { get_plex_info(&plex, sd.plexno); printf("\t\tPlex %s", plex.name); @@ -828,6 +816,21 @@ return &text[11]; } +/* Return the difference in microseconds between two timevals. */ +inline struct timeval +timediff(struct timeval then, struct timeval now) +{ + struct timeval diff; + + diff.tv_sec = now.tv_sec - then.tv_sec; + diff.tv_usec = now.tv_usec - then.tv_usec; + if (diff.tv_usec < 0) { + diff.tv_usec += 1000000; + diff.tv_sec--; + } + return diff; +} + void vinum_info(int argc, char *argv[], char *argv0[]) { @@ -835,6 +838,8 @@ struct mc malloced; int i; struct rqinfo rq; + struct timeval lasttime; /* time of previous request */ + struct timeval diff; /* difference from now */ if (ioctl(superdev, VINUM_GETCONFIG, &vinum_conf) < 0) { perror("Can't get vinum config"); @@ -848,7 +853,8 @@ perror("Can't get information"); return; } - printf("Total of %d blocks malloced, total memory: %d\nMaximum allocs: %8d, malloc table at 0x%08x\n", + printf("Total of %d blocks malloced, total memory: %d\n" + "Maximum allocs: %8d, malloc table at 0x%08x\n", meminfo.mallocs, meminfo.total_malloced, meminfo.highwater, @@ -875,147 +881,194 @@ (char *) &malloced.file); } if (Verbose) { - printf("\nTime\t\t Event\t Buf\tDev\t Offset\tBytes\tSD\tSDoff\tDoffset\tGoffset\n\n"); + if (Verbose > 1) { + lasttime.tv_sec = 0; + lasttime.tv_usec = 0; + printf("\n Time\t\t Event\t Buf\tDev\t Offset\t" + "Bytes\tSD\tSDoff\tDoffset\tGoffset\n\n"); + } else + printf("\nTime\t\t Event\t Buf\tDev\t Offset\tBytes\tSD" + "\tSDoff\tDoffset\tGoffset\n\n"); for (i = RQINFO_SIZE - 1; i >= 0; i--) { /* go through the request list in order */ *((int *) &rq) = i; if (ioctl(superdev, VINUM_RQINFO, &rq) < 0) { perror("Can't get information"); return; } - /* Compress devminor into something printable. */ - rq.devminor = (rq.devminor & 0xff) - | ((rq.devminor & 0xfff0000) >> 8); - switch (rq.type) { - case loginfo_unused: /* never been used */ - break; + if (rq.type != loginfo_unused) { + switch (Verbose) { + case 2: + if ((lasttime.tv_usec != 0) || (lasttime.tv_sec != 0)) { + diff = timediff(lasttime, rq.timestamp); + if (diff.tv_sec != 0) + printf("\n+ %d.%06d sec:\n ", diff.tv_sec, diff.tv_usec); + else + printf("+%6d µs ", diff.tv_usec); + } else + printf(" "); + break; + + case 3: + if ((lasttime.tv_usec != 0) || (lasttime.tv_sec != 0)) + diff = timediff(lasttime, rq.timestamp); + if (diff.tv_sec != 0) + printf("\n+ %d.%06d sec:\n ", diff.tv_sec, diff.tv_usec); + else if (rq.type == loginfo_iodone) { + diff = timediff(rq.info.rqe.launchtime, rq.timestamp); + printf("+%6d µs ", + diff.tv_usec); + } else + printf(" "); + break; + + default: + break; + } - case loginfo_user_bp: /* this is the bp when strategy is called */ - printf("%s %dVS %s %p\t%2d.%-6d 0x%9llx\t%d\n", - timetext(&rq.timestamp), - rq.type, - rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.devmajor, - rq.devminor, - rq.info.b.b_blkno, - rq.info.b.b_bcount); - break; + /* Compress devminor into something printable. */ + rq.devminor = (rq.devminor & 0xff) + | ((rq.devminor & 0xfff0000) >> 8); + switch (rq.type) { + case loginfo_user_bp: /* this is the bp when strategy is called */ + printf("%s %dVS %s %p\t%2d.%-6d 0x%9llx\t%d\n", + timetext(&rq.timestamp), + rq.type, + rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.devmajor, + rq.devminor, + rq.info.b.b_blkno, + rq.info.b.b_bcount); + break; - case loginfo_sdiol: /* subdisk I/O launch */ - case loginfo_user_bpl: /* and this is the bp at launch time */ - printf("%s %dLR %s %p\t%2d.%-6d 0x%9llx\t%ld\n", - timetext(&rq.timestamp), - rq.type, - rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.devmajor, - rq.devminor, - rq.info.b.b_blkno, - rq.info.b.b_bcount); - break; + case loginfo_sdiol: /* subdisk I/O launch */ + case loginfo_user_bpl: /* and this is the bp at launch time */ + printf("%s %dLR %s %p\t%2d.%-6d 0x%9llx\t%ld\n", + timetext(&rq.timestamp), + rq.type, + rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.devmajor, + rq.devminor, + rq.info.b.b_blkno, + rq.info.b.b_bcount); + break; - case loginfo_rqe: /* user RQE */ - printf("%s 3RQ %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", - timetext(&rq.timestamp), - rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.devmajor, - rq.devminor, - rq.info.rqe.b.b_blkno, - rq.info.rqe.b.b_bcount, - rq.info.rqe.sdno, - rq.info.rqe.sdoffset, - rq.info.rqe.dataoffset, - rq.info.rqe.groupoffset); - break; + case loginfo_rqe: /* user RQE */ + /* + * We have two timestamps + * in this request, and + * they might not agree by + * one or two µs. Make + * them agree by force. + */ + rq.timestamp = rq.info.rqe.launchtime; + printf("%s 3RQ %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", + timetext(&rq.timestamp), + rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.devmajor, + rq.devminor, + rq.info.rqe.b.b_blkno, + rq.info.rqe.b.b_bcount, + rq.info.rqe.sdno, + rq.info.rqe.sdoffset, + rq.info.rqe.dataoffset, + rq.info.rqe.groupoffset); + break; - case loginfo_iodone: /* iodone called */ - printf("%s 4DN %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", - timetext(&rq.timestamp), - rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.devmajor, - rq.devminor, - rq.info.rqe.b.b_blkno, - rq.info.rqe.b.b_bcount, - rq.info.rqe.sdno, - rq.info.rqe.sdoffset, - rq.info.rqe.dataoffset, - rq.info.rqe.groupoffset); - break; + case loginfo_iodone: /* iodone called */ + printf("%s 4DN %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", + timetext(&rq.timestamp), + rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.devmajor, + rq.devminor, + rq.info.rqe.b.b_blkno, + rq.info.rqe.b.b_bcount, + rq.info.rqe.sdno, + rq.info.rqe.sdoffset, + rq.info.rqe.dataoffset, + rq.info.rqe.groupoffset); + break; - case loginfo_raid5_data: /* RAID-5 write data block */ - printf("%s 5RD %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", - timetext(&rq.timestamp), - rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.devmajor, - rq.devminor, - rq.info.rqe.b.b_blkno, - rq.info.rqe.b.b_bcount, - rq.info.rqe.sdno, - rq.info.rqe.sdoffset, - rq.info.rqe.dataoffset, - rq.info.rqe.groupoffset); - break; + case loginfo_raid5_data: /* RAID-5 write data block */ + printf("%s 5RD %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", + timetext(&rq.timestamp), + rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.devmajor, + rq.devminor, + rq.info.rqe.b.b_blkno, + rq.info.rqe.b.b_bcount, + rq.info.rqe.sdno, + rq.info.rqe.sdoffset, + rq.info.rqe.dataoffset, + rq.info.rqe.groupoffset); + break; - case loginfo_raid5_parity: /* RAID-5 write parity block */ - printf("%s 6RP %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", - timetext(&rq.timestamp), - rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.devmajor, - rq.devminor, - rq.info.rqe.b.b_blkno, - rq.info.rqe.b.b_bcount, - rq.info.rqe.sdno, - rq.info.rqe.sdoffset, - rq.info.rqe.dataoffset, - rq.info.rqe.groupoffset); - break; + case loginfo_raid5_parity: /* RAID-5 write parity block */ + printf("%s 6RP %s %p\t%2d.%-6d 0x%9llx\t%ld\t%d\t%6x\t%6x\t%x\n", + timetext(&rq.timestamp), + rq.info.rqe.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.devmajor, + rq.devminor, + rq.info.rqe.b.b_blkno, + rq.info.rqe.b.b_bcount, + rq.info.rqe.sdno, + rq.info.rqe.sdoffset, + rq.info.rqe.dataoffset, + rq.info.rqe.groupoffset); + break; - case loginfo_sdio: /* subdisk I/O */ - printf("%s %dVS %s %p\t\t 0x%9llx\t%ld\t%d\n", - timetext(&rq.timestamp), - rq.type, - rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.info.b.b_blkno, - rq.info.b.b_bcount, - rq.devminor); - break; + case loginfo_sdio: /* subdisk I/O */ + printf("%s %dVS %s %p\t\t 0x%9llx\t%ld\t%d\n", + timetext(&rq.timestamp), + rq.type, + rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.info.b.b_blkno, + rq.info.b.b_bcount, + rq.devminor); + break; - case loginfo_sdiodone: /* subdisk I/O done */ - printf("%s %dSD %s %p\t\t 0x%9llx\t%ld\t%d\n", - timetext(&rq.timestamp), - rq.type, - rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", - rq.bp, - rq.info.b.b_blkno, - rq.info.b.b_bcount, - rq.devminor); - break; + case loginfo_sdiodone: /* subdisk I/O done */ + printf("%s %dSD %s %p\t\t 0x%9llx\t%ld\t%d\n", + timetext(&rq.timestamp), + rq.type, + rq.info.b.b_iocmd == BIO_READ ? "Read " : "Write", + rq.bp, + rq.info.b.b_blkno, + rq.info.b.b_bcount, + rq.devminor); + break; - case loginfo_lockwait: - printf("%s Lockwait %p\t 0x%x\n", - timetext(&rq.timestamp), - rq.bp, - rq.info.lockinfo.stripe); - break; + case loginfo_lockwait: + printf("%s Lockwait %p\t 0x%x\n", + timetext(&rq.timestamp), + rq.bp, + rq.info.lockinfo.stripe); + break; - case loginfo_lock: - printf("%s Lock %p\t 0x%x\n", - timetext(&rq.timestamp), - rq.bp, - rq.info.lockinfo.stripe); - break; + case loginfo_lock: + printf("%s Lock %p\t 0x%x\n", + timetext(&rq.timestamp), + rq.bp, + rq.info.lockinfo.stripe); + break; - case loginfo_unlock: - printf("%s Unlock\t %p\t 0x%x\n", - timetext(&rq.timestamp), - rq.bp, - rq.info.lockinfo.stripe); - break; + case loginfo_unlock: + printf("%s Unlock\t %p\t 0x%x\n", + timetext(&rq.timestamp), + rq.bp, + rq.info.lockinfo.stripe); + break; + default: + printf("*** invalid log type: %d ***\n", rq.type); + } + if (Verbose > 1) + lasttime = rq.timestamp; } } } @@ -1214,7 +1267,7 @@ { int i; - if (argc == 0) { /* start everything */ + if (argc == 0) { /* dump everything */ int devs = devstat_getnumdevs(NULL); struct statinfo statinfo; char *namelist; ==== //depot/projects/ia64_epc/sbin/vinum/v.c#2 (text+ko) ==== @@ -36,37 +36,14 @@ * otherwise) arising in any way out of the use of this software, even if * advised of the possibility of such damage. * - * $Id: v.c,v 1.31 2000/09/03 01:29:26 grog Exp grog $ - * $FreeBSD: src/sbin/vinum/v.c,v 1.37 2003/01/16 23:48:34 joerg Exp $ + * $Id: v.c,v 1.35 2003/04/26 02:02:49 grog Exp $ + * $FreeBSD: src/sbin/vinum/v.c,v 1.38 2003/05/01 01:39:42 grog Exp $ */ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include #include "vext.h" -#include -#include -#include -#include -#include -#include -#include -#include FILE *cf; /* config file handle */ -FILE *history; /* history file */ +FILE *History; /* history file */ char *historyfile; /* and its name */ char *dateformat; /* format in which to store date */ @@ -150,11 +127,11 @@ errno); exit(1); } - history = fopen(historyfile, "a+"); - if (history != NULL) { + History = fopen(historyfile, "a+"); + if (History != NULL) { timestamp(); - fprintf(history, "*** " VINUMMOD " started ***\n"); - fflush(history); /* before we start the daemon */ + fprintf(History, "*** " VINUMMOD " started ***\n"); + fflush(History); /* before we start the daemon */ } if (sysctlbyname("vfs.devfs.generation", NULL, NULL, NULL, 0) == 0) no_devfs = 0; @@ -246,8 +223,8 @@ if (tokens) parseline(tokens, token); /* and do what he says */ } - if (history) - fflush(history); + if (History) + fflush(History); } } return 0; /* normal completion */ @@ -336,11 +313,11 @@ int j; enum keyword command; /* command to execute */ - if (history != NULL) { /* save the command to history file */ + if (History != NULL) { /* save the command to history file */ timestamp(); for (i = 0; i < args; i++) /* all args */ - fprintf(history, "%s ", argv[i]); - fputs("\n", history); + fprintf(History, "%s ", argv[i]); + fputs("\n", History); } if ((args == 0) /* empty line */ ||(*argv[0] == '#')) /* or a comment, */ @@ -544,9 +521,9 @@ perror(VINUMMOD ": Can't write to " _PATH_DEV); return; } - if (history) { + if (History) { timestamp(); - fprintf(history, "*** Created devices ***\n"); + fprintf(History, "*** Created devices ***\n"); } if (superdev >= 0) /* super device open */ close(superdev); @@ -559,10 +536,9 @@ if (mknod(VINUM_SUPERDEV_NAME, S_IRUSR | S_IWUSR | S_IFCHR, /* user only */ - makedev(VINUM_CDEV_MAJOR, VINUM_SUPERDEV)) < 0) + makedev(VINUM_CDEV_MAJOR, VINUM_SUPERDEV_VOL)) < 0) fprintf(stderr, "Can't create %s: %s\n", VINUM_SUPERDEV_NAME, strerror(errno)); - superdev = open(VINUM_SUPERDEV_NAME, O_RDWR); /* open the super device */ if (superdev < 0) { perror(VINUM_SUPERDEV_NAME); @@ -570,7 +546,7 @@ } if (mknod(VINUM_DAEMON_DEV_NAME, /* daemon super device */ S_IRUSR | S_IWUSR | S_IFCHR, /* user only */ - makedev(VINUM_CDEV_MAJOR, VINUM_DAEMON_DEV)) < 0) + makedev(VINUM_CDEV_MAJOR, VINUM_DAEMON_VOL)) < 0) fprintf(stderr, "Can't create %s: %s\n", VINUM_DAEMON_DEV_NAME, strerror(errno)); if (ioctl(superdev, VINUM_GETCONFIG, &vinum_conf) < 0) { @@ -608,26 +584,29 @@ get_volume_info(&vol, volno); if (vol.state != volume_unallocated) { /* we could have holes in our lists */ - voldev = VINUMDEV(volno, 0, 0, VINUM_VOLUME_TYPE); /* create a device number */ + voldev = VINUMDEV(volno, VINUM_VOLUME_TYPE); /* create a device number */ /* Create /dev/vinum/ */ sprintf(filename, VINUM_DIR "/%s", vol.name); if (mknod(filename, S_IRUSR | S_IWUSR | S_IRGRP | S_IFCHR, voldev) < 0) fprintf(stderr, "Can't create %s: %s\n", filename, strerror(errno)); - (void)chown(filename, UID_ROOT, gid_operator); + else + chown(filename, UID_ROOT, gid_operator); /* Create /dev/vinum/vol/ */ sprintf(filename, VINUM_DIR "/vol/%s", vol.name); if (mknod(filename, S_IRUSR | S_IWUSR | S_IRGRP | S_IFCHR, voldev) < 0) fprintf(stderr, "Can't create %s: %s\n", filename, strerror(errno)); - (void)chown(filename, UID_ROOT, gid_operator); + else + chown(filename, UID_ROOT, gid_operator); if (vol.plexes > 0) { /* Create /dev/vinum/vol/.plex/ */ sprintf(filename, VINUM_DIR "/vol/%s.plex", vol.name); if (mkdir(filename, S_IRUSR | S_IWUSR | S_IRGRP | S_IXOTH) < 0) fprintf(stderr, "Can't create %s: %s\n", filename, strerror(errno)); - (void)chown(filename, UID_ROOT, gid_operator); + else + chown(filename, UID_ROOT, gid_operator); } if (recurse) for (plexno = 0; plexno < vol.plexes; plexno++) @@ -654,23 +633,26 @@ sprintf(filename, VINUM_DIR "/plex/%s", plex.name); if (mknod(filename, S_IRUSR | S_IWUSR | S_IRGRP | S_IFCHR, plexdev) < 0) fprintf(stderr, "Can't create %s: %s\n", filename, strerror(errno)); - (void)chown(filename, UID_ROOT, gid_operator); + else + chown(filename, UID_ROOT, gid_operator); >>> TRUNCATED FOR MAIL (1000 lines) <<<