PERFORCE change 69006 for review

John Baldwin jhb at FreeBSD.org
Fri Jan 14 07:30:50 PST 2005


http://perforce.freebsd.org/chv.cgi?CH=69006

Change 69006 by jhb at jhb_slimer on 2005/01/14 15:30:06

	IFC @69003

Affected files ...

.. //depot/projects/smpng/sys/amd64/amd64/prof_machdep.c#2 integrate
.. //depot/projects/smpng/sys/amd64/isa/atpic.c#8 integrate
.. //depot/projects/smpng/sys/arm/arm/cpufunc_asm_xscale.S#4 integrate
.. //depot/projects/smpng/sys/arm/arm/machdep.c#8 integrate
.. //depot/projects/smpng/sys/arm/arm/trap.c#7 integrate
.. //depot/projects/smpng/sys/arm/arm/undefined.c#5 integrate
.. //depot/projects/smpng/sys/arm/include/proc.h#3 integrate
.. //depot/projects/smpng/sys/arm/include/trap.h#2 integrate
.. //depot/projects/smpng/sys/boot/i386/boot0/boot0.S#5 integrate
.. //depot/projects/smpng/sys/coda/coda_fbsd.c#12 integrate
.. //depot/projects/smpng/sys/coda/coda_venus.c#11 integrate
.. //depot/projects/smpng/sys/coda/coda_venus.h#5 integrate
.. //depot/projects/smpng/sys/coda/coda_vfsops.c#21 integrate
.. //depot/projects/smpng/sys/coda/coda_vnops.c#19 integrate
.. //depot/projects/smpng/sys/compat/linprocfs/linprocfs.c#43 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_file.c#25 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_getcwd.c#15 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_ioctl.c#36 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_ipc.c#17 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_mib.c#11 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_misc.c#51 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_signal.c#16 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_socket.c#21 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_stats.c#21 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_sysctl.c#11 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_uid16.c#20 integrate
.. //depot/projects/smpng/sys/compat/pecoff/imgact_pecoff.c#24 integrate
.. //depot/projects/smpng/sys/conf/NOTES#90 integrate
.. //depot/projects/smpng/sys/conf/files#133 integrate
.. //depot/projects/smpng/sys/conf/files.i386#74 integrate
.. //depot/projects/smpng/sys/conf/files.pc98#68 integrate
.. //depot/projects/smpng/sys/conf/newvers.sh#15 integrate
.. //depot/projects/smpng/sys/conf/options#91 integrate
.. //depot/projects/smpng/sys/contrib/dev/acpica/dsutils.c#17 integrate
.. //depot/projects/smpng/sys/contrib/dev/acpica/nsinit.c#16 integrate
.. //depot/projects/smpng/sys/contrib/ipfilter/netinet/fil.c#16 integrate
.. //depot/projects/smpng/sys/dev/acpica/acpi.c#77 integrate
.. //depot/projects/smpng/sys/dev/aha/aha.c#15 integrate
.. //depot/projects/smpng/sys/dev/aha/aha_isa.c#12 integrate
.. //depot/projects/smpng/sys/dev/amr/amr_cam.c#11 integrate
.. //depot/projects/smpng/sys/dev/amr/amrvar.h#16 integrate
.. //depot/projects/smpng/sys/dev/bfe/if_bfe.c#14 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_audio.c#6 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_card.c#9 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_core.c#16 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_i2c.c#7 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_os.c#23 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_reg.h#8 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_tuner.c#6 integrate
.. //depot/projects/smpng/sys/dev/cardbus/cardbus.c#22 integrate
.. //depot/projects/smpng/sys/dev/cardbus/cardbus_cis.c#22 integrate
.. //depot/projects/smpng/sys/dev/cardbus/cardbus_cis.h#7 integrate
.. //depot/projects/smpng/sys/dev/cardbus/cardbusreg.h#5 integrate
.. //depot/projects/smpng/sys/dev/cardbus/cardbusvar.h#8 integrate
.. //depot/projects/smpng/sys/dev/exca/exca.c#14 integrate
.. //depot/projects/smpng/sys/dev/fdc/fdc_isa.c#8 integrate
.. //depot/projects/smpng/sys/dev/fdc/fdc_pccard.c#5 integrate
.. //depot/projects/smpng/sys/dev/fdc/fdcvar.h#6 integrate
.. //depot/projects/smpng/sys/dev/fe/if_fe.c#17 integrate
.. //depot/projects/smpng/sys/dev/fe/if_fe_cbus.c#6 integrate
.. //depot/projects/smpng/sys/dev/fe/if_fe_isa.c#5 integrate
.. //depot/projects/smpng/sys/dev/fe/if_fe_pccard.c#10 integrate
.. //depot/projects/smpng/sys/dev/fe/if_fevar.h#4 integrate
.. //depot/projects/smpng/sys/dev/matcd/creativeif.h#3 delete
.. //depot/projects/smpng/sys/dev/matcd/matcd.c#7 delete
.. //depot/projects/smpng/sys/dev/matcd/matcd_data.h#4 delete
.. //depot/projects/smpng/sys/dev/matcd/matcd_isa.c#5 delete
.. //depot/projects/smpng/sys/dev/matcd/matcddrv.h#3 delete
.. //depot/projects/smpng/sys/dev/matcd/options.h#3 delete
.. //depot/projects/smpng/sys/dev/mse/mse.c#3 integrate
.. //depot/projects/smpng/sys/dev/mse/mse_cbus.c#3 integrate
.. //depot/projects/smpng/sys/dev/mse/mse_isa.c#3 integrate
.. //depot/projects/smpng/sys/dev/mse/msevar.h#3 integrate
.. //depot/projects/smpng/sys/dev/pccard/pccarddevs#40 integrate
.. //depot/projects/smpng/sys/dev/pccbb/pccbb.c#48 integrate
.. //depot/projects/smpng/sys/dev/pccbb/pccbb_isa.c#3 integrate
.. //depot/projects/smpng/sys/dev/pccbb/pccbb_pci.c#4 integrate
.. //depot/projects/smpng/sys/dev/pccbb/pccbbdevid.h#15 integrate
.. //depot/projects/smpng/sys/dev/pccbb/pccbbreg.h#10 integrate
.. //depot/projects/smpng/sys/dev/pccbb/pccbbvar.h#15 integrate
.. //depot/projects/smpng/sys/dev/puc/puc.c#20 integrate
.. //depot/projects/smpng/sys/dev/puc/puc_pci.c#8 integrate
.. //depot/projects/smpng/sys/dev/puc/pucvar.h#13 integrate
.. //depot/projects/smpng/sys/dev/sio/sio_pci.c#15 integrate
.. //depot/projects/smpng/sys/dev/usb/ehci.c#19 integrate
.. //depot/projects/smpng/sys/dev/usb/ehcivar.h#6 integrate
.. //depot/projects/smpng/sys/dev/usb/ohcivar.h#12 integrate
.. //depot/projects/smpng/sys/dev/usb/uhcivar.h#12 integrate
.. //depot/projects/smpng/sys/fs/deadfs/dead_vnops.c#12 integrate
.. //depot/projects/smpng/sys/fs/devfs/devfs_vfsops.c#20 integrate
.. //depot/projects/smpng/sys/fs/devfs/devfs_vnops.c#39 integrate
.. //depot/projects/smpng/sys/fs/fdescfs/fdesc_vnops.c#20 integrate
.. //depot/projects/smpng/sys/fs/fifofs/fifo_vnops.c#33 integrate
.. //depot/projects/smpng/sys/fs/hpfs/hpfs_vfsops.c#26 integrate
.. //depot/projects/smpng/sys/fs/hpfs/hpfs_vnops.c#25 integrate
.. //depot/projects/smpng/sys/fs/msdosfs/msdosfs_vfsops.c#38 integrate
.. //depot/projects/smpng/sys/fs/msdosfs/msdosfs_vnops.c#30 integrate
.. //depot/projects/smpng/sys/fs/ntfs/ntfs_vfsops.c#26 integrate
.. //depot/projects/smpng/sys/fs/ntfs/ntfs_vnops.c#20 integrate
.. //depot/projects/smpng/sys/fs/nullfs/null_vfsops.c#17 integrate
.. //depot/projects/smpng/sys/fs/nullfs/null_vnops.c#18 integrate
.. //depot/projects/smpng/sys/fs/nwfs/nwfs.h#6 integrate
.. //depot/projects/smpng/sys/fs/nwfs/nwfs_io.c#16 integrate
.. //depot/projects/smpng/sys/fs/nwfs/nwfs_node.c#13 integrate
.. //depot/projects/smpng/sys/fs/nwfs/nwfs_vnops.c#12 integrate
.. //depot/projects/smpng/sys/fs/portalfs/portal_vnops.c#21 integrate
.. //depot/projects/smpng/sys/fs/pseudofs/pseudofs_vncache.c#20 integrate
.. //depot/projects/smpng/sys/fs/pseudofs/pseudofs_vnops.c#34 integrate
.. //depot/projects/smpng/sys/fs/smbfs/smbfs.h#10 integrate
.. //depot/projects/smpng/sys/fs/smbfs/smbfs_io.c#20 integrate
.. //depot/projects/smpng/sys/fs/smbfs/smbfs_node.c#18 integrate
.. //depot/projects/smpng/sys/fs/smbfs/smbfs_vnops.c#29 integrate
.. //depot/projects/smpng/sys/fs/udf/udf_vnops.c#23 integrate
.. //depot/projects/smpng/sys/fs/umapfs/umap_vnops.c#10 integrate
.. //depot/projects/smpng/sys/fs/unionfs/union_subr.c#22 integrate
.. //depot/projects/smpng/sys/fs/unionfs/union_vnops.c#22 integrate
.. //depot/projects/smpng/sys/geom/geom_vfs.c#2 integrate
.. //depot/projects/smpng/sys/geom/mirror/g_mirror.c#17 integrate
.. //depot/projects/smpng/sys/geom/raid3/g_raid3.c#14 integrate
.. //depot/projects/smpng/sys/geom/shsec/g_shsec.c#1 branch
.. //depot/projects/smpng/sys/geom/shsec/g_shsec.h#1 branch
.. //depot/projects/smpng/sys/gnu/ext2fs/ext2_vfsops.c#41 integrate
.. //depot/projects/smpng/sys/gnu/ext2fs/ext2_vnops.c#29 integrate
.. //depot/projects/smpng/sys/i386/conf/GENERIC.hints#7 integrate
.. //depot/projects/smpng/sys/i386/i386/mptable.c#13 integrate
.. //depot/projects/smpng/sys/isa/psm.c#32 integrate
.. //depot/projects/smpng/sys/isofs/cd9660/cd9660_vnops.c#21 integrate
.. //depot/projects/smpng/sys/kern/kern_acct.c#35 integrate
.. //depot/projects/smpng/sys/kern/kern_exit.c#91 integrate
.. //depot/projects/smpng/sys/kern/kern_umtx.c#18 integrate
.. //depot/projects/smpng/sys/kern/uipc_socket.c#65 integrate
.. //depot/projects/smpng/sys/kern/vfs_bio.c#72 integrate
.. //depot/projects/smpng/sys/kern/vfs_default.c#34 integrate
.. //depot/projects/smpng/sys/kern/vfs_init.c#20 integrate
.. //depot/projects/smpng/sys/kern/vfs_lookup.c#22 integrate
.. //depot/projects/smpng/sys/kern/vfs_mount.c#43 integrate
.. //depot/projects/smpng/sys/kern/vfs_subr.c#93 integrate
.. //depot/projects/smpng/sys/kern/vfs_syscalls.c#80 integrate
.. //depot/projects/smpng/sys/kern/vfs_vnops.c#56 integrate
.. //depot/projects/smpng/sys/kern/vnode_if.src#21 integrate
.. //depot/projects/smpng/sys/modules/geom/Makefile#11 integrate
.. //depot/projects/smpng/sys/modules/geom/geom_shsec/Makefile#1 branch
.. //depot/projects/smpng/sys/net/bridge.c#33 integrate
.. //depot/projects/smpng/sys/net/if.c#60 integrate
.. //depot/projects/smpng/sys/net/if_ethersubr.c#55 integrate
.. //depot/projects/smpng/sys/net/if_stf.c#29 integrate
.. //depot/projects/smpng/sys/net/net_osdep.h#12 integrate
.. //depot/projects/smpng/sys/netgraph/bluetooth/drivers/h4/ng_h4.c#10 integrate
.. //depot/projects/smpng/sys/netgraph/bluetooth/drivers/h4/ng_h4_var.h#5 integrate
.. //depot/projects/smpng/sys/netgraph/bluetooth/include/ng_btsocket_rfcomm.h#4 integrate
.. //depot/projects/smpng/sys/netgraph/ng_eiface.c#15 integrate
.. //depot/projects/smpng/sys/netgraph/ng_ether.c#21 integrate
.. //depot/projects/smpng/sys/netgraph/ng_iface.c#18 integrate
.. //depot/projects/smpng/sys/netgraph/ng_l2tp.c#10 integrate
.. //depot/projects/smpng/sys/netgraph/ng_lmi.c#7 integrate
.. //depot/projects/smpng/sys/netgraph/ng_ppp.c#18 integrate
.. //depot/projects/smpng/sys/netgraph/ng_pptpgre.c#16 integrate
.. //depot/projects/smpng/sys/netgraph/ng_tty.c#16 integrate
.. //depot/projects/smpng/sys/netinet/ip_fw.h#26 integrate
.. //depot/projects/smpng/sys/netinet/ip_fw2.c#47 integrate
.. //depot/projects/smpng/sys/netinet/ip_fw_pfil.c#9 integrate
.. //depot/projects/smpng/sys/netinet/tcp_output.c#35 integrate
.. //depot/projects/smpng/sys/netipx/ipx.c#11 integrate
.. //depot/projects/smpng/sys/netipx/ipx_input.c#14 integrate
.. //depot/projects/smpng/sys/netipx/ipx_pcb.c#17 integrate
.. //depot/projects/smpng/sys/netipx/ipx_pcb.h#8 integrate
.. //depot/projects/smpng/sys/netipx/ipx_usrreq.c#21 integrate
.. //depot/projects/smpng/sys/netipx/spx_usrreq.c#20 integrate
.. //depot/projects/smpng/sys/netkey/key.c#29 integrate
.. //depot/projects/smpng/sys/nfs4client/nfs4_vfsops.c#12 integrate
.. //depot/projects/smpng/sys/nfs4client/nfs4_vnops.c#12 integrate
.. //depot/projects/smpng/sys/nfsclient/nfs_bio.c#38 integrate
.. //depot/projects/smpng/sys/nfsclient/nfs_diskless.c#9 integrate
.. //depot/projects/smpng/sys/nfsclient/nfs_vfsops.c#46 integrate
.. //depot/projects/smpng/sys/nfsclient/nfs_vnops.c#48 integrate
.. //depot/projects/smpng/sys/nfsserver/nfs_serv.c#39 integrate
.. //depot/projects/smpng/sys/nfsserver/nfs_srvsubs.c#24 integrate
.. //depot/projects/smpng/sys/pc98/pc98/30line.h#3 integrate
.. //depot/projects/smpng/sys/pc98/pc98/module.h#2 delete
.. //depot/projects/smpng/sys/pc98/pc98/pc98gdc.c#13 integrate
.. //depot/projects/smpng/sys/pci/if_sis.c#47 integrate
.. //depot/projects/smpng/sys/pci/if_sisreg.h#14 integrate
.. //depot/projects/smpng/sys/powerpc/powermac/uninorth.c#9 integrate
.. //depot/projects/smpng/sys/sparc64/conf/NOTES#13 integrate
.. //depot/projects/smpng/sys/sparc64/ebus/ebus.c#18 integrate
.. //depot/projects/smpng/sys/sys/buf.h#35 integrate
.. //depot/projects/smpng/sys/sys/bufobj.h#3 integrate
.. //depot/projects/smpng/sys/sys/joystick.h#3 integrate
.. //depot/projects/smpng/sys/sys/linker_set.h#7 integrate
.. //depot/projects/smpng/sys/sys/mount.h#36 integrate
.. //depot/projects/smpng/sys/sys/umtx.h#9 integrate
.. //depot/projects/smpng/sys/sys/vnode.h#55 integrate
.. //depot/projects/smpng/sys/tools/vnode_if.awk#10 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_balloc.c#15 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_inode.c#20 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_rawread.c#11 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_snapshot.c#44 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_softdep.c#38 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_vfsops.c#65 integrate
.. //depot/projects/smpng/sys/ufs/ufs/ufs_extattr.c#31 integrate
.. //depot/projects/smpng/sys/ufs/ufs/ufs_lookup.c#20 integrate
.. //depot/projects/smpng/sys/ufs/ufs/ufs_vnops.c#45 integrate
.. //depot/projects/smpng/sys/vm/uma_core.c#53 integrate
.. //depot/projects/smpng/sys/vm/vm_object.c#65 integrate

