svn commit: r262150 - head/release/picobsd/floppy.tree/etc
Author: luigi Date: Tue Feb 18 04:38:26 2014 New Revision: 262150 URL: http://svnweb.freebsd.org/changeset/base/262150 Log: enable rfc1323 and rfc1644 by default in picobsd images. I disabled it some 15 years ago but it is useful to have them on when doing tcp throughput tests. Modified: head/release/picobsd/floppy.tree/etc/rc.conf (contents, props changed) Modified: head/release/picobsd/floppy.tree/etc/rc.conf == --- head/release/picobsd/floppy.tree/etc/rc.confTue Feb 18 04:27:41 2014(r262149) +++ head/release/picobsd/floppy.tree/etc/rc.confTue Feb 18 04:38:26 2014(r262150) @@ -1,6 +1,8 @@ # Sample rc.conf file for PicoBSD # you should mostly set variables here, see rc.conf.defaults. +tcp_extensions=YES # enable rfc1323 and rfc1644 + case ${hostname} in *) echo "processing rc.conf for ${hostname}" ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262149 - head/sys/dev/netmap
Author: luigi Date: Tue Feb 18 04:27:41 2014 New Revision: 262149 URL: http://svnweb.freebsd.org/changeset/base/262149 Log: two small changes: - intercept FIONBIO and FIOASYNC ioctls on netmap file descriptors. libpcap calls them to set non blocking I/O on the file descriptor, for netmap this is a no-op because there is no read/write, but not intercepting would cause fcntl() to return -1 - rate limit and put under netmap.verbose some messages that occur when threads use concurrently the same file descriptor. Modified: head/sys/dev/netmap/netmap.c Modified: head/sys/dev/netmap/netmap.c == --- head/sys/dev/netmap/netmap.cTue Feb 18 03:42:49 2014 (r262148) +++ head/sys/dev/netmap/netmap.cTue Feb 18 04:27:41 2014 (r262149) @@ -137,6 +137,7 @@ ports attached to the switch) #include /* defines used in kernel.h */ #include /* types used in module initialization */ #include /* cdevsw struct, UID, GID */ +#include /* FIONBIO */ #include #include /* struct socket */ #include @@ -1827,6 +1828,11 @@ netmap_ioctl(struct cdev *dev, u_long cm break; #ifdef __FreeBSD__ + case FIONBIO: + case FIOASYNC: + ND("FIONBIO/FIOASYNC are no-ops"); + break; + case BIOCIMMEDIATE: case BIOCGHDRCMPLT: case BIOCSHDRCMPLT: @@ -2002,7 +2008,9 @@ flush_tx: continue; /* only one thread does txsync */ if (nm_kr_tryget(kring)) { - D("%p lost race on txring %d, ok", priv, i); + if (netmap_verbose) + RD(2, "%p lost race on txring %d, ok", + priv, i); continue; } if (nm_txsync_prologue(kring) >= kring->nkr_num_slots) { @@ -2049,7 +2057,9 @@ do_retry_rx: kring = &na->rx_rings[i]; if (nm_kr_tryget(kring)) { - D("%p lost race on rxring %d, ok", priv, i); + if (netmap_verbose) + RD(2, "%p lost race on rxring %d, ok", + priv, i); continue; } ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262144 - head/sys/amd64/vmm/intel
Author: jhb Date: Tue Feb 18 03:07:36 2014 New Revision: 262144 URL: http://svnweb.freebsd.org/changeset/base/262144 Log: A first pass at adding support for injecting hardware exceptions for emulated instructions. - Add helper routines to inject interrupt information for a hardware exception from the VM exit callback routines. - Use the new routines to inject GP and UD exceptions for invalid operations when emulating the xsetbv instruction. - Don't directly manipulate the entry interrupt info when a user event is injected. Instead, store the event info in the vmx state and only apply it during a VM entry if a hardware exception or NMI is not already pending. - While here, use HANDLED/UNHANDLED instead of 1/0 in a couple of routines. Reviewed by: neel Modified: head/sys/amd64/vmm/intel/vmcs.h head/sys/amd64/vmm/intel/vmx.c head/sys/amd64/vmm/intel/vmx.h Modified: head/sys/amd64/vmm/intel/vmcs.h == --- head/sys/amd64/vmm/intel/vmcs.h Tue Feb 18 03:00:20 2014 (r262143) +++ head/sys/amd64/vmm/intel/vmcs.h Tue Feb 18 03:07:36 2014 (r262144) @@ -345,6 +345,8 @@ vmcs_write(uint32_t encoding, uint64_t v #defineVMCS_INTR_T_MASK0x700 /* Interruption-info type */ #defineVMCS_INTR_T_HWINTR (0 << 8) #defineVMCS_INTR_T_NMI (2 << 8) +#defineVMCS_INTR_T_HWEXCEPTION (3 << 8) +#defineVMCS_INTR_DEL_ERRCODE (1 << 11) /* * VMCS IDT-Vectoring information fields Modified: head/sys/amd64/vmm/intel/vmx.c == --- head/sys/amd64/vmm/intel/vmx.c Tue Feb 18 03:00:20 2014 (r262143) +++ head/sys/amd64/vmm/intel/vmx.c Tue Feb 18 03:07:36 2014 (r262144) @@ -884,6 +884,7 @@ vmx_vminit(struct vm *vm, pmap_t pmap) vmx->state[i].lastcpu = -1; vmx->state[i].vpid = vpid[i]; + vmx->state[i].user_event.intr_info = 0; msr_save_area_init(vmx->guest_msrs[i], &guest_msr_count); @@ -1062,6 +1063,66 @@ vmx_clear_nmi_window_exiting(struct vmx VMCS_INTERRUPTIBILITY_MOVSS_BLOCKING) static void +vmx_inject_user_event(struct vmx *vmx, int vcpu) +{ + struct vmxevent *user_event; + uint32_t info; + + user_event = &vmx->state[vcpu].user_event; + + info = vmcs_read(VMCS_ENTRY_INTR_INFO); + KASSERT((info & VMCS_INTR_VALID) == 0, ("vmx_inject_user_event: invalid " + "VM-entry interruption information %#x", info)); + + vmcs_write(VMCS_ENTRY_INTR_INFO, user_event->intr_info); + if (user_event->intr_info & VMCS_INTR_DEL_ERRCODE) + vmcs_write(VMCS_ENTRY_EXCEPTION_ERROR, user_event->error_code); + user_event->intr_info = 0; +} + +static void +vmx_inject_exception(struct vmx *vmx, int vcpu, struct vm_exit *vmexit, +int fault, int errvalid, int errcode) +{ + uint32_t info; + + info = vmcs_read(VMCS_ENTRY_INTR_INFO); + KASSERT((info & VMCS_INTR_VALID) == 0, ("vmx_inject_exception: invalid " + "VM-entry interruption information %#x", info)); + + /* +* Although INTR_T_HWEXCEPTION does not advance %rip, vmx_run() +* always advances it, so we clear the instruction length to zero +* explicitly. +*/ + vmexit->inst_length = 0; + info = fault | VMCS_INTR_T_HWEXCEPTION | VMCS_INTR_VALID; + if (errvalid) { + info |= VMCS_INTR_DEL_ERRCODE; + vmcs_write(VMCS_ENTRY_EXCEPTION_ERROR, errcode); + } + vmcs_write(VMCS_ENTRY_INTR_INFO, info); + + VCPU_CTR2(vmx->vm, vcpu, "Injecting fault %d (errcode %d)", fault, + errcode); +} + +/* All GP# faults VMM injects use an error code of 0. */ +static void +vmx_inject_gp(struct vmx *vmx, int vcpu, struct vm_exit *vmexit) +{ + + vmx_inject_exception(vmx, vcpu, vmexit, IDT_GP, 1, 0); +} + +static void +vmx_inject_ud(struct vmx *vmx, int vcpu, struct vm_exit *vmexit) +{ + + vmx_inject_exception(vmx, vcpu, vmexit, IDT_UD, 0, 0); +} + +static void vmx_inject_nmi(struct vmx *vmx, int vcpu) { uint32_t gi, info; @@ -1126,6 +1187,24 @@ vmx_inject_interrupts(struct vmx *vmx, i vmx_set_nmi_window_exiting(vmx, vcpu); } + /* +* If there is a user injection event pending and there isn't +* an interrupt queued already, inject the user event. +*/ + if (vmx->state[vcpu].user_event.intr_info & VMCS_INTR_VALID) { + info = vmcs_read(VMCS_ENTRY_INTR_INFO); + if ((info & VMCS_INTR_VALID) == 0) { + vmx_inject_user_event(vmx, vcpu); + } else { + /* +* XXX: Do we need to force an exit so this can +* be inj
svn commit: r262143 - head/usr.sbin/bhyve
Author: jhb Date: Tue Feb 18 03:00:20 2014 New Revision: 262143 URL: http://svnweb.freebsd.org/changeset/base/262143 Log: Tweak the handling of PCI capabilities in emulated devices to remove the non-standard zero capability list terminator. Instead, track the start and end of the most recently added capability and use that to adjust the previous capability's next pointer when a capability is added and to determine the range of config registers belonging to PCI capability registers. Reviewed by: neel Modified: head/usr.sbin/bhyve/pci_emul.c head/usr.sbin/bhyve/pci_emul.h Modified: head/usr.sbin/bhyve/pci_emul.c == --- head/usr.sbin/bhyve/pci_emul.c Tue Feb 18 01:20:26 2014 (r262142) +++ head/usr.sbin/bhyve/pci_emul.c Tue Feb 18 03:00:20 2014 (r262143) @@ -630,48 +630,39 @@ pci_emul_alloc_pbar(struct pci_devinst * static int pci_emul_add_capability(struct pci_devinst *pi, u_char *capdata, int caplen) { - int i, capoff, capid, reallen; + int i, capoff, reallen; uint16_t sts; - static u_char endofcap[4] = { - PCIY_RESERVED, 0, 0, 0 - }; - - assert(caplen > 0 && capdata[0] != PCIY_RESERVED); + assert(caplen > 0); reallen = roundup2(caplen, 4); /* dword aligned */ sts = pci_get_cfgdata16(pi, PCIR_STATUS); - if ((sts & PCIM_STATUS_CAPPRESENT) == 0) { + if ((sts & PCIM_STATUS_CAPPRESENT) == 0) capoff = CAP_START_OFFSET; - pci_set_cfgdata8(pi, PCIR_CAP_PTR, capoff); - pci_set_cfgdata16(pi, PCIR_STATUS, sts|PCIM_STATUS_CAPPRESENT); - } else { - capoff = pci_get_cfgdata8(pi, PCIR_CAP_PTR); - while (1) { - assert((capoff & 0x3) == 0); - capid = pci_get_cfgdata8(pi, capoff); - if (capid == PCIY_RESERVED) - break; - capoff = pci_get_cfgdata8(pi, capoff + 1); - } - } + else + capoff = pi->pi_capend + 1; /* Check if we have enough space */ - if (capoff + reallen + sizeof(endofcap) > PCI_REGMAX + 1) + if (capoff + reallen > PCI_REGMAX + 1) return (-1); + /* Set the previous capability pointer */ + if ((sts & PCIM_STATUS_CAPPRESENT) == 0) { + pci_set_cfgdata8(pi, PCIR_CAP_PTR, capoff); + pci_set_cfgdata16(pi, PCIR_STATUS, sts|PCIM_STATUS_CAPPRESENT); + } else + pci_set_cfgdata8(pi, pi->pi_prevcap + 1, capoff); + /* Copy the capability */ for (i = 0; i < caplen; i++) pci_set_cfgdata8(pi, capoff + i, capdata[i]); /* Set the next capability pointer */ - pci_set_cfgdata8(pi, capoff + 1, capoff + reallen); - - /* Copy of the reserved capability which serves as the end marker */ - for (i = 0; i < sizeof(endofcap); i++) - pci_set_cfgdata8(pi, capoff + reallen + i, endofcap[i]); + pci_set_cfgdata8(pi, capoff + 1, 0); + pi->pi_prevcap = capoff; + pi->pi_capend = capoff + reallen - 1; return (0); } @@ -756,7 +747,7 @@ pci_emul_add_msicap(struct pci_devinst * static void pci_populate_msixcap(struct msixcap *msixcap, int msgnum, int barnum, -uint32_t msix_tab_size, int nextptr) +uint32_t msix_tab_size) { CTASSERT(sizeof(struct msixcap) == 12); @@ -764,7 +755,6 @@ pci_populate_msixcap(struct msixcap *msi bzero(msixcap, sizeof(struct msixcap)); msixcap->capid = PCIY_MSIX; - msixcap->nextptr = nextptr; /* * Message Control Register, all fields set to @@ -826,7 +816,7 @@ pci_emul_add_msixcap(struct pci_devinst pci_msix_table_init(pi, msgnum); - pci_populate_msixcap(&msixcap, msgnum, barnum, tab_size, 0); + pci_populate_msixcap(&msixcap, msgnum, barnum, tab_size); /* allocate memory for MSI-X Table and PBA */ pci_emul_alloc_bar(pi, barnum, PCIBAR_MEM32, @@ -949,11 +939,9 @@ pci_emul_capwrite(struct pci_devinst *pi /* Find the capability that we want to update */ capoff = CAP_START_OFFSET; while (1) { - capid = pci_get_cfgdata8(pi, capoff); - if (capid == PCIY_RESERVED) - break; - nextoff = pci_get_cfgdata8(pi, capoff + 1); + if (nextoff == 0) + break; if (offset >= capoff && offset < nextoff) break; @@ -976,6 +964,7 @@ pci_emul_capwrite(struct pci_devinst *pi return; } + capid = pci_get_cfgdata8(pi, capoff); switch (capid) { case PCIY_MSI: msicap_cfgwrite(pi, capoff, offset, bytes, val); @@ -994,25 +983,14
svn commit: r262142 - head/sys/dev/usb/net
Author: rodrigc Date: Tue Feb 18 01:20:26 2014 New Revision: 262142 URL: http://svnweb.freebsd.org/changeset/base/262142 Log: In ue_attach_post_task(), initialize curvnet to vnet0 before calling if_attach(). Before this patch, curvnet was NULL. When the VIMAGE kernel option is enabled, this eliminates kernel panics when USB ethernet devices are plugged in. PR: 183835 Submitted by: Hiroo Oono Modified: head/sys/dev/usb/net/usb_ethernet.c Modified: head/sys/dev/usb/net/usb_ethernet.c == --- head/sys/dev/usb/net/usb_ethernet.c Tue Feb 18 01:15:32 2014 (r262141) +++ head/sys/dev/usb/net/usb_ethernet.c Tue Feb 18 01:20:26 2014 (r262142) @@ -208,6 +208,7 @@ ue_attach_post_task(struct usb_proc_msg sysctl_ctx_init(&ue->ue_sysctl_ctx); error = 0; + CURVNET_SET_QUIET(vnet0); ifp = if_alloc(IFT_ETHER); if (ifp == NULL) { device_printf(ue->ue_dev, "could not allocate ifnet\n"); @@ -254,6 +255,8 @@ ue_attach_post_task(struct usb_proc_msg if (ifp->if_capabilities & IFCAP_VLAN_MTU) ifp->if_hdrlen = sizeof(struct ether_vlan_header); + CURVNET_RESTORE(); + snprintf(num, sizeof(num), "%u", ue->ue_unit); ue->ue_sysctl_oid = SYSCTL_ADD_NODE(&ue->ue_sysctl_ctx, &SYSCTL_NODE_CHILDREN(_net, ue), @@ -267,6 +270,7 @@ ue_attach_post_task(struct usb_proc_msg return; fail: + CURVNET_RESTORE(); free_unr(ueunit, ue->ue_unit); if (ue->ue_ifp != NULL) { if_free(ue->ue_ifp); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262140 - head/sys/amd64/vmm/io
Author: neel Date: Mon Feb 17 23:07:16 2014 New Revision: 262140 URL: http://svnweb.freebsd.org/changeset/base/262140 Log: Handle writes to the SELF_IPI MSR by the guest when the vlapic is configured in x2apic mode. Reads to this MSR are currently ignored but should cause a general proctection exception to be injected into the vcpu. All accesses to the corresponding offset in xAPIC mode are ignored. Also, do not panic the host if there is mismatch between the trigger mode programmed in the TMR and the actual interrupt being delivered. Instead the anomaly is logged to aid debugging and to prevent a misbehaving guest from panicking the host. Modified: head/sys/amd64/vmm/io/vlapic.c head/sys/amd64/vmm/io/vlapic_priv.h Modified: head/sys/amd64/vmm/io/vlapic.c == --- head/sys/amd64/vmm/io/vlapic.c Mon Feb 17 22:57:51 2014 (r262139) +++ head/sys/amd64/vmm/io/vlapic.c Mon Feb 17 23:07:16 2014 (r262140) @@ -289,9 +289,11 @@ vlapic_set_intr_ready(struct vlapic *vla * the vlapic TMR registers. */ tmrptr = &lapic->tmr0; - KASSERT((tmrptr[idx] & mask) == (level ? mask : 0), - ("vlapic TMR[%d] is 0x%08x but interrupt is %s-triggered", - idx / 4, tmrptr[idx], level ? "level" : "edge")); + if ((tmrptr[idx] & mask) != (level ? mask : 0)) { + VLAPIC_CTR3(vlapic, "vlapic TMR[%d] is 0x%08x but " + "interrupt is %s-triggered", idx / 4, tmrptr[idx], + level ? "level" : "edge"); + } VLAPIC_CTR_IRR(vlapic, "vlapic_set_intr_ready"); return (1); @@ -997,6 +999,18 @@ vlapic_icrlo_write_handler(struct vlapic return (1); } +static void +vlapic_self_ipi_handler(struct vlapic *vlapic, uint64_t val) +{ + int vec; + + vec = val & 0xff; + lapic_intr_edge(vlapic->vm, vlapic->vcpuid, vec); + vmm_stat_array_incr(vlapic->vm, vlapic->vcpuid, IPIS_SENT, + vlapic->vcpuid, 1); + VLAPIC_CTR1(vlapic, "vlapic self-ipi %d", vec); +} + int vlapic_pending_intr(struct vlapic *vlapic, int *vecptr) { @@ -1190,6 +1204,12 @@ vlapic_read(struct vlapic *vlapic, uint6 case APIC_OFFSET_TIMER_DCR: *data = lapic->dcr_timer; break; + case APIC_OFFSET_SELF_IPI: + /* +* XXX generate a GP fault if vlapic is in x2apic mode +*/ + *data = 0; + break; case APIC_OFFSET_RRR: default: *data = 0; @@ -1270,6 +1290,12 @@ vlapic_write(struct vlapic *vlapic, uint case APIC_OFFSET_ESR: vlapic_esr_write_handler(vlapic); break; + + case APIC_OFFSET_SELF_IPI: + if (x2apic(vlapic)) + vlapic_self_ipi_handler(vlapic, data); + break; + case APIC_OFFSET_VER: case APIC_OFFSET_APR: case APIC_OFFSET_PPR: Modified: head/sys/amd64/vmm/io/vlapic_priv.h == --- head/sys/amd64/vmm/io/vlapic_priv.h Mon Feb 17 22:57:51 2014 (r262139) +++ head/sys/amd64/vmm/io/vlapic_priv.h Mon Feb 17 23:07:16 2014 (r262140) @@ -81,6 +81,7 @@ #define APIC_OFFSET_TIMER_ICR 0x380 /* Timer's Initial Count*/ #define APIC_OFFSET_TIMER_CCR 0x390 /* Timer's Current Count*/ #define APIC_OFFSET_TIMER_DCR 0x3E0 /* Timer's Divide Configuration */ +#defineAPIC_OFFSET_SELF_IPI0x3F0 /* Self IPI register */ #defineVLAPIC_CTR0(vlapic, format) \ VCPU_CTR0((vlapic)->vm, (vlapic)->vcpuid, format) @@ -91,6 +92,9 @@ #defineVLAPIC_CTR2(vlapic, format, p1, p2) \ VCPU_CTR2((vlapic)->vm, (vlapic)->vcpuid, format, p1, p2) +#defineVLAPIC_CTR3(vlapic, format, p1, p2, p3) \ + VCPU_CTR3((vlapic)->vm, (vlapic)->vcpuid, format, p1, p2, p3) + #defineVLAPIC_CTR_IRR(vlapic, msg) \ do { \ uint32_t *irrptr = &(vlapic)->apic_page->irr0; \ ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262139 - head/sys/amd64/vmm/io
Author: neel Date: Mon Feb 17 22:57:51 2014 New Revision: 262139 URL: http://svnweb.freebsd.org/changeset/base/262139 Log: Use spinlocks to lock accesses to the vioapic. This is necessary because if the vlapic is configured in x2apic mode the vioapic_process_eoi() function is called inside the critical section established by vm_run(). Modified: head/sys/amd64/vmm/io/vioapic.c Modified: head/sys/amd64/vmm/io/vioapic.c == --- head/sys/amd64/vmm/io/vioapic.c Mon Feb 17 22:43:07 2014 (r262138) +++ head/sys/amd64/vmm/io/vioapic.c Mon Feb 17 22:57:51 2014 (r262139) @@ -64,8 +64,8 @@ struct vioapic { } rtbl[REDIR_ENTRIES]; }; -#defineVIOAPIC_LOCK(vioapic) mtx_lock(&((vioapic)->mtx)) -#defineVIOAPIC_UNLOCK(vioapic) mtx_unlock(&((vioapic)->mtx)) +#defineVIOAPIC_LOCK(vioapic) mtx_lock_spin(&((vioapic)->mtx)) +#defineVIOAPIC_UNLOCK(vioapic) mtx_unlock_spin(&((vioapic)->mtx)) #defineVIOAPIC_LOCKED(vioapic) mtx_owned(&((vioapic)->mtx)) static MALLOC_DEFINE(M_VIOAPIC, "vioapic", "bhyve virtual ioapic"); @@ -476,7 +476,7 @@ vioapic_init(struct vm *vm) vioapic = malloc(sizeof(struct vioapic), M_VIOAPIC, M_WAITOK | M_ZERO); vioapic->vm = vm; - mtx_init(&vioapic->mtx, "vioapic lock", NULL, MTX_DEF); + mtx_init(&vioapic->mtx, "vioapic lock", NULL, MTX_SPIN); /* Initialize all redirection entries to mask all interrupts */ for (i = 0; i < REDIR_ENTRIES; i++) ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262135 - in head/libexec: fingerd rbootd
Author: brueffer Date: Mon Feb 17 22:26:21 2014 New Revision: 262135 URL: http://svnweb.freebsd.org/changeset/base/262135 Log: Add $FreeBSD$. MFC after:1 week Modified: head/libexec/fingerd/pathnames.h head/libexec/rbootd/pathnames.h head/libexec/rbootd/rmp.h head/libexec/rbootd/rmp_var.h Modified: head/libexec/fingerd/pathnames.h == --- head/libexec/fingerd/pathnames.hMon Feb 17 22:19:49 2014 (r262134) +++ head/libexec/fingerd/pathnames.hMon Feb 17 22:26:21 2014 (r262135) @@ -31,6 +31,8 @@ * SUCH DAMAGE. * * @(#)pathnames.h 8.1 (Berkeley) 6/4/93 + * + * $FreeBSD$ */ #define_PATH_FINGER"/usr/bin/finger" Modified: head/libexec/rbootd/pathnames.h == --- head/libexec/rbootd/pathnames.h Mon Feb 17 22:19:49 2014 (r262134) +++ head/libexec/rbootd/pathnames.h Mon Feb 17 22:26:21 2014 (r262135) @@ -42,6 +42,8 @@ * * From: Utah Hdr: pathnames.h 3.1 92/07/06 * Author: Jeff Forys, University of Utah CSS + * + * $FreeBSD$ */ #define_PATH_BPF "/dev/bpf%d" Modified: head/libexec/rbootd/rmp.h == --- head/libexec/rbootd/rmp.h Mon Feb 17 22:19:49 2014(r262134) +++ head/libexec/rbootd/rmp.h Mon Feb 17 22:26:21 2014(r262135) @@ -42,6 +42,8 @@ * * From: Utah Hdr: rmp.h 3.1 92/07/06 * Author: Jeff Forys, University of Utah CSS + * + * $FreeBSD$ */ /* Modified: head/libexec/rbootd/rmp_var.h == --- head/libexec/rbootd/rmp_var.h Mon Feb 17 22:19:49 2014 (r262134) +++ head/libexec/rbootd/rmp_var.h Mon Feb 17 22:26:21 2014 (r262135) @@ -42,6 +42,8 @@ * * from: Utah Hdr: rmp_var.h 3.1 92/07/06 * Author: Jeff Forys, University of Utah CSS + * + * $FreeBSD$ */ /* ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r262051 - head/cddl/contrib/opensolaris/cmd/zpool
On Tuesday 18 February 2014 02:07:06 Bruce Evans wrote: > On Mon, 17 Feb 2014, Mark Felder wrote: > > Log: > > Fix formatting. > > > > "Manpages should start a new sentence on a new line. This makes it easier > > for translators to track changes." -jhb > > This has very little to do with translators. > > This makes it possible for man(1) to format the output correctly, at least > for monospaced fonts. My bad. I knew the rule, but not the correct reason. -- John Baldwin ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262133 - head/tests/sys/kern
Author: asomers Date: Mon Feb 17 22:06:52 2014 New Revision: 262133 URL: http://svnweb.freebsd.org/changeset/base/262133 Log: test_eagain_*_* should've been using nonblocking sockets instead of blocking sockets. The error was not exposed as long as the kernel suffered from PR kern/185812. Now corrected, these tests pass on DragonFlyBSD 3.6.0. PR: kern/185812 Sponsored by: Spectra Logic Corporation MFC after:2 weeks Modified: head/tests/sys/kern/unix_seqpacket_test.c Modified: head/tests/sys/kern/unix_seqpacket_test.c == --- head/tests/sys/kern/unix_seqpacket_test.c Mon Feb 17 20:45:39 2014 (r262132) +++ head/tests/sys/kern/unix_seqpacket_test.c Mon Feb 17 22:06:52 2014 (r262133) @@ -136,7 +136,7 @@ test_eagain(size_t sndbufsize, size_t rc ssize_t ssize, rsize; /* setup the socket pair */ - do_socketpair(sv); + do_socketpair_nonblocking(sv); /* Setup the buffers */ ATF_REQUIRE_EQ(0, setsockopt(sv[0], SOL_SOCKET, SO_SNDBUF, &sndbufsize, sizeof(sndbufsize))); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262129 - head/sys/dev/usb/quirk
Author: hselasky Date: Mon Feb 17 20:30:29 2014 New Revision: 262129 URL: http://svnweb.freebsd.org/changeset/base/262129 Log: Our quirk table is almost full. Add some room for more quirks. MFC after:1 week Modified: head/sys/dev/usb/quirk/usb_quirk.c Modified: head/sys/dev/usb/quirk/usb_quirk.c == --- head/sys/dev/usb/quirk/usb_quirk.c Mon Feb 17 20:26:13 2014 (r262128) +++ head/sys/dev/usb/quirk/usb_quirk.c Mon Feb 17 20:30:29 2014 (r262129) @@ -59,7 +59,7 @@ MODULE_DEPEND(usb_quirk, usb, 1, 1, 1); MODULE_VERSION(usb_quirk, 1); -#defineUSB_DEV_QUIRKS_MAX 256 +#defineUSB_DEV_QUIRKS_MAX 320 #defineUSB_SUB_QUIRKS_MAX 8 struct usb_quirk_entry { ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262128 - head/sys/dev/usb/quirk
Author: hselasky Date: Mon Feb 17 20:26:13 2014 New Revision: 262128 URL: http://svnweb.freebsd.org/changeset/base/262128 Log: Adjust USB quirk. MFC after:1 week Submitted by: Volodymyr Kostyrko Modified: head/sys/dev/usb/quirk/usb_quirk.c Modified: head/sys/dev/usb/quirk/usb_quirk.c == --- head/sys/dev/usb/quirk/usb_quirk.c Mon Feb 17 20:25:17 2014 (r262127) +++ head/sys/dev/usb/quirk/usb_quirk.c Mon Feb 17 20:26:13 2014 (r262128) @@ -454,8 +454,8 @@ static struct usb_quirk_entry usb_quirks UQ_MSC_FORCE_PROTO_ATAPI), USB_QUIRK(MEIZU, M6_SL, 0x, 0x, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY, UQ_MSC_NO_SYNC_CACHE), - - USB_QUIRK(TOSHIBA, TRANSMEMORY, 0x, 0x, UQ_MSC_NO_SYNC_CACHE), + USB_QUIRK(TOSHIBA, TRANSMEMORY, 0x, 0x, UQ_MSC_NO_SYNC_CACHE, + UQ_MSC_NO_PREVENT_ALLOW), USB_QUIRK(VIALABS, USB30SATABRIDGE, 0x, 0x, UQ_MSC_NO_SYNC_CACHE), /* Non-standard USB MIDI devices */ ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r262125 - head/sys/dev/usb/controller
On Mon, Feb 17, 2014 at 5:08 PM, Dimitry Andric wrote: > Author: dim > Date: Mon Feb 17 20:08:11 2014 > New Revision: 262125 > URL: http://svnweb.freebsd.org/changeset/base/262125 > > Log: > In sys/dev/usb/controller/uss820dci.c, similar to r261977, fix a warning > about uss820dci_odevd being unused, by adding it to the part that > handles getting descriptors. > > Thanks for the quick fix! Luiz ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262125 - head/sys/dev/usb/controller
Author: dim Date: Mon Feb 17 20:08:11 2014 New Revision: 262125 URL: http://svnweb.freebsd.org/changeset/base/262125 Log: In sys/dev/usb/controller/uss820dci.c, similar to r261977, fix a warning about uss820dci_odevd being unused, by adding it to the part that handles getting descriptors. Reported by: loos Reviewed by: hselasky MFC after:3 days Modified: head/sys/dev/usb/controller/uss820dci.c Modified: head/sys/dev/usb/controller/uss820dci.c == --- head/sys/dev/usb/controller/uss820dci.c Mon Feb 17 20:06:09 2014 (r262124) +++ head/sys/dev/usb/controller/uss820dci.c Mon Feb 17 20:08:11 2014 (r262125) @@ -2005,6 +2005,13 @@ tr_handle_get_descriptor: len = sizeof(uss820dci_devd); ptr = (const void *)&uss820dci_devd; goto tr_valid; + case UDESC_DEVICE_QUALIFIER: + if (value & 0xff) { + goto tr_stalled; + } + len = sizeof(uss820dci_odevd); + ptr = (const void *)&uss820dci_odevd; + goto tr_valid; case UDESC_CONFIG: if (value & 0xff) { goto tr_stalled; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262123 - head/sys/arm/include
Author: ian Date: Mon Feb 17 20:04:57 2014 New Revision: 262123 URL: http://svnweb.freebsd.org/changeset/base/262123 Log: Give the fdt helper routines static linkage since no global definition of them is provided anywhere. (gcc was nice enough to warn about this, clang didn't for some reason.) Modified: head/sys/arm/include/physmem.h Modified: head/sys/arm/include/physmem.h == --- head/sys/arm/include/physmem.h Mon Feb 17 20:04:16 2014 (r262122) +++ head/sys/arm/include/physmem.h Mon Feb 17 20:04:57 2014 (r262123) @@ -65,7 +65,7 @@ void arm_physmem_print_tables(void); #include -inline void +static inline void arm_physmem_hardware_regions(struct mem_region * mrptr, int mrcount) { while (mrcount--) { @@ -74,7 +74,7 @@ arm_physmem_hardware_regions(struct mem_ } } -inline void +static inline void arm_physmem_exclude_regions(struct mem_region * mrptr, int mrcount, uint32_t exflags) { ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262121 - in head: contrib/llvm/tools/lldb/include/lldb/Expression contrib/llvm/tools/lldb/source/Core contrib/llvm/tools/lldb/source/Expression contrib/llvm/tools/lldb/source/Host/comm...
Author: emaste Date: Mon Feb 17 18:50:03 2014 New Revision: 262121 URL: http://svnweb.freebsd.org/changeset/base/262121 Log: Update lldb for clang/llvm 3.4 import This commit largely restores the lldb source to the upstream r196259 snapshot with the addition of threaded inferior support and a few bug fixes. Specific upstream lldb revisions restored include: SVN git 181387 779e6ac 181703 7bef4e2 182099 b31044e 182650 f2dcf35 182683 0d91b80 183862 15c1774 183929 99447a6 184177 0b2934b 184948 4dc3761 184954 007e7bc 186990 eebd175 Sponsored by: DARPA, AFRL Modified: head/contrib/llvm/tools/lldb/include/lldb/Expression/IRExecutionUnit.h head/contrib/llvm/tools/lldb/source/Core/ArchSpec.cpp head/contrib/llvm/tools/lldb/source/Expression/ClangExpressionParser.cpp head/contrib/llvm/tools/lldb/source/Expression/IRExecutionUnit.cpp head/contrib/llvm/tools/lldb/source/Expression/IRForTarget.cpp head/contrib/llvm/tools/lldb/source/Host/common/FileSpec.cpp head/contrib/llvm/tools/lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.cpp head/contrib/llvm/tools/lldb/source/Plugins/Instruction/ARM/EmulateInstructionARM.cpp head/contrib/llvm/tools/lldb/source/Symbol/ClangASTType.cpp head/usr.bin/clang/lldb/Makefile Modified: head/contrib/llvm/tools/lldb/include/lldb/Expression/IRExecutionUnit.h == --- head/contrib/llvm/tools/lldb/include/lldb/Expression/IRExecutionUnit.h Mon Feb 17 18:25:41 2014(r262120) +++ head/contrib/llvm/tools/lldb/include/lldb/Expression/IRExecutionUnit.h Mon Feb 17 18:50:03 2014(r262121) @@ -18,7 +18,6 @@ #include // Other libraries and framework includes -#include "llvm/ADT/StringRef.h" #include "llvm/IR/Module.h" // Project includes @@ -288,7 +287,8 @@ private: /// Allocated space. //-- virtual uint8_t *allocateCodeSection(uintptr_t Size, unsigned Alignment, - unsigned SectionID); + unsigned SectionID, + llvm::StringRef SectionName); //-- /// Allocate space for data, and add it to the m_spaceBlocks map @@ -309,7 +309,9 @@ private: /// Allocated space. //-- virtual uint8_t *allocateDataSection(uintptr_t Size, unsigned Alignment, - unsigned SectionID, bool IsReadOnly); + unsigned SectionID, + llvm::StringRef SectionName, + bool IsReadOnly); //-- /// Allocate space for a global variable, and add it to the @@ -337,7 +339,13 @@ private: /// @return /// True in case of failure, false in case of success. //-- -bool applyPermissions(std::string *ErrMsg) { return false; } +virtual bool finalizeMemory(std::string *ErrMsg) { +// TODO: Ensure that the instruction cache is flushed because +// relocations are updated by dy-load. See: +// sys::Memory::InvalidateInstructionCache +// llvm::SectionMemoryManager +return false; +} //-- /// Passthrough interface stub @@ -347,38 +355,6 @@ private: //-- /// Passthrough interface stub //-- -virtual uint8_t* startExceptionTable(const llvm::Function* F, - uintptr_t &ActualSize); - -//-- -/// Complete the exception table for a function, and add it to the -/// m_exception_tables map -/// -/// @param[in] F -/// The function whose exception table is being written. -/// -/// @param[in] TableStart -/// The first byte of the exception table. -/// -/// @param[in] TableEnd -/// The last byte of the exception table. -/// -/// @param[in] FrameRegister -/// I don't know what this does, but it's passed through. -//-- -virtual void endE
svn commit: r262066 - head/sys/dev/sound/pcm
Author: eadler Date: Mon Feb 17 15:33:21 2014 New Revision: 262066 URL: http://svnweb.freebsd.org/changeset/base/262066 Log: pcm(4): Permit non-root users to change default unit Discussed with: mav Modified: head/sys/dev/sound/pcm/sound.c Modified: head/sys/dev/sound/pcm/sound.c == --- head/sys/dev/sound/pcm/sound.c Mon Feb 17 15:32:08 2014 (r262065) +++ head/sys/dev/sound/pcm/sound.c Mon Feb 17 15:33:21 2014 (r262066) @@ -448,8 +448,10 @@ sysctl_hw_snd_default_unit(SYSCTL_HANDLE return (error); } /* XXX: do we need a way to let the user change the default unit? */ -SYSCTL_PROC(_hw_snd, OID_AUTO, default_unit, CTLTYPE_INT | CTLFLAG_RW, -0, sizeof(int), sysctl_hw_snd_default_unit, "I", "default sound device"); +SYSCTL_PROC(_hw_snd, OID_AUTO, default_unit, + CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_ANYBODY, + 0, sizeof(int), sysctl_hw_snd_default_unit, "I", + "default sound device"); static int sysctl_hw_snd_maxautovchans(SYSCTL_HANDLER_ARGS) ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r262051 - head/cddl/contrib/opensolaris/cmd/zpool
On Mon, 17 Feb 2014, Mark Felder wrote: Log: Fix formatting. "Manpages should start a new sentence on a new line. This makes it easier for translators to track changes." -jhb This has very little to do with translators. This makes it possible for man(1) to format the output correctly, at least for monospaced fonts. Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 == --- head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Mon Feb 17 13:19:27 2014(r262050) +++ head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Mon Feb 17 13:23:49 2014(r262051) @@ -1960,5 +1960,5 @@ implementation of this manual page was i The .Cm spare feature requires a utility to detect zpool degradation and initiate -disk replacement within the zpool. FreeBSD does not provide such a -utility at this time. +disk replacement within the zpool. +FreeBSD does not provide such a utility at this time. Not splitting the line gave a hard-coded the sentence break of 1 space. Splitting the line allows man(1) to format with the default number of spaces. The default isn't 1. Bruce ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262051 - head/cddl/contrib/opensolaris/cmd/zpool
Author: feld (ports committer) Date: Mon Feb 17 13:23:49 2014 New Revision: 262051 URL: http://svnweb.freebsd.org/changeset/base/262051 Log: Fix formatting. "Manpages should start a new sentence on a new line. This makes it easier for translators to track changes." -jhb Approved by: jhb MFC after:3 days Sponsored by: SupraNet Communications, Inc Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 == --- head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Mon Feb 17 13:19:27 2014(r262050) +++ head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Mon Feb 17 13:23:49 2014(r262051) @@ -1960,5 +1960,5 @@ implementation of this manual page was i The .Cm spare feature requires a utility to detect zpool degradation and initiate -disk replacement within the zpool. FreeBSD does not provide such a -utility at this time. +disk replacement within the zpool. +FreeBSD does not provide such a utility at this time. ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262036 - head/release
Author: jhay Date: Mon Feb 17 12:29:17 2014 New Revision: 262036 URL: http://svnweb.freebsd.org/changeset/base/262036 Log: etcupdate should use the src tree from where the release is built, not the default (/usr/src) tree. MFC after:2 weeks Modified: head/release/Makefile Modified: head/release/Makefile == --- head/release/Makefile Mon Feb 17 12:27:02 2014(r262035) +++ head/release/Makefile Mon Feb 17 12:29:17 2014(r262036) @@ -105,7 +105,7 @@ base.txz: sh ${.CURDIR}/scripts/mm-mtree.sh -m ${WORLDDIR} -F \ "TARGET_ARCH=${TARGET_ARCH} TARGET=${TARGET}" -D "${.OBJDIR}/${DISTDIR}/base" etcupdate extract -B -M "TARGET_ARCH=${TARGET_ARCH} TARGET=${TARGET}" \ - -d "${.OBJDIR}/${DISTDIR}/base/var/db/etcupdate" + -s ${WORLDDIR} -d "${.OBJDIR}/${DISTDIR}/base/var/db/etcupdate" # Package all components cd ${WORLDDIR} && ${IMAKE} packageworld DISTDIR=${.OBJDIR}/${DISTDIR} mv ${DISTDIR}/*.txz . ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262030 - head/sys/net
Author: glebius Date: Mon Feb 17 12:07:17 2014 New Revision: 262030 URL: http://svnweb.freebsd.org/changeset/base/262030 Log: Add my copyright to flowtable. Modified: head/sys/net/flowtable.c head/sys/net/flowtable.h Modified: head/sys/net/flowtable.c == --- head/sys/net/flowtable.cMon Feb 17 12:02:44 2014(r262029) +++ head/sys/net/flowtable.cMon Feb 17 12:07:17 2014(r262030) @@ -1,5 +1,5 @@ /*- - * + * Copyright (c) 2014 Gleb Smirnoff * Copyright (c) 2008-2010, BitGravity Inc. * All rights reserved. * Modified: head/sys/net/flowtable.h == --- head/sys/net/flowtable.hMon Feb 17 12:02:44 2014(r262029) +++ head/sys/net/flowtable.hMon Feb 17 12:07:17 2014(r262030) @@ -1,5 +1,5 @@ /*- - * + * Copyright (c) 2014 Gleb Smirnoff * Copyright (c) 2008-2010, BitGravity Inc. * All rights reserved. * ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262029 - head/sys/net
Author: glebius Date: Mon Feb 17 12:02:44 2014 New Revision: 262029 URL: http://svnweb.freebsd.org/changeset/base/262029 Log: Whitespace. Modified: head/sys/net/flowtable.c Modified: head/sys/net/flowtable.c == --- head/sys/net/flowtable.cMon Feb 17 12:01:50 2014(r262028) +++ head/sys/net/flowtable.cMon Feb 17 12:02:44 2014(r262029) @@ -412,7 +412,7 @@ static bitstr_t * flowtable_mask(struct flowtable *ft) { - /* + /* * flowtable_free_stale() calls w/o critical section, but * with sched_bind(). Since pointer is stable throughout * ft lifetime, it is safe, otherwise... @@ -496,10 +496,10 @@ flowtable_insert(struct flowtable *ft, u int keylen, uint32_t fibnum0) { #ifdef INET6 -struct route_in6 sro6; + struct route_in6 sro6; #endif #ifdef INET -struct route sro; + struct route sro; #endif struct route *ro = NULL; struct rtentry *rt; @@ -735,7 +735,7 @@ flowtable_lookup_common(struct flowtable /* * used by the bit_alloc macro */ -#define calloc(count, size) malloc((count)*(size), M_FTABLE, M_WAITOK | M_ZERO) +#define calloc(count, size) malloc((count)*(size), M_FTABLE, M_WAITOK | M_ZERO) static void flowtable_alloc(struct flowtable *ft) { ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r262028 - head/sys/net
Author: glebius Date: Mon Feb 17 12:01:50 2014 New Revision: 262028 URL: http://svnweb.freebsd.org/changeset/base/262028 Log: Bring copyright notice to standard style. Modified: head/sys/net/flowtable.c head/sys/net/flowtable.h Modified: head/sys/net/flowtable.c == --- head/sys/net/flowtable.cMon Feb 17 11:50:56 2014(r262027) +++ head/sys/net/flowtable.cMon Feb 17 12:01:50 2014(r262028) @@ -1,31 +1,30 @@ -/** - -Copyright (c) 2008-2010, BitGravity Inc. -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. Neither the name of the BitGravity Corporation nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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. - -***/ +/*- + * + * Copyright (c) 2008-2010, BitGravity Inc. + * 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. Neither the name of the BitGravity Corporation nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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. + */ #include "opt_route.h" #include "opt_mpath.h" Modified: head/sys/net/flowtable.h == --- head/sys/net/flowtable.hMon Feb 17 11:50:56 2014(r262027) +++ head/sys/net/flowtable.hMon Feb 17 12:01:50 2014(r262028) @@ -1,33 +1,33 @@ -/** - -Copyright (c) 2008-2010, BitGravity Inc. -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. Neither the name of the BitGravity Corporation nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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,
svn commit: r262027 - in head/sys: conf net netinet netinet6
Author: glebius Date: Mon Feb 17 11:50:56 2014 New Revision: 262027 URL: http://svnweb.freebsd.org/changeset/base/262027 Log: o Remove at compile time the HASH_ALL code, that was never tested and is unfinished. However, I've tested my version, it works okay. As before it is unfinished: timeout aren't driven by TCP session state. To enable the HASH_ALL mode, one needs in kernel config: options FLOWTABLE_HASH_ALL o Reduce the alignment on flentry to 64 bytes. Without the FLOWTABLE_HASH_ALL option, twice less memory would be consumed by flows. o API to ip_output()/ip6_output() got even more thin: 1 liner. o Remove unused unions. Simply use fle->f_key[]. o Merge all IPv4 code into flowtable_lookup_ipv4(), and do same flowtable_lookup_ipv6(). Stop copying data to on stack sockaddr structures, simply use key[] on stack. o Move code from flowtable_lookup_common() that actually works on insertion into flowtable_insert(). Sponsored by: Netflix Sponsored by: Nginx, Inc. Modified: head/sys/conf/options head/sys/net/flowtable.c head/sys/net/flowtable.h head/sys/netinet/ip_output.c head/sys/netinet6/ip6_output.c Modified: head/sys/conf/options == --- head/sys/conf/options Mon Feb 17 11:44:58 2014(r262026) +++ head/sys/conf/options Mon Feb 17 11:50:56 2014(r262027) @@ -440,6 +440,7 @@ TCP_SIGNATURE opt_inet.h VLAN_ARRAY opt_vlan.h XBONEHACK FLOWTABLE opt_route.h +FLOWTABLE_HASH_ALL opt_route.h # # SCTP Modified: head/sys/net/flowtable.c == --- head/sys/net/flowtable.cMon Feb 17 11:44:58 2014(r262026) +++ head/sys/net/flowtable.cMon Feb 17 11:50:56 2014(r262027) @@ -73,91 +73,53 @@ __FBSDID("$FreeBSD$"); #ifdef INET6 #include #endif +#ifdef FLOWTABLE_HASH_ALL #include #include #include +#endif #include -#ifdef INET -struct ipv4_tuple { - uint16_tip_sport; /* source port */ - uint16_tip_dport; /* destination port */ - in_addr_t ip_saddr; /* source address */ - in_addr_t ip_daddr; /* destination address */ -}; - -union ipv4_flow { - struct ipv4_tuple ipf_ipt; - uint32_tipf_key[3]; -}; +#ifdef FLOWTABLE_HASH_ALL +#defineKEY_PORTS (sizeof(uint16_t) * 2) +#defineKEY_ADDRS 2 +#else +#defineKEY_PORTS 0 +#defineKEY_ADDRS 1 #endif -#ifdef INET6 -struct ipv6_tuple { - uint16_tip_sport; /* source port */ - uint16_tip_dport; /* destination port */ - struct in6_addr ip_saddr; /* source address */ - struct in6_addr ip_daddr; /* destination address */ -}; - -union ipv6_flow { - struct ipv6_tuple ipf_ipt; - uint32_tipf_key[9]; -}; +#ifdef INET6 +#defineKEY_ADDR_LENsizeof(struct in6_addr) +#else +#defineKEY_ADDR_LENsizeof(struct in_addr) #endif +#defineKEYLEN ((KEY_ADDR_LEN * KEY_ADDRS + KEY_PORTS) / sizeof(uint32_t)) + struct flentry { - uint32_tf_fhash;/* hash flowing forward */ - uint16_tf_flags;/* flow flags */ - uint8_t f_pad; - uint8_t f_proto;/* protocol */ - uint32_tf_fibnum; /* fib index */ + uint32_tf_hash; /* hash flowing forward */ + uint32_tf_key[KEYLEN]; /* address(es and ports) */ uint32_tf_uptime; /* uptime at last access */ + uint16_tf_fibnum; /* fib index */ +#ifdef FLOWTABLE_HASH_ALL + uint8_t f_proto;/* protocol */ + uint8_t f_flags;/* stale? */ +#define FL_STALE 1 +#endif SLIST_ENTRY(flentry)f_next; /* pointer to collision entry */ struct rtentry *f_rt; /* rtentry for flow */ struct llentry *f_lle; /* llentry for flow */ - union { -#ifdef INET - union ipv4_flow v4; -#endif -#ifdef INET6 - union ipv6_flow v6; -#endif - } f_flow; -#definef_flow4 f_flow.v4 -#definef_flow6 f_flow.v6 }; -#defineKEYLEN(flags) flags) & FL_IPV6) ? 9 : 3) * 4) - -/* Make sure f_flow begins with key. */ -#ifdef INET -CTASSERT(offsetof(struct flentry, f_flow) == -offsetof(struct flentry, f_flow4.ipf_key)); -#endif -#ifdef INET6 -CTASSERT(offsetof(struct flentry, f_flow) == -offsetof(struct flentry, f_flow6.ipf_key)); -#endif +#undef KEYLEN SLIST_HEAD(flist, flentry); /* Make sure we can use pcpu_zone_ptr for struct flist. */ CTASSERT(sizeof(struct flist) =
svn commit: r262020 - head/sys/arm/xscale/ixp425
Author: jhay Date: Mon Feb 17 11:05:57 2014 New Revision: 262020 URL: http://svnweb.freebsd.org/changeset/base/262020 Log: Make it possible to use the env kernel config file option for AVILA and CAMBRIA boards that does not use loader to load the kernel. This is basically how it was done for i386. This way tunables can also be set. For example in config file: env "/conf/AVILA.env" And in AVILA.env: vfs.unmapped_buf_allowed=0 MFC after:2 weeks Modified: head/sys/arm/xscale/ixp425/avila_machdep.c Modified: head/sys/arm/xscale/ixp425/avila_machdep.c == --- head/sys/arm/xscale/ixp425/avila_machdep.c Mon Feb 17 10:57:06 2014 (r262019) +++ head/sys/arm/xscale/ixp425/avila_machdep.c Mon Feb 17 11:05:57 2014 (r262020) @@ -227,6 +227,8 @@ initarm(struct arm_boot_params *abp) pcpu_init(pcpup, 0, sizeof(struct pcpu)); PCPU_SET(curthread, &thread0); + if (envmode == 1) + kern_envp = static_env; /* Do basic tuning, hz etc */ init_param1(); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"