svn commit: r271451 - in head/sys/amd64: include vmm vmm/intel
Author: neel Date: Fri Sep 12 06:15:20 2014 New Revision: 271451 URL: http://svnweb.freebsd.org/changeset/base/271451 Log: Optimize the common case of injecting an interrupt into a vcpu after a HLT by explicitly moving it out of the interrupt shadow. The hypervisor is done executing the HLT and by definition this moves the vcpu out of the 1-instruction interrupt shadow. Prior to this change the interrupt would be held pending because the VMCS guest-interruptibility-state would indicate that blocking by STI was in effect. This resulted in an unnecessary round trip into the guest before the pending interrupt could be injected. Reviewed by: grehan Modified: head/sys/amd64/include/vmm.h head/sys/amd64/vmm/intel/vmx.c head/sys/amd64/vmm/vmm.c Modified: head/sys/amd64/include/vmm.h == --- head/sys/amd64/include/vmm.hFri Sep 12 05:25:56 2014 (r271450) +++ head/sys/amd64/include/vmm.hFri Sep 12 06:15:20 2014 (r271451) @@ -82,6 +82,7 @@ enum vm_reg_name { VM_REG_GUEST_PDPTE1, VM_REG_GUEST_PDPTE2, VM_REG_GUEST_PDPTE3, + VM_REG_GUEST_INTR_SHADOW, VM_REG_LAST }; Modified: head/sys/amd64/vmm/intel/vmx.c == --- head/sys/amd64/vmm/intel/vmx.c Fri Sep 12 05:25:56 2014 (r271450) +++ head/sys/amd64/vmm/intel/vmx.c Fri Sep 12 06:15:20 2014 (r271451) @@ -2712,6 +2712,46 @@ vmxctx_setreg(struct vmxctx *vmxctx, int } static int +vmx_get_intr_shadow(struct vmx *vmx, int vcpu, int running, uint64_t *retval) +{ + uint64_t gi; + int error; + + error = vmcs_getreg(vmx-vmcs[vcpu], running, + VMCS_IDENT(VMCS_GUEST_INTERRUPTIBILITY), gi); + *retval = (gi HWINTR_BLOCKING) ? 1 : 0; + return (error); +} + +static int +vmx_modify_intr_shadow(struct vmx *vmx, int vcpu, int running, uint64_t val) +{ + struct vmcs *vmcs; + uint64_t gi; + int error, ident; + + /* +* Forcing the vcpu into an interrupt shadow is not supported. +*/ + if (val) { + error = EINVAL; + goto done; + } + + vmcs = vmx-vmcs[vcpu]; + ident = VMCS_IDENT(VMCS_GUEST_INTERRUPTIBILITY); + error = vmcs_getreg(vmcs, running, ident, gi); + if (error == 0) { + gi = ~HWINTR_BLOCKING; + error = vmcs_setreg(vmcs, running, ident, gi); + } +done: + VCPU_CTR2(vmx-vm, vcpu, Setting intr_shadow to %#lx %s, val, + error ? failed : succeeded); + return (error); +} + +static int vmx_shadow_reg(int reg) { int shreg; @@ -2742,6 +2782,9 @@ vmx_getreg(void *arg, int vcpu, int reg, if (running hostcpu != curcpu) panic(vmx_getreg: %s%d is running, vm_name(vmx-vm), vcpu); + if (reg == VM_REG_GUEST_INTR_SHADOW) + return (vmx_get_intr_shadow(vmx, vcpu, running, retval)); + if (vmxctx_getreg(vmx-ctx[vcpu], reg, retval) == 0) return (0); @@ -2760,6 +2803,9 @@ vmx_setreg(void *arg, int vcpu, int reg, if (running hostcpu != curcpu) panic(vmx_setreg: %s%d is running, vm_name(vmx-vm), vcpu); + if (reg == VM_REG_GUEST_INTR_SHADOW) + return (vmx_modify_intr_shadow(vmx, vcpu, running, val)); + if (vmxctx_setreg(vmx-ctx[vcpu], reg, val) == 0) return (0); Modified: head/sys/amd64/vmm/vmm.c == --- head/sys/amd64/vmm/vmm.cFri Sep 12 05:25:56 2014(r271450) +++ head/sys/amd64/vmm/vmm.cFri Sep 12 06:15:20 2014(r271451) @@ -1090,7 +1090,7 @@ vm_handle_hlt(struct vm *vm, int vcpuid, { struct vcpu *vcpu; const char *wmesg; - int t, vcpu_halted, vm_halted; + int error, t, vcpu_halted, vm_halted; KASSERT(!CPU_ISSET(vcpuid, vm-halted_cpus), (vcpu already halted)); @@ -1098,6 +1098,22 @@ vm_handle_hlt(struct vm *vm, int vcpuid, vcpu_halted = 0; vm_halted = 0; + /* +* The typical way to halt a cpu is to execute: sti; hlt +* +* STI sets RFLAGS.IF to enable interrupts. However, the processor +* remains in an interrupt shadow for an additional instruction +* following the STI. This guarantees that sti; hlt sequence is +* atomic and a pending interrupt will be recognized after the HLT. +* +* After the HLT emulation is done the vcpu is no longer in an +* interrupt shadow and a pending interrupt can be injected on +* the next entry into the guest. +*/ + error = vm_set_register(vm, vcpuid, VM_REG_GUEST_INTR_SHADOW, 0); + KASSERT(error == 0, (%s: error %d clearing interrupt shadow, + __func__, error)); +
svn commit: r271452 - head/share/vt/keymaps
Author: se Date: Fri Sep 12 06:23:57 2014 New Revision: 271452 URL: http://svnweb.freebsd.org/changeset/base/271452 Log: Add forgotten keymap files fr.kbd and fr.acc.kbd to the FILES list. Obtained from:thierry MFC after:3 days Modified: head/share/vt/keymaps/Makefile Modified: head/share/vt/keymaps/Makefile == --- head/share/vt/keymaps/Makefile Fri Sep 12 06:15:20 2014 (r271451) +++ head/share/vt/keymaps/Makefile Fri Sep 12 06:23:57 2014 (r271452) @@ -31,8 +31,10 @@ FILES= INDEX.keymaps \ es.dvorak.kbd \ es.kbd \ fi.kbd \ + fr.acc.kbd \ fr.dvorak.acc.kbd \ fr.dvorak.kbd \ + fr.kbd \ fr.macbook.kbd \ gr.101.acc.kbd \ gr.elot.acc.kbd \ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271455 - head/share/man/man9
Author: glebius Date: Fri Sep 12 08:33:53 2014 New Revision: 271455 URL: http://svnweb.freebsd.org/changeset/base/271455 Log: - Fix argument list after 271387. - While here fix typo. Submitted by: markj Modified: head/share/man/man9/VOP_GETPAGES.9 Modified: head/share/man/man9/VOP_GETPAGES.9 == --- head/share/man/man9/VOP_GETPAGES.9 Fri Sep 12 08:22:29 2014 (r271454) +++ head/share/man/man9/VOP_GETPAGES.9 Fri Sep 12 08:33:53 2014 (r271455) @@ -29,7 +29,7 @@ .\ .\ $FreeBSD$ .\ -.Dd September 27, 2003 +.Dd September 12, 2014 .Dt VOP_GETPAGES 9 .Os .Sh NAME @@ -41,9 +41,9 @@ .In sys/vnode.h .In vm/vm.h .Ft int -.Fn VOP_GETPAGES struct vnode *vp vm_page_t *ma int count int reqpage vm_ooffset_t offset +.Fn VOP_GETPAGES struct vnode *vp vm_page_t *ma int count int reqpage .Ft int -.Fn VOP_PUTPAGES struct vnode *vp vm_page_t *ma int count int sync int *rtvals vm_ooffset_t offset +.Fn VOP_PUTPAGES struct vnode *vp vm_page_t *ma int count int sync int *rtvals .Sh DESCRIPTION The .Fn VOP_GETPAGES @@ -81,8 +81,6 @@ page written by .It Fa reqpage The index in the page array of the requested page; i.e., the one page which the implementation of this method must handle. -.It Fa offset -Offset in the file at which the mapped pages begin. .El .Pp The status of the @@ -156,7 +154,7 @@ is .Sh SEE ALSO .Xr vm_object_pip_wakeup 9 , .Xr vm_page_free 9 , -.Xr vm_pagge_sunbusy 9 , +.Xr vm_page_sunbusy 9 , .Xr vm_page_undirty 9 , .Xr vm_page_xunbusy 9 , .Xr vnode 9 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271457 - head/sys/dev/ahci
Author: mav Date: Fri Sep 12 08:37:21 2014 New Revision: 271457 URL: http://svnweb.freebsd.org/changeset/base/271457 Log: Initialize variables before resource_int_value(). Submitted by: Dmitry Luhtionov dmitryluhtio...@gmail.com Modified: head/sys/dev/ahci/ahci.c Modified: head/sys/dev/ahci/ahci.c == --- head/sys/dev/ahci/ahci.cFri Sep 12 08:35:12 2014(r271456) +++ head/sys/dev/ahci/ahci.cFri Sep 12 08:37:21 2014(r271457) @@ -159,6 +159,7 @@ ahci_attach(device_t dev) device_t child; ctlr-dev = dev; + ctlr-ccc = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), ccc, ctlr-ccc); @@ -624,6 +625,7 @@ ahci_ch_attach(device_t dev) ch-subdeviceid = ctlr-subdeviceid; ch-numslots = ((ch-caps AHCI_CAP_NCS) AHCI_CAP_NCS_SHIFT) + 1; mtx_init(ch-mtx, AHCI channel lock, NULL, MTX_DEF); + ch-pm_level = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), pm_level, ch-pm_level); STAILQ_INIT(ch-doneq); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271458 - head/sys/netpfil/pf
Author: glebius Date: Fri Sep 12 08:39:15 2014 New Revision: 271458 URL: http://svnweb.freebsd.org/changeset/base/271458 Log: - Provide a sleepable lock to protect against ioctl() vs ioctl() races. - Use the new lock to protect against simultaneous DIOCSTART and/or DIOCSTOP ioctls. Reported tested by: jmallett Sponsored by: Nginx, Inc. Modified: head/sys/netpfil/pf/pf_ioctl.c Modified: head/sys/netpfil/pf/pf_ioctl.c == --- head/sys/netpfil/pf/pf_ioctl.c Fri Sep 12 08:37:21 2014 (r271457) +++ head/sys/netpfil/pf/pf_ioctl.c Fri Sep 12 08:39:15 2014 (r271458) @@ -191,6 +191,7 @@ static volatile VNET_DEFINE(int, pf_pfil VNET_DEFINE(int, pf_end_threads); struct rwlock pf_rules_lock; +struct sx pf_ioctl_lock; /* pfsync */ pfsync_state_import_t *pfsync_state_import_ptr = NULL; @@ -1095,20 +1096,18 @@ pfioctl(struct cdev *dev, u_long cmd, ca switch (cmd) { case DIOCSTART: - PF_RULES_WLOCK(); + sx_xlock(pf_ioctl_lock); if (V_pf_status.running) error = EEXIST; else { int cpu; - PF_RULES_WUNLOCK(); error = hook_pf(); if (error) { DPFPRINTF(PF_DEBUG_MISC, (pf: pfil registration failed\n)); break; } - PF_RULES_WLOCK(); V_pf_status.running = 1; V_pf_status.since = time_second; @@ -1117,27 +1116,23 @@ pfioctl(struct cdev *dev, u_long cmd, ca DPFPRINTF(PF_DEBUG_MISC, (pf: started\n)); } - PF_RULES_WUNLOCK(); break; case DIOCSTOP: - PF_RULES_WLOCK(); + sx_xlock(pf_ioctl_lock); if (!V_pf_status.running) error = ENOENT; else { V_pf_status.running = 0; - PF_RULES_WUNLOCK(); error = dehook_pf(); if (error) { V_pf_status.running = 1; DPFPRINTF(PF_DEBUG_MISC, (pf: pfil unregistration failed\n)); } - PF_RULES_WLOCK(); V_pf_status.since = time_second; DPFPRINTF(PF_DEBUG_MISC, (pf: stopped\n)); } - PF_RULES_WUNLOCK(); break; case DIOCADDRULE: { @@ -3261,6 +3256,8 @@ DIOCCHANGEADDR_error: break; } fail: + if (sx_xlocked(pf_ioctl_lock)) + sx_xunlock(pf_ioctl_lock); CURVNET_RESTORE(); return (error); @@ -3734,6 +3731,7 @@ pf_load(void) VNET_LIST_RUNLOCK(); rw_init(pf_rules_lock, pf rulesets); + sx_init(pf_ioctl_lock, pf ioctl); pf_dev = make_dev(pf_cdevsw, 0, 0, 0, 0600, PF_NAME); if ((error = pfattach()) != 0) @@ -3747,9 +3745,7 @@ pf_unload(void) { int error = 0; - PF_RULES_WLOCK(); V_pf_status.running = 0; - PF_RULES_WUNLOCK(); swi_remove(V_pf_swi_cookie); error = dehook_pf(); if (error) { @@ -3778,6 +3774,7 @@ pf_unload(void) PF_RULES_WUNLOCK(); destroy_dev(pf_dev); rw_destroy(pf_rules_lock); + sx_destroy(pf_ioctl_lock); return (error); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271459 - head/tools/regression/acltools
Author: trasz Date: Fri Sep 12 09:50:32 2014 New Revision: 271459 URL: http://svnweb.freebsd.org/changeset/base/271459 Log: Fix ACL tests to correctly work with ZFS; previous version used wrong paths. PR: 191545 MFC after:1 week Sponsored by: The FreeBSD Foundation Modified: head/tools/regression/acltools/01.t head/tools/regression/acltools/03.t head/tools/regression/acltools/04.t Modified: head/tools/regression/acltools/01.t == --- head/tools/regression/acltools/01.t Fri Sep 12 08:39:15 2014 (r271458) +++ head/tools/regression/acltools/01.t Fri Sep 12 09:50:32 2014 (r271459) @@ -51,7 +51,7 @@ TESTDIR=$(dirname $(realpath $0)) # Set up the test filesystem. MD=`mdconfig -at swap -s 64m` MNT=`mktemp -dt acltools` -zpool create -R $MNT acltools /dev/$MD +zpool create -m $MNT acltools /dev/$MD if [ $? -ne 0 ]; then echo not ok 1 - 'zpool create' failed. exit 1 Modified: head/tools/regression/acltools/03.t == --- head/tools/regression/acltools/03.t Fri Sep 12 08:39:15 2014 (r271458) +++ head/tools/regression/acltools/03.t Fri Sep 12 09:50:32 2014 (r271459) @@ -48,7 +48,7 @@ MNTROOT=`mktemp -dt acltools` MD1=`mdconfig -at swap -s 64m` MNT1=$MNTROOT/nfs4 mkdir $MNT1 -zpool create -R $MNT1 acltools /dev/$MD1 +zpool create -m $MNT1 acltools /dev/$MD1 if [ $? -ne 0 ]; then echo not ok 1 - 'zpool create' failed. exit 1 Modified: head/tools/regression/acltools/04.t == --- head/tools/regression/acltools/04.t Fri Sep 12 08:39:15 2014 (r271458) +++ head/tools/regression/acltools/04.t Fri Sep 12 09:50:32 2014 (r271459) @@ -43,7 +43,7 @@ TESTDIR=$(dirname $(realpath $0)) # Set up the test filesystem. MD=`mdconfig -at swap -s 64m` MNT=`mktemp -dt acltools` -zpool create -R $MNT acltools /dev/$MD +zpool create -m $MNT acltools /dev/$MD if [ $? -ne 0 ]; then echo not ok 1 - 'zpool create' failed. exit 1 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271461 - in head/sys/dev: mvs siis
Author: mav Date: Fri Sep 12 12:04:51 2014 New Revision: 271461 URL: http://svnweb.freebsd.org/changeset/base/271461 Log: Initialize variables before resource_int_value(). Submitted by: Dmitry Luhtionov dmitryluhtio...@gmail.com Modified: head/sys/dev/mvs/mvs.c head/sys/dev/mvs/mvs_pci.c head/sys/dev/mvs/mvs_soc.c head/sys/dev/siis/siis.c Modified: head/sys/dev/mvs/mvs.c == --- head/sys/dev/mvs/mvs.c Fri Sep 12 10:08:11 2014(r271460) +++ head/sys/dev/mvs/mvs.c Fri Sep 12 12:04:51 2014(r271461) @@ -122,6 +122,7 @@ mvs_ch_attach(device_t dev) ch-unit = (intptr_t)device_get_ivars(dev); ch-quirks = ctlr-quirks; mtx_init(ch-mtx, MVS channel lock, NULL, MTX_DEF); + ch-pm_level = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), pm_level, ch-pm_level); if (ch-pm_level 3) Modified: head/sys/dev/mvs/mvs_pci.c == --- head/sys/dev/mvs/mvs_pci.c Fri Sep 12 10:08:11 2014(r271460) +++ head/sys/dev/mvs/mvs_pci.c Fri Sep 12 12:04:51 2014(r271461) @@ -111,6 +111,7 @@ mvs_attach(device_t dev) i++; ctlr-channels = mvs_ids[i].ports; ctlr-quirks = mvs_ids[i].quirks; + ctlr-ccc = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), ccc, ctlr-ccc); ctlr- = 8; Modified: head/sys/dev/mvs/mvs_soc.c == --- head/sys/dev/mvs/mvs_soc.c Fri Sep 12 10:08:11 2014(r271460) +++ head/sys/dev/mvs/mvs_soc.c Fri Sep 12 12:04:51 2014(r271461) @@ -114,6 +114,7 @@ mvs_attach(device_t dev) i++; ctlr-channels = mvs_ids[i].ports; ctlr-quirks = mvs_ids[i].quirks; + ctlr-ccc = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), ccc, ctlr-ccc); ctlr- = 8; Modified: head/sys/dev/siis/siis.c == --- head/sys/dev/siis/siis.cFri Sep 12 10:08:11 2014(r271460) +++ head/sys/dev/siis/siis.cFri Sep 12 12:04:51 2014(r271461) @@ -465,6 +465,7 @@ siis_ch_attach(device_t dev) ch-dev = dev; ch-unit = (intptr_t)device_get_ivars(dev); ch-quirks = ctlr-quirks; + ch-pm_level = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), pm_level, ch-pm_level); resource_int_value(device_get_name(dev), ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271462 - svnadmin/hooks/scripts
Author: bdrewery Date: Fri Sep 12 13:12:06 2014 New Revision: 271462 URL: http://svnweb.freebsd.org/changeset/base/271462 Log: Fix URL for bz hook. Reported by: ngie Pointyhat to: bdrewery Modified: svnadmin/hooks/scripts/notify_bz.sh Modified: svnadmin/hooks/scripts/notify_bz.sh == --- svnadmin/hooks/scripts/notify_bz.sh Fri Sep 12 12:04:51 2014 (r271461) +++ svnadmin/hooks/scripts/notify_bz.sh Fri Sep 12 13:12:06 2014 (r271462) @@ -32,7 +32,7 @@ for pr in $PRS; do echo Author: $WHO echo Date: $(date) echo New revision: $REV - echo URL: http://svnweb.freebsd.org/changeset/ports/$REV; + echo URL: http://svnweb.freebsd.org/changeset/base/$REV; echo echo Log: svnlook log $REPO -r $REV | sed -e 's/^/ /' ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271463 - in head/sys/dev/vt: . hw/ofwfb logo
Author: ray Date: Fri Sep 12 14:07:20 2014 New Revision: 271463 URL: http://svnweb.freebsd.org/changeset/base/271463 Log: Remove stray whitespaces. Modified: head/sys/dev/vt/hw/ofwfb/ofwfb.c head/sys/dev/vt/logo/logo_freebsd.c head/sys/dev/vt/vt_consolectl.c Modified: head/sys/dev/vt/hw/ofwfb/ofwfb.c == --- head/sys/dev/vt/hw/ofwfb/ofwfb.cFri Sep 12 13:12:06 2014 (r271462) +++ head/sys/dev/vt/hw/ofwfb/ofwfb.cFri Sep 12 14:07:20 2014 (r271463) @@ -53,7 +53,7 @@ struct ofwfb_softc { phandle_t sc_node; ihandle_t sc_handle; - bus_space_tag_t sc_memt; + bus_space_tag_t sc_memt; }; static vd_probe_t ofwfb_probe; Modified: head/sys/dev/vt/logo/logo_freebsd.c == --- head/sys/dev/vt/logo/logo_freebsd.c Fri Sep 12 13:12:06 2014 (r271462) +++ head/sys/dev/vt/logo/logo_freebsd.c Fri Sep 12 14:07:20 2014 (r271463) @@ -637,5 +637,5 @@ unsigned char vt_logo_image[] = { 0x1f, 0xff, 0xfc, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x03, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x7f, 0xc0, 0x00, 0x00, 0x3f, 0xff, 0xff, 0xf0, 0x00, 0x00, 0x3f, 0xe0, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, }; Modified: head/sys/dev/vt/vt_consolectl.c == --- head/sys/dev/vt/vt_consolectl.c Fri Sep 12 13:12:06 2014 (r271462) +++ head/sys/dev/vt/vt_consolectl.c Fri Sep 12 14:07:20 2014 (r271463) @@ -51,7 +51,7 @@ consolectl_ioctl(struct cdev *dev, u_lon { switch (cmd) { - case CONS_GETVERS: + case CONS_GETVERS: *(int*)data = 0x200; return 0; case CONS_MOUSECTL: { ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271464 - head/sys/dev/vt
Author: ray Date: Fri Sep 12 14:14:50 2014 New Revision: 271464 URL: http://svnweb.freebsd.org/changeset/base/271464 Log: Switch vt(4) to traditional behaviour with copy-paste same as syscons(4) do. Reviewed by: dumbbell (as D755) MFC after:1 week Modified: head/sys/dev/vt/vt_core.c Modified: head/sys/dev/vt/vt_core.c == --- head/sys/dev/vt/vt_core.c Fri Sep 12 14:07:20 2014(r271463) +++ head/sys/dev/vt/vt_core.c Fri Sep 12 14:14:50 2014(r271464) @@ -162,6 +162,7 @@ static int vt_late_window_switch(struct static int vt_proc_alive(struct vt_window *); static void vt_resize(struct vt_device *); static void vt_update_static(void *); +static void vt_mouse_paste(); SET_DECLARE(vt_drv_set, struct vt_driver); @@ -176,10 +177,14 @@ static struct vt_device vt_consdev = { .vd_flags = VDF_INVALID, .vd_windows = { [VT_CONSWINDOW] = vt_conswindow, }, .vd_curwindow = vt_conswindow, - .vd_markedwin = NULL, .vd_kbstate = 0, #ifndef SC_NO_CUTPASTE + .vd_pastebuf = { + .vpb_buf = NULL, + .vpb_bufsz = 0, + .vpb_len = 0 + }, .vd_mcursor = vt_default_mouse_pointer, .vd_mcursor_fg = TC_WHITE, .vd_mcursor_bg = TC_BLACK, @@ -508,7 +513,7 @@ vt_machine_kbdevent(int c) case SPCLKEY | PASTE: /* kbdmap(5) keyword `paste`. */ #ifndef SC_NO_CUTPASTE /* Insert text from cut-paste buffer. */ - /* TODO */ + vt_mouse_paste(); #endif break; case SPCLKEY | PDWN: /* kbdmap(5) keyword `pdwn`. */ @@ -1576,7 +1581,7 @@ vt_mouse_terminput_button(struct vt_devi mouseb[4] = '!' + x; mouseb[5] = '!' + y; - for (i = 0; i sizeof(mouseb); i++ ) + for (i = 0; i sizeof(mouseb); i++) terminal_input_char(vw-vw_terminal, mouseb[i]); } @@ -1614,6 +1619,23 @@ vt_mouse_terminput(struct vt_device *vd, } } +static void +vt_mouse_paste() +{ + term_char_t *buf; + int i, len; + + len = VD_PASTEBUFLEN(main_vd); + buf = VD_PASTEBUF(main_vd); + len /= sizeof(term_char_t); + for (i = 0; i len; i++) { + if (buf[i] == '\0') + continue; + terminal_input_char(main_vd-vd_curwindow-vw_terminal, + buf[i]); + } +} + void vt_mouse_event(int type, int x, int y, int event, int cnt, int mlevel) { @@ -1621,8 +1643,7 @@ vt_mouse_event(int type, int x, int y, i struct vt_window *vw; struct vt_font *vf; term_pos_t size; - term_char_t *buf; - int i, len, mark; + int len, mark; vd = main_vd; vw = vd-vd_curwindow; @@ -1665,17 +1686,10 @@ vt_mouse_event(int type, int x, int y, i vd-vd_mx = x; vd-vd_my = y; - if ((vd-vd_mstate MOUSE_BUTTON1DOWN) - (vtbuf_set_mark(vw-vw_buf, VTB_MARK_MOVE, - vd-vd_mx / vf-vf_width, - vd-vd_my / vf-vf_height) == 1)) { - - /* -* We have something marked to copy, so update pointer -* to window with selection. -*/ - vd-vd_markedwin = vw; - } + if (vd-vd_mstate MOUSE_BUTTON1DOWN) + vtbuf_set_mark(vw-vw_buf, VTB_MARK_MOVE, + vd-vd_mx / vf-vf_width, + vd-vd_my / vf-vf_height); vt_resume_flush_timer(vw-vw_device, 0); return; /* Done */ @@ -1708,27 +1722,7 @@ vt_mouse_event(int type, int x, int y, i case 0: /* up */ break; default: - if (vd-vd_markedwin == NULL) - return; - /* Get current selecton size in bytes. */ - len = vtbuf_get_marked_len(vd-vd_markedwin-vw_buf); - if (len = 0) - return; - - buf = malloc(len, M_VT, M_WAITOK | M_ZERO); - /* Request copy/paste buffer data, no more than `len' */ - vtbuf_extract_marked(vd-vd_markedwin-vw_buf, buf, - len); - - len /= sizeof(term_char_t); - for (i = 0; i len; i++ ) { - if (buf[i] == '\0') - continue; - terminal_input_char(vw-vw_terminal, buf[i]); - } - - /* Done, so cleanup. */ - free(buf, M_VT); + vt_mouse_paste(); break; } return; /*
svn commit: r271465 - head/sys/dev/vt
Author: ray Date: Fri Sep 12 14:16:10 2014 New Revision: 271465 URL: http://svnweb.freebsd.org/changeset/base/271465 Log: Switch vt(4) to traditional behaviour with copy-paste same as syscons(4) do. (forgetted in last commit) Reviewed by: dumbbell (as D755) MFC after:1 week Modified: head/sys/dev/vt/vt.h Modified: head/sys/dev/vt/vt.h == --- head/sys/dev/vt/vt.hFri Sep 12 14:14:50 2014(r271464) +++ head/sys/dev/vt/vt.hFri Sep 12 14:16:10 2014(r271465) @@ -113,11 +113,17 @@ typedef unsigned int vt_axis_t; struct vt_mouse_cursor; #endif +struct vt_pastebuf { + term_char_t *vpb_buf; /* Copy-paste buffer. */ + unsigned int vpb_bufsz; /* Buffer size. */ + unsigned int vpb_len; /* Length of a last selection. */ +}; + struct vt_device { struct vt_window*vd_windows[VT_MAXWINDOWS]; /* (c) Windows. */ struct vt_window*vd_curwindow; /* (d) Current window. */ struct vt_window*vd_savedwindow;/* (?) Saved for suspend. */ - struct vt_window*vd_markedwin; /* (?) Copy/paste buf owner. */ + struct vt_pastebuf vd_pastebuf; /* (?) Copy/paste buf. */ const struct vt_driver *vd_driver; /* (c) Graphics driver. */ void*vd_softc; /* (u) Driver data. */ #ifndef SC_NO_CUTPASTE @@ -151,6 +157,10 @@ struct vt_device { unsigned int vd_unit; /* (c) Device unit. */ }; +#defineVD_PASTEBUF(vd) ((vd)-vd_pastebuf.vpb_buf) +#defineVD_PASTEBUFSZ(vd) ((vd)-vd_pastebuf.vpb_bufsz) +#defineVD_PASTEBUFLEN(vd) ((vd)-vd_pastebuf.vpb_len) + /* * Per-window terminal screen buffer. * ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271466 - head/sys/dev/vt
Author: ray Date: Fri Sep 12 14:17:09 2014 New Revision: 271466 URL: http://svnweb.freebsd.org/changeset/base/271466 Log: Fix stray char on paste. Tested by:dumbbell and me MFC after:1 week Modified: head/sys/dev/vt/vt_buf.c Modified: head/sys/dev/vt/vt_buf.c == --- head/sys/dev/vt/vt_buf.cFri Sep 12 14:16:10 2014(r271465) +++ head/sys/dev/vt/vt_buf.cFri Sep 12 14:17:09 2014(r271466) @@ -603,7 +603,7 @@ vtbuf_get_marked_len(struct vt_buf *vb) ei = e.tp_row * vb-vb_scr_size.tp_col + e.tp_col; /* Number symbols and number of rows to inject \n */ - sz = ei - si + ((e.tp_row - s.tp_row) * 2) + 1; + sz = ei - si + ((e.tp_row - s.tp_row) * 2); return (sz * sizeof(term_char_t)); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271467 - head/sys/fs/ext2fs
Author: pfg Date: Fri Sep 12 15:49:21 2014 New Revision: 271467 URL: http://svnweb.freebsd.org/changeset/base/271467 Log: ext2fs: add ext2_getpages(). Literally copy/pasted from ffs_getpages(). Tested with: fsx MFC after:2 months Modified: head/sys/fs/ext2fs/ext2_vnops.c Modified: head/sys/fs/ext2fs/ext2_vnops.c == --- head/sys/fs/ext2fs/ext2_vnops.c Fri Sep 12 14:17:09 2014 (r271466) +++ head/sys/fs/ext2fs/ext2_vnops.c Fri Sep 12 15:49:21 2014 (r271467) @@ -54,6 +54,7 @@ #include sys/buf.h #include sys/endian.h #include sys/priv.h +#include sys/rwlock.h #include sys/mount.h #include sys/unistd.h #include sys/time.h @@ -65,9 +66,11 @@ #include sys/file.h #include vm/vm.h -#include vm/vm_page.h -#include vm/vm_object.h +#include vm/vm_param.h #include vm/vm_extern.h +#include vm/vm_object.h +#include vm/vm_page.h +#include vm/vm_pager.h #include vm/vnode_pager.h #include opt_directio.h @@ -94,6 +97,7 @@ static int ext2_chown(struct vnode *, ui static vop_close_t ext2_close; static vop_create_text2_create; static vop_fsync_t ext2_fsync; +static vop_getpages_t ext2_getpages; static vop_getattr_t ext2_getattr; static vop_ioctl_t ext2_ioctl; static vop_link_t ext2_link; @@ -124,6 +128,7 @@ struct vop_vector ext2_vnodeops = { .vop_close =ext2_close, .vop_create = ext2_create, .vop_fsync =ext2_fsync, + .vop_getpages = ext2_getpages, .vop_getattr = ext2_getattr, .vop_inactive = ext2_inactive, .vop_ioctl =ext2_ioctl, @@ -2058,3 +2063,43 @@ ext2_write(struct vop_write_args *ap) } return (error); } + +/* + * get page routine + */ +static int +ext2_getpages( struct vop_getpages_args *ap) +{ + int i; + vm_page_t mreq; + int pcount; + + pcount = round_page(ap-a_count) / PAGE_SIZE; + mreq = ap-a_m[ap-a_reqpage]; + + /* +* if ANY DEV_BSIZE blocks are valid on a large filesystem block, +* then the entire page is valid. Since the page may be mapped, +* user programs might reference data beyond the actual end of file +* occuring within the page. We have to zero that data. +*/ + VM_OBJECT_WLOCK(mreq-object); + if (mreq-valid) { + if (mreq-valid != VM_PAGE_BITS_ALL) + vm_page_zero_invalid(mreq, TRUE); + for (i = 0; i pcount; i++) { + if (i != ap-a_reqpage) { + vm_page_lock(ap-a_m[i]); + vm_page_free(ap-a_m[i]); + vm_page_unlock(ap-a_m[i]); + } + } + VM_OBJECT_WUNLOCK(mreq-object); + return VM_PAGER_OK; + } + VM_OBJECT_WUNLOCK(mreq-object); + + return vnode_pager_generic_getpages(ap-a_vp, ap-a_m, + ap-a_count, + ap-a_reqpage); +} ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271468 - head/sys/fs/ext2fs
Author: pfg Date: Fri Sep 12 15:54:18 2014 New Revision: 271468 URL: http://svnweb.freebsd.org/changeset/base/271468 Log: Extra space from r271467. MFC after:2 months Modified: head/sys/fs/ext2fs/ext2_vnops.c Modified: head/sys/fs/ext2fs/ext2_vnops.c == --- head/sys/fs/ext2fs/ext2_vnops.c Fri Sep 12 15:49:21 2014 (r271467) +++ head/sys/fs/ext2fs/ext2_vnops.c Fri Sep 12 15:54:18 2014 (r271468) @@ -2068,7 +2068,7 @@ ext2_write(struct vop_write_args *ap) * get page routine */ static int -ext2_getpages( struct vop_getpages_args *ap) +ext2_getpages(struct vop_getpages_args *ap) { int i; vm_page_t mreq; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271469 - in stable/10/libexec/rtld-elf: . amd64 arm i386 ia64 mips powerpc powerpc64 sparc64
Author: kib Date: Fri Sep 12 16:22:01 2014 New Revision: 271469 URL: http://svnweb.freebsd.org/changeset/base/271469 Log: MFC r270798: Process STT_GNU_IFUNC when doing non-plt relocations. MFC r270802: Only do the second pass over non-plt relocations when the first pass found IFUNCs. Approved by: re (gjb) Modified: stable/10/libexec/rtld-elf/amd64/reloc.c stable/10/libexec/rtld-elf/arm/reloc.c stable/10/libexec/rtld-elf/i386/reloc.c stable/10/libexec/rtld-elf/ia64/reloc.c stable/10/libexec/rtld-elf/mips/reloc.c stable/10/libexec/rtld-elf/powerpc/reloc.c stable/10/libexec/rtld-elf/powerpc64/reloc.c stable/10/libexec/rtld-elf/rtld.c stable/10/libexec/rtld-elf/rtld.h stable/10/libexec/rtld-elf/sparc64/reloc.c Directory Properties: stable/10/ (props changed) Modified: stable/10/libexec/rtld-elf/amd64/reloc.c == --- stable/10/libexec/rtld-elf/amd64/reloc.cFri Sep 12 15:54:18 2014 (r271468) +++ stable/10/libexec/rtld-elf/amd64/reloc.cFri Sep 12 16:22:01 2014 (r271469) @@ -125,213 +125,188 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry const Elf_Rela *relalim; const Elf_Rela *rela; SymCache *cache; - int r = -1; + const Elf_Sym *def; + const Obj_Entry *defobj; + Elf_Addr *where, symval; + Elf32_Addr *where32; + int r; + r = -1; /* * The dynamic loader may be called from a thread, we have * limited amounts of stack available so we cannot use alloca(). */ if (obj != obj_rtld) { - cache = calloc(obj-dynsymcount, sizeof(SymCache)); - /* No need to check for NULL here */ + cache = calloc(obj-dynsymcount, sizeof(SymCache)); + /* No need to check for NULL here */ } else - cache = NULL; + cache = NULL; - relalim = (const Elf_Rela *) ((caddr_t) obj-rela + obj-relasize); + relalim = (const Elf_Rela *)((caddr_t)obj-rela + obj-relasize); for (rela = obj-rela; rela relalim; rela++) { - Elf_Addr *where = (Elf_Addr *) (obj-relocbase + rela-r_offset); - Elf32_Addr *where32 = (Elf32_Addr *)where; - - switch (ELF_R_TYPE(rela-r_info)) { - - case R_X86_64_NONE: - break; - - case R_X86_64_64: - { - const Elf_Sym *def; - const Obj_Entry *defobj; - - def = find_symdef(ELF_R_SYM(rela-r_info), obj, defobj, - flags, cache, lockstate); - if (def == NULL) - goto done; - - *where = (Elf_Addr) (defobj-relocbase + def-st_value + rela-r_addend); - } - break; - - case R_X86_64_PC32: - /* -* I don't think the dynamic linker should ever see this -* type of relocation. But the binutils-2.6 tools sometimes -* generate it. -*/ - { - const Elf_Sym *def; - const Obj_Entry *defobj; - - def = find_symdef(ELF_R_SYM(rela-r_info), obj, defobj, - flags, cache, lockstate); - if (def == NULL) - goto done; - - *where32 = (Elf32_Addr) (unsigned long) (defobj-relocbase + - def-st_value + rela-r_addend - (Elf_Addr) where); - } - break; - /* missing: R_X86_64_GOT32 R_X86_64_PLT32 */ - - case R_X86_64_COPY: /* -* These are deferred until all other relocations have -* been done. All we do here is make sure that the COPY -* relocation is not in a shared library. They are allowed -* only in executable files. +* First, resolve symbol for relocations which +* reference symbols. */ - if (!obj-mainprog) { - _rtld_error(%s: Unexpected R_X86_64_COPY relocation - in shared library, obj-path); - goto done; - } - break; - - case R_X86_64_GLOB_DAT: - { - const Elf_Sym *def; - const Obj_Entry *defobj; - - def = find_symdef(ELF_R_SYM(rela-r_info), obj, defobj, - flags, cache, lockstate); - if (def == NULL) - goto done; - - *where = (Elf_Addr) (defobj-relocbase + def-st_value); - } - break; - - case R_X86_64_TPOFF64: - { - const Elf_Sym *def; - const Obj_Entry *defobj; - - def = find_symdef(ELF_R_SYM(rela-r_info),
svn commit: r271470 - stable/10/release/amd64
Author: emaste Date: Fri Sep 12 16:37:56 2014 New Revision: 271470 URL: http://svnweb.freebsd.org/changeset/base/271470 Log: MFC r264995 (nwhitehorn): Add script to setup bootable CD ISOs for both BIOS and EFI systems. Tested and working on QEMU. Actually using this script as the regular image generator, like with the memstick one, will require that the kernel support EFI too. In particular, the following two things are required: 1. vt(9) be the default console driver 2. vt_efifb and vt_vga be able to coexist usefully in the same kernel One other note here is that this requires newfs_msdos and mdconfig, which is really ugly. NetBSD's makefs at least seems to support FAT now. If that actually works, it should be imported and we can get rid of the mdconfig mess. Approved by: re Relnotes: Yes Sponsored by: The FreeBSD Foundation Added: stable/10/release/amd64/mkisoimages-uefi.sh - copied unchanged from r264995, head/release/amd64/mkisoimages-uefi.sh Modified: Directory Properties: stable/10/ (props changed) Copied: stable/10/release/amd64/mkisoimages-uefi.sh (from r264995, head/release/amd64/mkisoimages-uefi.sh) == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/release/amd64/mkisoimages-uefi.sh Fri Sep 12 16:37:56 2014 (r271470, copy of r264995, head/release/amd64/mkisoimages-uefi.sh) @@ -0,0 +1,60 @@ +#!/bin/sh +# +# Module: mkisoimages.sh +# Author: Jordan K Hubbard +# Date: 22 June 2001 +# +# $FreeBSD$ +# +# This script is used by release/Makefile to build the (optional) ISO images +# for a FreeBSD release. It is considered architecture dependent since each +# platform has a slightly unique way of making bootable CDs. This script +# is also allowed to generate any number of images since that is more of +# publishing decision than anything else. +# +# Usage: +# +# mkisoimages.sh [-b] image-label image-name base-bits-dir [extra-bits-dir] +# +# Where -b is passed if the ISO image should be made bootable by +# whatever standards this architecture supports (may be unsupported), +# image-label is the ISO image label, image-name is the filename of the +# resulting ISO image, base-bits-dir contains the image contents and +# extra-bits-dir, if provided, contains additional files to be merged +# into base-bits-dir as part of making the image. + +if [ x$1 = x-b ]; then + # This is highly x86-centric and will be used directly below. + bootable=-o bootimage=i386;$4/boot/cdboot -o no-emul-boot + + # Make EFI system partition (should be done with makefs in the future) + dd if=/dev/zero of=efiboot.img bs=4k count=100 + device=`mdconfig -a -t vnode -f efiboot.img` + newfs_msdos -F 12 -m 0xf8 /dev/$device + mkdir efi + mount -t msdosfs /dev/$device efi + mkdir -p efi/efi/boot + cp ${4}/boot/loader.efi efi/efi/boot/bootx64.efi + umount efi + rmdir efi + mdconfig -d -u $device + bootable=-o bootimage=i386;efiboot.img -o no-emul-boot $bootable + + shift +else + bootable= +fi + +if [ $# -lt 3 ]; then + echo Usage: $0 '[-b] image-label image-name base-bits-dir [extra-bits-dir]' + exit 1 +fi + +LABEL=`echo $1 | tr '[:lower:]' '[:upper:]'`; shift +NAME=$1; shift + +publisher=The FreeBSD Project. http://www.FreeBSD.org/; +echo /dev/iso9660/$LABEL / cd9660 ro 0 0 $1/etc/fstab +makefs -t cd9660 $bootable -o rockridge -o label=$LABEL -o publisher=$publisher $NAME $* +rm $1/etc/fstab +rm -f efiboot.img ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271471 - in stable/10/release/doc: en_US.ISO8859-1/share/xml share/mk share/xml
Author: gjb Date: Fri Sep 12 17:01:14 2014 New Revision: 271471 URL: http://svnweb.freebsd.org/changeset/base/271471 Log: MFC r271331: Change how the recommended mailing list to track is added to the footer of the release/doc/ pages by moving a hard-coded value (that is subject to human error to change) to release.ent where other values are regularly changed, and adding parsing logic to release.xsl. Approved by: re (implicit, relnotes) Sponsored by: The FreeBSD Foundation Modified: stable/10/release/doc/en_US.ISO8859-1/share/xml/release.xsl stable/10/release/doc/share/mk/doc.relnotes.mk stable/10/release/doc/share/xml/release.ent stable/10/release/doc/share/xml/release.xsl Directory Properties: stable/10/ (props changed) Modified: stable/10/release/doc/en_US.ISO8859-1/share/xml/release.xsl == --- stable/10/release/doc/en_US.ISO8859-1/share/xml/release.xsl Fri Sep 12 16:37:56 2014(r271470) +++ stable/10/release/doc/en_US.ISO8859-1/share/xml/release.xsl Fri Sep 12 17:01:14 2014(r271471) @@ -8,6 +8,7 @@ xsl:param name=release.url/ xsl:param name=release.branch/ + xsl:param name=release.maillist/ xsl:template name=user.footer.content p align=centersmallThis file, and other release-related documents, @@ -17,8 +18,8 @@ a href=http://www.FreeBSD.org/docs.html;documentation/a before contacting lt;a href=mailto:questi...@freebsd.org;questi...@freebsd.org/agt;./small/p -p align=centersmallAll users of FreeBSD stable should - subscribe to the lt;a href=mailto:sta...@freebsd.org;sta...@freebsd.org/agt; +p align=centersmallAll users of FreeBSD xsl:value-of select=$release.branch/ should + subscribe to the lt;a href=mailto:{$release.maillist}@FreeBSD.org;xsl:value-of select=$release.maillist/@FreeBSD.org/agt; mailing list./small/p p align=centersmallFor questions about this documentation, Modified: stable/10/release/doc/share/mk/doc.relnotes.mk == --- stable/10/release/doc/share/mk/doc.relnotes.mk Fri Sep 12 16:37:56 2014(r271470) +++ stable/10/release/doc/share/mk/doc.relnotes.mk Fri Sep 12 17:01:14 2014(r271471) @@ -6,6 +6,7 @@ DOC_PREFIX?= ${RELN_ROOT}/../../../doc RELEASETYPE!= grep -o 'release.type [a-z]*' ${RELN_ROOT}/share/xml/release.ent | sed 's|[a-z.]* \([a-z]*\)|\1|' RELEASEURL!= grep -o 'release.url \[^\]*\' ${RELN_ROOT}/share/xml/release.ent | sed 's|[^ ]* \([^]*\)|\1|' RELEASEBRANCH!= grep -o 'release.branch \([^]*\)' ${RELN_ROOT}/share/xml/release.ent | sed 's|[^ ]* \([^]*\)|\1|' +RELEASEMAILLIST!= grep -o 'release.maillist \([^]*\)' ${RELN_ROOT}/share/xml/release.ent | sed 's|[^ ]* \([^]*\)|\1|' .if ${RELEASETYPE} == current PROFILING+= --param profile.attribute 'releasetype' --param profile.value 'current' .elif ${RELEASETYPE} == snapshot @@ -15,6 +16,7 @@ PROFILING+= --param profile.attribute ' .endif XSLTPROCFLAGS+= --param release.url '${RELEASEURL}' XSLTPROCFLAGS+= --param release.branch '${RELEASEBRANCH}' +XSLTPROCFLAGS+= --param release.maillist '${RELEASEMAILLIST}' # Find the RELNOTESng document catalogs EXTRA_CATALOGS+= file://${RELN_ROOT}/${LANGCODE}/share/xml/catalog.xml \ Modified: stable/10/release/doc/share/xml/release.ent == --- stable/10/release/doc/share/xml/release.ent Fri Sep 12 16:37:56 2014 (r271470) +++ stable/10/release/doc/share/xml/release.ent Fri Sep 12 17:01:14 2014 (r271471) @@ -27,6 +27,9 @@ !-- The URL for obtaining this version of FreeBSD. -- !ENTITY release.url http://www.FreeBSD.org/snapshots/; +!-- The recommended mailing list to track. -- +!ENTITY release.maillist stable + !-- The type of release (usually this will be either snapshot or release -- !-- WARNING: Do not forget to also change the release type in Modified: stable/10/release/doc/share/xml/release.xsl == --- stable/10/release/doc/share/xml/release.xsl Fri Sep 12 16:37:56 2014 (r271470) +++ stable/10/release/doc/share/xml/release.xsl Fri Sep 12 17:01:14 2014 (r271471) @@ -12,6 +12,7 @@ xsl:param name=release.url/ xsl:param name=release.branch/ + xsl:param name=release.maillist/ xsl:template name=paragraph xsl:param name=class select=''/ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271472 - in stable/9/release/doc: en_US.ISO8859-1/share/xml share/mk share/xml
Author: gjb Date: Fri Sep 12 17:02:13 2014 New Revision: 271472 URL: http://svnweb.freebsd.org/changeset/base/271472 Log: MFC r271331: Change how the recommended mailing list to track is added to the footer of the release/doc/ pages by moving a hard-coded value (that is subject to human error to change) to release.ent where other values are regularly changed, and adding parsing logic to release.xsl. Approved by: re (implicit) Sponsored by: The FreeBSD Foundation Modified: stable/9/release/doc/en_US.ISO8859-1/share/xml/release.xsl stable/9/release/doc/share/mk/doc.relnotes.mk stable/9/release/doc/share/xml/release.ent stable/9/release/doc/share/xml/release.xsl Directory Properties: stable/9/release/doc/ (props changed) Modified: stable/9/release/doc/en_US.ISO8859-1/share/xml/release.xsl == --- stable/9/release/doc/en_US.ISO8859-1/share/xml/release.xsl Fri Sep 12 17:01:14 2014(r271471) +++ stable/9/release/doc/en_US.ISO8859-1/share/xml/release.xsl Fri Sep 12 17:02:13 2014(r271472) @@ -8,6 +8,7 @@ xsl:param name=release.url/ xsl:param name=release.branch/ + xsl:param name=release.maillist/ xsl:template name=user.footer.content p align=centersmallThis file, and other release-related documents, @@ -18,7 +19,7 @@ contacting lt;a href=mailto:questi...@freebsd.org;questi...@freebsd.org/agt;./small/p p align=centersmallAll users of FreeBSD xsl:value-of select=$release.branch/ should - subscribe to the lt;a href=mailto:sta...@freebsd.org;sta...@freebsd.org/agt; + subscribe to the lt;a href=mailto:{$release.maillist}@FreeBSD.org;xsl:value-of select=$release.maillist/@FreeBSD.org/agt; mailing list./small/p p align=centersmallFor questions about this documentation, Modified: stable/9/release/doc/share/mk/doc.relnotes.mk == --- stable/9/release/doc/share/mk/doc.relnotes.mk Fri Sep 12 17:01:14 2014(r271471) +++ stable/9/release/doc/share/mk/doc.relnotes.mk Fri Sep 12 17:02:13 2014(r271472) @@ -6,6 +6,7 @@ DOC_PREFIX?= ${RELN_ROOT}/../../../doc RELEASETYPE!= grep -o 'release.type [a-z]*' ${RELN_ROOT}/share/xml/release.ent | sed 's|[a-z.]* \([a-z]*\)|\1|' RELEASEURL!= grep -o 'release.url \[^\]*\' ${RELN_ROOT}/share/xml/release.ent | sed 's|[^ ]* \([^]*\)|\1|' RELEASEBRANCH!= grep -o 'release.branch \([^]*\)' ${RELN_ROOT}/share/xml/release.ent | sed 's|[^ ]* \([^]*\)|\1|' +RELEASEMAILLIST!= grep -o 'release.maillist \([^]*\)' ${RELN_ROOT}/share/xml/release.ent | sed 's|[^ ]* \([^]*\)|\1|' .if ${RELEASETYPE} == current PROFILING+= --param profile.attribute 'releasetype' --param profile.value 'current' .elif ${RELEASETYPE} == snapshot @@ -15,6 +16,7 @@ PROFILING+= --param profile.attribute ' .endif XSLTPROCFLAGS+= --param release.url '${RELEASEURL}' XSLTPROCFLAGS+= --param release.branch '${RELEASEBRANCH}' +XSLTPROCFLAGS+= --param release.maillist '${RELEASEMAILLIST}' # Find the RELNOTESng document catalogs EXTRA_CATALOGS+= file://${RELN_ROOT}/${LANGCODE}/share/xml/catalog.xml \ Modified: stable/9/release/doc/share/xml/release.ent == --- stable/9/release/doc/share/xml/release.ent Fri Sep 12 17:01:14 2014 (r271471) +++ stable/9/release/doc/share/xml/release.ent Fri Sep 12 17:02:13 2014 (r271472) @@ -22,6 +22,9 @@ !-- The URL for obtaining this version of FreeBSD. -- !ENTITY release.url http://www.FreeBSD.org/releases/; +!-- The recommended mailing list to track. -- +!ENTITY release.maillist stable + !-- The type of release (usually this will be either snapshot or release -- Modified: stable/9/release/doc/share/xml/release.xsl == --- stable/9/release/doc/share/xml/release.xsl Fri Sep 12 17:01:14 2014 (r271471) +++ stable/9/release/doc/share/xml/release.xsl Fri Sep 12 17:02:13 2014 (r271472) @@ -12,6 +12,7 @@ xsl:param name=release.url/ xsl:param name=release.branch/ + xsl:param name=release.maillist/ xsl:template name=paragraph xsl:param name=class select=''/ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271473 - stable/10/crypto/heimdal/tools
Author: gjb Date: Fri Sep 12 17:06:55 2014 New Revision: 271473 URL: http://svnweb.freebsd.org/changeset/base/271473 Log: MFC r271284: Include the gssapi_krb5 library in KRB5_LDFLAGS. PR: 156245 Approved by: re (marius) Sponsored by: The FreeBSD Foundation Modified: stable/10/crypto/heimdal/tools/krb5-config.in Directory Properties: stable/10/ (props changed) Modified: stable/10/crypto/heimdal/tools/krb5-config.in == --- stable/10/crypto/heimdal/tools/krb5-config.in Fri Sep 12 17:02:13 2014(r271472) +++ stable/10/crypto/heimdal/tools/krb5-config.in Fri Sep 12 17:06:55 2014(r271473) @@ -123,7 +123,7 @@ if test $do_libs = yes; then lib_flags=-L${libdir} case $library in gssapi) - lib_flags=$lib_flags -lgssapi -lheimntlm + lib_flags=$lib_flags -lgssapi -lgssapi_krb5 -lheimntlm ;; kadm-client) lib_flags=$lib_flags -lkadm5clnt ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271474 - stable/9/crypto/heimdal/tools
Author: gjb Date: Fri Sep 12 17:07:19 2014 New Revision: 271474 URL: http://svnweb.freebsd.org/changeset/base/271474 Log: MFC r271284: Include the gssapi_krb5 library in KRB5_LDFLAGS. PR: 156245 Sponsored by: The FreeBSD Foundation Modified: stable/9/crypto/heimdal/tools/krb5-config.in Directory Properties: stable/9/crypto/heimdal/ (props changed) Modified: stable/9/crypto/heimdal/tools/krb5-config.in == --- stable/9/crypto/heimdal/tools/krb5-config.inFri Sep 12 17:06:55 2014(r271473) +++ stable/9/crypto/heimdal/tools/krb5-config.inFri Sep 12 17:07:19 2014(r271474) @@ -93,7 +93,7 @@ if test $do_libs = yes; then lib_flags=-L${libdir} case $library in gssapi) - lib_flags=$lib_flags -lgssapi -lheimntlm + lib_flags=$lib_flags -lgssapi -lgssapi_krb5 -lheimntlm ;; kadm-client) lib_flags=$lib_flags -lkadm5clnt ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271475 - in head/sys/boot: amd64/efi efi/libefi i386/libi386
Author: ambrisko Date: Fri Sep 12 17:32:28 2014 New Revision: 271475 URL: http://svnweb.freebsd.org/changeset/base/271475 Log: Add support for serial and null console to UEFI boot loader. Modified: head/sys/boot/amd64/efi/bootinfo.c head/sys/boot/amd64/efi/conf.c head/sys/boot/efi/libefi/Makefile head/sys/boot/i386/libi386/comconsole.c Modified: head/sys/boot/amd64/efi/bootinfo.c == --- head/sys/boot/amd64/efi/bootinfo.c Fri Sep 12 17:07:19 2014 (r271474) +++ head/sys/boot/amd64/efi/bootinfo.c Fri Sep 12 17:32:28 2014 (r271475) @@ -60,6 +60,7 @@ bi_getboothowto(char *kargs) { const char *sw; char *opts; + char *console; int howto, i; howto = 0; @@ -70,6 +71,14 @@ bi_getboothowto(char *kargs) howto |= howto_names[i].mask; } + console = getenv(console); + if (console != NULL) { + if (strcmp(console, comconsole) == 0) + howto |= RB_SERIAL; + if (strcmp(console, nullconsole) == 0) + howto |= RB_MUTE; + } + /* Parse kargs */ if (kargs == NULL) return (howto); Modified: head/sys/boot/amd64/efi/conf.c == --- head/sys/boot/amd64/efi/conf.c Fri Sep 12 17:07:19 2014 (r271474) +++ head/sys/boot/amd64/efi/conf.c Fri Sep 12 17:32:28 2014 (r271475) @@ -62,8 +62,12 @@ struct file_format *file_formats[] = { }; extern struct console efi_console; +extern struct console comconsole; +extern struct console nullconsole; struct console *consoles[] = { efi_console, + comconsole, + nullconsole, NULL }; Modified: head/sys/boot/efi/libefi/Makefile == --- head/sys/boot/efi/libefi/Makefile Fri Sep 12 17:07:19 2014 (r271474) +++ head/sys/boot/efi/libefi/Makefile Fri Sep 12 17:32:28 2014 (r271475) @@ -5,6 +5,8 @@ INTERNALLIB= SRCS= delay.c efi_console.c efinet.c efipart.c errno.c handles.c \ libefi.c time.c +.PATH: ${.CURDIR}/../../i386/libi386 +SRCS+= nullconsole.c comconsole.c .if ${MACHINE_ARCH} == amd64 CFLAGS+= -fPIC @@ -16,6 +18,8 @@ CFLAGS+= -I${.CURDIR}/../../../../lib/li # Pick up the bootstrap header for some interface items CFLAGS+= -I${.CURDIR}/../../common +CFLAGS+= -DNO_PCI + # Suppress warning from clang for FreeBSD %b and %D formats CFLAGS+= -fformat-extensions Modified: head/sys/boot/i386/libi386/comconsole.c == --- head/sys/boot/i386/libi386/comconsole.c Fri Sep 12 17:07:19 2014 (r271474) +++ head/sys/boot/i386/libi386/comconsole.c Fri Sep 12 17:32:28 2014 (r271475) @@ -214,6 +214,9 @@ comc_port_set(struct env_var *ev, int fl static uint32_t comc_parse_pcidev(const char *string) { +#ifdef NO_PCI + return (0); +#else char *p, *p1; uint8_t bus, dev, func, bar; uint32_t locator; @@ -247,11 +250,15 @@ comc_parse_pcidev(const char *string) locator = (bar 16) | biospci_locator(bus, dev, func); return (locator); +#endif } static int comc_pcidev_handle(uint32_t locator) { +#ifdef NO_PCI + return (CMD_ERROR); +#else char intbuf[64]; uint32_t port; @@ -275,6 +282,7 @@ comc_pcidev_handle(uint32_t locator) comc_locator = locator; return (CMD_OK); +#endif } static int ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271476 - stable/9/sys/dev/bxe
Author: davidcs Date: Fri Sep 12 18:20:35 2014 New Revision: 271476 URL: http://svnweb.freebsd.org/changeset/base/271476 Log: MFC r268854 Initiate error recovery stats fail to update after 3 retries. Change bxe_panic() ECORE_DBG_BREAK_IF() ECORE_BUG() ECORE_BUG_ON() to panic only if ECORE_STOP_ON_ERROR is defined. Modified: stable/9/sys/dev/bxe/bxe.c stable/9/sys/dev/bxe/bxe.h stable/9/sys/dev/bxe/bxe_stats.c stable/9/sys/dev/bxe/ecore_reg.h stable/9/sys/dev/bxe/ecore_sp.h Directory Properties: stable/9/ (props changed) stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/bxe/bxe.c == --- stable/9/sys/dev/bxe/bxe.c Fri Sep 12 17:32:28 2014(r271475) +++ stable/9/sys/dev/bxe/bxe.c Fri Sep 12 18:20:35 2014(r271476) @@ -11486,6 +11486,10 @@ bxe_process_kill(struct bxe_softc *sc, bxe_process_kill_chip_reset(sc, global); mb(); +/* clear errors in PGB */ +if (!CHIP_IS_E1(sc)) +REG_WR(sc, PGLUE_B_REG_LATCHED_ERRORS_CLR, 0x7f); + /* Recover after reset: */ /* MCP */ if (global bxe_reset_mcp_comp(sc, val)) { Modified: stable/9/sys/dev/bxe/bxe.h == --- stable/9/sys/dev/bxe/bxe.h Fri Sep 12 17:32:28 2014(r271475) +++ stable/9/sys/dev/bxe/bxe.h Fri Sep 12 18:20:35 2014(r271476) @@ -2301,11 +2301,20 @@ void ecore_storm_memset_struct(struct bx } \ } while(0) +#ifdef ECORE_STOP_ON_ERROR + #define bxe_panic(sc, msg) \ do { \ panic msg; \ } while (0) +#else + +#define bxe_panic(sc, msg) \ +device_printf((sc)-dev, %s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#endif + #define CATC_TRIGGER(sc, data) REG_WR((sc), 0x2000, (data)); #define CATC_TRIGGER_START(sc) CATC_TRIGGER((sc), 0xcafecafe) Modified: stable/9/sys/dev/bxe/bxe_stats.c == --- stable/9/sys/dev/bxe/bxe_stats.cFri Sep 12 17:32:28 2014 (r271475) +++ stable/9/sys/dev/bxe/bxe_stats.cFri Sep 12 18:20:35 2014 (r271476) @@ -1306,7 +1306,10 @@ bxe_stats_update(struct bxe_softc *sc) if (bxe_storm_stats_update(sc)) { if (sc-stats_pending++ == 3) { -bxe_panic(sc, (storm stats not updated for 3 times\n)); + if (sc-ifnet-if_drv_flags IFF_DRV_RUNNING) { + atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT); + taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task); + } } return; } Modified: stable/9/sys/dev/bxe/ecore_reg.h == --- stable/9/sys/dev/bxe/ecore_reg.hFri Sep 12 17:32:28 2014 (r271475) +++ stable/9/sys/dev/bxe/ecore_reg.hFri Sep 12 18:20:35 2014 (r271476) @@ -1039,6 +1039,8 @@ __FBSDID($FreeBSD$); 0x942cUL #define PGLUE_B_REG_INTERNAL_PFID_ENABLE_TARGET_READ \ 0x9430UL +#define PGLUE_B_REG_LATCHED_ERRORS_CLR \ + 0x943CUL #define PGLUE_B_REG_PGLUE_B_INT_STS \ 0x9298UL #define PGLUE_B_REG_PGLUE_B_INT_STS_CLR \ Modified: stable/9/sys/dev/bxe/ecore_sp.h == --- stable/9/sys/dev/bxe/ecore_sp.h Fri Sep 12 17:32:28 2014 (r271475) +++ stable/9/sys/dev/bxe/ecore_sp.h Fri Sep 12 18:20:35 2014 (r271476) @@ -223,6 +223,8 @@ ECORE_CRC32_LE(uint32_t seed, uint8_t *m #define ecore_sp_post(_sc, _a, _b, _c, _d) \ bxe_sp_post(_sc, _a, _b, U64_HI(_c), U64_LO(_c), _d) +#ifdef ECORE_STOP_ON_ERROR + #define ECORE_DBG_BREAK_IF(exp) \ do {\ if (__predict_false(exp)) { \ @@ -242,6 +244,20 @@ ECORE_CRC32_LE(uint32_t seed, uint8_t *m }\ } while (0) +#else + +#define ECORE_DBG_BREAK_IF(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#define ECORE_BUG(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#define ECORE_BUG_ON(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + + +#endif /* #ifdef ECORE_STOP_ON_ERROR */ + #define ECORE_ERR(str, ...) \ BLOGE(sc, ECORE: str, ##__VA_ARGS__) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271477 - stable/10/release
Author: gjb Date: Fri Sep 12 18:23:22 2014 New Revision: 271477 URL: http://svnweb.freebsd.org/changeset/base/271477 Log: Connect the UEFI-capable disc1.iso and dvd1.iso variants to the build. This is a direct commit to stable/10. Approved by: re (marius) Sponsored by: The FreeBSD Foundation Modified: stable/10/release/Makefile Modified: stable/10/release/Makefile == --- stable/10/release/Makefile Fri Sep 12 18:20:35 2014(r271476) +++ stable/10/release/Makefile Fri Sep 12 18:23:22 2014(r271477) @@ -97,6 +97,16 @@ IMAGES+= mini-memstick.img RELEASE_TARGETS+=uefi-memstick.img IMAGES+= uefi-memstick.img .endif +.if exists(${.CURDIR}/${TARGET}/mkisoimages-uefi.sh) +RELEASE_TARGETS+=uefi-disc1.iso +RELEASE_TARGETS+=uefi-bootonly.iso +IMAGES+= uefi-disc1.iso +IMAGES+= uefi-bootonly.iso +. if defined(WITH_DVD) !empty(WITH_DVD) +RELEASE_TARGETS+=uefi-dvd1.iso +IMAGES+= uefi-dvd1.iso +. endif +.endif CLEANFILES=packagesystem *.txz MANIFEST system ${IMAGES} .if defined(WITH_COMPRESSED_IMAGES) !empty(WITH_COMPRESSED_IMAGES) @@ -220,9 +230,24 @@ release.iso: disc1.iso disc1.iso: system sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b FreeBSD_Install ${.TARGET} release +uefi-disc1.iso: system +.if exists(${.CURDIR}/${TARGET}/mkisoimages-uefi.sh) + sh ${.CURDIR}/${TARGET}/mkisoimages-uefi.sh -b FreeBSD_Install ${.TARGET} release +.endif + +uefi-bootonly.iso: bootonly +.if exists(${.CURDIR}/${TARGET}/mkisoimages-uefi.sh) + sh ${.CURDIR}/${TARGET}/mkisoimages-uefi.sh -b FreeBSD_Install ${.TARGET} bootonly +.endif + dvd1.iso: dvd pkg-stage sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b FreeBSD_Install ${.TARGET} dvd +uefi-dvd1.iso: dvd pkg-stage +.if exists(${.CURDIR}/${TARGET}/mkisoimages-uefi.sh) + sh ${.CURDIR}/${TARGET}/mkisoimages-uefi.sh -b FreeBSD_Install ${.TARGET} dvd +.endif + bootonly.iso: bootonly sh ${.CURDIR}/${TARGET}/mkisoimages.sh -b FreeBSD_Install ${.TARGET} bootonly ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271478 - stable/8/sys/dev/bxe
Author: davidcs Date: Fri Sep 12 18:27:20 2014 New Revision: 271478 URL: http://svnweb.freebsd.org/changeset/base/271478 Log: MFC r268854 Initiate error recovery stats fail to update after 3 retries. Change bxe_panic() ECORE_DBG_BREAK_IF() ECORE_BUG() ECORE_BUG_ON() to panic only if ECORE_STOP_ON_ERROR is defined. Modified: stable/8/sys/dev/bxe/bxe.c stable/8/sys/dev/bxe/bxe.h stable/8/sys/dev/bxe/bxe_stats.c stable/8/sys/dev/bxe/ecore_reg.h stable/8/sys/dev/bxe/ecore_sp.h Directory Properties: stable/8/ (props changed) stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) Modified: stable/8/sys/dev/bxe/bxe.c == --- stable/8/sys/dev/bxe/bxe.c Fri Sep 12 18:23:22 2014(r271477) +++ stable/8/sys/dev/bxe/bxe.c Fri Sep 12 18:27:20 2014(r271478) @@ -11486,6 +11486,10 @@ bxe_process_kill(struct bxe_softc *sc, bxe_process_kill_chip_reset(sc, global); mb(); +/* clear errors in PGB */ +if (!CHIP_IS_E1(sc)) +REG_WR(sc, PGLUE_B_REG_LATCHED_ERRORS_CLR, 0x7f); + /* Recover after reset: */ /* MCP */ if (global bxe_reset_mcp_comp(sc, val)) { Modified: stable/8/sys/dev/bxe/bxe.h == --- stable/8/sys/dev/bxe/bxe.h Fri Sep 12 18:23:22 2014(r271477) +++ stable/8/sys/dev/bxe/bxe.h Fri Sep 12 18:27:20 2014(r271478) @@ -2301,11 +2301,20 @@ void ecore_storm_memset_struct(struct bx } \ } while(0) +#ifdef ECORE_STOP_ON_ERROR + #define bxe_panic(sc, msg) \ do { \ panic msg; \ } while (0) +#else + +#define bxe_panic(sc, msg) \ +device_printf((sc)-dev, %s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#endif + #define CATC_TRIGGER(sc, data) REG_WR((sc), 0x2000, (data)); #define CATC_TRIGGER_START(sc) CATC_TRIGGER((sc), 0xcafecafe) Modified: stable/8/sys/dev/bxe/bxe_stats.c == --- stable/8/sys/dev/bxe/bxe_stats.cFri Sep 12 18:23:22 2014 (r271477) +++ stable/8/sys/dev/bxe/bxe_stats.cFri Sep 12 18:27:20 2014 (r271478) @@ -1306,7 +1306,10 @@ bxe_stats_update(struct bxe_softc *sc) if (bxe_storm_stats_update(sc)) { if (sc-stats_pending++ == 3) { -bxe_panic(sc, (storm stats not updated for 3 times\n)); + if (sc-ifnet-if_drv_flags IFF_DRV_RUNNING) { + atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT); + taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task); + } } return; } Modified: stable/8/sys/dev/bxe/ecore_reg.h == --- stable/8/sys/dev/bxe/ecore_reg.hFri Sep 12 18:23:22 2014 (r271477) +++ stable/8/sys/dev/bxe/ecore_reg.hFri Sep 12 18:27:20 2014 (r271478) @@ -1039,6 +1039,8 @@ __FBSDID($FreeBSD$); 0x942cUL #define PGLUE_B_REG_INTERNAL_PFID_ENABLE_TARGET_READ \ 0x9430UL +#define PGLUE_B_REG_LATCHED_ERRORS_CLR \ + 0x943CUL #define PGLUE_B_REG_PGLUE_B_INT_STS \ 0x9298UL #define PGLUE_B_REG_PGLUE_B_INT_STS_CLR \ Modified: stable/8/sys/dev/bxe/ecore_sp.h == --- stable/8/sys/dev/bxe/ecore_sp.h Fri Sep 12 18:23:22 2014 (r271477) +++ stable/8/sys/dev/bxe/ecore_sp.h Fri Sep 12 18:27:20 2014 (r271478) @@ -223,6 +223,8 @@ ECORE_CRC32_LE(uint32_t seed, uint8_t *m #define ecore_sp_post(_sc, _a, _b, _c, _d) \ bxe_sp_post(_sc, _a, _b, U64_HI(_c), U64_LO(_c), _d) +#ifdef ECORE_STOP_ON_ERROR + #define ECORE_DBG_BREAK_IF(exp) \ do {\ if (__predict_false(exp)) { \ @@ -242,6 +244,20 @@ ECORE_CRC32_LE(uint32_t seed, uint8_t *m }\ } while (0) +#else + +#define ECORE_DBG_BREAK_IF(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#define ECORE_BUG(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#define ECORE_BUG_ON(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + + +#endif /* #ifdef ECORE_STOP_ON_ERROR */ + #define ECORE_ERR(str, ...) \ BLOGE(sc, ECORE: str, ##__VA_ARGS__) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271479 - stable/7/sys/dev/bxe
Author: davidcs Date: Fri Sep 12 18:31:44 2014 New Revision: 271479 URL: http://svnweb.freebsd.org/changeset/base/271479 Log: MFC r268854 Initiate error recovery stats fail to update after 3 retries. Change bxe_panic() ECORE_DBG_BREAK_IF() ECORE_BUG() ECORE_BUG_ON() to panic only if ECORE_STOP_ON_ERROR is defined. Modified: stable/7/sys/dev/bxe/bxe.c stable/7/sys/dev/bxe/bxe.h stable/7/sys/dev/bxe/bxe_stats.c stable/7/sys/dev/bxe/ecore_reg.h stable/7/sys/dev/bxe/ecore_sp.h Directory Properties: stable/7/ (props changed) stable/7/sys/ (props changed) Modified: stable/7/sys/dev/bxe/bxe.c == --- stable/7/sys/dev/bxe/bxe.c Fri Sep 12 18:27:20 2014(r271478) +++ stable/7/sys/dev/bxe/bxe.c Fri Sep 12 18:31:44 2014(r271479) @@ -11488,6 +11488,10 @@ bxe_process_kill(struct bxe_softc *sc, bxe_process_kill_chip_reset(sc, global); mb(); +/* clear errors in PGB */ +if (!CHIP_IS_E1(sc)) +REG_WR(sc, PGLUE_B_REG_LATCHED_ERRORS_CLR, 0x7f); + /* Recover after reset: */ /* MCP */ if (global bxe_reset_mcp_comp(sc, val)) { Modified: stable/7/sys/dev/bxe/bxe.h == --- stable/7/sys/dev/bxe/bxe.h Fri Sep 12 18:27:20 2014(r271478) +++ stable/7/sys/dev/bxe/bxe.h Fri Sep 12 18:31:44 2014(r271479) @@ -2301,11 +2301,20 @@ void ecore_storm_memset_struct(struct bx } \ } while(0) +#ifdef ECORE_STOP_ON_ERROR + #define bxe_panic(sc, msg) \ do { \ panic msg; \ } while (0) +#else + +#define bxe_panic(sc, msg) \ +device_printf((sc)-dev, %s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#endif + #define CATC_TRIGGER(sc, data) REG_WR((sc), 0x2000, (data)); #define CATC_TRIGGER_START(sc) CATC_TRIGGER((sc), 0xcafecafe) Modified: stable/7/sys/dev/bxe/bxe_stats.c == --- stable/7/sys/dev/bxe/bxe_stats.cFri Sep 12 18:27:20 2014 (r271478) +++ stable/7/sys/dev/bxe/bxe_stats.cFri Sep 12 18:31:44 2014 (r271479) @@ -1306,7 +1306,10 @@ bxe_stats_update(struct bxe_softc *sc) if (bxe_storm_stats_update(sc)) { if (sc-stats_pending++ == 3) { -bxe_panic(sc, (storm stats not updated for 3 times\n)); + if (sc-ifnet-if_drv_flags IFF_DRV_RUNNING) { + atomic_store_rel_long(sc-chip_tq_flags, CHIP_TQ_REINIT); + taskqueue_enqueue(sc-chip_tq, sc-chip_tq_task); + } } return; } Modified: stable/7/sys/dev/bxe/ecore_reg.h == --- stable/7/sys/dev/bxe/ecore_reg.hFri Sep 12 18:27:20 2014 (r271478) +++ stable/7/sys/dev/bxe/ecore_reg.hFri Sep 12 18:31:44 2014 (r271479) @@ -1039,6 +1039,8 @@ __FBSDID($FreeBSD$); 0x942cUL #define PGLUE_B_REG_INTERNAL_PFID_ENABLE_TARGET_READ \ 0x9430UL +#define PGLUE_B_REG_LATCHED_ERRORS_CLR \ + 0x943CUL #define PGLUE_B_REG_PGLUE_B_INT_STS \ 0x9298UL #define PGLUE_B_REG_PGLUE_B_INT_STS_CLR \ Modified: stable/7/sys/dev/bxe/ecore_sp.h == --- stable/7/sys/dev/bxe/ecore_sp.h Fri Sep 12 18:27:20 2014 (r271478) +++ stable/7/sys/dev/bxe/ecore_sp.h Fri Sep 12 18:31:44 2014 (r271479) @@ -223,6 +223,8 @@ ECORE_CRC32_LE(uint32_t seed, uint8_t *m #define ecore_sp_post(_sc, _a, _b, _c, _d) \ bxe_sp_post(_sc, _a, _b, U64_HI(_c), U64_LO(_c), _d) +#ifdef ECORE_STOP_ON_ERROR + #define ECORE_DBG_BREAK_IF(exp) \ do {\ if (__predict_false(exp)) { \ @@ -242,6 +244,20 @@ ECORE_CRC32_LE(uint32_t seed, uint8_t *m }\ } while (0) +#else + +#define ECORE_DBG_BREAK_IF(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#define ECORE_BUG(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + +#define ECORE_BUG_ON(exp) \ +printf(%s (%s,%d)\n, __FUNCTION__, __FILE__, __LINE__); + + +#endif /* #ifdef ECORE_STOP_ON_ERROR */ + #define ECORE_ERR(str, ...) \ BLOGE(sc, ECORE: str, ##__VA_ARGS__) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271480 - head/release/scripts
Author: gjb Date: Fri Sep 12 18:52:01 2014 New Revision: 271480 URL: http://svnweb.freebsd.org/changeset/base/271480 Log: Set PKG_CACHEDIR to an 'All/' directory one level lower to fix 'pkg repo' generating repository metadata for the on-disc packages. MFC after:3 days X-MFC-to-10.1:yes Sponsored by: The FreeBSD Foundation Modified: head/release/scripts/pkg-stage.sh Modified: head/release/scripts/pkg-stage.sh == --- head/release/scripts/pkg-stage.sh Fri Sep 12 18:31:44 2014 (r271479) +++ head/release/scripts/pkg-stage.sh Fri Sep 12 18:52:01 2014 (r271480) @@ -44,7 +44,8 @@ PKG_ABI=$(pkg -vv | grep ^ABI | awk '{pr PKG_ABI=${PKG_ABI%\;} PKG_ABI=${PKG_ABI#\} export PKG_ABI -export PKG_CACHEDIR=dvd/packages/${PKG_ABI} +export PKG_REPODIR=dvd/packages/${PKG_ABI} +export PKG_CACHEDIR=${PKG_REPODIR}/${PKG_ABI}/All /bin/mkdir -p ${PKG_CACHEDIR} @@ -53,7 +54,7 @@ ${PKGCMD} -vv ${PKGCMD} update -f ${PKGCMD} fetch -d ${DVD_PACKAGES} -${PKGCMD} repo ${PKG_CACHEDIR} +${PKGCMD} repo ${PKG_REPODIR} # Always exit '0', even if pkg(8) complains about conflicts. exit 0 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271481 - stable/10/release
Author: gjb Date: Fri Sep 12 19:32:18 2014 New Revision: 271481 URL: http://svnweb.freebsd.org/changeset/base/271481 Log: Include the 'mini' (bootonly) UEFI memstick image in the list of IMAGES. This is a direct commit to stable/10. Approved by: re (marius) Sponsored by: The FreeBSD Foundation Modified: stable/10/release/Makefile Modified: stable/10/release/Makefile == --- stable/10/release/Makefile Fri Sep 12 18:52:01 2014(r271480) +++ stable/10/release/Makefile Fri Sep 12 19:32:18 2014(r271481) @@ -95,7 +95,9 @@ IMAGES+= mini-memstick.img .endif .if exists(${.CURDIR}/${TARGET}/make-uefi-memstick.sh) RELEASE_TARGETS+=uefi-memstick.img +RELEASE_TARGETS+=uefi-mini-memstick.img IMAGES+= uefi-memstick.img +IMAGES+= uefi-mini-memstick.img .endif .if exists(${.CURDIR}/${TARGET}/mkisoimages-uefi.sh) RELEASE_TARGETS+=uefi-disc1.iso @@ -265,6 +267,12 @@ uefi-memstick.img: system sh ${.CURDIR}/${TARGET}/make-uefi-memstick.sh release ${.TARGET} .endif +uefi-mini-memstick: uefi-mini-memstick.img +uefi-mini-memstick.img: system +.if exists(${.CURDIR}/${TARGET}/make-uefi-memstick.sh) + sh ${.CURDIR}/${TARGET}/make-uefi-memstick.sh bootonly ${.TARGET} +.endif + packagesystem: base.txz kernel.txz ${EXTRA_PACKAGES} sh ${.CURDIR}/scripts/make-manifest.sh *.txz MANIFEST touch ${.TARGET} ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r269964 - head/sys/kern
Hi guys, Both r269963 and r269964 have broken the MIPS platforms with smaller amounts of RAM ( 64MB.) Sean noticed it and filed a bug: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193465 Can we please figure out what changed? Otherwise I'm going to revert these two changes until we figure out what happened. Thanks, -a On 13 August 2014 22:31, Xin LI delp...@freebsd.org wrote: Author: delphij Date: Thu Aug 14 05:31:39 2014 New Revision: 269964 URL: http://svnweb.freebsd.org/changeset/base/269964 Log: Add a new loader tunable, vm.kmem_zmax which allows a system administrator to limit the maximum allocation size that malloc(9) would consider using the UMA cache allocator as backend. Suggested by: alfred MFC after:2 weeks Modified: head/sys/kern/kern_malloc.c Modified: head/sys/kern/kern_malloc.c == --- head/sys/kern/kern_malloc.c Thu Aug 14 05:13:24 2014(r269963) +++ head/sys/kern/kern_malloc.c Thu Aug 14 05:31:39 2014(r269964) @@ -172,6 +172,10 @@ u_long vm_kmem_size; SYSCTL_ULONG(_vm, OID_AUTO, kmem_size, CTLFLAG_RDTUN, vm_kmem_size, 0, Size of kernel memory); +static u_long kmem_zmax = KMEM_ZMAX; +SYSCTL_ULONG(_vm, OID_AUTO, kmem_zmax, CTLFLAG_RDTUN, kmem_zmax, 0, +Maximum allocation size that malloc(9) would use UMA as backend); + static u_long vm_kmem_size_min; SYSCTL_ULONG(_vm, OID_AUTO, kmem_size_min, CTLFLAG_RDTUN, vm_kmem_size_min, 0, Minimum size of kernel memory); @@ -485,7 +489,7 @@ malloc(unsigned long size, struct malloc size = redzone_size_ntor(size); #endif - if (size = KMEM_ZMAX) { + if (size = kmem_zmax) { mtip = mtp-ks_handle; if (size KMEM_ZMASK) size = (size ~KMEM_ZMASK) + KMEM_ZBASE; @@ -776,6 +780,9 @@ mallocinit(void *dummy) uma_startup2(); + if (kmem_zmax PAGE_SIZE || kmem_zmax KMEM_ZMAX) + kmem_zmax = KMEM_ZMAX; + mt_zone = uma_zcreate(mt_zone, sizeof(struct malloc_type_internal), #ifdef INVARIANTS mtrash_ctor, mtrash_dtor, mtrash_init, mtrash_fini, @@ -800,7 +807,7 @@ mallocinit(void *dummy) } for (;i = size; i+= KMEM_ZBASE) kmemsize[i KMEM_ZSHIFT] = indx; - + } } SYSINIT(kmem, SI_SUB_KMEM, SI_ORDER_SECOND, mallocinit, NULL); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271482 - head/usr.bin/mkimg
Author: marcel Date: Fri Sep 12 20:05:08 2014 New Revision: 271482 URL: http://svnweb.freebsd.org/changeset/base/271482 Log: Add support for adding empty partition entries. I.e. skip partition numbers or names. This gives more control over the actual layout and helps to construct BSD disklabels with /usr or /var at dedicated partitions. Obtained from:Juniper Networks, Inc. MFC after:3 days Relnotes: yes Modified: head/usr.bin/mkimg/mkimg.1 head/usr.bin/mkimg/mkimg.c Modified: head/usr.bin/mkimg/mkimg.1 == --- head/usr.bin/mkimg/mkimg.1 Fri Sep 12 19:32:18 2014(r271481) +++ head/usr.bin/mkimg/mkimg.1 Fri Sep 12 20:05:08 2014(r271482) @@ -24,7 +24,7 @@ .\ .\ $FreeBSD$ .\ -.Dd July 4, 2014 +.Dd September 12, 2014 .Dt MKIMG 1 .Os .Sh NAME @@ -171,6 +171,25 @@ utility as follows: .Dl % mkimg -s mbr -b /boot/mbr -p freebsd:-'mkimg -s bsd -b /boot/boot \ -p freebsd-ufs:=root-file-system.ufs -p freebsd-swap::1G' -o mbr-bsd.img .Pp +To accomodate the need to have partitions named or numbered in a certain +way, the +.Nm +utility allows for the specification of empty partitions. +For example, to create an image that is compatible with partition layouts +found in +.Pa /etc/disktab , +the 'd' partition often needs to be skipped. +This is accomplished by inserting an unused partition after the first 2 +partition specifications. +It is worth noting at this time that the BSD scheme will automatically +skip the 'c' partition by virtue of it referring to the entire disk. +To create an image that is compatible with the qp120at disk, use the +.Nm +utility as follows: +.Dl % mkimg -s bsd -b /boot/boot -p freebsd-ufs:=root-file-system.ufs \ +-p freebsd-swap::20M -p- -p- -p- -p- -p freebsd-ufs:=usr-file-system.ufs \ +-o bsd.img +.Pp For partitioning schemes that feature partition labels, the .Nm utility supports assigning labels to the partitions specified. Modified: head/usr.bin/mkimg/mkimg.c == --- head/usr.bin/mkimg/mkimg.c Fri Sep 12 19:32:18 2014(r271481) +++ head/usr.bin/mkimg/mkimg.c Fri Sep 12 20:05:08 2014(r271482) @@ -101,6 +101,7 @@ usage(const char *why) are determined\n\t\t\t\t by the named file\n); fprintf(stderr, \tt[/l]:-cmd\t- partition content and size are taken from\n\t\t\t\t the output of the command to run\n); + fprintf(stderr, \t-\t\t\t- unused partition entry\n); fprintf(stderr, \twhere:\n); fprintf(stderr, \t\tt\t- scheme neutral partition type\n); fprintf(stderr, \t\tl\t- optional scheme-dependent partition @@ -140,6 +141,9 @@ pwr_of_two(u_int nr) * '-' contents holds a command to run; the output of * which is the contents of the partition. * contents the specification of a partition's contents + * + * A specification that is a single dash indicates an unused partition + * entry. */ static int parse_part(const char *spec) @@ -149,6 +153,11 @@ parse_part(const char *spec) size_t len; int error; + if (strcmp(spec, -) == 0) { + nparts++; + return (0); + } + part = calloc(1, sizeof(struct part)); if (part == NULL) return (ENOMEM); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271483 - head/release/scripts
Author: gjb Date: Fri Sep 12 20:16:55 2014 New Revision: 271483 URL: http://svnweb.freebsd.org/changeset/base/271483 Log: Fix duplicate PKG_ABI in the PKG_CACHEDIR path. MFC after:3 days X-MFC-With: r271480 Sponsored by: The FreeBSD Foundation Modified: head/release/scripts/pkg-stage.sh Modified: head/release/scripts/pkg-stage.sh == --- head/release/scripts/pkg-stage.sh Fri Sep 12 20:05:08 2014 (r271482) +++ head/release/scripts/pkg-stage.sh Fri Sep 12 20:16:55 2014 (r271483) @@ -45,7 +45,7 @@ PKG_ABI=${PKG_ABI%\;} PKG_ABI=${PKG_ABI#\} export PKG_ABI export PKG_REPODIR=dvd/packages/${PKG_ABI} -export PKG_CACHEDIR=${PKG_REPODIR}/${PKG_ABI}/All +export PKG_CACHEDIR=${PKG_REPODIR}/All /bin/mkdir -p ${PKG_CACHEDIR} ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271484 - in head/sys/arm: arm xscale/ixp425
Author: jhb Date: Fri Sep 12 20:34:19 2014 New Revision: 271484 URL: http://svnweb.freebsd.org/changeset/base/271484 Log: - Don't let rman_reserve_resource() activate the resource in nexus_alloc_resource() and don't set a bushandle. nexus_activate_resource() will set a proper bushandle. - Implement a proper nexus_release_resource(). - Fix ixppcib_activate_resource() to call rman_activate_resource() before creating a mapping for the resource. Tested by:jmg Modified: head/sys/arm/arm/nexus.c head/sys/arm/xscale/ixp425/ixp425_pci.c Modified: head/sys/arm/arm/nexus.c == --- head/sys/arm/arm/nexus.cFri Sep 12 20:16:55 2014(r271483) +++ head/sys/arm/arm/nexus.cFri Sep 12 20:34:19 2014(r271484) @@ -90,6 +90,8 @@ static int nexus_config_intr(device_t de enum intr_polarity pol); static int nexus_deactivate_resource(device_t, device_t, int, int, struct resource *); +static int nexus_release_resource(device_t, device_t, int, int, +struct resource *); static int nexus_setup_intr(device_t dev, device_t child, struct resource *res, int flags, driver_filter_t *filt, driver_intr_t *intr, void *arg, void **cookiep); @@ -111,6 +113,7 @@ static device_method_t nexus_methods[] = DEVMETHOD(bus_activate_resource,nexus_activate_resource), DEVMETHOD(bus_config_intr, nexus_config_intr), DEVMETHOD(bus_deactivate_resource, nexus_deactivate_resource), + DEVMETHOD(bus_release_resource, nexus_release_resource), DEVMETHOD(bus_setup_intr, nexus_setup_intr), DEVMETHOD(bus_teardown_intr,nexus_teardown_intr), #ifdef FDT @@ -205,6 +208,8 @@ nexus_alloc_resource(device_t bus, devic struct rman *rm; int needactivate = flags RF_ACTIVE; + flags = ~RF_ACTIVE; + switch (type) { case SYS_RES_MEMORY: case SYS_RES_IOPORT: @@ -212,15 +217,14 @@ nexus_alloc_resource(device_t bus, devic break; default: - return (0); + return (NULL); } rv = rman_reserve_resource(rm, start, end, count, flags, child); if (rv == 0) - return (0); + return (NULL); rman_set_rid(rv, *rid); - rman_set_bushandle(rv, rman_get_start(rv)); if (needactivate) { if (bus_activate_resource(child, type, *rid, rv)) { @@ -233,6 +237,20 @@ nexus_alloc_resource(device_t bus, devic } static int +nexus_release_resource(device_t bus, device_t child, int type, int rid, +struct resource *res) +{ + int error; + + if (rman_get_flags(res) RF_ACTIVE) { + error = bus_deactivate_resource(child, type, rid, res); + if (error) + return (error); + } + return (rman_release_resource(res)); +} + +static int nexus_config_intr(device_t dev, int irq, enum intr_trigger trig, enum intr_polarity pol) { Modified: head/sys/arm/xscale/ixp425/ixp425_pci.c == --- head/sys/arm/xscale/ixp425/ixp425_pci.c Fri Sep 12 20:16:55 2014 (r271483) +++ head/sys/arm/xscale/ixp425/ixp425_pci.c Fri Sep 12 20:34:19 2014 (r271484) @@ -320,9 +320,12 @@ static int ixppcib_activate_resource(device_t bus, device_t child, int type, int rid, struct resource *r) { - struct ixppcib_softc *sc = device_get_softc(bus); + int error; + error = rman_activate_resource(r); + if (error) + return (error); switch (type) { case SYS_RES_IOPORT: rman_set_bustag(r, sc-sc_pci_iot); @@ -335,7 +338,7 @@ ixppcib_activate_resource(device_t bus, break; } - return (rman_activate_resource(r)); + return (0); } static int ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r271418 - head/sbin/dhclient
On Thursday, September 11, 2014 06:15:34 PM Hiroki Sato wrote: Andriy Gapon a...@freebsd.org wrote in 541163c0.2080...@freebsd.org: av On 11/09/2014 11:11, Robert Watson wrote: av A bit behind on commits, but: does this mean that an older userspace dhclient av will no longer work with a newer kernel? av av At least in my case it appeared to work. I guess this is because the broadcast av queries were not affected by the change. Only a unicast DHCPREQUEST sent from a DHCP client to renew the lease does not work. dhclient[N]: send_packet: Invalid argument log appears at certain interval due to it. A lease will expire, and it will repeatedly restart from the broadcast discovery phase. Ah, I've seen that for a while on my laptop. Thanks for tracking that down! -- John Baldwin ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r270759 - in head/sys: cddl/compat/opensolaris/kern cddl/compat/opensolaris/sys cddl/contrib/opensolaris/uts/common/fs/zfs vm
On Wednesday, September 10, 2014 11:29:21 PM Slawa Olhovchenkov wrote: On Wed, Sep 10, 2014 at 02:29:30PM -0400, John Baldwin wrote: Application must change behaviour when reach limit (run GC, switch algorithm and etc.). But mmap of big data file for scaning and processing don't touch this limit. Must be mmap of some temoprary file touch this limit? I don't know. Must be MAP_ANON touch this limit? I think yes. How to make distinction of mmap data file for processing and mmap temporary file for bypass this limit? I don't know. Consider also mmap() of shm_open(SHM_ANON). No, shm limited separatly. mmap of shm_open(SHM_ANON) don't need to adjust this limit. It would be another trivial way of escaping RLIMIT_DATA however. PS: question about jemalloc. How I can stop jemalloc to give back memory to OS for some application? You would have to hack pages_purge() in chunk_mmap.c to always return true and not call madvise(). And got memory leak? No, that doesn't leak memory. jemalloc() considers that address range free regardless and will always reuse it for a future allocation. This is just a hint to let the VM system take back the backing pages because they are currently not in use by the application, and if the address is reused, the current contents of the pages are not important (can be thrown away). I am talk about change behaviour from periodic mmap and madvise memory to only mmap when need and leave for future use when freed by aplication. I think (may be wrong -- please correct) in some cases mmap/madvise will be too often. The madvise() does not cause a future mmap(). You would have to munmap() to require a future mmap(). Instead, the madvise() can result in the page being released back to the system. Later when that address is reused by jemalloc, the process would fault on the address requiring the VM to locate a new page. Disabling the madvise() only prevents that fault from occurring (However, leaving all the pages around and marked as in-use may increase memory pressure and cause you to swap and still have to fault the page back in in the future, but at greater expense.) -- John Baldwin ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271485 - head/sys/dev/vt
Author: ray Date: Fri Sep 12 20:55:17 2014 New Revision: 271485 URL: http://svnweb.freebsd.org/changeset/base/271485 Log: Fix 'function declaration isn't a prototype' warning. Pointed by: ian MFC after:1 week Modified: head/sys/dev/vt/vt_core.c Modified: head/sys/dev/vt/vt_core.c == --- head/sys/dev/vt/vt_core.c Fri Sep 12 20:34:19 2014(r271484) +++ head/sys/dev/vt/vt_core.c Fri Sep 12 20:55:17 2014(r271485) @@ -162,7 +162,7 @@ static int vt_late_window_switch(struct static int vt_proc_alive(struct vt_window *); static void vt_resize(struct vt_device *); static void vt_update_static(void *); -static void vt_mouse_paste(); +static void vt_mouse_paste(void); SET_DECLARE(vt_drv_set, struct vt_driver); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271486 - head/sys/kern
Author: jhb Date: Fri Sep 12 20:56:09 2014 New Revision: 271486 URL: http://svnweb.freebsd.org/changeset/base/271486 Log: Simplify vntype_to_kinfo() by returning when the desired value is found instead of breaking out of the loop and then immediately checking the loop index so that if it was broken out of the proper value can be returned. While here, use nitems(). Modified: head/sys/kern/kern_descrip.c Modified: head/sys/kern/kern_descrip.c == --- head/sys/kern/kern_descrip.cFri Sep 12 20:55:17 2014 (r271485) +++ head/sys/kern/kern_descrip.cFri Sep 12 20:56:09 2014 (r271486) @@ -3531,17 +3531,14 @@ vntype_to_kinfo(int vtype) { VREG, KF_VTYPE_VREG }, { VSOCK, KF_VTYPE_VSOCK } }; -#defineNVTYPES (sizeof(vtypes_table) / sizeof(*vtypes_table)) unsigned int i; /* * Perform vtype translation. */ - for (i = 0; i NVTYPES; i++) + for (i = 0; i nitems(vtypes_table); i++) if (vtypes_table[i].vtype == vtype) - break; - if (i NVTYPES) - return (vtypes_table[i].kf_vtype); + return (vtypes_table[i].kf_vtype); return (KF_VTYPE_UNKNOWN); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271487 - head/sbin/sysctl
Author: jhb Date: Fri Sep 12 21:01:39 2014 New Revision: 271487 URL: http://svnweb.freebsd.org/changeset/base/271487 Log: Pass the length of an structure to the pretty-printer backends as a size_t instead of an int. Modified: head/sbin/sysctl/sysctl.c Modified: head/sbin/sysctl/sysctl.c == --- head/sbin/sysctl/sysctl.c Fri Sep 12 20:56:09 2014(r271486) +++ head/sbin/sysctl/sysctl.c Fri Sep 12 21:01:39 2014(r271487) @@ -458,12 +458,12 @@ parsefile(const char *filename) /* These functions will dump out various interesting structures. */ static int -S_clockinfo(int l2, void *p) +S_clockinfo(size_t l2, void *p) { struct clockinfo *ci = (struct clockinfo*)p; if (l2 != sizeof(*ci)) { - warnx(S_clockinfo %d != %zu, l2, sizeof(*ci)); + warnx(S_clockinfo %zu != %zu, l2, sizeof(*ci)); return (1); } printf(hflag ? { hz = %'d, tick = %'d, profhz = %'d, stathz = %'d } : @@ -473,12 +473,12 @@ S_clockinfo(int l2, void *p) } static int -S_loadavg(int l2, void *p) +S_loadavg(size_t l2, void *p) { struct loadavg *tv = (struct loadavg*)p; if (l2 != sizeof(*tv)) { - warnx(S_loadavg %d != %zu, l2, sizeof(*tv)); + warnx(S_loadavg %zu != %zu, l2, sizeof(*tv)); return (1); } printf(hflag ? { %'.2f %'.2f %'.2f } : { %.2f %.2f %.2f }, @@ -489,14 +489,14 @@ S_loadavg(int l2, void *p) } static int -S_timeval(int l2, void *p) +S_timeval(size_t l2, void *p) { struct timeval *tv = (struct timeval*)p; time_t tv_sec; char *p1, *p2; if (l2 != sizeof(*tv)) { - warnx(S_timeval %d != %zu, l2, sizeof(*tv)); + warnx(S_timeval %zu != %zu, l2, sizeof(*tv)); return (1); } printf(hflag ? { sec = %'jd, usec = %'ld } : @@ -513,13 +513,13 @@ S_timeval(int l2, void *p) } static int -S_vmtotal(int l2, void *p) +S_vmtotal(size_t l2, void *p) { struct vmtotal *v = (struct vmtotal *)p; int pageKilo = getpagesize() / 1024; if (l2 != sizeof(*v)) { - warnx(S_vmtotal %d != %zu, l2, sizeof(*v)); + warnx(S_vmtotal %zu != %zu, l2, sizeof(*v)); return (1); } @@ -540,19 +540,19 @@ S_vmtotal(int l2, void *p) v-t_vmshr * pageKilo, v-t_avmshr * pageKilo); printf(Shared Real Memory:\t(Total: %dK Active: %dK)\n, v-t_rmshr * pageKilo, v-t_armshr * pageKilo); - printf(Free Memory:\t%dK\n, v-t_free * pageKilo); + printf(Free Memory:\t%dK, v-t_free * pageKilo); return (0); } #if defined(__amd64__) || defined(__i386__) static int -S_bios_smap_xattr(int l2, void *p) +S_bios_smap_xattr(size_t l2, void *p) { struct bios_smap_xattr *smap, *end; if (l2 % sizeof(*smap) != 0) { - warnx(S_bios_smap_xattr %d is not a multiple of %zu, l2, + warnx(S_bios_smap_xattr %zu is not a multiple of %zu, l2, sizeof(*smap)); return (1); } @@ -680,7 +680,7 @@ show_var(int *oid, int nlen) size_t intlen; size_t j, len; u_int kind; - int (*func)(int, void *); + int (*func)(size_t, void *); /* Silence GCC. */ umv = mv = intlen = 0; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271488 - head/sys/kern
Author: jhb Date: Fri Sep 12 21:20:36 2014 New Revision: 271488 URL: http://svnweb.freebsd.org/changeset/base/271488 Log: Tweak pipe_truncate() to more closely match pipe_chown() and pipe_chmod() by checking PIPE_NAMED and using invfo_truncate() for unnamed pipes. Modified: head/sys/kern/sys_pipe.c Modified: head/sys/kern/sys_pipe.c == --- head/sys/kern/sys_pipe.cFri Sep 12 21:01:39 2014(r271487) +++ head/sys/kern/sys_pipe.cFri Sep 12 21:20:36 2014(r271488) @@ -1324,11 +1324,15 @@ pipe_truncate(fp, length, active_cred, t struct ucred *active_cred; struct thread *td; { + struct pipe *cpipe; + int error; - /* For named pipes call the vnode operation. */ - if (fp-f_vnode != NULL) - return (vnops.fo_truncate(fp, length, active_cred, td)); - return (EINVAL); + cpipe = fp-f_data; + if (cpipe-pipe_state PIPE_NAMED) + error = vnops.fo_truncate(fp, length, active_cred, td); + else + error = invfo_truncate(fp, length, active_cred, td); + return (error); } /* ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r271480 - head/release/scripts
On 9/12/2014 1:52 PM, Glen Barber wrote: Author: gjb Date: Fri Sep 12 18:52:01 2014 New Revision: 271480 URL: http://svnweb.freebsd.org/changeset/base/271480 Log: Set PKG_CACHEDIR to an 'All/' directory one level lower to fix 'pkg repo' generating repository metadata for the on-disc packages. MFC after: 3 days X-MFC-to-10.1: yes Sponsored by: The FreeBSD Foundation Modified: head/release/scripts/pkg-stage.sh Modified: head/release/scripts/pkg-stage.sh == --- head/release/scripts/pkg-stage.sh Fri Sep 12 18:31:44 2014 (r271479) +++ head/release/scripts/pkg-stage.sh Fri Sep 12 18:52:01 2014 (r271480) @@ -44,7 +44,8 @@ PKG_ABI=$(pkg -vv | grep ^ABI | awk '{pr PKG_ABI=${PKG_ABI%\;} PKG_ABI=${PKG_ABI#\} export PKG_ABI -export PKG_CACHEDIR=dvd/packages/${PKG_ABI} +export PKG_REPODIR=dvd/packages/${PKG_ABI} +export PKG_CACHEDIR=${PKG_REPODIR}/${PKG_ABI}/All /bin/mkdir -p ${PKG_CACHEDIR} @@ -53,7 +54,7 @@ ${PKGCMD} -vv ${PKGCMD} update -f ${PKGCMD} fetch -d ${DVD_PACKAGES} -${PKGCMD} repo ${PKG_CACHEDIR} +${PKGCMD} repo ${PKG_REPODIR} # Always exit '0', even if pkg(8) complains about conflicts. exit 0 There's still an issue with 1.3 here. pkg-fetch now uses mangled package names in its cache dir, and does not use the All/ subdir anymore as you've found. # ls /var/cache/pkg/psutils-1.17_4* /var/cache/pkg/psutils-1.17_4-fe318c25d7.txz /var/cache/pkg/psutils-1.17_4.txz@ Rather the polluting the DVD with these hashed filenames you can just not set PKG_CACHEDIR and use pkg fetch -o ${PKG_REPODIR} -d ${DVD_PACKAGES}. You can also now simplify the PKG_ABI lookup 4 lines to just: export PKG_ABI=$(pkg config ABI). pkg fetch -o was added to 1.3 specifically for cases such as creating DVDs. It will then store the files in dvd/packages/${PKG_ABI}/All. See https://people.freebsd.org/~bdrewery/patches/pkg-stage-1.3.diff -- Regards, Bryan Drewery signature.asc Description: OpenPGP digital signature
svn commit: r271489 - in head/sys: kern ofed/include/linux opencrypto sys
Author: jhb Date: Fri Sep 12 21:29:10 2014 New Revision: 271489 URL: http://svnweb.freebsd.org/changeset/base/271489 Log: Fix various issues with invalid file operations: - Add invfo_rdwr() (for read and write), invfo_ioctl(), invfo_poll(), and invfo_kqfilter() for use by file types that do not support the respective operations. Home-grown versions of invfo_poll() were universally broken (they returned an errno value, invfo_poll() uses poll_no_poll() to return an appropriate event mask). Home-grown ioctl routines also tended to return an incorrect errno (invfo_ioctl returns ENOTTY). - Use the invfo_*() functions instead of local versions for unsupported file operations. - Reorder fileops members to match the order in the structure definition to make it easier to spot missing members. - Add several missing methods to linuxfileops used by the OFED shim layer: fo_write(), fo_truncate(), fo_kqfilter(), and fo_stat(). Most of these used invfo_*(), but a dummy fo_stat() implementation was added. Modified: head/sys/kern/kern_descrip.c head/sys/kern/kern_event.c head/sys/kern/sys_procdesc.c head/sys/kern/tty_pts.c head/sys/kern/uipc_mqueue.c head/sys/kern/uipc_sem.c head/sys/kern/uipc_shm.c head/sys/ofed/include/linux/linux_compat.c head/sys/opencrypto/cryptodev.c head/sys/sys/file.h Modified: head/sys/kern/kern_descrip.c == --- head/sys/kern/kern_descrip.cFri Sep 12 21:20:36 2014 (r271488) +++ head/sys/kern/kern_descrip.cFri Sep 12 21:29:10 2014 (r271489) @@ -3941,6 +3941,14 @@ struct fileops badfileops = { }; int +invfo_rdwr(struct file *fp, struct uio *uio, struct ucred *active_cred, +int flags, struct thread *td) +{ + + return (EOPNOTSUPP); +} + +int invfo_truncate(struct file *fp, off_t length, struct ucred *active_cred, struct thread *td) { @@ -3949,6 +3957,29 @@ invfo_truncate(struct file *fp, off_t le } int +invfo_ioctl(struct file *fp, u_long com, void *data, +struct ucred *active_cred, struct thread *td) +{ + + return (ENOTTY); +} + +int +invfo_poll(struct file *fp, int events, struct ucred *active_cred, +struct thread *td) +{ + + return (poll_no_poll(events)); +} + +int +invfo_kqfilter(struct file *fp, struct knote *kn) +{ + + return (EINVAL); +} + +int invfo_chmod(struct file *fp, mode_t mode, struct ucred *active_cred, struct thread *td) { Modified: head/sys/kern/kern_event.c == --- head/sys/kern/kern_event.c Fri Sep 12 21:20:36 2014(r271488) +++ head/sys/kern/kern_event.c Fri Sep 12 21:29:10 2014(r271489) @@ -109,9 +109,6 @@ static void kqueue_wakeup(struct kqueue static struct filterops *kqueue_fo_find(int filt); static voidkqueue_fo_release(int filt); -static fo_rdwr_t kqueue_read; -static fo_rdwr_t kqueue_write; -static fo_truncate_t kqueue_truncate; static fo_ioctl_t kqueue_ioctl; static fo_poll_t kqueue_poll; static fo_kqfilter_t kqueue_kqfilter; @@ -119,9 +116,9 @@ static fo_stat_tkqueue_stat; static fo_close_t kqueue_close; static struct fileops kqueueops = { - .fo_read = kqueue_read, - .fo_write = kqueue_write, - .fo_truncate = kqueue_truncate, + .fo_read = invfo_rdwr, + .fo_write = invfo_rdwr, + .fo_truncate = invfo_truncate, .fo_ioctl = kqueue_ioctl, .fo_poll = kqueue_poll, .fo_kqfilter = kqueue_kqfilter, @@ -1602,35 +1599,6 @@ done_nl: return (error); } -/* - * XXX - * This could be expanded to call kqueue_scan, if desired. - */ -/*ARGSUSED*/ -static int -kqueue_read(struct file *fp, struct uio *uio, struct ucred *active_cred, - int flags, struct thread *td) -{ - return (ENXIO); -} - -/*ARGSUSED*/ -static int -kqueue_write(struct file *fp, struct uio *uio, struct ucred *active_cred, -int flags, struct thread *td) -{ - return (ENXIO); -} - -/*ARGSUSED*/ -static int -kqueue_truncate(struct file *fp, off_t length, struct ucred *active_cred, - struct thread *td) -{ - - return (EINVAL); -} - /*ARGSUSED*/ static int kqueue_ioctl(struct file *fp, u_long cmd, void *data, Modified: head/sys/kern/sys_procdesc.c == --- head/sys/kern/sys_procdesc.cFri Sep 12 21:20:36 2014 (r271488) +++ head/sys/kern/sys_procdesc.cFri Sep 12 21:29:10 2014 (r271489) @@ -87,28 +87,22 @@ FEATURE(process_descriptors, Process De static uma_zone_t procdesc_zone; -static fo_rdwr_t procdesc_read; -static fo_rdwr_t procdesc_write; -static fo_truncate_t procdesc_truncate; -static fo_ioctl_t procdesc_ioctl; static fo_poll_t procdesc_poll; static fo_kqfilter_t procdesc_kqfilter; static
Re: svn commit: r271489 - in head/sys: kern ofed/include/linux opencrypto sys
On Friday, September 12, 2014 09:29:11 PM John Baldwin wrote: Author: jhb Date: Fri Sep 12 21:29:10 2014 New Revision: 271489 URL: http://svnweb.freebsd.org/changeset/base/271489 Log: Fix various issues with invalid file operations: - Add invfo_rdwr() (for read and write), invfo_ioctl(), invfo_poll(), and invfo_kqfilter() for use by file types that do not support the respective operations. Home-grown versions of invfo_poll() were universally broken (they returned an errno value, invfo_poll() uses poll_no_poll() to return an appropriate event mask). Home-grown ioctl routines also tended to return an incorrect errno (invfo_ioctl returns ENOTTY). - Use the invfo_*() functions instead of local versions for unsupported file operations. - Reorder fileops members to match the order in the structure definition to make it easier to spot missing members. - Add several missing methods to linuxfileops used by the OFED shim layer: fo_write(), fo_truncate(), fo_kqfilter(), and fo_stat(). Most of these used invfo_*(), but a dummy fo_stat() implementation was added. For this last, if you managed to get a handle to one of these file descriptors using any of the associated system calls (write(), fstat(), etc.) would trigger an instant-panic. I don't think that non-root users can get to these descriptors however. -- John Baldwin ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271490 - head/sys/dev/cxgbe
Author: np Date: Fri Sep 12 21:56:57 2014 New Revision: 271490 URL: http://svnweb.freebsd.org/changeset/base/271490 Log: cxgbe(4): add support for the SIOCGI2C ioctl. Modified: head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgbe/t4_main.c == --- head/sys/dev/cxgbe/t4_main.cFri Sep 12 21:29:10 2014 (r271489) +++ head/sys/dev/cxgbe/t4_main.cFri Sep 12 21:56:57 2014 (r271490) @@ -1378,6 +1378,31 @@ fail: ifmedia_ioctl(ifp, ifr, pi-media, cmd); break; + case SIOCGI2C: { + struct ifi2creq i2c; + + rc = copyin(ifr-ifr_data, i2c, sizeof(i2c)); + if (rc != 0) + break; + if (i2c.dev_addr != 0xA0 i2c.dev_addr != 0xA2) { + rc = EPERM; + break; + } + if (i2c.len sizeof(i2c.data)) { + rc = EINVAL; + break; + } + rc = begin_synchronized_op(sc, pi, SLEEP_OK | INTR_OK, t4i2c); + if (rc) + return (rc); + rc = -t4_i2c_rd(sc, sc-mbox, pi-port_id, i2c.dev_addr, + i2c.offset, i2c.len, i2c.data[0]); + end_synchronized_op(sc, 0); + if (rc == 0) + rc = copyout(i2c, ifr-ifr_data, sizeof(i2c)); + break; + } + default: rc = ether_ioctl(ifp, cmd, data); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271491 - head/release/scripts
Author: gjb Date: Fri Sep 12 22:20:07 2014 New Revision: 271491 URL: http://svnweb.freebsd.org/changeset/base/271491 Log: Simplify dvd package population with pkg-1.3. Submitted by: bdrewery MFC after:3 days X-MFC-With: r271480, r271483 Sponsored by: The FreeBSD Foundation Modified: head/release/scripts/pkg-stage.sh Modified: head/release/scripts/pkg-stage.sh == --- head/release/scripts/pkg-stage.sh Fri Sep 12 21:56:57 2014 (r271490) +++ head/release/scripts/pkg-stage.sh Fri Sep 12 22:20:07 2014 (r271491) @@ -40,19 +40,15 @@ if [ ! -x /usr/local/sbin/pkg ]; then /usr/bin/make -C /usr/ports/ports-mgmt/pkg install clean fi -PKG_ABI=$(pkg -vv | grep ^ABI | awk '{print $3}') -PKG_ABI=${PKG_ABI%\;} -PKG_ABI=${PKG_ABI#\} -export PKG_ABI +export PKG_ABI=$(pkg config ABI) export PKG_REPODIR=dvd/packages/${PKG_ABI} -export PKG_CACHEDIR=${PKG_REPODIR}/All -/bin/mkdir -p ${PKG_CACHEDIR} +/bin/mkdir -p ${PKG_REPODIR} # Print pkg(8) information to make debugging easier. ${PKGCMD} -vv ${PKGCMD} update -f -${PKGCMD} fetch -d ${DVD_PACKAGES} +${PKGCMD} fetch -o ${PKG_REPODIR} -d ${DVD_PACKAGES} ${PKGCMD} repo ${PKG_REPODIR} ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r271480 - head/release/scripts
On Fri, Sep 12, 2014 at 04:21:26PM -0500, Bryan Drewery wrote: There's still an issue with 1.3 here. pkg-fetch now uses mangled package names in its cache dir, and does not use the All/ subdir anymore as you've found. # ls /var/cache/pkg/psutils-1.17_4* /var/cache/pkg/psutils-1.17_4-fe318c25d7.txz /var/cache/pkg/psutils-1.17_4.txz@ Rather the polluting the DVD with these hashed filenames you can just not set PKG_CACHEDIR and use pkg fetch -o ${PKG_REPODIR} -d ${DVD_PACKAGES}. Ah, I overlooked '-o' in 1.3.x. You can also now simplify the PKG_ABI lookup 4 lines to just: export PKG_ABI=$(pkg config ABI). pkg fetch -o was added to 1.3 specifically for cases such as creating DVDs. It will then store the files in dvd/packages/${PKG_ABI}/All. See https://people.freebsd.org/~bdrewery/patches/pkg-stage-1.3.diff Thank you. Committed as r271491. Glen pgpWbX3JwRC3E.pgp Description: PGP signature
svn commit: r271492 - head/sys/dev/usb/serial
Author: hselasky Date: Fri Sep 12 22:40:12 2014 New Revision: 271492 URL: http://svnweb.freebsd.org/changeset/base/271492 Log: Workaround for receiving Voice Calls using the E1750 dongle from Huawei. It might appear as if the firmware is allocating memory blocks according to the USB transfer size and if there is initially a lot of data, like at the answering machine prompt, it simply dies without any apparent reason. The simple workaround for this is to force a zero length packet at hardware level after every 512 bytes of data. This will force the other side to use smaller memory blocks aswell. MFC after:1 week Modified: head/sys/dev/usb/serial/u3g.c Modified: head/sys/dev/usb/serial/u3g.c == --- head/sys/dev/usb/serial/u3g.c Fri Sep 12 22:20:07 2014 (r271491) +++ head/sys/dev/usb/serial/u3g.c Fri Sep 12 22:40:12 2014 (r271492) @@ -75,6 +75,8 @@ SYSCTL_INT(_hw_usb_u3g, OID_AUTO, debug, #defineU3G_MAXPORTS12 #defineU3G_CONFIG_INDEX0 #defineU3G_BSIZE 2048 +#defineU3G_TXSIZE (U3G_BSIZE / U3G_TXFRAMES) +#defineU3G_TXFRAMES4 /* Eject methods; See also usb_quirks.h:UQ_MSC_EJECT_* */ #defineU3GINIT_HUAWEI 1 /* Requires Huawei init command */ @@ -145,6 +147,7 @@ static const struct usb_config u3g_confi .endpoint = UE_ADDR_ANY, .direction = UE_DIR_OUT, .bufsize = U3G_BSIZE,/* bytes */ + .frames = U3G_TXFRAMES, .flags = {.pipe_bof = 1,.force_short_xfer = 1,}, .callback = u3g_write_callback, }, @@ -1011,14 +1014,22 @@ u3g_write_callback(struct usb_xfer *xfer struct ucom_softc *ucom = usbd_xfer_softc(xfer); struct usb_page_cache *pc; uint32_t actlen; + uint32_t frame; switch (USB_GET_STATE(xfer)) { case USB_ST_TRANSFERRED: case USB_ST_SETUP: tr_setup: - pc = usbd_xfer_get_frame(xfer, 0); - if (ucom_get_data(ucom, pc, 0, U3G_BSIZE, actlen)) { - usbd_xfer_set_frame_len(xfer, 0, actlen); + for (frame = 0; frame != U3G_TXFRAMES; frame++) { + usbd_xfer_set_frame_offset(xfer, frame * U3G_TXSIZE, frame); + + pc = usbd_xfer_get_frame(xfer, frame); + if (ucom_get_data(ucom, pc, 0, U3G_TXSIZE, actlen) == 0) + break; + usbd_xfer_set_frame_len(xfer, frame, actlen); + } + if (frame != 0) { + usbd_xfer_set_frames(xfer, frame); usbd_transfer_submit(xfer); } break; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271493 - in head: contrib/hyperv contrib/hyperv/tools contrib/hyperv/tools/scripts etc/mtree etc/rc.d libexec libexec/hyperv share/mk sys/conf sys/dev/hyperv/include sys/dev/hyperv/uti...
Author: delphij Date: Sat Sep 13 02:15:31 2014 New Revision: 271493 URL: http://svnweb.freebsd.org/changeset/base/271493 Log: Import HyperV Key-Value Pair (KVP) driver and daemon code by Microsoft, many thanks for their continued support of FreeBSD. While I'm there, also implement a new build knob, WITHOUT_HYPERV to disable building and installing of the HyperV utilities when necessary. The HyperV utilities are only built for i386 and amd64 targets. This is a stable/10 candidate for inclusion with 10.1-RELEASE. Submitted by: Wei Hu weh microsoft com MFC after:1 week Added: head/contrib/hyperv/ head/contrib/hyperv/tools/ head/contrib/hyperv/tools/hv_kvp_daemon.8 (contents, props changed) head/contrib/hyperv/tools/hv_kvp_daemon.c (contents, props changed) head/contrib/hyperv/tools/scripts/ head/contrib/hyperv/tools/scripts/hv_get_dhcp_info head/contrib/hyperv/tools/scripts/hv_get_dns_info head/contrib/hyperv/tools/scripts/hv_set_ifconfig head/etc/rc.d/hv_kvpd (contents, props changed) head/libexec/hyperv/ head/libexec/hyperv/Makefile (contents, props changed) head/sys/dev/hyperv/utilities/hv_kvp.c (contents, props changed) head/sys/dev/hyperv/utilities/unicode.h (contents, props changed) head/tools/build/options/WITHOUT_HYPERV (contents, props changed) head/tools/build/options/WITH_HYPERV (contents, props changed) head/usr.sbin/hyperv/ head/usr.sbin/hyperv/Makefile (contents, props changed) head/usr.sbin/hyperv/Makefile.inc (contents, props changed) head/usr.sbin/hyperv/tools/ head/usr.sbin/hyperv/tools/Makefile (contents, props changed) Modified: head/etc/mtree/BSD.usr.dist head/etc/mtree/BSD.var.dist head/etc/rc.d/Makefile head/libexec/Makefile head/share/mk/src.opts.mk head/sys/conf/files.amd64 head/sys/conf/files.i386 head/sys/dev/hyperv/include/hyperv.h head/sys/dev/hyperv/utilities/hv_kvp.h head/sys/dev/hyperv/utilities/hv_util.c head/sys/modules/hyperv/utilities/Makefile head/tools/build/mk/OptionalObsoleteFiles.inc head/usr.sbin/Makefile.amd64 head/usr.sbin/Makefile.i386 Added: head/contrib/hyperv/tools/hv_kvp_daemon.8 == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/hyperv/tools/hv_kvp_daemon.8 Sat Sep 13 02:15:31 2014 (r271493) @@ -0,0 +1,68 @@ +.\ Copyright (c) 2014 Microsoft Corp. +.\ All rights reserved. +.\ +.\ Redistribution and use in source and binary forms, with or without +.\ modification, are permitted provided that the following conditions +.\ are met: +.\ 1. Redistributions of source code must retain the above copyright +.\notice, this list of conditions and the following disclaimer. +.\ 2. Redistributions in binary form must reproduce the above copyright +.\notice, this list of conditions and the following disclaimer in the +.\documentation and/or other materials provided with the distribution. +.\ +.\ THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\ ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\ OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\ HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\ SUCH DAMAGE. +.\ +.Dd September 10, 2013 +.Dt HYPER-V 4 +.Os +.Sh NAME +.Nm hv_kvp_daemon +.Nd Hyper-V Key Value Pair Daemon +.Sh SYNOPSIS +The \fBhv_kvp_daemon\fP daemon provides the ability to store, retrieve, modify and delete +Key Value pairs for FreeBSD guest partitions running on Hyper-V. +.Sh DESCRIPTION +Hyper-V allows administrators to store custom metadata in the form +of Key Value pairs inside the FreeBSD guest partition. Administrators can +use Windows Powershell scripts to add, read, modify and delete such +Key Value pairs. + +The \fBhv_kvp_daemon\fP accepts Key Value pair management requests from the +\fBhv_utils\fP driver and performs the actual metadata management on the file-system. + +The same daemon and driver combination is also used to set and get +IP addresses from a FreeBSD guest. + +The set functionality is particularly +useful when the FreeBSD guest is assigned a static IP address and is failed +over from one Hyper-V host to another. After failover, Hyper-V uses the set IP +functionality to automatically +update the FreeBSD guest's IP address to its original static value. + +On the other hand, the get IP functionality is used to update the guest IP
svn commit: r271494 - head/share/man/man5
Author: delphij Date: Sat Sep 13 02:18:54 2014 New Revision: 271494 URL: http://svnweb.freebsd.org/changeset/base/271494 Log: Regen. Modified: head/share/man/man5/src.conf.5 Modified: head/share/man/man5/src.conf.5 == --- head/share/man/man5/src.conf.5 Sat Sep 13 02:15:31 2014 (r271493) +++ head/share/man/man5/src.conf.5 Sat Sep 13 02:18:54 2014 (r271494) @@ -1,7 +1,7 @@ .\ DO NOT EDIT-- this file is automatically generated. .\ from FreeBSD: head/tools/build/options/makeman 255964 2013-10-01 07:22:04Z des .\ $FreeBSD$ -.Dd September 10, 2014 +.Dd September 12, 2014 .Dt SRC.CONF 5 .Os .Sh NAME @@ -522,6 +522,18 @@ Set to build Hesiod support. .It Va WITHOUT_HTML .\ from FreeBSD: head/tools/build/options/WITHOUT_HTML 156932 2006-03-21 07:50:50Z ru Set to not build HTML docs. +.It Va WITHOUT_HYPERV +.\ from FreeBSD: head/tools/build/options/WITHOUT_HYPERV 271493 2014-09-13 02:15:31Z delphij +Set to not build or install HyperV utilities. +.Pp +It is a default setting on +arm/arm, arm/armeb, arm/armv6, arm/armv6hf, mips/mipsel, mips/mips, mips/mips64el, mips/mips64, mips/mipsn32, powerpc/powerpc, powerpc/powerpc64 and sparc64/sparc64. +.It Va WITH_HYPERV +.\ from FreeBSD: head/tools/build/options/WITH_HYPERV 271493 2014-09-13 02:15:31Z delphij +Set to build and install HyperV utilities. +.Pp +It is a default setting on +amd64/amd64, i386/i386 and pc98/i386. .It Va WITHOUT_ICONV .\ from FreeBSD: head/tools/build/options/WITHOUT_ICONV 254919 2013-08-26 17:15:56Z antoine Set to not build iconv as part of libc. ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271495 - in head: sbin/sysctl sys/amd64/amd64
Author: jhb Date: Sat Sep 13 03:10:02 2014 New Revision: 271495 URL: http://svnweb.freebsd.org/changeset/base/271495 Log: Add a sysctl to export the EFI memory map along with a handler in the sysctl(8) binary to format it. Reviewed by: emaste MFC after:2 weeks Differential Revision:https://reviews.freebsd.org/D771 Modified: head/sbin/sysctl/sysctl.c head/sys/amd64/amd64/machdep.c Modified: head/sbin/sysctl/sysctl.c == --- head/sbin/sysctl/sysctl.c Sat Sep 13 02:18:54 2014(r271494) +++ head/sbin/sysctl/sysctl.c Sat Sep 13 03:10:02 2014(r271495) @@ -48,6 +48,11 @@ static const char rcsid[] = #include sys/sysctl.h #include sys/vmmeter.h +#ifdef __amd64__ +#include sys/efi.h +#include machine/metadata.h +#endif + #if defined(__amd64__) || defined(__i386__) #include machine/pc/bios.h #endif @@ -545,6 +550,91 @@ S_vmtotal(size_t l2, void *p) return (0); } +#ifdef __amd64__ +#define efi_next_descriptor(ptr, size) \ + ((struct efi_md *)(((uint8_t *) ptr) + size)) + +static int +S_efi_map(size_t l2, void *p) +{ + struct efi_map_header *efihdr; + struct efi_md *map; + const char *type; + size_t efisz; + int ndesc, i; + + static const char *types[] = { + Reserved, + LoaderCode, + LoaderData, + BootServicesCode, + BootServicesData, + RuntimeServicesCode, + RuntimeServicesData, + ConventionalMemory, + UnusableMemory, + ACPIReclaimMemory, + ACPIMemoryNVS, + MemoryMappedIO, + MemoryMappedIOPortSpace, + PalCode + }; + + /* +* Memory map data provided by UEFI via the GetMemoryMap +* Boot Services API. +*/ + if (l2 sizeof(*efihdr)) { + warnx(S_efi_map length less than header); + return (1); + } + efihdr = p; + efisz = (sizeof(struct efi_map_header) + 0xf) ~0xf; + map = (struct efi_md *)((uint8_t *)efihdr + efisz); + + if (efihdr-descriptor_size == 0) + return (0); + if (l2 != efisz + efihdr-memory_size) { + warnx(S_efi_map length mismatch %zu vs %zu, l2, efisz + + efihdr-memory_size); + return (1); + } + ndesc = efihdr-memory_size / efihdr-descriptor_size; + + printf(\n%23s %12s %12s %8s %4s, + Type, Physical, Virtual, #Pages, Attr); + + for (i = 0; i ndesc; i++, + map = efi_next_descriptor(map, efihdr-descriptor_size)) { + if (map-md_type = EFI_MD_TYPE_PALCODE) + type = types[map-md_type]; + else + type = INVALID; + printf(\n%23s %012lx %12p %08lx , type, map-md_phys, + map-md_virt, map-md_pages); + if (map-md_attr EFI_MD_ATTR_UC) + printf(UC ); + if (map-md_attr EFI_MD_ATTR_WC) + printf(WC ); + if (map-md_attr EFI_MD_ATTR_WT) + printf(WT ); + if (map-md_attr EFI_MD_ATTR_WB) + printf(WB ); + if (map-md_attr EFI_MD_ATTR_UCE) + printf(UCE ); + if (map-md_attr EFI_MD_ATTR_WP) + printf(WP ); + if (map-md_attr EFI_MD_ATTR_RP) + printf(RP ); + if (map-md_attr EFI_MD_ATTR_XP) + printf(XP ); + if (map-md_attr EFI_MD_ATTR_RT) + printf(RUNTIME); + } + return (0); +} +#endif + #if defined(__amd64__) || defined(__i386__) static int S_bios_smap_xattr(size_t l2, void *p) @@ -818,6 +908,10 @@ show_var(int *oid, int nlen) func = S_loadavg; else if (strcmp(fmt, S,vmtotal) == 0) func = S_vmtotal; +#ifdef __amd64__ + else if (strcmp(fmt, S,efi_map_header) == 0) + func = S_efi_map; +#endif #if defined(__amd64__) || defined(__i386__) else if (strcmp(fmt, S,bios_smap_xattr) == 0) func = S_bios_smap_xattr; Modified: head/sys/amd64/amd64/machdep.c == --- head/sys/amd64/amd64/machdep.c Sat Sep 13 02:18:54 2014 (r271494) +++ head/sys/amd64/amd64/machdep.c Sat Sep 13 03:10:02 2014 (r271495) @@ -2124,6 +2124,26 @@ smap_sysctl_handler(SYSCTL_HANDLER_ARGS) SYSCTL_PROC(_machdep, OID_AUTO, smap, CTLTYPE_OPAQUE|CTLFLAG_RD, NULL, 0, smap_sysctl_handler, S,bios_smap_xattr, Raw BIOS SMAP data); +static int +efi_map_sysctl_handler(SYSCTL_HANDLER_ARGS) +{ +
Re: svn commit: r271495 - in head: sbin/sysctl sys/amd64/amd64
On 12 September 2014 23:10, John Baldwin j...@freebsd.org wrote: Author: jhb Date: Sat Sep 13 03:10:02 2014 New Revision: 271495 URL: http://svnweb.freebsd.org/changeset/base/271495 Log: Add a sysctl to export the EFI memory map along with a handler in the sysctl(8) binary to format it. The output (from QEMU in this case) looks like: root@:~ # sysctl machdep.efi_map machdep.efi_map: Type Physical Virtual #Pages Attr ConventionalMemory 0x0 00a0 UC WC WT WB ConventionalMemory 0010 0x0 0720 UC WC WT WB BootServicesData 0082 0x0 07e0 UC WC WT WB ConventionalMemory 0100 0x0 3000 UC WC WT WB BootServicesData 0400 0x0 0020 UC WC WT WB ConventionalMemory 0402 0x0 088a UC WC WT WB LoaderData 048aa000 0x0 2200 UC WC WT WB LoaderCode 06aaa000 0x0 004a UC WC WT WB LoaderData 06af4000 0x0 004c UC WC WT WB LoaderCode 06b4 0x0 000f UC WC WT WB ConventionalMemory 06b4f000 0x0 000c UC WC WT WB LoaderData 06b5b000 0x0 0005 UC WC WT WB BootServicesData 06b6 0x0 018c UC WC WT WB BootServicesCode 06cec000 0x0 0150 UC WC WT WB RuntimeServicesData 06e3c000 0x0 0012 UC WC WT WB RUNTIME BootServicesData 06e4e000 0x0 0f00 UC WC WT WB BootServicesCode 07d4e000 0x0 0180 UC WC WT WB RuntimeServicesCode 07ece000 0x0 0030 UC WC WT WB RUNTIME RuntimeServicesData 07efe000 0x0 0024 UC WC WT WB RUNTIME Reserved 07f22000 0x0 0004 UC WC WT WB ACPIReclaimMemory 07f26000 0x0 0008 UC WC WT WB ACPIMemoryNVS 07f2e000 0x0 0004 UC WC WT WB BootServicesData 07f32000 0x0 009e UC WC WT WB RuntimeServicesData 07fd 0x0 0030 UC WC WT WB RUNTIME ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r269964 - head/sys/kern
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 On 9/13/14 3:41 AM, Adrian Chadd wrote: Hi guys, Both r269963 and r269964 have broken the MIPS platforms with smaller amounts of RAM ( 64MB.) Sean noticed it and filed a bug: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193465 Can we please figure out what changed? Otherwise I'm going to revert these two changes until we figure out what happened. Could you please try if this would mitigate the issue? Index: sys/kern/kern_malloc.c === - --- sys/kern/kern_malloc.c (revision 271494) +++ sys/kern/kern_malloc.c (working copy) @@ -717,6 +717,8 @@ kmeminit(void) * a given architecture. */ mem_size = vm_cnt.v_page_count; + if (mem_size = 32768) /* delphij XXX 128MB */ + kmem_zmax = PAGE_SIZE; if (vm_kmem_size_scale 1) vm_kmem_size_scale = VM_KMEM_SIZE_SCALE; Thanks, -a On 13 August 2014 22:31, Xin LI delp...@freebsd.org wrote: Author: delphij Date: Thu Aug 14 05:31:39 2014 New Revision: 269964 URL: http://svnweb.freebsd.org/changeset/base/269964 Log: Add a new loader tunable, vm.kmem_zmax which allows a system administrator to limit the maximum allocation size that malloc(9) would consider using the UMA cache allocator as backend. Suggested by: alfred MFC after:2 weeks Modified: head/sys/kern/kern_malloc.c Modified: head/sys/kern/kern_malloc.c == - --- head/sys/kern/kern_malloc.c Thu Aug 14 05:13:24 2014(r269963) +++ head/sys/kern/kern_malloc.c Thu Aug 14 05:31:39 2014 (r269964) @@ -172,6 +172,10 @@ u_long vm_kmem_size; SYSCTL_ULONG(_vm, OID_AUTO, kmem_size, CTLFLAG_RDTUN, vm_kmem_size, 0, Size of kernel memory); +static u_long kmem_zmax = KMEM_ZMAX; +SYSCTL_ULONG(_vm, OID_AUTO, kmem_zmax, CTLFLAG_RDTUN, kmem_zmax, 0, +Maximum allocation size that malloc(9) would use UMA as backend); + static u_long vm_kmem_size_min; SYSCTL_ULONG(_vm, OID_AUTO, kmem_size_min, CTLFLAG_RDTUN, vm_kmem_size_min, 0, Minimum size of kernel memory); @@ -485,7 +489,7 @@ malloc(unsigned long size, struct malloc size = redzone_size_ntor(size); #endif - if (size = KMEM_ZMAX) { + if (size = kmem_zmax) { mtip = mtp-ks_handle; if (size KMEM_ZMASK) size = (size ~KMEM_ZMASK) + KMEM_ZBASE; @@ -776,6 +780,9 @@ mallocinit(void *dummy) uma_startup2(); + if (kmem_zmax PAGE_SIZE || kmem_zmax KMEM_ZMAX) + kmem_zmax = KMEM_ZMAX; + mt_zone = uma_zcreate(mt_zone, sizeof(struct malloc_type_internal), #ifdef INVARIANTS mtrash_ctor, mtrash_dtor, mtrash_init, mtrash_fini, @@ -800,7 +807,7 @@ mallocinit(void *dummy) } for (;i = size; i+= KMEM_ZBASE) kmemsize[i KMEM_ZSHIFT] = indx; - + } } SYSINIT(kmem, SI_SUB_KMEM, SI_ORDER_SECOND, mallocinit, NULL); -BEGIN PGP SIGNATURE- iQIcBAEBCgAGBQJUE8bBAAoJEJW2GBstM+nsxp8P+gLu9St6tQsTeSy2nWIe3wKY PIvkntSRxPFnHFyHnaeSqdwpi1+7vVyb2kmy3fj/HYEvyiBwZf1mw4akOxUTjlo2 nTSISdnn07rACrnQXOxrc9gd0PDETbWzZuAZ5gOA5Y/REQ6DVl6nZUrtaBhzfuZr OoQilpXTuP4n82tjl3OufjdN8ObcAlGigrjgjOxLL/deUfW5zktdkgrPSuFbtYYj d5ERr2J48tTul0VnVBbeo7AfE082l/TKynnPJiKeJRhaE0oUVVlT2tkJjZz//E3k Rw5dRdn0ptXroo88Pk/HdwxZi1eOTv2RJyz7zYIH9N8YLSZFNhGnrXbXbH6PFGqV 3cGaYIfiq4OTtSaY0nxjdRRllm/Alm0r9JSTw99nzCpW8G/QI5544znmNNZ52bCF /Z/HNCVLWChzd4rQ4f8PWwjn06vCYhLGWFEH0DBdTRMRxCtBLDDyTBhePBebh7dc RNFTG+1gPQSNXIPMBa/UU9YLqdXBqYYpD53qYKjYxovR3Yp1ZpjwsV1S2ehC4rFM 33+Rma7zVKkTaPsX9GTL4PhqWHyMXfUGbMD3VawAGAVxsJvDUgjVkWyTgWgfeZDi AXq19g79MoGX5sDS1bGx24d9Yy8gEI6nQ0z0hvJSE3g/29+3JnlNgP6537vpSJTo 5+cK52wxY4fKff+Txr/Y =mOQe -END PGP SIGNATURE- ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r271496 - head/share/examples/bhyve
Author: rodrigc Date: Sat Sep 13 05:08:35 2014 New Revision: 271496 URL: http://svnweb.freebsd.org/changeset/base/271496 Log: Propagate the error status of /usr/sbin/bhyve out of the vmrun.sh script. Clean up the /dev/vmm entry for this VM when vmrun.sh exits. Reviewed by: neel Phabric: D767 Modified: head/share/examples/bhyve/vmrun.sh Modified: head/share/examples/bhyve/vmrun.sh == --- head/share/examples/bhyve/vmrun.sh Sat Sep 13 03:10:02 2014 (r271495) +++ head/share/examples/bhyve/vmrun.sh Sat Sep 13 05:08:35 2014 (r271496) @@ -204,7 +204,8 @@ while [ 1 ]; do ${LOADER} -c ${console} -m ${memsize} -d ${BOOTDISK} ${loader_opt} \ ${vmname} - if [ $? -ne 0 ]; then + bhyve_exit=$? + if [ $bhyve_exit -ne 0 ]; then break fi @@ -239,6 +240,7 @@ while [ 1 ]; do ${installer_opt}\ ${vmname} + bhyve_exit=$? # bhyve returns the following status codes: # 0 - VM has been reset # 1 - VM has been powered off @@ -246,9 +248,18 @@ while [ 1 ]; do # 3 - VM generated a triple fault # all other non-zero status codes are errors # - if [ $? -ne 0 ]; then + if [ $bhyve_exit -ne 0 ]; then break fi done -exit 99 + +case $bhyve_exit in + 0|1|2) + # Cleanup /dev/vmm entry when bhyve did not exit + # due to an error. + ${BHYVECTL} --vm=${vmname} --destroy /dev/null 21 + ;; +esac + +exit $bhyve_exit ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r269964 - head/sys/kern
Xin Li wrote this message on Sat, Sep 13, 2014 at 12:23 +0800: -BEGIN PGP SIGNED MESSAGE- Hash: SHA512 On 9/13/14 3:41 AM, Adrian Chadd wrote: Hi guys, Both r269963 and r269964 have broken the MIPS platforms with smaller amounts of RAM ( 64MB.) Sean noticed it and filed a bug: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193465 Can we please figure out what changed? Otherwise I'm going to revert these two changes until we figure out what happened. Could you please try if this would mitigate the issue? Index: sys/kern/kern_malloc.c === - --- sys/kern/kern_malloc.c (revision 271494) +++ sys/kern/kern_malloc.c (working copy) @@ -717,6 +717,8 @@ kmeminit(void) * a given architecture. */ mem_size = vm_cnt.v_page_count; + if (mem_size = 32768) /* delphij XXX 128MB */ + kmem_zmax = PAGE_SIZE; if (vm_kmem_size_scale 1) vm_kmem_size_scale = VM_KMEM_SIZE_SCALE; Has more research been done on this? My 64MB AVILA board boots fine, and ath attaches fine... I can't test if ath works yet since I can't find my antennas... FreeBSD 11.0-CURRENT #35 r271408M: Wed Sep 10 14:42:46 PDT 2014 j...@carbon.funkthat.com:/usr/obj/arm.armeb/usr/src.avila/sys/AVILA arm gcc version 4.2.1 20070831 patched [FreeBSD] CPU: IXP425 266MHz rev 1 (ARMv5TE) (XScale core) Big-endian DC enabled IC enabled WB enabled LABT branch prediction enabled 32KB/32B 32-way instruction cache 32KB/32B 32-way write-back-locking data cache real memory = 67104768 (63 MB) avail memory = 58843136 (56 MB) random: Software, Yarrow initialized ixp0: Intel IXP4XX ixp0: 37603RCOMP,USB,ETH0,ETH1,PCI pcib0: IXP4XX PCI Bus on ixp0 pci0: PCI bus on pcib0 ath0: Atheros 9220 irq 27 at device 2.0 on pci0 ath0: AR9220 mac 128.2 RF5133 phy 13.0 ath0: 2GHz radio: 0x; 5GHz radio: 0x00c0 [...] -- John-Mark Gurney Voice: +1 415 225 5579 All that I will do, has been done, All that I have, has not. ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org