Differences ...

==== //depot/projects/smpng/sys/amd64/amd64/prof_machdep.c#2 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/prof_machdep.c,v 1.21 2004/05/26 09:43:37 bde Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/prof_machdep.c,v 1.22 2005/01/11 03:44:17 imp Exp $");
 
 #ifdef GUPROF
 #if 0
@@ -49,11 +49,7 @@
 
 #include <machine/asmacros.h>
 
-#ifdef PC98
-#include <pc98/pc98/pc98.h>
-#else
 #include <i386/isa/isa.h>
-#endif
 #include <i386/isa/timerreg.h>
 
 #ifdef GUPROF

==== //depot/projects/smpng/sys/amd64/isa/atpic.c#8 (text+ko) ====

@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/isa/atpic.c,v 1.13 2004/08/16 23:12:30 peter Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/isa/atpic.c,v 1.14 2005/01/11 03:44:16 imp Exp $");
 
 #include "opt_auto_eoi.h"
 #include "opt_isa.h"
@@ -64,14 +64,9 @@
 #define	SLAVE	1
 
 /*
- * PC-98 machines wire the slave 8259A to pin 7 on the master PIC, and
  * PC-AT machines wire the slave PIC to pin 2 on the master PIC.
  */
-#ifdef PC98
-#define	ICU_SLAVEID	7
-#else
 #define	ICU_SLAVEID	2
