PERFORCE change 147578 for review
Maxim Zhuravlev
thioretic at FreeBSD.org
Sat Aug 16 18:17:22 UTC 2008
http://perforce.freebsd.org/chv.cgi?CH=147578
Change 147578 by thioretic at thioretic on 2008/08/16 18:16:53
Integrate from parent.
Affected files ...
.. //depot/projects/soc2007/thioretic_gidl/amd64/amd64/amd64_mem.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/amd64/busdma_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/amd64/machdep.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/amd64/mem.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/conf/GENERIC#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/conf/NOTES#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/ia32/ia32_signal.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/include/clock.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/include/pc/bios.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/include/specialreg.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/include/vmparam.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/isa/clock.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/amd64/linux32/linux32_sysvec.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/arm/busdma_machdep.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/arm/uio_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/conf/AVILA#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/conf/HL200#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/conf/IQ31244#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/conf/SIMICS#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/arm/conf/SKYEYE#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/forth/loader.conf#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/boot2/boot2.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/btx/btx/Makefile#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/btx/btx/btx.S#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/gptboot/gptboot.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/libi386/biosmem.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/libi386/biossmap.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/i386/loader/main.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/boot/pc98/boot2/README.serial.98#2 delete
.. //depot/projects/soc2007/thioretic_gidl/boot/pc98/loader/main.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/cam/cam_periph.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/cam/cam_xpt.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/cam/scsi/scsi_cd.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/cam/scsi/scsi_ch.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/cam/scsi/scsi_da.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/cam/scsi/scsi_sa.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/freebsd32/freebsd32_proto.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/freebsd32/freebsd32_syscall.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/freebsd32/freebsd32_syscalls.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/freebsd32/freebsd32_sysent.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/freebsd32/syscalls.master#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/linprocfs/linprocfs.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/linux/linux_file.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/compat/svr4/svr4_fcntl.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/NOTES#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/files#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/files.amd64#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/files.i386#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/files.sparc64#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/kmod.mk#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/newvers.sh#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/conf/options#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/contrib/pf/net/pf_if.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/contrib/pf/net/pf_ioctl.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/contrib/pf/net/pfvar.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/ddb/db_command.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/ddb/db_input.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aac.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aac_cam.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aac_debug.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aac_disk.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aac_pci.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aacreg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/aac/aacvar.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/acpi_support/acpi_asus.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/acpica/acpi_cpu.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/ata/ata-chipset.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/ata/ata-disk.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/ata/ata-pci.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/bfe/if_bfe.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/bfe/if_bfereg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/bge/if_bge.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/bge/if_bgereg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/ciss/ciss.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/coretemp/coretemp.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/drm/drm_pciids.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/drm/i915_dma.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/fdc/fdc.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/gem/if_gem.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/gem/if_gem_pci.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/gem/if_gemreg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/gem/if_gemvar.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/hme/if_hme.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/hme/if_hme_pci.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/hme/if_hme_sbus.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/hme/if_hmereg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/hme/if_hmevar.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/iir/iir.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/jme/if_jme.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/jme/if_jmereg.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/jme/if_jmevar.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/lge/if_lge.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mfi/mfi.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mfi/mfi_ioctl.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mfi/mfi_pci.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/brgphy.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/brgphyreg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/icsphy.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/icsphyreg.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/ip1000phy.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/ip1000phyreg.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/jmphy.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/jmphyreg.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/miidevs#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mii/rgephy.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mpt/mpt.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mpt/mpt_pci.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mpt/mpt_raid.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mpt/mpt_user.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/msk/if_msk.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/msk/if_mskreg.h#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/mxge/if_mxge.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/nvram/nvram.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/dev/pci/pci.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/re/if_re.c#6 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/sym/sym_defs.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/sym/sym_fw.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/sym/sym_fw1.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/sym/sym_fw2.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/sym/sym_hipd.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/ehci_pci.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/ubsa.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/ucom.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/uhci_pci.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/umass.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/ums.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/usb_quirks.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/usbdevs#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/usb/uscanner.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/dev/vx/if_vx.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/fs/devfs/devfs_rule.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/fs/msdosfs/msdosfs_vfsops.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/fs/msdosfs/msdosfs_vnops.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/fs/smbfs/smbfs_vnops.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/gdb/gdb_main.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/geom/vinum/geom_vinum_drive.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/geom/vinum/geom_vinum_rename.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/geom/vinum/geom_vinum_share.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/conf/GENERIC#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/conf/NOTES#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/conf/XBOX#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/cpufreq/est.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/busdma_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/i686_mem.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/identcpu.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/initcpu.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/k6_mem.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/locore.s#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/machdep.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/mp_machdep.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/i386/pmap.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/ibcs2/ibcs2_fcntl.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/include/clock.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/include/pc/bios.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/include/pmap.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/include/specialreg.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/isa/clock.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/linux/linux_sysvec.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/i386/svr4/svr4_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/ia64/conf/GENERIC#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/ia64/ia64/busdma_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/init_sysent.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_clock.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_conf.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_cpu.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_descrip.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_lockf.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_malloc.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_mib.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_resource.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_shutdown.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_switch.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/kern_timeout.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/link_elf.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/link_elf_obj.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/sched_4bsd.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/sys_process.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/syscalls.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/syscalls.master#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/sysv_sem.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/tty.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/uipc_sem.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/vfs_syscalls.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/kern/vnode_if.src#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/modules/Makefile#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/modules/bge/Makefile#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/modules/jme/Makefile#1 branch
.. //depot/projects/soc2007/thioretic_gidl/modules/krpc/Makefile#1 branch
.. //depot/projects/soc2007/thioretic_gidl/modules/mii/Makefile#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/modules/mpt/Makefile#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/modules/nfslockd/Makefile#1 branch
.. //depot/projects/soc2007/thioretic_gidl/modules/nvram/Makefile#1 branch
.. //depot/projects/soc2007/thioretic_gidl/net/bpf.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/bridge.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/bridgestp.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/bridgestp.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/ethernet.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/ieee8023ad_lacp.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/ieee8023ad_lacp.h#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if_bridge.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if_ethersubr.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if_lagg.c#7 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if_media.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/net/if_tap.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/bluetooth/socket/ng_btsocket_l2cap.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/bluetooth/socket/ng_btsocket_l2cap_raw.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/netgraph.h#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_base.c#6 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_ksocket.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_l2tp.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_nat.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_nat.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_pppoe.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_pptpgre.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_pptpgre.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netgraph/ng_socket.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/in.c#4 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/ip_dummynet.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/ip_dummynet.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/ip_fw2.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/ip_fw_pfil.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/libalias/alias_db.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/libalias/alias_irc.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netinet/tcp_hostcache.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/netipsec/ipsec.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netipsec/ipsec_input.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netipsec/ipsec_output.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netipsec/key.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netipsec/xform_ipip.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/netkey/key.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfs4client/nfs4_vnops.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfsclient/nfs_lock.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfsclient/nfs_socket.c#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfsclient/nfs_subs.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfsclient/nfs_vnops.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfsclient/nfsm_subs.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/nfsserver/nfs_srvsock.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm_prot.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm_prot_clnt.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm_prot_impl.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm_prot_server.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm_prot_svc.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/nlm_prot_xdr.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/sm_inter.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/nlm/sm_inter_xdr.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/pc98/conf/GENERIC#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/pc98/include/md_var.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/pc98/pc98/machdep.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pc98/pc98/pc98_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/agp_nvidia.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_dc.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_dcreg.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_de.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_rl.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_rlreg.h#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_sis.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_xl.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/pci/if_xlreg.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/posix4/semaphore.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/powerpc/conf/GENERIC#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/powerpc/conf/NOTES#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/rpc/auth.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/auth_none.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/auth_unix.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/authunix_prot.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/clnt.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/clnt_dg.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/clnt_rc.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/clnt_stat.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/clnt_vc.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/getnetconfig.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/inet_ntop.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/inet_pton.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/netconfig.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/nettype.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/pmap_prot.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpc.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpc_callmsg.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpc_com.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpc_generic.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpc_msg.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpc_prot.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpcb_clnt.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpcb_clnt.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpcb_prot.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/rpcb_prot.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc_auth.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc_auth.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc_auth_unix.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc_dg.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc_generic.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/svc_vc.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/types.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/rpc/xdr.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/security/audit/audit_syscalls.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/conf/GENERIC#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/include/bus_common.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/include/in_cksum.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/include/iommuvar.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/include/md_var.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/include/sysarch.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/include/tlb.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/pci/ofw_pcib_subr.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/pci/psycho.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sbus/sbus.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/ata_machdep.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/cache.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/cheetah.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/counter.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/in_cksum.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/iommu.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/mp_machdep.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/pmap.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/spitfire.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sparc64/sparc64/tlb.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/aac_ioctl.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/extattr.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/fcntl.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/hash.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/lockf.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/malloc.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/mbuf.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/mpt_ioctl.h#1 branch
.. //depot/projects/soc2007/thioretic_gidl/sys/param.h#5 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/pcpu.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/resource.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/sockio.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/syscall.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/syscall.mk#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/sysctl.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/sys/sysproto.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ffs/ffs_softdep.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ffs/ffs_vfsops.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ufs/extattr.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ufs/quota.h#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ufs/ufs_lookup.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ufs/ufs_quota.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/ufs/ufs/ufs_vnops.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/memguard.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/memguard.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/vm_kern.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/vm_mmap.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/vm_object.c#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/vm_object.h#2 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/vm_pageout.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/vm/vnode_pager.c#3 integrate
.. //depot/projects/soc2007/thioretic_gidl/xdr/xdr.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/xdr/xdr_array.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/xdr/xdr_mbuf.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/xdr/xdr_mem.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/xdr/xdr_reference.c#1 branch
.. //depot/projects/soc2007/thioretic_gidl/xdr/xdr_sizeof.c#1 branch
Differences ...
==== //depot/projects/soc2007/thioretic_gidl/amd64/amd64/amd64_mem.c#2 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/amd64_mem.c,v 1.25 2004/08/07 06:21:37 scottl Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/amd64_mem.c,v 1.25.8.3 2008/03/19 16:37:23 jhb Exp $");
#include <sys/param.h>
#include <sys/kernel.h>
@@ -47,31 +47,31 @@
static char *mem_owner_bios = "BIOS";
-#define MR686_FIXMTRR (1<<0)
+#define MR686_FIXMTRR (1<<0)
-#define mrwithin(mr, a) \
- (((a) >= (mr)->mr_base) && ((a) < ((mr)->mr_base + (mr)->mr_len)))
-#define mroverlap(mra, mrb) \
- (mrwithin(mra, mrb->mr_base) || mrwithin(mrb, mra->mr_base))
+#define mrwithin(mr, a) \
+ (((a) >= (mr)->mr_base) && ((a) < ((mr)->mr_base + (mr)->mr_len)))
+#define mroverlap(mra, mrb) \
+ (mrwithin(mra, mrb->mr_base) || mrwithin(mrb, mra->mr_base))
-#define mrvalid(base, len) \
- ((!(base & ((1 << 12) - 1))) && /* base is multiple of 4k */ \
- ((len) >= (1 << 12)) && /* length is >= 4k */ \
- powerof2((len)) && /* ... and power of two */ \
- !((base) & ((len) - 1))) /* range is not discontiuous */
+#define mrvalid(base, len) \
+ ((!(base & ((1 << 12) - 1))) && /* base is multiple of 4k */ \
+ ((len) >= (1 << 12)) && /* length is >= 4k */ \
+ powerof2((len)) && /* ... and power of two */ \
+ !((base) & ((len) - 1))) /* range is not discontiuous */
-#define mrcopyflags(curr, new) (((curr) & ~MDF_ATTRMASK) | ((new) & MDF_ATTRMASK))
+#define mrcopyflags(curr, new) \
+ (((curr) & ~MDF_ATTRMASK) | ((new) & MDF_ATTRMASK))
-static int mtrrs_disabled;
+static int mtrrs_disabled;
TUNABLE_INT("machdep.disable_mtrrs", &mtrrs_disabled);
SYSCTL_INT(_machdep, OID_AUTO, disable_mtrrs, CTLFLAG_RDTUN,
- &mtrrs_disabled, 0, "Disable amd64 MTRRs.");
+ &mtrrs_disabled, 0, "Disable amd64 MTRRs.");
-static void amd64_mrinit(struct mem_range_softc *sc);
-static int amd64_mrset(struct mem_range_softc *sc,
- struct mem_range_desc *mrd,
- int *arg);
-static void amd64_mrAPinit(struct mem_range_softc *sc);
+static void amd64_mrinit(struct mem_range_softc *sc);
+static int amd64_mrset(struct mem_range_softc *sc,
+ struct mem_range_desc *mrd, int *arg);
+static void amd64_mrAPinit(struct mem_range_softc *sc);
static struct mem_range_ops amd64_mrops = {
amd64_mrinit,
@@ -80,157 +80,159 @@
};
/* XXX for AP startup hook */
-static u_int64_t mtrrcap, mtrrdef;
+static u_int64_t mtrrcap, mtrrdef;
+
+/* The bitmask for the PhysBase and PhysMask fields of the variable MTRRs. */
+static u_int64_t mtrr_physmask;
-static struct mem_range_desc *mem_range_match(struct mem_range_softc *sc,
- struct mem_range_desc *mrd);
-static void amd64_mrfetch(struct mem_range_softc *sc);
-static int amd64_mtrrtype(int flags);
-static int amd64_mrt2mtrr(int flags, int oldval);
-static int amd64_mtrrconflict(int flag1, int flag2);
-static void amd64_mrstore(struct mem_range_softc *sc);
-static void amd64_mrstoreone(void *arg);
-static struct mem_range_desc *amd64_mtrrfixsearch(struct mem_range_softc *sc,
- u_int64_t addr);
-static int amd64_mrsetlow(struct mem_range_softc *sc,
- struct mem_range_desc *mrd,
- int *arg);
-static int amd64_mrsetvariable(struct mem_range_softc *sc,
- struct mem_range_desc *mrd,
- int *arg);
+static struct mem_range_desc *mem_range_match(struct mem_range_softc *sc,
+ struct mem_range_desc *mrd);
+static void amd64_mrfetch(struct mem_range_softc *sc);
+static int amd64_mtrrtype(int flags);
+static int amd64_mrt2mtrr(int flags, int oldval);
+static int amd64_mtrrconflict(int flag1, int flag2);
+static void amd64_mrstore(struct mem_range_softc *sc);
+static void amd64_mrstoreone(void *arg);
+static struct mem_range_desc *amd64_mtrrfixsearch(struct mem_range_softc *sc,
+ u_int64_t addr);
+static int amd64_mrsetlow(struct mem_range_softc *sc,
+ struct mem_range_desc *mrd, int *arg);
+static int amd64_mrsetvariable(struct mem_range_softc *sc,
+ struct mem_range_desc *mrd, int *arg);
/* amd64 MTRR type to memory range type conversion */
static int amd64_mtrrtomrt[] = {
- MDF_UNCACHEABLE,
- MDF_WRITECOMBINE,
- MDF_UNKNOWN,
- MDF_UNKNOWN,
- MDF_WRITETHROUGH,
- MDF_WRITEPROTECT,
- MDF_WRITEBACK
+ MDF_UNCACHEABLE,
+ MDF_WRITECOMBINE,
+ MDF_UNKNOWN,
+ MDF_UNKNOWN,
+ MDF_WRITETHROUGH,
+ MDF_WRITEPROTECT,
+ MDF_WRITEBACK
};
-#define MTRRTOMRTLEN (sizeof(amd64_mtrrtomrt) / sizeof(amd64_mtrrtomrt[0]))
-
-/*
- * Used in /dev/mem drivers and elsewhere
- */
-MALLOC_DEFINE(M_MEMDESC, "memdesc", "memory range descriptors");
+#define MTRRTOMRTLEN (sizeof(amd64_mtrrtomrt) / sizeof(amd64_mtrrtomrt[0]))
static int
amd64_mtrr2mrt(int val)
{
+
if (val < 0 || val >= MTRRTOMRTLEN)
- return MDF_UNKNOWN;
- return amd64_mtrrtomrt[val];
+ return (MDF_UNKNOWN);
+ return (amd64_mtrrtomrt[val]);
}
-/*
+/*
* amd64 MTRR conflicts. Writeback and uncachable may overlap.
*/
static int
amd64_mtrrconflict(int flag1, int flag2)
{
+
flag1 &= MDF_ATTRMASK;
flag2 &= MDF_ATTRMASK;
if ((flag1 & MDF_UNKNOWN) || (flag2 & MDF_UNKNOWN))
- return 1;
+ return (1);
if (flag1 == flag2 ||
(flag1 == MDF_WRITEBACK && flag2 == MDF_UNCACHEABLE) ||
(flag2 == MDF_WRITEBACK && flag1 == MDF_UNCACHEABLE))
- return 0;
- return 1;
+ return (0);
+ return (1);
}
/*
* Look for an exactly-matching range.
*/
static struct mem_range_desc *
-mem_range_match(struct mem_range_softc *sc, struct mem_range_desc *mrd)
+mem_range_match(struct mem_range_softc *sc, struct mem_range_desc *mrd)
{
- struct mem_range_desc *cand;
- int i;
-
- for (i = 0, cand = sc->mr_desc; i < sc->mr_ndesc; i++, cand++)
- if ((cand->mr_base == mrd->mr_base) &&
- (cand->mr_len == mrd->mr_len))
- return(cand);
- return(NULL);
+ struct mem_range_desc *cand;
+ int i;
+
+ for (i = 0, cand = sc->mr_desc; i < sc->mr_ndesc; i++, cand++)
+ if ((cand->mr_base == mrd->mr_base) &&
+ (cand->mr_len == mrd->mr_len))
+ return (cand);
+ return (NULL);
}
/*
- * Fetch the current mtrr settings from the current CPU (assumed to all
- * be in sync in the SMP case). Note that if we are here, we assume
- * that MTRRs are enabled, and we may or may not have fixed MTRRs.
+ * Fetch the current mtrr settings from the current CPU (assumed to
+ * all be in sync in the SMP case). Note that if we are here, we
+ * assume that MTRRs are enabled, and we may or may not have fixed
+ * MTRRs.
*/
static void
amd64_mrfetch(struct mem_range_softc *sc)
{
- struct mem_range_desc *mrd;
- u_int64_t msrv;
- int i, j, msr;
+ struct mem_range_desc *mrd;
+ u_int64_t msrv;
+ int i, j, msr;
- mrd = sc->mr_desc;
+ mrd = sc->mr_desc;
- /* Get fixed-range MTRRs */
- if (sc->mr_cap & MR686_FIXMTRR) {
- msr = MSR_MTRR64kBase;
- for (i = 0; i < (MTRR_N64K / 8); i++, msr++) {
- msrv = rdmsr(msr);
- for (j = 0; j < 8; j++, mrd++) {
- mrd->mr_flags = (mrd->mr_flags & ~MDF_ATTRMASK) |
- amd64_mtrr2mrt(msrv & 0xff) |
- MDF_ACTIVE;
- if (mrd->mr_owner[0] == 0)
- strcpy(mrd->mr_owner, mem_owner_bios);
- msrv = msrv >> 8;
- }
+ /* Get fixed-range MTRRs. */
+ if (sc->mr_cap & MR686_FIXMTRR) {
+ msr = MSR_MTRR64kBase;
+ for (i = 0; i < (MTRR_N64K / 8); i++, msr++) {
+ msrv = rdmsr(msr);
+ for (j = 0; j < 8; j++, mrd++) {
+ mrd->mr_flags =
+ (mrd->mr_flags & ~MDF_ATTRMASK) |
+ amd64_mtrr2mrt(msrv & 0xff) | MDF_ACTIVE;
+ if (mrd->mr_owner[0] == 0)
+ strcpy(mrd->mr_owner, mem_owner_bios);
+ msrv = msrv >> 8;
+ }
+ }
+ msr = MSR_MTRR16kBase;
+ for (i = 0; i < (MTRR_N16K / 8); i++, msr++) {
+ msrv = rdmsr(msr);
+ for (j = 0; j < 8; j++, mrd++) {
+ mrd->mr_flags =
+ (mrd->mr_flags & ~MDF_ATTRMASK) |
+ amd64_mtrr2mrt(msrv & 0xff) | MDF_ACTIVE;
+ if (mrd->mr_owner[0] == 0)
+ strcpy(mrd->mr_owner, mem_owner_bios);
+ msrv = msrv >> 8;
+ }
+ }
+ msr = MSR_MTRR4kBase;
+ for (i = 0; i < (MTRR_N4K / 8); i++, msr++) {
+ msrv = rdmsr(msr);
+ for (j = 0; j < 8; j++, mrd++) {
+ mrd->mr_flags =
+ (mrd->mr_flags & ~MDF_ATTRMASK) |
+ amd64_mtrr2mrt(msrv & 0xff) | MDF_ACTIVE;
+ if (mrd->mr_owner[0] == 0)
+ strcpy(mrd->mr_owner, mem_owner_bios);
+ msrv = msrv >> 8;
+ }
+ }
}
- msr = MSR_MTRR16kBase;
- for (i = 0; i < (MTRR_N16K / 8); i++, msr++) {
- msrv = rdmsr(msr);
- for (j = 0; j < 8; j++, mrd++) {
+
+ /* Get remainder which must be variable MTRRs. */
+ msr = MSR_MTRRVarBase;
+ for (; (mrd - sc->mr_desc) < sc->mr_ndesc; msr += 2, mrd++) {
+ msrv = rdmsr(msr);
mrd->mr_flags = (mrd->mr_flags & ~MDF_ATTRMASK) |
- amd64_mtrr2mrt(msrv & 0xff) |
- MDF_ACTIVE;
- if (mrd->mr_owner[0] == 0)
- strcpy(mrd->mr_owner, mem_owner_bios);
- msrv = msrv >> 8;
- }
+ amd64_mtrr2mrt(msrv & MTRR_PHYSBASE_TYPE);
+ mrd->mr_base = msrv & mtrr_physmask;
+ msrv = rdmsr(msr + 1);
+ mrd->mr_flags = (msrv & MTRR_PHYSMASK_VALID) ?
+ (mrd->mr_flags | MDF_ACTIVE) :
+ (mrd->mr_flags & ~MDF_ACTIVE);
+
+ /* Compute the range from the mask. Ick. */
+ mrd->mr_len = (~(msrv & mtrr_physmask) &
+ (mtrr_physmask | 0xfffL)) + 1;
+ if (!mrvalid(mrd->mr_base, mrd->mr_len))
+ mrd->mr_flags |= MDF_BOGUS;
+
+ /* If unclaimed and active, must be the BIOS. */
+ if ((mrd->mr_flags & MDF_ACTIVE) && (mrd->mr_owner[0] == 0))
+ strcpy(mrd->mr_owner, mem_owner_bios);
}
- msr = MSR_MTRR4kBase;
- for (i = 0; i < (MTRR_N4K / 8); i++, msr++) {
- msrv = rdmsr(msr);
- for (j = 0; j < 8; j++, mrd++) {
- mrd->mr_flags = (mrd->mr_flags & ~MDF_ATTRMASK) |
- amd64_mtrr2mrt(msrv & 0xff) |
- MDF_ACTIVE;
- if (mrd->mr_owner[0] == 0)
- strcpy(mrd->mr_owner, mem_owner_bios);
- msrv = msrv >> 8;
- }
- }
- }
-
- /* Get remainder which must be variable MTRRs */
- msr = MSR_MTRRVarBase;
- for (; (mrd - sc->mr_desc) < sc->mr_ndesc; msr += 2, mrd++) {
- msrv = rdmsr(msr);
- mrd->mr_flags = (mrd->mr_flags & ~MDF_ATTRMASK) |
- amd64_mtrr2mrt(msrv & 0xff);
- mrd->mr_base = msrv & 0x000000fffffff000L;
- msrv = rdmsr(msr + 1);
- mrd->mr_flags = (msrv & 0x800) ?
- (mrd->mr_flags | MDF_ACTIVE) :
- (mrd->mr_flags & ~MDF_ACTIVE);
- /* Compute the range from the mask. Ick. */
- mrd->mr_len = (~(msrv & 0x000000fffffff000L) & 0x000000ffffffffffL) + 1;
- if (!mrvalid(mrd->mr_base, mrd->mr_len))
- mrd->mr_flags |= MDF_BOGUS;
- /* If unclaimed and active, must be the BIOS */
- if ((mrd->mr_flags & MDF_ACTIVE) && (mrd->mr_owner[0] == 0))
- strcpy(mrd->mr_owner, mem_owner_bios);
- }
}
/*
@@ -239,17 +241,17 @@
static int
amd64_mtrrtype(int flags)
{
- int i;
+ int i;
- flags &= MDF_ATTRMASK;
+ flags &= MDF_ATTRMASK;
- for (i = 0; i < MTRRTOMRTLEN; i++) {
- if (amd64_mtrrtomrt[i] == MDF_UNKNOWN)
- continue;
- if (flags == amd64_mtrrtomrt[i])
- return(i);
- }
- return(-1);
+ for (i = 0; i < MTRRTOMRTLEN; i++) {
+ if (amd64_mtrrtomrt[i] == MDF_UNKNOWN)
+ continue;
+ if (flags == amd64_mtrrtomrt[i])
+ return (i);
+ }
+ return (-1);
}
static int
@@ -258,8 +260,8 @@
int val;
if ((val = amd64_mtrrtype(flags)) == -1)
- return oldval & 0xff;
- return val & 0xff;
+ return (oldval & 0xff);
+ return (val & 0xff);
}
/*
@@ -272,105 +274,124 @@
amd64_mrstore(struct mem_range_softc *sc)
{
#ifdef SMP
- /*
- * We should use ipi_all_but_self() to call other CPUs into a
- * locking gate, then call a target function to do this work.
- * The "proper" solution involves a generalised locking gate
- * implementation, not ready yet.
- */
- smp_rendezvous(NULL, amd64_mrstoreone, NULL, (void *)sc);
+ /*
+ * We should use ipi_all_but_self() to call other CPUs into a
+ * locking gate, then call a target function to do this work.
+ * The "proper" solution involves a generalised locking gate
+ * implementation, not ready yet.
+ */
+ smp_rendezvous(NULL, amd64_mrstoreone, NULL, sc);
#else
- disable_intr(); /* disable interrupts */
- amd64_mrstoreone((void *)sc);
- enable_intr();
+ disable_intr(); /* disable interrupts */
+ amd64_mrstoreone(sc);
+ enable_intr();
#endif
}
/*
* Update the current CPU's MTRRs with those represented in the
- * descriptor list. Note that we do this wholesale rather than
- * just stuffing one entry; this is simpler (but slower, of course).
+ * descriptor list. Note that we do this wholesale rather than just
+ * stuffing one entry; this is simpler (but slower, of course).
*/
static void
amd64_mrstoreone(void *arg)
{
- struct mem_range_softc *sc = (struct mem_range_softc *)arg;
- struct mem_range_desc *mrd;
- u_int64_t omsrv, msrv;
- int i, j, msr;
- u_int cr4save;
+ struct mem_range_softc *sc = arg;
+ struct mem_range_desc *mrd;
+ u_int64_t omsrv, msrv;
+ int i, j, msr;
+ u_int cr4save;
+
+ mrd = sc->mr_desc;
+
+ /* Disable PGE. */
+ cr4save = rcr4();
+ if (cr4save & CR4_PGE)
+ load_cr4(cr4save & ~CR4_PGE);
+
+ /* Disable caches (CD = 1, NW = 0). */
+ load_cr0((rcr0() & ~CR0_NW) | CR0_CD);
- mrd = sc->mr_desc;
+ /* Flushes caches and TLBs. */
+ wbinvd();
- cr4save = rcr4(); /* save cr4 */
- if (cr4save & CR4_PGE)
- load_cr4(cr4save & ~CR4_PGE);
- load_cr0((rcr0() & ~CR0_NW) | CR0_CD); /* disable caches (CD = 1, NW = 0) */
- wbinvd(); /* flush caches, TLBs */
- wrmsr(MSR_MTRRdefType, rdmsr(MSR_MTRRdefType) & ~0x800); /* disable MTRRs (E = 0) */
+ /* Disable MTRRs (E = 0). */
+ wrmsr(MSR_MTRRdefType, rdmsr(MSR_MTRRdefType) & ~MTRR_DEF_ENABLE);
- /* Set fixed-range MTRRs */
- if (sc->mr_cap & MR686_FIXMTRR) {
- msr = MSR_MTRR64kBase;
- for (i = 0; i < (MTRR_N64K / 8); i++, msr++) {
- msrv = 0;
- omsrv = rdmsr(msr);
- for (j = 7; j >= 0; j--) {
- msrv = msrv << 8;
- msrv |= amd64_mrt2mtrr((mrd + j)->mr_flags, omsrv >> (j*8));
- }
- wrmsr(msr, msrv);
- mrd += 8;
+ /* Set fixed-range MTRRs. */
+ if (sc->mr_cap & MR686_FIXMTRR) {
+ msr = MSR_MTRR64kBase;
+ for (i = 0; i < (MTRR_N64K / 8); i++, msr++) {
+ msrv = 0;
+ omsrv = rdmsr(msr);
+ for (j = 7; j >= 0; j--) {
+ msrv = msrv << 8;
+ msrv |= amd64_mrt2mtrr((mrd + j)->mr_flags,
+ omsrv >> (j * 8));
+ }
+ wrmsr(msr, msrv);
+ mrd += 8;
+ }
+ msr = MSR_MTRR16kBase;
+ for (i = 0; i < (MTRR_N16K / 8); i++, msr++) {
+ msrv = 0;
+ omsrv = rdmsr(msr);
+ for (j = 7; j >= 0; j--) {
+ msrv = msrv << 8;
+ msrv |= amd64_mrt2mtrr((mrd + j)->mr_flags,
+ omsrv >> (j * 8));
+ }
+ wrmsr(msr, msrv);
+ mrd += 8;
+ }
+ msr = MSR_MTRR4kBase;
+ for (i = 0; i < (MTRR_N4K / 8); i++, msr++) {
+ msrv = 0;
+ omsrv = rdmsr(msr);
+ for (j = 7; j >= 0; j--) {
+ msrv = msrv << 8;
+ msrv |= amd64_mrt2mtrr((mrd + j)->mr_flags,
+ omsrv >> (j * 8));
+ }
+ wrmsr(msr, msrv);
+ mrd += 8;
+ }
}
- msr = MSR_MTRR16kBase;
- for (i = 0; i < (MTRR_N16K / 8); i++, msr++) {
- msrv = 0;
- omsrv = rdmsr(msr);
- for (j = 7; j >= 0; j--) {
- msrv = msrv << 8;
- msrv |= amd64_mrt2mtrr((mrd + j)->mr_flags, omsrv >> (j*8));
- }
- wrmsr(msr, msrv);
- mrd += 8;
+
+ /* Set remainder which must be variable MTRRs. */
+ msr = MSR_MTRRVarBase;
+ for (; (mrd - sc->mr_desc) < sc->mr_ndesc; msr += 2, mrd++) {
+ /* base/type register */
+ omsrv = rdmsr(msr);
+ if (mrd->mr_flags & MDF_ACTIVE) {
+ msrv = mrd->mr_base & mtrr_physmask;
+ msrv |= amd64_mrt2mtrr(mrd->mr_flags, omsrv);
+ } else {
+ msrv = 0;
+ }
+ wrmsr(msr, msrv);
+
+ /* mask/active register */
+ if (mrd->mr_flags & MDF_ACTIVE) {
+ msrv = MTRR_PHYSMASK_VALID |
+ (~(mrd->mr_len - 1) & mtrr_physmask);
+ } else {
+ msrv = 0;
+ }
+ wrmsr(msr + 1, msrv);
}
- msr = MSR_MTRR4kBase;
- for (i = 0; i < (MTRR_N4K / 8); i++, msr++) {
- msrv = 0;
- omsrv = rdmsr(msr);
- for (j = 7; j >= 0; j--) {
- msrv = msrv << 8;
- msrv |= amd64_mrt2mtrr((mrd + j)->mr_flags, omsrv >> (j*8));
- }
- wrmsr(msr, msrv);
- mrd += 8;
- }
- }
+
+ /* Flush caches, TLBs. */
+ wbinvd();
+
+ /* Enable MTRRs. */
+ wrmsr(MSR_MTRRdefType, rdmsr(MSR_MTRRdefType) | MTRR_DEF_ENABLE);
+
+ /* Enable caches (CD = 0, NW = 0). */
+ load_cr0(rcr0() & ~(CR0_CD | CR0_NW));
- /* Set remainder which must be variable MTRRs */
- msr = MSR_MTRRVarBase;
- for (; (mrd - sc->mr_desc) < sc->mr_ndesc; msr += 2, mrd++) {
- /* base/type register */
- omsrv = rdmsr(msr);
- if (mrd->mr_flags & MDF_ACTIVE) {
- msrv = mrd->mr_base & 0x000000fffffff000L;
- msrv |= amd64_mrt2mtrr(mrd->mr_flags, omsrv);
- } else {
- msrv = 0;
- }
- wrmsr(msr, msrv);
-
- /* mask/active register */
- if (mrd->mr_flags & MDF_ACTIVE) {
- msrv = 0x800 | (~(mrd->mr_len - 1) & 0x000000fffffff000L);
- } else {
- msrv = 0;
- }
- wrmsr(msr + 1, msrv);
- }
- wbinvd(); /* flush caches, TLBs */
- wrmsr(MSR_MTRRdefType, rdmsr(MSR_MTRRdefType) | 0x800); /* restore MTRR state */
- load_cr0(rcr0() & ~(CR0_CD | CR0_NW)); /* enable caches CD = 0 and NW = 0 */
- load_cr4(cr4save); /* restore cr4 */
+ /* Restore PGE. */
+ load_cr4(cr4save);
}
/*
@@ -379,227 +400,260 @@
static struct mem_range_desc *
amd64_mtrrfixsearch(struct mem_range_softc *sc, u_int64_t addr)
{
- struct mem_range_desc *mrd;
- int i;
-
- for (i = 0, mrd = sc->mr_desc; i < (MTRR_N64K + MTRR_N16K + MTRR_N4K); i++, mrd++)
- if ((addr >= mrd->mr_base) && (addr < (mrd->mr_base + mrd->mr_len)))
- return(mrd);
- return(NULL);
+ struct mem_range_desc *mrd;
+ int i;
+
+ for (i = 0, mrd = sc->mr_desc; i < (MTRR_N64K + MTRR_N16K + MTRR_N4K);
+ i++, mrd++)
+ if ((addr >= mrd->mr_base) &&
+ (addr < (mrd->mr_base + mrd->mr_len)))
+ return (mrd);
+ return (NULL);
}
/*
- * Try to satisfy the given range request by manipulating the fixed MTRRs that
- * cover low memory.
+ * Try to satisfy the given range request by manipulating the fixed
+ * MTRRs that cover low memory.
*
- * Note that we try to be generous here; we'll bloat the range out to the
- * next higher/lower boundary to avoid the consumer having to know too much
- * about the mechanisms here.
+ * Note that we try to be generous here; we'll bloat the range out to
+ * the next higher/lower boundary to avoid the consumer having to know
+ * too much about the mechanisms here.
*
- * XXX note that this will have to be updated when we start supporting "busy" ranges.
+ * XXX note that this will have to be updated when we start supporting
+ * "busy" ranges.
*/
static int
amd64_mrsetlow(struct mem_range_softc *sc, struct mem_range_desc *mrd, int *arg)
{
- struct mem_range_desc *first_md, *last_md, *curr_md;
+ struct mem_range_desc *first_md, *last_md, *curr_md;
+
+ /* Range check. */
+ if (((first_md = amd64_mtrrfixsearch(sc, mrd->mr_base)) == NULL) ||
+ ((last_md = amd64_mtrrfixsearch(sc, mrd->mr_base + mrd->mr_len - 1)) == NULL))
+ return (EINVAL);
- /* range check */
- if (((first_md = amd64_mtrrfixsearch(sc, mrd->mr_base)) == NULL) ||
- ((last_md = amd64_mtrrfixsearch(sc, mrd->mr_base + mrd->mr_len - 1)) == NULL))
- return(EINVAL);
+ /* Check that we aren't doing something risky. */
+ if (!(mrd->mr_flags & MDF_FORCE))
+ for (curr_md = first_md; curr_md <= last_md; curr_md++) {
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list