-#endif
 
 /*
  * Determine the base master and slave modes not including auto EOI support.

==== //depot/projects/smpng/sys/arm/arm/cpufunc_asm_xscale.S#4 (text+ko) ====

@@ -73,7 +73,7 @@
  */
  
 #include <machine/asm.h>
-__FBSDID("$FreeBSD: src/sys/arm/arm/cpufunc_asm_xscale.S,v 1.3 2005/01/05 21:58:47 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/arm/arm/cpufunc_asm_xscale.S,v 1.4 2005/01/10 22:41:08 cognet Exp $");
 
 /*
  * Size of the XScale core D-cache.
@@ -171,13 +171,11 @@
 /*
  * TLB functions
  *
- * Note: We don't need to worry about issuing a CPWAIT after
- * TLB operations, because we expect a pmap_update() to follow.
  */
 ENTRY(xscale_tlb_flushID_SE)
 	mcr	p15, 0, r0, c8, c6, 1	/* flush D tlb single entry */
 	mcr	p15, 0, r0, c8, c5, 1	/* flush I tlb single entry */
-	RET
+	CPWAIT_AND_RETURN(r0)
 
 /*
  * Cache functions

==== //depot/projects/smpng/sys/arm/arm/machdep.c#8 (text+ko) ====

@@ -44,7 +44,7 @@
 
 #include "opt_compat.h"
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/arm/arm/machdep.c,v 1.8 2005/01/05 21:58:47 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/arm/arm/machdep.c,v 1.9 2005/01/10 22:43:16 cognet Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -64,8 +64,10 @@
 #include <sys/buf.h>
 #include <sys/exec.h>
 #include <sys/sysent.h>
+#include <sys/uio.h>
 #include <machine/reg.h>
 #include <machine/cpu.h>
+#include <machine/trap.h>
 
 #include <vm/vm.h>
 #include <vm/pmap.h>
@@ -289,17 +291,68 @@
 	return (0);
 }
 
+
+static int
+ptrace_read_int(struct thread *td, vm_offset_t addr, u_int32_t *v)
+{
+	struct iovec iov;
+	struct uio uio;
+	iov.iov_base = (caddr_t) v;
+	iov.iov_len = sizeof(u_int32_t);
+	uio.uio_iov = &iov;
+	uio.uio_iovcnt = 1;
+	uio.uio_offset = (off_t)addr;
+	uio.uio_resid = sizeof(u_int32_t);
+	uio.uio_segflg = UIO_SYSSPACE;
+	uio.uio_rw = UIO_READ;
+	uio.uio_td = td;
+	return proc_rwmem(td->td_proc, &uio);
+}
+
+static int
+ptrace_write_int(struct thread *td, vm_offset_t addr, u_int32_t v)
+{
+	struct iovec iov;
+	struct uio uio;
+	iov.iov_base = (caddr_t) &v;
+	iov.iov_len = sizeof(u_int32_t);
+	uio.uio_iov = &iov;
+	uio.uio_iovcnt = 1;
+	uio.uio_offset = (off_t)addr;
+	uio.uio_resid = sizeof(u_int32_t);
+	uio.uio_segflg = UIO_SYSSPACE;
+	uio.uio_rw = UIO_WRITE;
+	uio.uio_td = td;
+	return proc_rwmem(td->td_proc, &uio);
+}
+
 int
 ptrace_single_step(struct thread *td)
 {
-	/* XXX */
-	return (0);
+	int error;
+	
+	KASSERT(td->td_md.md_ptrace_instr == 0,
+	 ("Didn't clear single step"));
+	error = ptrace_read_int(td, td->td_frame->tf_pc + 4, 
+	    &td->td_md.md_ptrace_instr);
+	if (error)
+		return (error);
+	error = ptrace_write_int(td, td->td_frame->tf_pc + 4,
+	    PTRACE_BREAKPOINT);
+	if (error)
+		td->td_md.md_ptrace_instr = 0;
+	td->td_md.md_ptrace_addr = td->td_frame->tf_pc + 4;
+	return (error);
 }
 
 int
 ptrace_clear_single_step(struct thread *td)
 {
-	/* XXX */
+	if (td->td_md.md_ptrace_instr) {
+		ptrace_write_int(td, td->td_md.md_ptrace_addr,
+		    td->td_md.md_ptrace_instr);
+		td->td_md.md_ptrace_instr = 0;
+	}
 	return (0);
 }
 

==== //depot/projects/smpng/sys/arm/arm/trap.c#7 (text+ko) ====

@@ -82,7 +82,7 @@
 #include "opt_ktrace.h"
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/arm/arm/trap.c,v 1.9 2005/01/05 21:58:47 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/arm/arm/trap.c,v 1.10 2005/01/10 22:43:16 cognet Exp $");
 
 #include <sys/types.h>
 
@@ -100,6 +100,8 @@
 #include <sys/uio.h>
 #include <sys/ktrace.h>
 #endif
+#include <sys/ptrace.h>
+#include <sys/pioctl.h>
 
 #include <vm/vm.h>
 #include <vm/pmap.h>
@@ -919,6 +921,8 @@
 	if (error == 0) {
 		td->td_retval[0] = 0;
 		td->td_retval[1] = 0;
+		STOPEVENT(p, S_SCE, (callp->sy_narg & SYF_ARGMASK));
+		PTRACESTOP_SC(p, td, S_PT_SCE);
 		error = (*callp->sy_call)(td, args);
 	}
 	switch (error) {
@@ -952,6 +956,8 @@
 	CTR4(KTR_SYSC, "syscall exit thread %p pid %d proc %s code %d", td,
 	    td->td_proc->p_pid, td->td_proc->p_comm, code);
 	
+	STOPEVENT(p, S_SCX, code);
+	PTRACESTOP_SC(p, td, S_PT_SCX);
 #ifdef KTRACE
       	if (KTRPOINT(td, KTR_SYSRET))
 		ktrsysret(code, error, td->td_retval[0]);

==== //depot/projects/smpng/sys/arm/arm/undefined.c#5 (text+ko) ====

@@ -48,7 +48,7 @@
 #include "opt_ddb.h"
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/arm/arm/undefined.c,v 1.6 2005/01/05 21:58:47 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/arm/arm/undefined.c,v 1.7 2005/01/10 22:43:16 cognet Exp $");
 
 #include <sys/param.h>
 #include <sys/malloc.h>
@@ -62,6 +62,7 @@
 #include <sys/lock.h>
 #include <sys/mutex.h>
 #include <sys/signalvar.h>
+#include <sys/ptrace.h>
 #ifdef KDB
 #include <sys/kdb.h>
 #endif
@@ -135,26 +136,17 @@
 	struct thread *td;
 	td = (curthread == NULL) ? &thread0 : curthread;
 
-#if 0
 	if (insn == GDB_BREAKPOINT || insn == GDB5_BREAKPOINT) {
 		if (code == FAULT_USER) {
-			ksiginfo_t ksi;
-
-			KSI_INIT_TRAP(&ksi);
-			ksi.ksi_signo = SIGTRAP;
-			ksi.ksi_code = TRAP_BRKPT;
-			ksi.ksi_addr = (u_int32_t *)addr;
-			ksi.ksi_trap = 0;
-			PROC_LOCK(td->td_proc);
-			trapsignal(td, &ksi);
-			PROC_UNLOCK(td->td_proc);
+			trapsignal(td, SIGTRAP, 0);
 			return 0;
 		}
+#if 0
 #ifdef KGDB
 		return !kgdb_trap(T_BREAKPOINT, frame);
 #endif
+#endif
 	}
-#endif
 	return 1;
 }
 
@@ -257,6 +249,11 @@
 			       fault_code) == 0)
 		    break;
 
+	if (fault_code & FAULT_USER && fault_instruction == PTRACE_BREAKPOINT) {
+		ptrace_clear_single_step(td);
+		return;
+	}
+
 	if (uh == NULL && (fault_code & FAULT_USER)) {
 		/* Fault has not been handled */
 		trapsignal(td, SIGILL, 0);
@@ -272,7 +269,7 @@
 		return;
 		} else
 			panic("Undefined instruction in kernel.\n");
-	}		
+	}
 
 #ifdef FAST_FPE
 	/* Optimised exit code */

==== //depot/projects/smpng/sys/arm/include/proc.h#3 (text+ko) ====

@@ -32,7 +32,7 @@
  *
  *      from: @(#)proc.h        7.1 (Berkeley) 5/15/91
  *	from: FreeBSD: src/sys/i386/include/proc.h,v 1.11 2001/06/29
- * $FreeBSD: src/sys/arm/include/proc.h,v 1.2 2005/01/05 21:58:48 imp Exp $
+ * $FreeBSD: src/sys/arm/include/proc.h,v 1.3 2005/01/10 22:43:16 cognet Exp $
  */
 
 #ifndef	_MACHINE_PROC_H_
@@ -47,6 +47,8 @@
 
 struct mdthread {
 	register_t md_savecrit;
+	int md_ptrace_instr;
+	int md_ptrace_addr;
 };
 
 struct mdproc {

==== //depot/projects/smpng/sys/arm/include/trap.h#2 (text+ko) ====

@@ -1,4 +1,10 @@
 /*	$NetBSD: trap.h,v 1.1 2001/02/23 03:48:19 ichiro Exp $	*/
-/* $FreeBSD: src/sys/arm/include/trap.h,v 1.1 2004/05/14 11:46:44 cognet Exp $ */
+/* $FreeBSD: src/sys/arm/include/trap.h,v 1.2 2005/01/10 22:43:16 cognet Exp $ */
 
+#ifndef _MACHINE_TRAP_H_
+#define _MACHINE_TRAP_H_
+#define GDB_BREAKPOINT		0xe6000011
+#define GDB5_BREAKPOINT		0xe7ffdefe
+#define PTRACE_BREAKPOINT	0xe7fffff0
 #define KERNEL_BREAKPOINT	0xe7ffffff
+#endif /* _MACHINE_TRAP_H_ */

==== //depot/projects/smpng/sys/boot/i386/boot0/boot0.S#5 (text+ko) ====

@@ -13,7 +13,7 @@
  * warranties of merchantability and fitness for a particular
  * purpose.
  *
- * $FreeBSD: src/sys/boot/i386/boot0/boot0.S,v 1.12 2004/11/24 15:39:04 jhb Exp $
+ * $FreeBSD: src/sys/boot/i386/boot0/boot0.S,v 1.13 2005/01/09 23:30:35 peadar Exp $
  */
 
 /* A 512-byte boot manager. */
@@ -104,10 +104,15 @@
  * number should be used.  If what the bios gives us is bad, use the '0' in
  * the block instead.
  */
-		testb $0x20,_FLAGS(%bp)		# Set number drive?
+		testb $0x20,_FLAGS(%bp)		# Set drive number?
 		jnz main.1			# Yes
 		testb %dl,%dl			# Drive number valid?
 		js main.2			# Possibly (0x80 set)
+/*
+ * Only update the boot-sector when there is a valid drive number or
+ * the drive number is set manually.
+ */
+		orb $0x40,_FLAGS(%bp)		# Disable updates
 main.1:		movb _SETDRV(%bp),%dl		# Drive number to use
 /*
  * Whatever we decided to use, now store it into the fake
@@ -145,16 +150,14 @@
 /*
  * Now scan the table of known types
  */
-		movb $TBL1SZ,%cl		# Number of entries
-		repne				# Known
-		scasb				#  type?
-		jne main.4			# No
+		movb $TBL1SZ+1,%cl		# Number of entries
+		repne				# Locate
+		scasb				#  type
 /*
- * If it matches get the matching element in the next array.  If it doesn't,
- * we are already pointing at its first element which points to a "?".
+ * Get the matching element in the next array.
  */
-		addw $TBL1SZ,%di		# Adjust
-main.4:		movb (%di),%cl			# Partition
+		addw $TBL1SZ-1, %di		# Adjust
+		movb (%di),%cl			# Partition
 		addw %cx,%di			#  description
 		callw putx			# Display it
 main.5:		incw %dx			# Next item
@@ -305,7 +308,6 @@
 /*
  * Load selected bootsector to the LOAD location in RAM.
  * If it fails to read or isn't marked bootable, treat it as a bad selection.
- * XXX: What does %si carry?
  */
 main.15:	movw $LOAD,%bx			# Address for read
 		movb $0x2,%ah			# Read sector
@@ -313,10 +315,8 @@
 		jc main.10			# If error
 		cmpw $MAGIC,0x1fe(%bx)		# Bootable?
 		jne main.10			# No
-		pushw %si			# Save
 		movw $crlf,%si			# Leave some
 		callw puts			#  space
-		popw %si			# Restore
 		jmp *%bx			# Invoke bootstrap
 
 /*
@@ -413,9 +413,9 @@
 		.byte 0x9f, 0xa5, 0xa6, 0xa9
 /*
  * These are offsets that match the known names above and point to the strings
- * that will be printed.
+ * that will be printed. os_misc will be used if the search of the above table
+ * runs over.
  */
-		.byte os_misc-. 		# Unknown
 		.byte os_dos-.			# DOS
 		.byte os_dos-.			# DOS
 		.byte os_dos-.			# DOS
@@ -427,6 +427,7 @@
 		.byte os_freebsd-.		# FreeBSD
 		.byte os_bsd-.			# OpenBSD
 		.byte os_bsd-.			# NetBSD
+		.byte os_misc-. 		# Unknown
 /*
  * And here are the strings themselves. 0x80 or'd into a byte indicates
  * the end of the string. (not so great for Russians but...)

==== //depot/projects/smpng/sys/coda/coda_fbsd.c#12 (text+ko) ====

@@ -29,7 +29,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/coda/coda_fbsd.c,v 1.39 2005/01/05 23:35:00 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/coda/coda_fbsd.c,v 1.40 2005/01/13 12:25:18 phk Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -140,9 +140,9 @@
 		return (error);
 	}
 	if (vp->v_type == VREG) {
-	    error = vfs_object_create(vp, p, cred);
+	    error = VOP_CREATEVOBJECT(vp, cred, p);
 	    if (error != 0) {
-		printf("coda_getpage: vfs_object_create() returns %d\n", error);
+		printf("coda_getpage: VOP_CREATEVOBJECT() returns %d\n", error);
 		vput(vp);
 		return(error);
 	    }

==== //depot/projects/smpng/sys/coda/coda_venus.c#11 (text+ko) ====

@@ -29,7 +29,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/coda/coda_venus.c,v 1.22 2005/01/05 23:35:00 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/coda/coda_venus.c,v 1.23 2005/01/11 07:36:18 phk Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -395,14 +395,13 @@
 }
 
 int
-venus_fsync(void *mdp, CodaFid *fid,
-	struct ucred *cred, struct proc *p)
+venus_fsync(void *mdp, CodaFid *fid, struct proc *p)
 {
     DECL_NO_OUT(coda_fsync);		/* sets Isize & Osize */
     ALLOC_NO_OUT(coda_fsync);		/* sets inp & outp */
 
     /* send the open to venus. */
-    INIT_IN(&inp->ih, CODA_FSYNC, cred, p);
+    INIT_IN(&inp->ih, CODA_FSYNC, NOCRED, p);	/* XXX: should be cached mount cred */
     inp->Fid = *fid;
 
     error = coda_call(mdp, Isize, &Osize, (char *)inp);

==== //depot/projects/smpng/sys/coda/coda_venus.h#5 (text+ko) ====

@@ -27,7 +27,7 @@
  * Mellon the rights to redistribute these changes without encumbrance.
  * 
  * 	@(#) src/sys/coda/coda_venus.h,v 1.1.1.1 1998/08/29 21:14:52 rvb Exp $ 
- * $FreeBSD: src/sys/coda/coda_venus.h,v 1.7 2005/01/05 23:35:00 imp Exp $
+ * $FreeBSD: src/sys/coda/coda_venus.h,v 1.8 2005/01/11 07:36:18 phk Exp $
  * 
  */
 
@@ -75,8 +75,7 @@
 /*out*/	char **str, int *len);
 
 int
-venus_fsync(void *mdp, CodaFid *fid,
-	struct ucred *cred, struct proc *p);
+venus_fsync(void *mdp, CodaFid *fid, struct proc *p);
 
 int
 venus_lookup(void *mdp, CodaFid *fid,

==== //depot/projects/smpng/sys/coda/coda_vfsops.c#21 (text+ko) ====

@@ -41,7 +41,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/coda/coda_vfsops.c,v 1.56 2005/01/05 23:35:00 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/coda/coda_vfsops.c,v 1.57 2005/01/11 07:36:18 phk Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -419,10 +419,9 @@
  * Flush any pending I/O.
  */
 int
-coda_sync(vfsp, waitfor, cred, td)
+coda_sync(vfsp, waitfor, td)
     struct mount *vfsp;
     int    waitfor;
-    struct ucred *cred;
     struct thread *td;
 {
     ENTRY;

==== //depot/projects/smpng/sys/coda/coda_vnops.c#19 (text+ko) ====

@@ -42,7 +42,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/coda/coda_vnops.c,v 1.56 2005/01/05 23:35:00 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/coda/coda_vnops.c,v 1.58 2005/01/13 12:25:18 phk Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -267,9 +267,9 @@
     }
 /* grab (above) does this when it calls newvnode unless it's in the cache*/
     if (vp->v_type == VREG) {
-    	error = vfs_object_create(vp, td, cred);
+    	error = VOP_CREATEVOBJECT(vp, cred, td);
 	if (error != 0) {
-	    printf("coda_open: vfs_object_create() returns %d\n", error);
+	    printf("coda_open: VOP_CREATEVOBJECT() returns %d\n", error);
 	    vput(vp);
 	}
     }
@@ -432,9 +432,9 @@
 		return (error);
 	    }
 	    if (vp->v_type == VREG) {
-		error = vfs_object_create(vp, td, cred);
+		error = VOP_CREATEVOBJECT(vp, cred, td);
 		if (error != 0) {
-		    printf("coda_rdwr: vfs_object_create() returns %d\n", error);
+		    printf("coda_rdwr: VOP_CREATEVOBJECT() returns %d\n", error);
 		    vput(vp);
 		}
 	    }
@@ -763,7 +763,6 @@
 /* true args */
     struct vnode *vp = ap->a_vp;
     struct cnode *cp = VTOC(vp);
-    struct ucred *cred = ap->a_cred;
     struct thread *td = ap->a_td;
 /* locals */
     struct vnode *convp = cp->c_ovp;
@@ -787,7 +786,7 @@
     }
 
     if (convp)
-    	VOP_FSYNC(convp, cred, MNT_WAIT, td);
+    	VOP_FSYNC(convp, MNT_WAIT, td);
 
     /*
      * We see fsyncs with usecount == 1 then usecount == 0.
@@ -815,7 +814,7 @@
 
     /* needs research */
     return 0;
-    error = venus_fsync(vtomi(vp), &cp->c_fid, cred, td->td_proc);
+    error = venus_fsync(vtomi(vp), &cp->c_fid, td->td_proc);
 
     CODADEBUG(CODA_FSYNC, myprintf(("in fsync result %d\n",error)); );
     return(error);
@@ -1564,9 +1563,9 @@
 		return (error);
 	    }
 	    if (vp->v_type == VREG) {
-		error = vfs_object_create(vp, td, cred);
+		error = VOP_CREATEVOBJECT(vp, cred, td);
 		if (error != 0) {
-		    printf("coda_readdir: vfs_object_create() returns %d\n", error);
+		    printf("coda_readdir: VOP_CREATEVOBJECT() returns %d\n", error);
 		    vput(vp);
 		}
 	    }

==== //depot/projects/smpng/sys/compat/linprocfs/linprocfs.c#43 (text+ko) ====

@@ -40,7 +40,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/linprocfs/linprocfs.c,v 1.87 2005/01/05 22:34:35 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/linprocfs/linprocfs.c,v 1.88 2005/01/14 04:44:56 obrien Exp $");
 
 #include <sys/param.h>
 #include <sys/queue.h>
@@ -92,10 +92,10 @@
 #endif /* __i386__ || __amd64__ */
 
 #include "opt_compat.h"
-#if !COMPAT_LINUX32				/* XXX */
+#ifdef COMPAT_LINUX32				/* XXX */
+#include <machine/../linux32/linux.h>
+#else
 #include <machine/../linux/linux.h>
-#else
-#include <machine/../linux32/linux.h>
 #endif
 #include <compat/linux/linux_ioctl.h>
 #include <compat/linux/linux_mib.h>

==== //depot/projects/smpng/sys/compat/linux/linux_file.c#25 (text+ko) ====

@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/linux/linux_file.c,v 1.89 2004/12/03 18:14:22 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/linux/linux_file.c,v 1.90 2005/01/14 04:44:56 obrien Exp $");
 
 #include "opt_compat.h"
 #include "opt_mac.h"
@@ -56,12 +56,12 @@
 
 #include "opt_compat.h"
 
-#if !COMPAT_LINUX32
+#ifdef COMPAT_LINUX32
+#include <machine/../linux32/linux.h>
+#include <machine/../linux32/linux32_proto.h>
+#else
 #include <machine/../linux/linux.h>
 #include <machine/../linux/linux_proto.h>
-#else
-#include <machine/../linux32/linux.h>
-#include <machine/../linux32/linux32_proto.h>
 #endif
 #include <compat/linux/linux_util.h>
 
@@ -833,7 +833,7 @@
 	l_off_t		l_len;
 	l_pid_t		l_pid;
 }
-#if __amd64__ && COMPAT_LINUX32
+#if defined(__amd64__) && defined(COMPAT_LINUX32)
 __packed
 #endif
 ;
@@ -881,7 +881,7 @@
 	linux_flock->l_pid = (l_pid_t)bsd_flock->l_pid;
 }
 
-#if defined(__i386__) || (defined(__amd64__) && COMPAT_LINUX32)
+#if defined(__i386__) || (defined(__amd64__) && defined(COMPAT_LINUX32))
 struct l_flock64 {
 	l_short		l_type;
 	l_short		l_whence;
@@ -889,7 +889,7 @@
 	l_loff_t	l_len;
 	l_pid_t		l_pid;
 }
-#if __amd64__ && COMPAT_LINUX32
+#if defined(__amd64__) && defined(COMPAT_LINUX32)
 __packed
 #endif
 ;
@@ -1064,7 +1064,7 @@
 	return (fcntl_common(td, &args64));
 }
 
-#if defined(__i386__) || (defined(__amd64__) && COMPAT_LINUX32)
+#if defined(__i386__) || (defined(__amd64__) && defined(COMPAT_LINUX32))
 int
 linux_fcntl64(struct thread *td, struct linux_fcntl64_args *args)
 {

==== //depot/projects/smpng/sys/compat/linux/linux_getcwd.c#15 (text+ko) ====

@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/linux/linux_getcwd.c,v 1.15 2004/08/16 07:28:16 tjr Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/linux/linux_getcwd.c,v 1.16 2005/01/14 04:44:56 obrien Exp $");
 
 #include "opt_compat.h"
 #include "opt_mac.h"
@@ -61,12 +61,12 @@
 
 #include "opt_compat.h"
 
-#if !COMPAT_LINUX32
+#ifdef COMPAT_LINUX32
+#include <machine/../linux32/linux.h>
+#include <machine/../linux32/linux32_proto.h>
+#else
 #include <machine/../linux/linux.h>
 #include <machine/../linux/linux_proto.h>
-#else
-#include <machine/../linux32/linux.h>
-#include <machine/../linux32/linux32_proto.h>
 #endif
 #include <compat/linux/linux_util.h>
 

==== //depot/projects/smpng/sys/compat/linux/linux_ioctl.c#36 (text+ko) ====

@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/linux/linux_ioctl.c,v 1.122 2005/01/05 22:34:35 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/linux/linux_ioctl.c,v 1.123 2005/01/14 04:44:56 obrien Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -58,12 +58,12 @@
 
 #include "opt_compat.h"
 
-#if !COMPAT_LINUX32
+#ifdef COMPAT_LINUX32
+#include <machine/../linux32/linux.h>
+#include <machine/../linux32/linux32_proto.h>
+#else
 #include <machine/../linux/linux.h>
 #include <machine/../linux/linux_proto.h>
-#else
-#include <machine/../linux32/linux.h>
-#include <machine/../linux32/linux32_proto.h>
 #endif
 
 #include <compat/linux/linux_ioctl.h>
@@ -2088,7 +2088,7 @@
 static int
 linux_ifconf(struct thread *td, struct ifconf *uifc)
 {
-#if COMPAT_LINUX32
+#ifdef COMPAT_LINUX32
 	struct l_ifconf ifc;
 #else
 	struct ifconf ifc;

==== //depot/projects/smpng/sys/compat/linux/linux_ipc.c#17 (text+ko) ====

@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/linux/linux_ipc.c,v 1.39 2004/08/16 07:28:16 tjr Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/linux/linux_ipc.c,v 1.40 2005/01/14 04:44:56 obrien Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -41,14 +41,14 @@
 
 #include "opt_compat.h"
 
-#if !COMPAT_LINUX32
+#ifdef COMPAT_LINUX32
+#include <machine/../linux32/linux.h>
+#include <machine/../linux32/linux32_proto.h>
+#include <machine/../linux32/linux32_ipc64.h>
+#else
 #include <machine/../linux/linux.h>
 #include <machine/../linux/linux_proto.h>
 #include <machine/../linux/linux_ipc64.h>
-#else
-#include <machine/../linux32/linux.h>
-#include <machine/../linux32/linux32_proto.h>
-#include <machine/../linux32/linux32_ipc64.h>
 #endif
 #include <compat/linux/linux_ipc.h>
 #include <compat/linux/linux_util.h>
@@ -154,7 +154,7 @@
 	l_pid_t			msg_lspid;	/* pid of last msgsnd */
 	l_pid_t			msg_lrpid;	/* last receive pid */
 }
-#if __amd64__ && COMPAT_LINUX32
+#if defined(__amd64__) && defined(COMPAT_LINUX32)
 __packed
 #endif
 ;
@@ -169,7 +169,7 @@
 	l_uintptr_t		undo;
 	l_ushort		sem_nsems;
 }
-#if __amd64__ && COMPAT_LINUX32
+#if defined(__amd64__) && defined(COMPAT_LINUX32)

>>> TRUNCATED FOR MAIL (1000 lines) <<<


More information about the p4-projects mailing list