Re: svn commit: r250134 - head/sys/mips/include

2013-05-01 Thread Warner Losh

On Apr 30, 2013, at 11:55 PM, Juli Mallett wrote:

 Warner,
 
 May I ask why you're bringing in the 4.4BSD version and not the NetBSD
 version, which already contained the appropriate ABI gunk?  Do we
 really need to duplicate their work improving the file since 4.4BSD?

The NetBSD version didn't have the CSRG copyright, so I wanted to create a 
clear chain of modifications.  I'll be done with that within the hour

But it turns out I was confused about which file lacked a copyright (I was also 
looking at elf_machdep.h), so I'll just bring NetBSD's in now. Sorry for the 
churn...

Warner

 Thanks,
 Juli.
 
 On Tue, Apr 30, 2013 at 10:46 PM, Warner Losh i...@freebsd.org wrote:
 Author: imp
 Date: Wed May  1 05:46:54 2013
 New Revision: 250134
 URL: http://svnweb.freebsd.org/changeset/base/250134
 
 Log:
  Import virgin regdef.h from 4.4 Lite 2's sys/pmax/include/regdef.h,
  expand the %sccs.include.redist.c% directive with the standard
  3-clause license, and add $FreeBSD$ to keep the commit script happy.
 
  # This may break some mips stuff, which will be fixed in the next commit.
 
 Modified:
  head/sys/mips/include/regdef.h
 
 Modified: head/sys/mips/include/regdef.h
 ==
 --- head/sys/mips/include/regdef.h  Wed May  1 05:14:59 2013
 (r250133)
 +++ head/sys/mips/include/regdef.h  Wed May  1 05:46:54 2013
 (r250134)
 @@ -1,86 +1,67 @@
 -/*-
 - * Copyright (c) 2001, Juniper Networks, Inc.
 - * All rights reserved.
 - * Truman Joe, February 2001.
 +/*
 + * Copyright (c) 1992, 1993
 + *  The Regents of the University of California.  All rights reserved.
  *
 - * regdef.h -- MIPS register definitions.
 + * This code is derived from software contributed to Berkeley by
 + * Ralph Campbell. This file is derived from the MIPS RISC
 + * Architecture book by Gerry Kane.
  *
 - * JNPR: regdef.h,v 1.3 2006/08/07 05:38:57 katta
 - * $FreeBSD$
 - */
 -
 -#ifndef _MACHINE_REGDEF_H_
 -#define_MACHINE_REGDEF_H_
 -
 -#include machine/cdefs.h /* For API selection */
 -
 -#if defined(__ASSEMBLER__)
 -/* General purpose CPU register names */
 -#definezero$0  /* wired zero */
 -#defineAT  $at /* assembler temp */
 -#definev0  $2  /* return value */
 -#definev1  $3
 -#definea0  $4  /* argument registers */
 -#definea1  $5
 -#definea2  $6
 -#definea3  $7
 -#if defined(__mips_n32) || defined(__mips_n64)
 -#definea4  $8
 -#definea5  $9
 -#definea6  $10
 -#definea7  $11
 -#definet0  $12 /* Temp regs, not saved accross subroutine 
 calls */
 -#definet1  $13
 -#definet2  $14
 -#definet3  $15
 -#else
 -#definet0  $8  /* caller saved */
 -#definet1  $9
 -#definet2  $10
 -#definet3  $11
 -#definet4  $12 /* caller saved - 32 bit env arg reg 64 bit 
 */
 -#definet5  $13
 -#definet6  $14
 -#definet7  $15
 -#endif
 -#defines0  $16 /* callee saved */
 -#defines1  $17
 -#defines2  $18
 -#defines3  $19
 -#defines4  $20
 -#defines5  $21
 -#defines6  $22
 -#defines7  $23
 -#definet8  $24 /* code generator */
 -#definet9  $25
 -#definek0  $26 /* kernel temporary */
 -#definek1  $27
 -#definegp  $28 /* global pointer */
 -#definesp  $29 /* stack pointer */
 -#definefp  $30 /* frame pointer */
 -#defines8  $30 /* callee saved */
 -#definera  $31 /* return address */
 -
 -/*
 - * These are temp registers whose names can be used in either the old
 - * or new ABI, although they map to different physical registers.  In
 - * the old ABI, they map to t4-t7, and in the new ABI, they map to a4-a7.
 + * 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.
 + * 4. Neither the name of the University nor the names of its contributors
 + *may be used to endorse or promote products derived from this software
 + *without specific prior written permission.
  *
 - * Because they overlap with the last 4 arg regs in the new ABI, ta0-ta3
 - * should be used only when we need more than t0-t3.
 + * THIS SOFTWARE IS PROVIDED BY THE 

svn commit: r250136 - head/sys/mips/include

2013-05-01 Thread Warner Losh
Author: imp
Date: Wed May  1 06:22:50 2013
New Revision: 250136
URL: http://svnweb.freebsd.org/changeset/base/250136

Log:
  Import NetBSD's version, which is perfectly fine.
  
  Submitted by: jmallet@

Modified:
  head/sys/mips/include/regdef.h

Modified: head/sys/mips/include/regdef.h
==
--- head/sys/mips/include/regdef.h  Wed May  1 05:48:32 2013
(r250135)
+++ head/sys/mips/include/regdef.h  Wed May  1 06:22:50 2013
(r250136)
@@ -1,6 +1,8 @@
+/* $NetBSD: regdef.h,v 1.12 2005/12/11 12:18:09 christos Exp $ */
+
 /*
  * Copyright (c) 1992, 1993
- *  The Regents of the University of California.  All rights reserved.
+ * The Regents of the University of California.  All rights reserved.
  *
  * This code is derived from software contributed to Berkeley by
  * Ralph Campbell. This file is derived from the MIPS RISC
@@ -14,7 +16,7 @@
  * 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.
- * 4. Neither the name of the University nor the names of its contributors
+ * 3. Neither the name of the University nor the names of its contributors
  *may be used to endorse or promote products derived from this software
  *without specific prior written permission.
  *
@@ -29,44 +31,80 @@
  * 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.
- *  @(#)regdef.h8.1 (Berkeley) 06/10/93
+ *
+ * @(#)regdef.h8.1 (Berkeley) 6/10/93
  * $FreeBSD$
  */
 
-#ifndef _MIPS_INCLUDE_REGDEF_H_
-#define _MIPS_INCLUDE_REGDEF_H_
+#ifndef _MIPS_REGDEF_H
+#define _MIPS_REGDEF_H
+
+#include machine/cdefs.h /* for API selection */
+
+#if defined(__ASSEMBLER__)
+#define zero   $0  /* always zero */
+#define AT $at /* assembler temporary */
+#define v0 $2  /* return value */
+#define v1 $3
+#define a0 $4  /* argument registers */
+#define a1 $5
+#define a2 $6
+#define a3 $7
+#if defined(__mips_n32) || defined(__mips_n64)
+#definea4  $8
+#definea5  $9
+#definea6  $10
+#definea7  $11
+#definet0  $12 /* temp registers (not saved across subroutine 
calls) */
+#definet1  $13
+#definet2  $14
+#definet3  $15
+#else
+#define t0 $8  /* temp registers (not saved across subroutine calls) */
+#define t1 $9
+#define t2 $10
+#define t3 $11
+#define t4 $12
+#define t5 $13
+#define t6 $14
+#define t7 $15
+#endif /* __mips_n32 || __mips_n64 */
+#define s0 $16 /* saved across subroutine calls (callee saved) */
+#define s1 $17
+#define s2 $18
+#define s3 $19
+#define s4 $20
+#define s5 $21
+#define s6 $22
+#define s7 $23
+#define t8 $24 /* two more temporary registers */
+#define t9 $25
+#define k0 $26 /* kernel temporary */
+#define k1 $27
+#define gp $28 /* global pointer */
+#define sp $29 /* stack pointer */
+#define s8 $30 /* one more callee saved */
+#define ra $31 /* return address */
 
-#define zero$0  /* always zero */
-#define AT  $at /* assembler temp */
-#define v0  $2  /* return value */
-#define v1  $3
-#define a0  $4  /* argument registers */
-#define a1  $5
-#define a2  $6
-#define a3  $7
-#define t0  $8  /* temp registers (not saved across subroutine calls) 
*/
-#define t1  $9
-#define t2  $10
-#define t3  $11
-#define t4  $12
-#define t5  $13
-#define t6  $14
-#define t7  $15
-#define s0  $16 /* saved across subroutine calls (callee saved) */
-#define s1  $17
-#define s2  $18
-#define s3  $19
-#define s4  $20
-#define s5  $21
-#define s6  $22
-#define s7  $23
-#define t8  $24 /* two more temp registers */
-#define t9  $25
-#define k0  $26 /* kernel temporary */
-#define k1  $27
-#define gp  $28 /* global pointer */
-#define sp  $29 /* stack pointer */
-#define s8  $30 /* one more callee saved */
-#define ra  $31 /* return address */
+/*
+ * These are temp registers whose names can be used in either the old
+ * or new ABI, although they map to different physical registers.  In
+ * the old ABI, they map to t4-t7, and in the new ABI, they map to a4-a7.
+ *
+ * Because they overlap with the last 4 arg regs in the new ABI, ta0-ta3
+ * should be used only when we need more than t0-t3.
+ */
+#if defined(__mips_n32) || defined(__mips_n64)
+#defineta0 $8
+#defineta1 $9
+#defineta2 $10
+#defineta3 $11
+#else
+#defineta0 $12
+#define  

svn commit: r250137 - head/sys/mips/mips

2013-05-01 Thread Warner Losh
Author: imp
Date: Wed May  1 06:55:13 2013
New Revision: 250137
URL: http://svnweb.freebsd.org/changeset/base/250137

Log:
  Remove asm.h dependency in a hackish way.
  Fixed comment.

Modified:
  head/sys/mips/mips/vm_machdep.c

Modified: head/sys/mips/mips/vm_machdep.c
==
--- head/sys/mips/mips/vm_machdep.c Wed May  1 06:22:50 2013
(r250136)
+++ head/sys/mips/mips/vm_machdep.c Wed May  1 06:55:13 2013
(r250137)
@@ -57,7 +57,6 @@ __FBSDID($FreeBSD$);
 #include sys/sysctl.h
 #include sys/unistd.h
 
-#include machine/asm.h
 #include machine/cache.h
 #include machine/clock.h
 #include machine/cpu.h
@@ -83,6 +82,18 @@ __FBSDID($FreeBSD$);
 #defineNSFBUFS (512 + maxusers * 16)
 #endif
 
+/* Duplicated from asm.h */
+#if defined(__mips_o32)
+#defineSZREG   4
+#else
+#defineSZREG   8
+#endif
+#if defined(__mips_o32) || defined(__mips_o64)
+#defineCALLFRAME_SIZ   (SZREG * (4 + 2))
+#elif defined(__mips_n32) || defined(__mips_n64)
+#defineCALLFRAME_SIZ   (SZREG * 4)
+#endif
+
 #ifndef __mips_n64
 static voidsf_buf_init(void *arg);
 SYSINIT(sock_sf, SI_SUB_MBUF, SI_ORDER_ANY, sf_buf_init, NULL);
@@ -437,10 +448,11 @@ cpu_set_upcall_kse(struct thread *td, vo
register_t sp;
 
/*
-   * At the point where a function is called, sp must be 8
-   * byte aligned[for compatibility with 64-bit CPUs]
-   * in ``See MIPS Run'' by D. Sweetman, p. 269
-   * align stack */
+* At the point where a function is called, sp must be 8
+* byte aligned[for compatibility with 64-bit CPUs]
+* in ``See MIPS Run'' by D. Sweetman, p. 269
+* align stack
+*/
sp = ((register_t)(intptr_t)(stack-ss_sp + stack-ss_size)  ~0x7) -
CALLFRAME_SIZ;
 
___
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: r250138 - in head/sys/mips: include mips

2013-05-01 Thread Warner Losh
Author: imp
Date: Wed May  1 06:57:46 2013
New Revision: 250138
URL: http://svnweb.freebsd.org/changeset/base/250138

Log:
  Don't include asm.h in non-asm files.
  Remove #define to get kludges that asm.h used to define
  Move clever macros to access assembler instructions to trap.c
  Remove __ASSEMBLER__ ifdefs in regdef.h: they aren't needed anymore.

Modified:
  head/sys/mips/include/asm.h
  head/sys/mips/include/regdef.h
  head/sys/mips/mips/db_interface.c
  head/sys/mips/mips/trap.c

Modified: head/sys/mips/include/asm.h
==
--- head/sys/mips/include/asm.h Wed May  1 06:55:13 2013(r250137)
+++ head/sys/mips/include/asm.h Wed May  1 06:57:46 2013(r250138)
@@ -56,9 +56,7 @@
 #ifndef _MACHINE_ASM_H_
 #define_MACHINE_ASM_H_
 
-#ifndef NO_REG_DEFS
 #include machine/regdef.h
-#endif
 #include machine/endian.h
 #include machine/cdefs.h
 
@@ -111,26 +109,6 @@
 #defineWARN_REFERENCES(_sym,_msg)  \
.section .gnu.warning. ## _sym ; .ascii _msg ; .text
 
-/*
- * These are temp registers whose names can be used in either the old
- * or new ABI, although they map to different physical registers.  In
- * the old ABI, they map to t4-t7, and in the new ABI, they map to a4-a7.
- *
- * Because they overlap with the last 4 arg regs in the new ABI, ta0-ta3
- * should be used only when we need more than t0-t3.
- */
-#if defined(__mips_n32) || defined(__mips_n64)
-#define ta0 $8
-#define ta1 $9
-#define ta2 $10
-#define ta3 $11
-#else
-#define ta0 $12
-#define ta1 $13
-#define ta2 $14
-#define ta3 $15
-#endif /* __mips_n32 || __mips_n64 */
-
 #ifdef __ELF__
 # define _C_LABEL(x)x
 #else
@@ -674,97 +652,6 @@ _C_LABEL(x):
 #defineUSE_ALT_CP(a)   .cplocal a
 #endif /* __mips_n32 || __mips_n64 */
 
-#definemfc0_macro(data, spr)   
\
-   __asm __volatile (mfc0 %0, $%1\
-   : =r (data)   /* outputs */   \
-   : i (spr));   /* inputs */
-
-#definemtc0_macro(data, spr)   
\
-   __asm __volatile (mtc0 %0, $%1\
-   :   /* outputs */   \
-   : r (data), i (spr));   /* inputs */
-
-#definecfc0_macro(data, spr)   
\
-   __asm __volatile (cfc0 %0, $%1\
-   : =r (data)   /* outputs */   \
-   : i (spr));   /* inputs */
-
-#definectc0_macro(data, spr)   
\
-   __asm __volatile (ctc0 %0, $%1\
-   :   /* outputs */   \
-   : r (data), i (spr));   /* inputs */
-
-
-#definelbu_macro(data, addr)   
\
-   __asm __volatile (lbu %0, 0x0(%1) \
-   : =r (data)   /* outputs */   \
-   : r (addr));  /* inputs */
-
-#definelb_macro(data, addr)
\
-   __asm __volatile (lb %0, 0x0(%1)  \
-   : =r (data)   /* outputs */   \
-   : r (addr));  /* inputs */
-
-#definelwl_macro(data, addr)   
\
-   __asm __volatile (lwl %0, 0x0(%1) \
-   : =r (data)   /* outputs */   \
-   : r (addr));  /* inputs */
-
-#definelwr_macro(data, addr)   
\
-   __asm __volatile (lwr %0, 0x0(%1) \
-   : =r (data)   /* outputs */   \
-   : r (addr));  /* inputs */
-
-#defineldl_macro(data, addr)   
\
-   __asm __volatile (ldl %0, 0x0(%1) \
-   : =r (data)   /* outputs */   \
-   : r (addr));  /* inputs */
-
-#defineldr_macro(data, addr)   
\
-   __asm __volatile (ldr %0, 0x0(%1) \
-   : =r (data)   /* outputs */   \
-   : r (addr));  /* inputs */
-
-#definesb_macro(data, addr)
\
-   __asm __volatile (sb %0, 0x0(%1)  \
-   :   /* outputs */   \
-   : r 

svn commit: r250139 - head

2013-05-01 Thread Warner Losh
Author: imp
Date: Wed May  1 07:13:36 2013
New Revision: 250139
URL: http://svnweb.freebsd.org/changeset/base/250139

Log:
  Add a historic footnote.

Modified:
  head/UPDATING

Modified: head/UPDATING
==
--- head/UPDATING   Wed May  1 06:57:46 2013(r250138)
+++ head/UPDATING   Wed May  1 07:13:36 2013(r250139)
@@ -291,7 +291,9 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10
is now spelled mips64.  mipsn32eb is now spelled mipsn32.  mipseb is
now spelled mips.  This is to aid compatibility with third-party
software that expects this naming scheme in uname(3).  Little-endian
-   settings are unchanged.
+   settings are unchanged. If you are updating a big-endian mips64 machine
+   from before this change, you may need to set MACHINE_ARCH=mips64 in
+   your environment before the new build system will recognize your 
machine.
 
 20120306:
Disable by default the option VFS_ALLOW_NONMPSAFE for all supported
___
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: r250140 - stable/9/sys/netinet

2013-05-01 Thread Lawrence Stewart
Author: lstewart
Date: Wed May  1 08:53:40 2013
New Revision: 250140
URL: http://svnweb.freebsd.org/changeset/base/250140

Log:
  MFC r245783:
  
  Simplify and fix a bug in cc_ack_received()'s are we congestion window 
limited
  logic (refer to [1] for associated discussion). snd_cwnd and snd_wnd are
  unsigned long and on 64 bit hosts, min() will truncate them to 32 bits and 
could
  therefore potentially corrupt the result (although under normal operation,
  neither variable should legitmately exceed 32 bits).
  
  [1] http://lists.freebsd.org/pipermail/freebsd-net/2013-January/034297.html
  
  Submitted by: jhb

Modified:
  stable/9/sys/netinet/tcp_input.c
Directory Properties:
  stable/9/sys/   (props changed)

Modified: stable/9/sys/netinet/tcp_input.c
==
--- stable/9/sys/netinet/tcp_input.cWed May  1 07:13:36 2013
(r250139)
+++ stable/9/sys/netinet/tcp_input.cWed May  1 08:53:40 2013
(r250140)
@@ -269,7 +269,7 @@ cc_ack_received(struct tcpcb *tp, struct
INP_WLOCK_ASSERT(tp-t_inpcb);
 
tp-ccv-bytes_this_ack = BYTES_THIS_ACK(tp, th);
-   if (tp-snd_cwnd == min(tp-snd_cwnd, tp-snd_wnd))
+   if (tp-snd_cwnd = tp-snd_wnd)
tp-ccv-flags |= CCF_CWND_LIMITED;
else
tp-ccv-flags = ~CCF_CWND_LIMITED;
___
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: r250141 - stable/8/sys/netinet

2013-05-01 Thread Lawrence Stewart
Author: lstewart
Date: Wed May  1 08:57:45 2013
New Revision: 250141
URL: http://svnweb.freebsd.org/changeset/base/250141

Log:
  MFC r245783:
  
  Simplify and fix a bug in cc_ack_received()'s are we congestion window 
limited
  logic (refer to [1] for associated discussion). snd_cwnd and snd_wnd are
  unsigned long and on 64 bit hosts, min() will truncate them to 32 bits and 
could
  therefore potentially corrupt the result (although under normal operation,
  neither variable should legitmately exceed 32 bits).
  
  [1] http://lists.freebsd.org/pipermail/freebsd-net/2013-January/034297.html
  
  Submitted by: jhb

Modified:
  stable/8/sys/netinet/tcp_input.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/netinet/   (props changed)

Modified: stable/8/sys/netinet/tcp_input.c
==
--- stable/8/sys/netinet/tcp_input.cWed May  1 08:53:40 2013
(r250140)
+++ stable/8/sys/netinet/tcp_input.cWed May  1 08:57:45 2013
(r250141)
@@ -269,7 +269,7 @@ cc_ack_received(struct tcpcb *tp, struct
INP_WLOCK_ASSERT(tp-t_inpcb);
 
tp-ccv-bytes_this_ack = BYTES_THIS_ACK(tp, th);
-   if (tp-snd_cwnd == min(tp-snd_cwnd, tp-snd_wnd))
+   if (tp-snd_cwnd = tp-snd_wnd)
tp-ccv-flags |= CCF_CWND_LIMITED;
else
tp-ccv-flags = ~CCF_CWND_LIMITED;
___
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: r250142 - stable/9/sys/dev/usb/storage

2013-05-01 Thread Alexander Motin
Author: mav
Date: Wed May  1 09:20:13 2013
New Revision: 250142
URL: http://svnweb.freebsd.org/changeset/base/250142

Log:
  MFC r245328:
  Freeze device queue before returning errors to CAM.  This is required
  for proper error recovery, including keeping original request order.

Modified:
  stable/9/sys/dev/usb/storage/umass.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/dev/usb/storage/umass.c
==
--- stable/9/sys/dev/usb/storage/umass.cWed May  1 08:57:45 2013
(r250141)
+++ stable/9/sys/dev/usb/storage/umass.cWed May  1 09:20:13 2013
(r250142)
@@ -2251,8 +2251,11 @@ umass_cam_action(struct cam_sim *sim, un
/*ascq*/ 0x00,
/*extra args*/ 
SSD_ELEM_NONE);
ccb-csio.scsi_status = 
SCSI_STATUS_CHECK_COND;
-   ccb-ccb_h.status = 
CAM_SCSI_STATUS_ERROR |
-   CAM_AUTOSNS_VALID;
+   ccb-ccb_h.status =
+   CAM_SCSI_STATUS_ERROR |
+   CAM_AUTOSNS_VALID |
+   CAM_DEV_QFRZN;
+   
xpt_freeze_devq(ccb-ccb_h.path, 1);
xpt_done(ccb);
goto done;
}
@@ -2512,7 +2515,8 @@ umass_cam_cb(struct umass_softc *sc, uni
 * recovered. We return an error to CAM and let CAM
 * retry the command if necessary.
 */
-   ccb-ccb_h.status = CAM_REQ_CMP_ERR;
+   xpt_freeze_devq(ccb-ccb_h.path, 1);
+   ccb-ccb_h.status = CAM_REQ_CMP_ERR | CAM_DEV_QFRZN;
xpt_done(ccb);
break;
}
@@ -2575,8 +2579,9 @@ umass_cam_sense_cb(struct umass_softc *s
 * usual.
 */
 
+   xpt_freeze_devq(ccb-ccb_h.path, 1);
ccb-ccb_h.status = CAM_SCSI_STATUS_ERROR
-   | CAM_AUTOSNS_VALID;
+   | CAM_AUTOSNS_VALID | CAM_DEV_QFRZN;
ccb-csio.scsi_status = SCSI_STATUS_CHECK_COND;
 
 #if 0
@@ -2587,17 +2592,18 @@ umass_cam_sense_cb(struct umass_softc *s
 
/* the rest of the command was filled in at attach */
 
-   if (umass_std_transform(sc, ccb,
+   if ((sc-sc_transform)(sc,
sc-cam_scsi_test_unit_ready.opcode,
-   sizeof(sc-cam_scsi_test_unit_ready))) {
+   sizeof(sc-cam_scsi_test_unit_ready)) == 1) {
umass_command_start(sc, DIR_NONE, NULL, 0,
ccb-ccb_h.timeout,
umass_cam_quirk_cb, ccb);
+   break;
}
-   break;
} else {
+   xpt_freeze_devq(ccb-ccb_h.path, 1);
ccb-ccb_h.status = CAM_SCSI_STATUS_ERROR
-   | CAM_AUTOSNS_VALID;
+   | CAM_AUTOSNS_VALID | CAM_DEV_QFRZN;
ccb-csio.scsi_status = SCSI_STATUS_CHECK_COND;
}
xpt_done(ccb);
@@ -2606,15 +2612,16 @@ umass_cam_sense_cb(struct umass_softc *s
default:
DPRINTF(sc, UDMASS_SCSI, Autosense failed, 
status %d\n, status);
-   ccb-ccb_h.status = CAM_AUTOSENSE_FAIL;
+   xpt_freeze_devq(ccb-ccb_h.path, 1);
+   ccb-ccb_h.status = CAM_AUTOSENSE_FAIL | CAM_DEV_QFRZN;
xpt_done(ccb);
}
 }
 
 /*
  * This completion code just handles the fact that we sent a test-unit-ready
- * after having previously failed a READ CAPACITY with CHECK_COND.  Even
- * though this command succeeded, we have to tell CAM to retry.
+ * after having previously failed a READ CAPACITY with CHECK_COND.  The CCB
+ * status for CAM is already set earlier.
  */
 static void
 umass_cam_quirk_cb(struct umass_softc *sc, union ccb *ccb, uint32_t residue,
@@ -2623,9 +2630,6 @@ umass_cam_quirk_cb(struct umass_softc *s
DPRINTF(sc, UDMASS_SCSI, Test unit ready 
returned status %d\n, status);
 
-   ccb-ccb_h.status = CAM_SCSI_STATUS_ERROR
-   | CAM_AUTOSNS_VALID;
-   ccb-csio.scsi_status = SCSI_STATUS_CHECK_COND;
xpt_done(ccb);
 }
 
@@ -2914,7 +2918,8 @@ umass_std_transform(struct umass_softc *
  

svn commit: r250143 - head

2013-05-01 Thread Benno Rice
Author: benno
Date: Wed May  1 09:56:09 2013
New Revision: 250143
URL: http://svnweb.freebsd.org/changeset/base/250143

Log:
  Optimize SUBDIR_OVERRIDE such that SUBDIR isn't automatically defined if
  SUBDIR_OVERRIDE is defined.
  
  PR:   conf/174071
  Submitted by: Garrett Cooper yaneurab...@gmail.com
  Sponsored by: EMC / Isilon Storage Division

Modified:
  head/Makefile.inc1

Modified: head/Makefile.inc1
==
--- head/Makefile.inc1  Wed May  1 09:20:13 2013(r250142)
+++ head/Makefile.inc1  Wed May  1 09:56:09 2013(r250143)
@@ -58,6 +58,9 @@
 # use that new version.  And the new (dynamically-linked) /bin/sh
 # will expect to find appropriate libraries in /lib and /libexec.
 #
+.if defined(SUBDIR_OVERRIDE)
+SUBDIR=${SUBDIR_OVERRIDE}
+.else
 SUBDIR=share/info lib libexec
 SUBDIR+=bin
 .if ${MK_GAMES} != no
@@ -96,9 +99,6 @@ SUBDIR+=etc
 SUBDIR+= ${_DIR}
 .endif
 .endfor
-
-.if defined(SUBDIR_OVERRIDE)
-SUBDIR=${SUBDIR_OVERRIDE}
 .endif
 
 .if defined(NOCLEAN)
___
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: r250105 - head/sys/dev/hwpmc

2013-05-01 Thread Gleb Smirnoff
On Tue, Apr 30, 2013 at 08:10:17PM +0400, Sergey Kandaurov wrote:
S On 30 April 2013 19:59, Davide Italiano dav...@freebsd.org wrote:
S  Author: davide
S  Date: Tue Apr 30 15:59:22 2013
S  New Revision: 250105
S  URL: http://svnweb.freebsd.org/changeset/base/250105
S 
S  Log:
Smalloc(9) cannot return NULL if M_WAITOK flag is specified.
S 
S  Modified:
Shead/sys/dev/hwpmc/hwpmc_mod.c
Shead/sys/dev/hwpmc/hwpmc_soft.c
S 
S  Modified: head/sys/dev/hwpmc/hwpmc_mod.c
S  
==
S  --- head/sys/dev/hwpmc/hwpmc_mod.c  Tue Apr 30 15:38:31 2013
(r250104)
S  +++ head/sys/dev/hwpmc/hwpmc_mod.c  Tue Apr 30 15:59:22 2013
(r250105)
S  @@ -2210,11 +2210,8 @@ pmc_allocate_pmc_descriptor(void)
S  struct pmc *pmc;
S 
S  pmc = malloc(sizeof(struct pmc), M_PMC, M_WAITOK|M_ZERO);
S  -
S  -   if (pmc != NULL) {
S  -   pmc-pm_owner = NULL;
S  -   LIST_INIT(pmc-pm_targets);
S  -   }
S  +   pmc-pm_owner = NULL;
S  +   LIST_INIT(pmc-pm_targets);
S 
S  PMCDBG(PMC,ALL,1, allocate-pmc - pmc=%p, pmc);
S 
S It looks like zeroing pm_owner can also be omitted with M_ZERO.

LIST_INIT is also an assignment of zero.

-- 
Totus tuus, Glebius.
___
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: r250144 - in stable/9/sys: cam/scsi dev/usb/storage

2013-05-01 Thread Alexander Motin
Author: mav
Date: Wed May  1 11:10:15 2013
New Revision: 250144
URL: http://svnweb.freebsd.org/changeset/base/250144

Log:
  MFC r245647 (by kan):
  Do not pretend to have autosense data when no such data is available.
  
  Make umass return an error code if SCSI sense retrieval request
  has failed. Make sure scsi_error_action honors SF_NO_RETRY and
  SF_NO_RECOVERY in all cases, even if it cannot parse sense bytes.

Modified:
  stable/9/sys/cam/scsi/scsi_all.c
  stable/9/sys/dev/usb/storage/umass.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/dev/   (props changed)

Modified: stable/9/sys/cam/scsi/scsi_all.c
==
--- stable/9/sys/cam/scsi/scsi_all.cWed May  1 09:56:09 2013
(r250143)
+++ stable/9/sys/cam/scsi/scsi_all.cWed May  1 11:10:15 2013
(r250144)
@@ -3071,16 +3071,15 @@ scsi_error_action(struct ccb_scsiio *csi
  SSQ_PRINT_SENSE;
}
}
-   if ((action  SS_MASK) = SS_START 
-   (sense_flags  SF_NO_RECOVERY)) {
-   action = ~SS_MASK;
-   action |= SS_FAIL;
-   } else if ((action  SS_MASK) == SS_RETRY 
-   (sense_flags  SF_NO_RETRY)) {
-   action = ~SS_MASK;
-   action |= SS_FAIL;
-   }
-
+   }
+   if ((action  SS_MASK) = SS_START 
+   (sense_flags  SF_NO_RECOVERY)) {
+   action = ~SS_MASK;
+   action |= SS_FAIL;
+   } else if ((action  SS_MASK) == SS_RETRY 
+   (sense_flags  SF_NO_RETRY)) {
+   action = ~SS_MASK;
+   action |= SS_FAIL;
}
if ((sense_flags  SF_PRINT_ALWAYS) != 0)
action |= SSQ_PRINT_SENSE;

Modified: stable/9/sys/dev/usb/storage/umass.c
==
--- stable/9/sys/dev/usb/storage/umass.cWed May  1 09:56:09 2013
(r250143)
+++ stable/9/sys/dev/usb/storage/umass.cWed May  1 11:10:15 2013
(r250144)
@@ -2602,9 +2602,13 @@ umass_cam_sense_cb(struct umass_softc *s
}
} else {
xpt_freeze_devq(ccb-ccb_h.path, 1);
-   ccb-ccb_h.status = CAM_SCSI_STATUS_ERROR
-   | CAM_AUTOSNS_VALID | CAM_DEV_QFRZN;
-   ccb-csio.scsi_status = SCSI_STATUS_CHECK_COND;
+   if (key = 0) {
+   ccb-ccb_h.status = CAM_SCSI_STATUS_ERROR
+   | CAM_AUTOSNS_VALID | CAM_DEV_QFRZN;
+   ccb-csio.scsi_status = SCSI_STATUS_CHECK_COND;
+   } else
+   ccb-ccb_h.status = CAM_AUTOSENSE_FAIL
+   | CAM_DEV_QFRZN;
}
xpt_done(ccb);
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: r250145 - head/sys/kern

2013-05-01 Thread Mikolaj Golub
Author: trociny
Date: Wed May  1 14:59:16 2013
New Revision: 250145
URL: http://svnweb.freebsd.org/changeset/base/250145

Log:
  Introduce a constant, ELF_NOTE_ROUNDSIZE, which evidently declare our
  intention to use 4-byte padding for elf notes.
  
  MFC after:3 weeks

Modified:
  head/sys/kern/imgact_elf.c

Modified: head/sys/kern/imgact_elf.c
==
--- head/sys/kern/imgact_elf.c  Wed May  1 11:10:15 2013(r250144)
+++ head/sys/kern/imgact_elf.c  Wed May  1 14:59:16 2013(r250145)
@@ -81,6 +81,7 @@ __FBSDID($FreeBSD$);
 #include machine/elf.h
 #include machine/md_var.h
 
+#define ELF_NOTE_ROUNDSIZE 4
 #define OLD_EI_BRAND   8
 
 static int __elfN(check_header)(const Elf_Ehdr *hdr);
@@ -161,7 +162,7 @@ __elfN(freebsd_trans_osrel)(const Elf_No
uintptr_t p;
 
p = (uintptr_t)(note + 1);
-   p += roundup2(note-n_namesz, sizeof(Elf32_Addr));
+   p += roundup2(note-n_namesz, ELF_NOTE_ROUNDSIZE);
*osrel = *(const int32_t *)(p);
 
return (TRUE);
@@ -186,7 +187,7 @@ kfreebsd_trans_osrel(const Elf_Note *not
uintptr_t p;
 
p = (uintptr_t)(note + 1);
-   p += roundup2(note-n_namesz, sizeof(Elf32_Addr));
+   p += roundup2(note-n_namesz, ELF_NOTE_ROUNDSIZE);
 
desc = (const Elf32_Word *)p;
if (desc[0] != GNU_KFREEBSD_ABI_DESC)
@@ -1546,7 +1547,7 @@ __elfN(puthdr)(struct thread *td, void *
phdr-p_filesz = notesz;
phdr-p_memsz = 0;
phdr-p_flags = PF_R;
-   phdr-p_align = sizeof(Elf32_Size);
+   phdr-p_align = ELF_NOTE_ROUNDSIZE;
phdr++;
 
/* All the writable segments from the program. */
@@ -1574,8 +1575,8 @@ register_note(struct note_info_list *lis
return (size);
 
notesize = sizeof(Elf_Note) +   /* note header */
-   roundup2(8, sizeof(Elf32_Size)) +   /* note name (FreeBSD) */
-   roundup2(size, sizeof(Elf32_Size)); /* note description */
+   roundup2(8, ELF_NOTE_ROUNDSIZE) +   /* note name (FreeBSD) */
+   roundup2(size, ELF_NOTE_ROUNDSIZE); /* note description */
 
return (notesize);
 }
@@ -1598,12 +1599,12 @@ __elfN(putnote)(struct note_info *ninfo,
sbuf_bcat(sb, note, sizeof(note));
sbuf_start_section(sb, old_len);
sbuf_bcat(sb, FreeBSD, note.n_namesz);
-   sbuf_end_section(sb, old_len, sizeof(Elf32_Size), 0);
+   sbuf_end_section(sb, old_len, ELF_NOTE_ROUNDSIZE, 0);
if (note.n_descsz == 0)
return;
sbuf_start_section(sb, old_len);
ninfo-outfunc(ninfo-outarg, sb, ninfo-outsize);
-   sbuf_end_section(sb, old_len, sizeof(Elf32_Size), 0);
+   sbuf_end_section(sb, old_len, ELF_NOTE_ROUNDSIZE, 0);
 }
 
 /*
@@ -2004,8 +2005,8 @@ __elfN(parse_notes)(struct image_params 
 
 nextnote:
note = (const Elf_Note *)((const char *)(note + 1) +
-   roundup2(note-n_namesz, sizeof(Elf32_Addr)) +
-   roundup2(note-n_descsz, sizeof(Elf32_Addr)));
+   roundup2(note-n_namesz, ELF_NOTE_ROUNDSIZE) +
+   roundup2(note-n_descsz, ELF_NOTE_ROUNDSIZE));
}
 
return (FALSE);
___
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: r250146 - head/lib/libprocstat

2013-05-01 Thread Mikolaj Golub
Author: trociny
Date: Wed May  1 15:01:05 2013
New Revision: 250146
URL: http://svnweb.freebsd.org/changeset/base/250146

Log:
  KVM method support for procstat_getgroups, procstat_getumask,
  procstat_getrlimit, and procstat_getosrel.
  
  MFC after:3 weeks

Modified:
  head/lib/libprocstat/libprocstat.c

Modified: head/lib/libprocstat/libprocstat.c
==
--- head/lib/libprocstat/libprocstat.c  Wed May  1 14:59:16 2013
(r250145)
+++ head/lib/libprocstat/libprocstat.c  Wed May  1 15:01:05 2013
(r250146)
@@ -39,6 +39,9 @@ __FBSDID($FreeBSD$);
 #include sys/elf.h
 #include sys/time.h
 #include sys/resourcevar.h
+#define_WANT_UCRED
+#include sys/ucred.h
+#undef _WANT_UCRED
 #include sys/proc.h
 #include sys/user.h
 #include sys/stat.h
@@ -141,19 +144,30 @@ static intprocstat_get_vnode_info_sysct
 struct vnstat *vn, char *errbuf);
 static gid_t   *procstat_getgroups_core(struct procstat_core *core,
 unsigned int *count);
+static gid_t * procstat_getgroups_kvm(kvm_t *kd, struct kinfo_proc *kp,
+unsigned int *count);
 static gid_t   *procstat_getgroups_sysctl(pid_t pid, unsigned int *count);
 static struct kinfo_kstack *procstat_getkstack_sysctl(pid_t pid,
 int *cntp);
+static int procstat_getosrel_core(struct procstat_core *core,
+int *osrelp);
+static int procstat_getosrel_kvm(kvm_t *kd, struct kinfo_proc *kp,
+int *osrelp);
+static int procstat_getosrel_sysctl(pid_t pid, int *osrelp);
 static int procstat_getpathname_core(struct procstat_core *core,
 char *pathname, size_t maxlen);
 static int procstat_getpathname_sysctl(pid_t pid, char *pathname,
 size_t maxlen);
 static int procstat_getrlimit_core(struct procstat_core *core, int which,
 struct rlimit* rlimit);
+static int procstat_getrlimit_kvm(kvm_t *kd, struct kinfo_proc *kp,
+int which, struct rlimit* rlimit);
 static int procstat_getrlimit_sysctl(pid_t pid, int which,
 struct rlimit* rlimit);
 static int procstat_getumask_core(struct procstat_core *core,
 unsigned short *maskp);
+static int procstat_getumask_kvm(kvm_t *kd, struct kinfo_proc *kp,
+unsigned short *maskp);
 static int procstat_getumask_sysctl(pid_t pid, unsigned short *maskp);
 static int vntype2psfsttype(int type);
 
@@ -1790,6 +1804,46 @@ procstat_freevmmap(struct procstat *proc
 }
 
 static gid_t *
+procstat_getgroups_kvm(kvm_t *kd, struct kinfo_proc *kp, unsigned int *cntp)
+{
+   struct proc proc;
+   struct ucred ucred;
+   gid_t *groups;
+   size_t len;
+
+   assert(kd != NULL);
+   assert(kp != NULL);
+   if (!kvm_read_all(kd, (unsigned long)kp-ki_paddr, proc,
+   sizeof(proc))) {
+   warnx(can't read proc struct at %p for pid %d,
+   kp-ki_paddr, kp-ki_pid);
+   return (NULL);
+   }
+   if (proc.p_ucred == NOCRED)
+   return (NULL);
+   if (!kvm_read_all(kd, (unsigned long)proc.p_ucred, ucred,
+   sizeof(ucred))) {
+   warnx(can't read ucred struct at %p for pid %d,
+   proc.p_ucred, kp-ki_pid);
+   return (NULL);
+   }
+   len = ucred.cr_ngroups * sizeof(gid_t);
+   groups = malloc(len);
+   if (groups == NULL) {
+   warn(malloc(%zu), len);
+   return (NULL);
+   }
+   if (!kvm_read_all(kd, (unsigned long)ucred.cr_groups, groups, len)) {
+   warnx(can't read groups at %p for pid %d,
+   ucred.cr_groups, kp-ki_pid);
+   free(groups);
+   return (NULL);
+   }
+   *cntp = ucred.cr_ngroups;
+   return (groups);
+}
+
+static gid_t *
 procstat_getgroups_sysctl(pid_t pid, unsigned int *cntp)
 {
int mib[4];
@@ -1834,8 +1888,7 @@ procstat_getgroups(struct procstat *proc
 {
switch(procstat-type) {
case PROCSTAT_KVM:
-   warnx(kvm method is not supported);
-   return (NULL);
+   return (procstat_getgroups_kvm(procstat-kd, kp, cntp));
case PROCSTAT_SYSCTL:
return (procstat_getgroups_sysctl(kp-ki_pid, cntp));
case PROCSTAT_CORE:
@@ -1854,6 +1907,24 @@ procstat_freegroups(struct procstat *pro
 }
 
 static int
+procstat_getumask_kvm(kvm_t *kd, struct kinfo_proc *kp, unsigned short *maskp)
+{
+   struct filedesc fd;
+
+   assert(kd != NULL);
+   assert(kp != NULL);
+   if (kp-ki_fd == NULL)
+   return (-1);
+   if (!kvm_read_all(kd, (unsigned long)kp-ki_fd, fd, sizeof(fd))) {
+   warnx(can't read filedesc at %p for pid %d, kp-ki_fd,
+   kp-ki_pid);
+   return (-1);
+   }
+   *maskp = fd.fd_cmask;
+   return (0);
+}
+
+static int
 procstat_getumask_sysctl(pid_t pid, unsigned short *maskp)
 {
int error;
@@ -1895,8 +1966,7 @@ procstat_getumask(struct 

svn commit: r250147 - head/lib/libprocstat

2013-05-01 Thread Mikolaj Golub
Author: trociny
Date: Wed May  1 15:02:58 2013
New Revision: 250147
URL: http://svnweb.freebsd.org/changeset/base/250147

Log:
  procstat_getpathname: for kvm method, instead of returning the error
  that the method is not supported, return an empty string.
  
  This looks more handy for callers like procstat(1), which will not
  abort after the failed call and still output some useful information.
  
  MFC after:3 weeks

Modified:
  head/lib/libprocstat/libprocstat.c

Modified: head/lib/libprocstat/libprocstat.c
==
--- head/lib/libprocstat/libprocstat.c  Wed May  1 15:01:05 2013
(r250146)
+++ head/lib/libprocstat/libprocstat.c  Wed May  1 15:02:58 2013
(r250147)
@@ -2114,8 +2114,10 @@ procstat_getpathname(struct procstat *pr
 {
switch(procstat-type) {
case PROCSTAT_KVM:
-   warnx(kvm method is not supported);
-   return (-1);
+   /* XXX: Return empty string. */
+   if (maxlen  0)
+   pathname[0] = '\0';
+   return (0);
case PROCSTAT_SYSCTL:
return (procstat_getpathname_sysctl(kp-ki_pid, pathname,
maxlen));
___
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: r250148 - head/share/misc

2013-05-01 Thread Niclas Zeising
Author: zeising (doc,ports committer)
Date: Wed May  1 17:29:42 2013
New Revision: 250148
URL: http://svnweb.freebsd.org/changeset/base/250148

Log:
  Add OpenBSD 5.3, released today, May 1 2013.

Modified:
  head/share/misc/bsd-family-tree

Modified: head/share/misc/bsd-family-tree
==
--- head/share/misc/bsd-family-tree Wed May  1 15:02:58 2013
(r250147)
+++ head/share/misc/bsd-family-tree Wed May  1 17:29:42 2013
(r250148)
@@ -261,6 +261,10 @@ FreeBSD 5.2   |  |  
  |  FreeBSD   |  | |   |
  |9.1 |  | |   |
  ||  | |   |
+ ||  |OpenBSD 5.3  |
+ ||  | |   |
+ ||  | |   |
+ ||  | |   |
 FreeBSD 10 -current   |  NetBSD -current  OpenBSD -current |
  ||  | |   |
  vv  v v   v
@@ -558,6 +562,7 @@ NetBSD 6.0  2012-10-17 [NBD]
 OpenBSD 5.22012-11-01 [OBD]
 DragonFly 3.2.12012-11-02 [DFB]
 FreeBSD 9.12012-12-30 [FBD]
+OpenBSD 5.32013-05-01 [OBD]
 
 Bibliography
 
___
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: r250149 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs

2013-05-01 Thread Davide Italiano
Author: davide
Date: Wed May  1 17:34:44 2013
New Revision: 250149
URL: http://svnweb.freebsd.org/changeset/base/250149

Log:
  In case ZFS doesn't use UMA for buffers there's no need to waste memory
  creating zones that will remain empty.
  
  Reviewed by:  pjd

Modified:
  head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c

Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c
==
--- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c   Wed May  1 
17:29:42 2013(r250148)
+++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c   Wed May  1 
17:34:44 2013(r250149)
@@ -154,6 +154,8 @@ zio_init(void)
sizeof (zio_t), 0, NULL, NULL, NULL, NULL, NULL, 0);
zio_link_cache = kmem_cache_create(zio_link_cache,
sizeof (zio_link_t), 0, NULL, NULL, NULL, NULL, NULL, 0);
+   if (!zio_use_uma)
+   goto out;
 
/*
 * For small buffers, we want a cache for each multiple of
@@ -217,6 +219,7 @@ zio_init(void)
if (zio_data_buf_cache[c - 1] == NULL)
zio_data_buf_cache[c - 1] = zio_data_buf_cache[c];
}
+out:
 
/*
 * The zio write taskqs have 1 thread per cpu, allow 1/2 of the taskqs
___
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: r250150 - head/share/misc

2013-05-01 Thread Niclas Zeising
Author: zeising (doc,ports committer)
Date: Wed May  1 17:59:41 2013
New Revision: 250150
URL: http://svnweb.freebsd.org/changeset/base/250150

Log:
  Add DragonFly BSD 3.4.1, released April 29 2013.
  
  Submitted by: Nikolai Lifanov lifa...@mail.lifanov.com

Modified:
  head/share/misc/bsd-family-tree

Modified: head/share/misc/bsd-family-tree
==
--- head/share/misc/bsd-family-tree Wed May  1 17:34:44 2013
(r250149)
+++ head/share/misc/bsd-family-tree Wed May  1 17:59:41 2013
(r250150)
@@ -261,7 +261,7 @@ FreeBSD 5.2   |  |  
  |  FreeBSD   |  | |   |
  |9.1 |  | |   |
  ||  | |   |
- ||  |OpenBSD 5.3  |
+ ||  |OpenBSD 5.3  DragonFly 3.4.1
  ||  | |   |
  ||  | |   |
  ||  | |   |
@@ -562,6 +562,7 @@ NetBSD 6.0  2012-10-17 [NBD]
 OpenBSD 5.22012-11-01 [OBD]
 DragonFly 3.2.12012-11-02 [DFB]
 FreeBSD 9.12012-12-30 [FBD]
+DragonFly 3.4.12013-04-29 [DFB]
 OpenBSD 5.32013-05-01 [OBD]
 
 Bibliography
___
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: r250151 - in stable: 6/sys/boot/i386/btx/btx 6/sys/boot/pc98/btx/btx 7/sys/boot/i386/btx/btx 7/sys/boot/pc98/btx/btx 8/sys/boot/i386/btx/btx 8/sys/boot/pc98/btx/btx 9/sys/boot/i386/btx/...

2013-05-01 Thread Dimitry Andric
Author: dim
Date: Wed May  1 18:06:53 2013
New Revision: 250151
URL: http://svnweb.freebsd.org/changeset/base/250151

Log:
  MFC r249846:
  
  When rebooting (exiting) from the BTX loader, make sure to restore the
  GDT from the correct segment, otherwise a triple fault would be caused.
  In some virtual environments (VMware, VirtualBox, etc) this could lead
  to a unhandled error or hang in the guest emulation software.
  
  Thanks to avg and jhb for a few hints in the right direction.
  
  Noticed by:   Jeremy Chadwick j...@koitsu.org (and many others)

Modified:
  stable/9/sys/boot/i386/btx/btx/btx.S
  stable/9/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/boot/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/6/sys/boot/i386/btx/btx/btx.S
  stable/6/sys/boot/pc98/btx/btx/btx.S
  stable/7/sys/boot/i386/btx/btx/btx.S
  stable/7/sys/boot/pc98/btx/btx/btx.S
  stable/8/sys/boot/i386/btx/btx/btx.S
  stable/8/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/6/sys/   (props changed)
  stable/7/sys/   (props changed)
  stable/8/sys/   (props changed)
  stable/8/sys/boot/   (props changed)

Modified: stable/9/sys/boot/i386/btx/btx/btx.S
==
--- stable/9/sys/boot/i386/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/9/sys/boot/i386/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -248,7 +248,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */

Modified: stable/9/sys/boot/pc98/btx/btx/btx.S
==
--- stable/9/sys/boot/pc98/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/9/sys/boot/pc98/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -248,7 +248,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */
___
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: r250151 - in stable: 6/sys/boot/i386/btx/btx 6/sys/boot/pc98/btx/btx 7/sys/boot/i386/btx/btx 7/sys/boot/pc98/btx/btx 8/sys/boot/i386/btx/btx 8/sys/boot/pc98/btx/btx 9/sys/boot/i386/btx/...

2013-05-01 Thread Dimitry Andric
Author: dim
Date: Wed May  1 18:06:53 2013
New Revision: 250151
URL: http://svnweb.freebsd.org/changeset/base/250151

Log:
  MFC r249846:
  
  When rebooting (exiting) from the BTX loader, make sure to restore the
  GDT from the correct segment, otherwise a triple fault would be caused.
  In some virtual environments (VMware, VirtualBox, etc) this could lead
  to a unhandled error or hang in the guest emulation software.
  
  Thanks to avg and jhb for a few hints in the right direction.
  
  Noticed by:   Jeremy Chadwick j...@koitsu.org (and many others)

Modified:
  stable/8/sys/boot/i386/btx/btx/btx.S
  stable/8/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/boot/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/6/sys/boot/i386/btx/btx/btx.S
  stable/6/sys/boot/pc98/btx/btx/btx.S
  stable/7/sys/boot/i386/btx/btx/btx.S
  stable/7/sys/boot/pc98/btx/btx/btx.S
  stable/9/sys/boot/i386/btx/btx/btx.S
  stable/9/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/6/sys/   (props changed)
  stable/7/sys/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/boot/   (props changed)

Modified: stable/8/sys/boot/i386/btx/btx/btx.S
==
--- stable/8/sys/boot/i386/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/8/sys/boot/i386/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -248,7 +248,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */

Modified: stable/8/sys/boot/pc98/btx/btx/btx.S
==
--- stable/8/sys/boot/pc98/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/8/sys/boot/pc98/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -248,7 +248,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */
___
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: r250151 - in stable: 6/sys/boot/i386/btx/btx 6/sys/boot/pc98/btx/btx 7/sys/boot/i386/btx/btx 7/sys/boot/pc98/btx/btx 8/sys/boot/i386/btx/btx 8/sys/boot/pc98/btx/btx 9/sys/boot/i386/btx/...

2013-05-01 Thread Dimitry Andric
Author: dim
Date: Wed May  1 18:06:53 2013
New Revision: 250151
URL: http://svnweb.freebsd.org/changeset/base/250151

Log:
  MFC r249846:
  
  When rebooting (exiting) from the BTX loader, make sure to restore the
  GDT from the correct segment, otherwise a triple fault would be caused.
  In some virtual environments (VMware, VirtualBox, etc) this could lead
  to a unhandled error or hang in the guest emulation software.
  
  Thanks to avg and jhb for a few hints in the right direction.
  
  Noticed by:   Jeremy Chadwick j...@koitsu.org (and many others)

Modified:
  stable/7/sys/boot/i386/btx/btx/btx.S
  stable/7/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/7/sys/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/6/sys/boot/i386/btx/btx/btx.S
  stable/6/sys/boot/pc98/btx/btx/btx.S
  stable/8/sys/boot/i386/btx/btx/btx.S
  stable/8/sys/boot/pc98/btx/btx/btx.S
  stable/9/sys/boot/i386/btx/btx/btx.S
  stable/9/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/6/sys/   (props changed)
  stable/8/sys/   (props changed)
  stable/8/sys/boot/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/boot/   (props changed)

Modified: stable/7/sys/boot/i386/btx/btx/btx.S
==
--- stable/7/sys/boot/i386/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/7/sys/boot/i386/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -246,7 +246,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */

Modified: stable/7/sys/boot/pc98/btx/btx/btx.S
==
--- stable/7/sys/boot/pc98/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/7/sys/boot/pc98/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -246,7 +246,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */
___
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: r250151 - in stable: 6/sys/boot/i386/btx/btx 6/sys/boot/pc98/btx/btx 7/sys/boot/i386/btx/btx 7/sys/boot/pc98/btx/btx 8/sys/boot/i386/btx/btx 8/sys/boot/pc98/btx/btx 9/sys/boot/i386/btx/...

2013-05-01 Thread Dimitry Andric
Author: dim
Date: Wed May  1 18:06:53 2013
New Revision: 250151
URL: http://svnweb.freebsd.org/changeset/base/250151

Log:
  MFC r249846:
  
  When rebooting (exiting) from the BTX loader, make sure to restore the
  GDT from the correct segment, otherwise a triple fault would be caused.
  In some virtual environments (VMware, VirtualBox, etc) this could lead
  to a unhandled error or hang in the guest emulation software.
  
  Thanks to avg and jhb for a few hints in the right direction.
  
  Noticed by:   Jeremy Chadwick j...@koitsu.org (and many others)

Modified:
  stable/6/sys/boot/i386/btx/btx/btx.S
  stable/6/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/6/sys/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/7/sys/boot/i386/btx/btx/btx.S
  stable/7/sys/boot/pc98/btx/btx/btx.S
  stable/8/sys/boot/i386/btx/btx/btx.S
  stable/8/sys/boot/pc98/btx/btx/btx.S
  stable/9/sys/boot/i386/btx/btx/btx.S
  stable/9/sys/boot/pc98/btx/btx/btx.S
Directory Properties:
  stable/7/sys/   (props changed)
  stable/8/sys/   (props changed)
  stable/8/sys/boot/   (props changed)
  stable/9/sys/   (props changed)
  stable/9/sys/boot/   (props changed)

Modified: stable/6/sys/boot/i386/btx/btx/btx.S
==
--- stable/6/sys/boot/i386/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/6/sys/boot/i386/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -246,7 +246,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */

Modified: stable/6/sys/boot/pc98/btx/btx/btx.S
==
--- stable/6/sys/boot/pc98/btx/btx/btx.SWed May  1 17:59:41 2013
(r250150)
+++ stable/6/sys/boot/pc98/btx/btx/btx.SWed May  1 18:06:53 2013
(r250151)
@@ -246,7 +246,7 @@ exit:   cli # 
Disable interrupts
 /*
  * Restore the GDT in case we caught a kernel trap.
  */
-   lgdt gdtdesc# Set GDT
+   lgdt %cs:gdtdesc# Set GDT
 /*
  * To 16 bits.
  */
___
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: r250152 - head/sys/amd64/amd64

2013-05-01 Thread Konstantin Belousov
Author: kib
Date: Wed May  1 20:03:50 2013
New Revision: 250152
URL: http://svnweb.freebsd.org/changeset/base/250152

Log:
  The check to ensure that xstate_bv always has XFEATURE_ENABLED_X87 and
  XFEATURE_ENABLED_SSE bits set is not needed.  CPU correctly handles
  any bitmask which is subset of the enabled bits in %XCR0.
  
  More, CPU instructions XSAVE and XSAVEOPT could write the mask without
  e.g. XFEATURE_ENABLED_SSE, after the VZEROALL.  The check prevents the
  restoration of the otherwise valid FPU save area.
  
  In collaboration with:jhb
  MFC after:1 week

Modified:
  head/sys/amd64/amd64/fpu.c

Modified: head/sys/amd64/amd64/fpu.c
==
--- head/sys/amd64/amd64/fpu.c  Wed May  1 18:06:53 2013(r250151)
+++ head/sys/amd64/amd64/fpu.c  Wed May  1 20:03:50 2013(r250152)
@@ -743,9 +743,6 @@ fpusetxstate(struct thread *td, char *xf
 */
if (bv  ~xsave_mask)
return (EINVAL);
-   if ((bv  (XFEATURE_ENABLED_X87 | XFEATURE_ENABLED_SSE)) !=
-   (XFEATURE_ENABLED_X87 | XFEATURE_ENABLED_SSE))
-   return (EINVAL);
 
hdr = (struct xstate_hdr *)(get_pcb_user_save_td(td) + 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: r250153 - head/sys/amd64/amd64

2013-05-01 Thread Konstantin Belousov
Author: kib
Date: Wed May  1 20:08:33 2013
New Revision: 250153
URL: http://svnweb.freebsd.org/changeset/base/250153

Log:
  Partially saved extended state must be handled always, i.e. for both
  fpu-owned context, and for pcb-saved one.  More, the XSAVE could do
  partial save, same as XSAVEOPT, so qualifier for the handler should be
  use_xsave and not use_xsaveopt.
  
  Since xsave_area_desc is now needed regardless of the XSAVEOPT use,
  remove the write-only use_xsaveopt variable.
  
  In collaboration with:jhb
  MFC after:1 week

Modified:
  head/sys/amd64/amd64/fpu.c

Modified: head/sys/amd64/amd64/fpu.c
==
--- head/sys/amd64/amd64/fpu.c  Wed May  1 20:03:50 2013(r250152)
+++ head/sys/amd64/amd64/fpu.c  Wed May  1 20:08:33 2013(r250153)
@@ -132,7 +132,6 @@ static  voidfpu_clean_state(void);
 SYSCTL_INT(_hw, HW_FLOATINGPT, floatingpoint, CTLFLAG_RD,
 NULL, 1, Floating point instructions executed in hardware);
 
-static int use_xsaveopt;
 int use_xsave; /* non-static for cpu_switch.S */
 uint64_t xsave_mask;   /* the same */
 static uma_zone_t fpu_save_area_zone;
@@ -198,7 +197,6 @@ fpuinit_bsp1(void)
 * REX byte, and set the bit 4 of the r/m byte.
 */
ctx_switch_xsave[3] |= 0x10;
-   use_xsaveopt = 1;
}
 }
 
@@ -296,7 +294,7 @@ fpuinitstate(void *arg __unused)
 * Create a table describing the layout of the CPU Extended
 * Save Area.
 */
-   if (use_xsaveopt) {
+   if (use_xsave) {
max_ext_n = flsl(xsave_mask);
xsave_area_desc = malloc(max_ext_n * sizeof(struct
xsave_area_elm_descr), M_DEVBUF, M_WAITOK | M_ZERO);
@@ -661,7 +659,7 @@ fpugetregs(struct thread *td)
struct pcb *pcb;
uint64_t *xstate_bv, bit;
char *sa;
-   int max_ext_n, i;
+   int max_ext_n, i, owned;
 
pcb = td-td_pcb;
if ((pcb-pcb_flags  PCB_USERFPUINITDONE) == 0) {
@@ -675,31 +673,31 @@ fpugetregs(struct thread *td)
critical_enter();
if (td == PCPU_GET(fpcurthread)  PCB_USER_FPU(pcb)) {
fpusave(get_pcb_user_save_pcb(pcb));
-   critical_exit();
-   return (_MC_FPOWNED_FPU);
+   owned = _MC_FPOWNED_FPU;
} else {
-   critical_exit();
-   if (use_xsaveopt) {
-   /*
-* Handle partially saved state.
-*/
-   sa = (char *)get_pcb_user_save_pcb(pcb);
-   xstate_bv = (uint64_t *)(sa + sizeof(struct savefpu) +
-   offsetof(struct xstate_hdr, xstate_bv));
-   max_ext_n = flsl(xsave_mask);
-   for (i = 0; i  max_ext_n; i++) {
-   bit = 1  i;
-   if ((*xstate_bv  bit) != 0)
-   continue;
-   bcopy((char *)fpu_initialstate +
-   xsave_area_desc[i].offset,
-   sa + xsave_area_desc[i].offset,
-   xsave_area_desc[i].size);
-   *xstate_bv |= bit;
-   }
+   owned = _MC_FPOWNED_PCB;
+   }
+   critical_exit();
+   if (use_xsave) {
+   /*
+* Handle partially saved state.
+*/
+   sa = (char *)get_pcb_user_save_pcb(pcb);
+   xstate_bv = (uint64_t *)(sa + sizeof(struct savefpu) +
+   offsetof(struct xstate_hdr, xstate_bv));
+   max_ext_n = flsl(xsave_mask);
+   for (i = 0; i  max_ext_n; i++) {
+   bit = 1  i;
+   if ((*xstate_bv  bit) != 0)
+   continue;
+   bcopy((char *)fpu_initialstate +
+   xsave_area_desc[i].offset,
+   sa + xsave_area_desc[i].offset,
+   xsave_area_desc[i].size);
+   *xstate_bv |= bit;
}
-   return (_MC_FPOWNED_PCB);
}
+   return (owned);
 }
 
 void
___
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: r250154 - in head: lib/libc/sys lib/libthr lib/libthr/thread sys/compat/freebsd32 sys/kern sys/sys

2013-05-01 Thread Jilles Tjoelker
Author: jilles
Date: Wed May  1 20:10:21 2013
New Revision: 250154
URL: http://svnweb.freebsd.org/changeset/base/250154

Log:
  Add accept4() system call.
  
  The accept4() function, compared to accept(), allows setting the new file
  descriptor atomically close-on-exec and explicitly controlling the
  non-blocking status on the new socket. (Note that the latter point means
  that accept() is not equivalent to any form of accept4().)
  
  The linuxulator's accept4 implementation leaves a race window where the new
  file descriptor is not close-on-exec because it calls sys_accept(). This
  implementation leaves no such race window (by using falloc() flags). The
  linuxulator could be fixed and simplified by using the new code.
  
  Like accept(), accept4() is async-signal-safe, a cancellation point and
  permitted in capability mode.

Modified:
  head/lib/libc/sys/Makefile.inc
  head/lib/libc/sys/Symbol.map
  head/lib/libc/sys/accept.2
  head/lib/libthr/pthread.map
  head/lib/libthr/thread/thr_syscalls.c
  head/sys/compat/freebsd32/syscalls.master
  head/sys/kern/capabilities.conf
  head/sys/kern/syscalls.master
  head/sys/kern/uipc_syscalls.c
  head/sys/sys/socket.h
  head/sys/sys/syscallsubr.h

Modified: head/lib/libc/sys/Makefile.inc
==
--- head/lib/libc/sys/Makefile.inc  Wed May  1 20:08:33 2013
(r250153)
+++ head/lib/libc/sys/Makefile.inc  Wed May  1 20:10:21 2013
(r250154)
@@ -270,6 +270,7 @@ MAN+=   sctp_generic_recvmsg.2 \
wait.2 \
write.2
 
+MLINKS+=accept.2 accept4.2
 MLINKS+=access.2 eaccess.2 \
access.2 faccessat.2
 MLINKS+=brk.2 sbrk.2

Modified: head/lib/libc/sys/Symbol.map
==
--- head/lib/libc/sys/Symbol.mapWed May  1 20:08:33 2013
(r250153)
+++ head/lib/libc/sys/Symbol.mapWed May  1 20:10:21 2013
(r250154)
@@ -378,6 +378,7 @@ FBSD_1.2 {
 };
 
 FBSD_1.3 {
+   accept4;
bindat;
cap_fcntls_get;
cap_fcntls_limit;
@@ -461,6 +462,8 @@ FBSDprivate_1.0 {
__sys_abort2;
_accept;
__sys_accept;
+   _accept4;
+   __sys_accept4;
_access;
__sys_access;
_acct;

Modified: head/lib/libc/sys/accept.2
==
--- head/lib/libc/sys/accept.2  Wed May  1 20:08:33 2013(r250153)
+++ head/lib/libc/sys/accept.2  Wed May  1 20:10:21 2013(r250154)
@@ -41,6 +41,8 @@
 .In sys/socket.h
 .Ft int
 .Fn accept int s struct sockaddr * restrict addr socklen_t * restrict 
addrlen
+.Ft int
+.Fn accept4 int s struct sockaddr * restrict addr socklen_t * restrict 
addrlen int flags
 .Sh DESCRIPTION
 The argument
 .Fa s
@@ -66,6 +68,26 @@ and
 signals from the original socket
 .Fa s .
 .Pp
+The
+.Fn accept4
+system call is similar,
+but the
+.Dv O_NONBLOCK
+property of the new socket is instead determined by the
+.Dv SOCK_NONBLOCK
+flag in the
+.Fa flags
+argument,
+the
+.Dv O_ASYNC
+property is cleared,
+the signal destination is cleared
+and the close-on-exec flag on the new file descriptor can be set via the
+.Dv SOCK_CLOEXEC
+flag in the
+.Fa flags
+argument.
+.Pp
 If no pending connections are
 present on the queue, and the original socket
 is not marked as non-blocking,
@@ -141,13 +163,15 @@ properties and the signal destination be
 but should set them explicitly using
 .Xr fcntl 2 .
 .Sh RETURN VALUES
-The call returns \-1 on error.
-If it succeeds, it returns a non-negative
+These calls return \-1 on error.
+If they succeed, they return a non-negative
 integer that is a descriptor for the accepted socket.
 .Sh ERRORS
 The
 .Fn accept
-system call will fail if:
+and
+.Fn accept4
+system calls will fail if:
 .Bl -tag -width Er
 .It Bq Er EBADF
 The descriptor is invalid.
@@ -176,6 +200,16 @@ are present to be accepted.
 A connection arrived, but it was closed while waiting
 on the listen queue.
 .El
+.Pp
+The
+.Fn accept4
+system call will also fail if:
+.Bl -tag -width Er
+.It Bq Er EINVAL
+The
+.Fa flags
+argument is invalid.
+.El
 .Sh SEE ALSO
 .Xr bind 2 ,
 .Xr connect 2 ,
@@ -190,3 +224,8 @@ The
 .Fn accept
 system call appeared in
 .Bx 4.2 .
+.Pp
+The
+.Fn accept4
+system call appeared in
+.Fx 10.0 .

Modified: head/lib/libthr/pthread.map
==
--- head/lib/libthr/pthread.map Wed May  1 20:08:33 2013(r250153)
+++ head/lib/libthr/pthread.map Wed May  1 20:10:21 2013(r250154)
@@ -181,6 +181,7 @@ FBSDprivate_1.0 {
___wait;
___waitpid;
__accept;
+   __accept4;
__aio_suspend;
__close;
__connect;
@@ -408,3 +409,7 @@ FBSD_1.2 {
setcontext;
swapcontext;
 };
+
+FBSD_1.3 {
+   accept4;
+};

Modified: head/lib/libthr/thread/thr_syscalls.c

svn commit: r250155 - in head/sys: compat/freebsd32 kern sys

2013-05-01 Thread Jilles Tjoelker
Author: jilles
Date: Wed May  1 20:12:58 2013
New Revision: 250155
URL: http://svnweb.freebsd.org/changeset/base/250155

Log:
  Regenerate files for accept4().

Modified:
  head/sys/compat/freebsd32/freebsd32_proto.h
  head/sys/compat/freebsd32/freebsd32_syscall.h
  head/sys/compat/freebsd32/freebsd32_syscalls.c
  head/sys/compat/freebsd32/freebsd32_sysent.c
  head/sys/compat/freebsd32/freebsd32_systrace_args.c
  head/sys/kern/init_sysent.c
  head/sys/kern/syscalls.c
  head/sys/kern/systrace_args.c
  head/sys/sys/syscall.h
  head/sys/sys/syscall.mk
  head/sys/sys/sysproto.h

Modified: head/sys/compat/freebsd32/freebsd32_proto.h
==
--- head/sys/compat/freebsd32/freebsd32_proto.h Wed May  1 20:10:21 2013
(r250154)
+++ head/sys/compat/freebsd32/freebsd32_proto.h Wed May  1 20:12:58 2013
(r250155)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
  */
 
 #ifndef _FREEBSD32_SYSPROTO_H_

Modified: head/sys/compat/freebsd32/freebsd32_syscall.h
==
--- head/sys/compat/freebsd32/freebsd32_syscall.h   Wed May  1 20:10:21 
2013(r250154)
+++ head/sys/compat/freebsd32/freebsd32_syscall.h   Wed May  1 20:12:58 
2013(r250155)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
  */
 
 #defineFREEBSD32_SYS_syscall   0
@@ -438,4 +438,5 @@
 #defineFREEBSD32_SYS_bindat538
 #defineFREEBSD32_SYS_connectat 539
 #defineFREEBSD32_SYS_chflagsat 540
-#defineFREEBSD32_SYS_MAXSYSCALL541
+#defineFREEBSD32_SYS_accept4   541
+#defineFREEBSD32_SYS_MAXSYSCALL542

Modified: head/sys/compat/freebsd32/freebsd32_syscalls.c
==
--- head/sys/compat/freebsd32/freebsd32_syscalls.c  Wed May  1 20:10:21 
2013(r250154)
+++ head/sys/compat/freebsd32/freebsd32_syscalls.c  Wed May  1 20:12:58 
2013(r250155)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
  */
 
 const char *freebsd32_syscallnames[] = {
@@ -564,4 +564,5 @@ const char *freebsd32_syscallnames[] = {
bindat,   /* 538 = bindat */
connectat,/* 539 = connectat */
chflagsat,/* 540 = chflagsat */
+   accept4,  /* 541 = accept4 */
 };

Modified: head/sys/compat/freebsd32/freebsd32_sysent.c
==
--- head/sys/compat/freebsd32/freebsd32_sysent.cWed May  1 20:10:21 
2013(r250154)
+++ head/sys/compat/freebsd32/freebsd32_sysent.cWed May  1 20:12:58 
2013(r250155)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
  */
 
 #include opt_compat.h
@@ -601,4 +601,5 @@ struct sysent freebsd32_sysent[] = {
{ AS(bindat_args), (sy_call_t *)sys_bindat, AUE_BINDAT, NULL, 0, 0, 0, 
SY_THR_STATIC }, /* 538 = bindat */
{ AS(connectat_args), (sy_call_t *)sys_connectat, AUE_CONNECTAT, NULL, 
0, 0, 0, SY_THR_STATIC },/* 539 = connectat */
{ AS(chflagsat_args), (sy_call_t *)sys_chflagsat, AUE_CHFLAGSAT, NULL, 
0, 0, 0, SY_THR_STATIC },/* 540 = chflagsat */
+   { AS(accept4_args), (sy_call_t *)sys_accept4, AUE_ACCEPT, NULL, 0, 0, 
0, SY_THR_STATIC },   /* 541 = accept4 */
 };

Modified: head/sys/compat/freebsd32/freebsd32_systrace_args.c
==
--- head/sys/compat/freebsd32/freebsd32_systrace_args.c Wed May  1 20:10:21 
2013(r250154)
+++ head/sys/compat/freebsd32/freebsd32_systrace_args.c Wed May  1 20:12:58 
2013(r250155)
@@ -3160,6 +3160,16 @@ systrace_args(int sysnum, void *params, 
*n_args = 4;
break;
}
+   /* accept4 */
+   case 541: {
+   struct accept4_args *p = params;
+   iarg[0] = p-s; /* int */
+   uarg[1] = (intptr_t) p-name; /* struct sockaddr *__restrict */
+   uarg[2] = (intptr_t) p-anamelen; /* __socklen_t *__restrict */
+   iarg[3] = p-flags; /* int */
+   *n_args = 4;
+   break;
+   }
default:
 

svn commit: r250156 - vendor/flex/dist

2013-05-01 Thread Jung-uk Kim
Author: jkim
Date: Wed May  1 21:53:38 2013
New Revision: 250156
URL: http://svnweb.freebsd.org/changeset/base/250156

Log:
  Clean up svn:keywords property.

Modified:
Directory Properties:
  vendor/flex/dist/FlexLexer.h   (props changed)
  vendor/flex/dist/Makefile.am   (props changed)
  vendor/flex/dist/Makefile.in   (props changed)
  vendor/flex/dist/autogen.sh   (props changed)
  vendor/flex/dist/buf.c   (props changed)
  vendor/flex/dist/ccl.c   (props changed)
  vendor/flex/dist/conf.in   (props changed)
  vendor/flex/dist/configure.in   (props changed)
  vendor/flex/dist/dfa.c   (props changed)
  vendor/flex/dist/ecs.c   (props changed)
  vendor/flex/dist/filter.c   (props changed)
  vendor/flex/dist/flexdef.h   (props changed)
  vendor/flex/dist/flexint.h   (props changed)
  vendor/flex/dist/gen.c   (props changed)
  vendor/flex/dist/gettext.h   (props changed)
  vendor/flex/dist/libmain.c   (props changed)
  vendor/flex/dist/libyywrap.c   (props changed)
  vendor/flex/dist/main.c   (props changed)
  vendor/flex/dist/misc.c   (props changed)
  vendor/flex/dist/mkskel.sh   (props changed)
  vendor/flex/dist/nfa.c   (props changed)
  vendor/flex/dist/options.c   (props changed)
  vendor/flex/dist/options.h   (props changed)
  vendor/flex/dist/parse.c   (props changed)
  vendor/flex/dist/parse.h   (props changed)
  vendor/flex/dist/parse.y   (props changed)
  vendor/flex/dist/regex.c   (props changed)
  vendor/flex/dist/scan.c   (props changed)
  vendor/flex/dist/scan.l   (props changed)
  vendor/flex/dist/scanflags.c   (props changed)
  vendor/flex/dist/scanopt.c   (props changed)
  vendor/flex/dist/scanopt.h   (props changed)
  vendor/flex/dist/skel.c   (props changed)
  vendor/flex/dist/sym.c   (props changed)
  vendor/flex/dist/tables.c   (props changed)
  vendor/flex/dist/tables.h   (props changed)
  vendor/flex/dist/tables_shared.c   (props changed)
  vendor/flex/dist/tables_shared.h   (props changed)
  vendor/flex/dist/tblcmp.c   (props changed)
  vendor/flex/dist/version.h   (props changed)
  vendor/flex/dist/yylex.c   (props changed)
___
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: r250157 - head/sys/kgssapi/krb5

2013-05-01 Thread Rick Macklem
Author: rmacklem
Date: Wed May  1 22:07:55 2013
New Revision: 250157
URL: http://svnweb.freebsd.org/changeset/base/250157

Log:
  Isilon reported that sec=krb5p NFS mounts had a problem when m_len == 0
  for the last mbuf of the list with an encrypted message. This patch replaces
  the KASSERT() with code that handles this case.
  
  Reported by:  john.gemign...@isilon.com
  Reviewed by:  jhb
  MFC after:2 weeks

Modified:
  head/sys/kgssapi/krb5/krb5_mech.c

Modified: head/sys/kgssapi/krb5/krb5_mech.c
==
--- head/sys/kgssapi/krb5/krb5_mech.c   Wed May  1 21:53:38 2013
(r250156)
+++ head/sys/kgssapi/krb5/krb5_mech.c   Wed May  1 22:07:55 2013
(r250157)
@@ -1585,6 +1585,8 @@ m_trim(struct mbuf *m, int len)
struct mbuf *n;
int off;
 
+   if (m == NULL)
+   return;
n = m_getptr(m, len, off);
if (n) {
n-m_len = off;
@@ -1600,7 +1602,7 @@ krb5_unwrap_old(struct krb5_context *kc,
 uint8_t sgn_alg[2], uint8_t seal_alg[2])
 {
OM_uint32 res;
-   struct mbuf *m, *mlast, *hm, *cm;
+   struct mbuf *m, *mlast, *hm, *cm, *n;
uint8_t *p, dir;
size_t mlen, tlen, elen, datalen, padlen;
size_t cklen;
@@ -1702,9 +1704,25 @@ krb5_unwrap_old(struct krb5_context *kc,
 
/*
 * Check the trailing pad bytes.
+* RFC1964 specifies between 1-8 bytes, each with a binary value
+* equal to the number of bytes.
 */
-   KASSERT(mlast-m_len  0, (Unexpected empty mbuf));
-   padlen = mlast-m_data[mlast-m_len - 1];
+   if (mlast-m_len  0)
+   padlen = mlast-m_data[mlast-m_len - 1];
+   else {
+   n = m_getptr(m, tlen + datalen - 1, i);
+   /*
+* When the position is exactly equal to the # of data bytes
+* in the mbuf list, m_getptr() will return the last mbuf in
+* the list and an off == m_len for that mbuf, so that case
+* needs to be checked as well as a NULL return.
+*/
+   if (n == NULL || n-m_len == i)
+   return (GSS_S_DEFECTIVE_TOKEN);
+   padlen = n-m_data[i];
+   }
+   if (padlen  1 || padlen  8 || padlen  tlen + datalen)
+   return (GSS_S_DEFECTIVE_TOKEN);
m_copydata(m, tlen + datalen - padlen, padlen, buf);
for (i = 0; i  padlen; i++) {
if (buf[i] != padlen) {
___
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: r250158 - head/usr.bin/nfsstat

2013-05-01 Thread Rick Macklem
Author: rmacklem
Date: Wed May  1 22:16:29 2013
New Revision: 250158
URL: http://svnweb.freebsd.org/changeset/base/250158

Log:
  Document that the NFSv4 server statistics are operation counts and
  not RPC counts.
  This is a content change.
  
  MFC after:2 weeks

Modified:
  head/usr.bin/nfsstat/nfsstat.1

Modified: head/usr.bin/nfsstat/nfsstat.1
==
--- head/usr.bin/nfsstat/nfsstat.1  Wed May  1 22:07:55 2013
(r250157)
+++ head/usr.bin/nfsstat/nfsstat.1  Wed May  1 22:16:29 2013
(r250158)
@@ -28,7 +28,7 @@
 .\ From: @(#)nfsstat.18.1 (Berkeley) 6/6/93
 .\ $FreeBSD$
 .\
-.Dd November 14, 2012
+.Dd May 1, 2013
 .Dt NFSSTAT 1
 .Os
 .Sh NAME
@@ -48,6 +48,10 @@ The
 command displays statistics kept about
 .Tn NFS
 client and server activity.
+For the NFSv4 server, the statistics are for operations within the Compound
+RPCs and not the count of RPCs.
+If you wish to compare RPC counts between NFSv3 and NFSv4, you must use
+statistics in the client(s).
 .Pp
 The options are as follows:
 .Bl -tag -width indent
___
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: r250159 - in head: include lib/libc/sys sys/compat/freebsd32 sys/kern

2013-05-01 Thread Jilles Tjoelker
Author: jilles
Date: Wed May  1 22:42:42 2013
New Revision: 250159
URL: http://svnweb.freebsd.org/changeset/base/250159

Log:
  Add pipe2() system call.
  
  The pipe2() function is similar to pipe() but allows setting FD_CLOEXEC and
  O_NONBLOCK (on both sides) as part of the function.
  
  If p points to two writable ints, pipe2(p, 0) is equivalent to pipe(p).
  
  If the pointer is not valid, behaviour differs: pipe2() writes into the
  array from the kernel like socketpair() does, while pipe() writes into the
  array from an architecture-specific assembler wrapper.
  
  Reviewed by:  kan, kib

Modified:
  head/include/unistd.h
  head/lib/libc/sys/Makefile.inc
  head/lib/libc/sys/Symbol.map
  head/lib/libc/sys/pipe.2
  head/sys/compat/freebsd32/syscalls.master
  head/sys/kern/capabilities.conf
  head/sys/kern/sys_pipe.c
  head/sys/kern/syscalls.master

Modified: head/include/unistd.h
==
--- head/include/unistd.h   Wed May  1 22:16:29 2013(r250158)
+++ head/include/unistd.h   Wed May  1 22:42:42 2013(r250159)
@@ -533,6 +533,7 @@ char*mktemp(char *);
 #endif
 int nfssvc(int, void *);
 int nlm_syscall(int, int, int, char **);
+int pipe2(int *, int);
 int profil(char *, size_t, vm_offset_t, int);
 int rcmd(char **, int, const char *, const char *, const char *, int *);
 int rcmd_af(char **, int, const char *,

Modified: head/lib/libc/sys/Makefile.inc
==
--- head/lib/libc/sys/Makefile.inc  Wed May  1 22:16:29 2013
(r250158)
+++ head/lib/libc/sys/Makefile.inc  Wed May  1 22:42:42 2013
(r250159)
@@ -352,6 +352,7 @@ MLINKS+=pathconf.2 lpathconf.2
 MLINKS+=pdfork.2 pdgetpid.2\
pdfork.2 pdkill.2 \
pdfork.2 pdwait4.2
+MLINKS+=pipe.2 pipe2.2
 MLINKS+=read.2 pread.2 \
read.2 preadv.2 \
read.2 readv.2

Modified: head/lib/libc/sys/Symbol.map
==
--- head/lib/libc/sys/Symbol.mapWed May  1 22:16:29 2013
(r250158)
+++ head/lib/libc/sys/Symbol.mapWed May  1 22:42:42 2013
(r250159)
@@ -393,6 +393,7 @@ FBSD_1.3 {
ffclock_getcounter;
ffclock_getestimate;
ffclock_setestimate;
+   pipe2;
posix_fadvise;
wait6;
 };

Modified: head/lib/libc/sys/pipe.2
==
--- head/lib/libc/sys/pipe.2Wed May  1 22:16:29 2013(r250158)
+++ head/lib/libc/sys/pipe.2Wed May  1 22:42:42 2013(r250159)
@@ -28,7 +28,7 @@
 .\ @(#)pipe.2 8.1 (Berkeley) 6/4/93
 .\ $FreeBSD$
 .\
-.Dd January 30, 2006
+.Dd March 31, 2013
 .Dt PIPE 2
 .Os
 .Sh NAME
@@ -40,6 +40,8 @@
 .In unistd.h
 .Ft int
 .Fn pipe int fildes[2]
+.Ft int
+.Fn pipe2 int fildes[2] int flags
 .Sh DESCRIPTION
 The
 .Fn pipe
@@ -50,6 +52,29 @@ which is an object allowing
 bidirectional data flow,
 and allocates a pair of file descriptors.
 .Pp
+The
+.Fn pipe2
+system call allows control over the attributes of the file descriptors
+via the
+.Fa flags
+argument.
+Values for
+.Fa flags
+are constructed by a bitwise-inclusive OR of flags from the following
+list, defined in
+.In fcntl.h :
+.Bl -tag -width .Dv O_NONBLOCK
+.It Dv O_CLOEXEC
+Set the close-on-exec flag for the new file descriptors.
+.It Dv O_NONBLOCK
+Set the non-blocking flag for the ends of the pipe.
+.El
+.Pp
+If the
+.Fa flags
+argument is 0, the behavior is identical to a call to
+.Fn pipe .
+.Pp
 By convention, the first descriptor is normally used as the
 .Em read end
 of the pipe,
@@ -88,7 +113,9 @@ pipe in one direction.
 .Sh ERRORS
 The
 .Fn pipe
-system call will fail if:
+and
+.Fn pipe2
+system calls will fail if:
 .Bl -tag -width Er
 .It Bq Er EMFILE
 Too many descriptors are active.
@@ -97,6 +124,16 @@ The system file table is full.
 .It Bq Er ENOMEM
 Not enough kernel memory to establish a pipe.
 .El
+.Pp
+The
+.Fn pipe2
+system call will also fail if:
+.Bl -tag -width Er
+.It Bq Er EINVAL
+The
+.Fa flags
+argument is invalid.
+.El
 .Sh SEE ALSO
 .Xr sh 1 ,
 .Xr fork 2 ,
@@ -111,3 +148,8 @@ function appeared in
 .Pp
 Bidirectional pipes were first used on
 .At V.4 .
+.Pp
+The
+.Fn pipe2
+function appeared in
+.Fx 10.0 .

Modified: head/sys/compat/freebsd32/syscalls.master
==
--- head/sys/compat/freebsd32/syscalls.master   Wed May  1 22:16:29 2013
(r250158)
+++ head/sys/compat/freebsd32/syscalls.master   Wed May  1 22:42:42 2013
(r250159)
@@ -1026,3 +1026,4 @@
struct sockaddr * __restrict name, \
__socklen_t * __restrict anamelen, \
int flags); }
+542AUE_PIPENOPROTO { int pipe2(int *fildes, int flags); }


svn commit: r250160 - in head/sys: compat/freebsd32 kern sys

2013-05-01 Thread Jilles Tjoelker
Author: jilles
Date: Wed May  1 22:45:04 2013
New Revision: 250160
URL: http://svnweb.freebsd.org/changeset/base/250160

Log:
  Regenerate files for pipe2().

Modified:
  head/sys/compat/freebsd32/freebsd32_proto.h
  head/sys/compat/freebsd32/freebsd32_syscall.h
  head/sys/compat/freebsd32/freebsd32_syscalls.c
  head/sys/compat/freebsd32/freebsd32_sysent.c
  head/sys/compat/freebsd32/freebsd32_systrace_args.c
  head/sys/kern/init_sysent.c
  head/sys/kern/syscalls.c
  head/sys/kern/systrace_args.c
  head/sys/sys/syscall.h
  head/sys/sys/syscall.mk
  head/sys/sys/sysproto.h

Modified: head/sys/compat/freebsd32/freebsd32_proto.h
==
--- head/sys/compat/freebsd32/freebsd32_proto.h Wed May  1 22:42:42 2013
(r250159)
+++ head/sys/compat/freebsd32/freebsd32_proto.h Wed May  1 22:45:04 2013
(r250160)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250159 
2013-05-01 22:42:42Z jilles 
  */
 
 #ifndef _FREEBSD32_SYSPROTO_H_

Modified: head/sys/compat/freebsd32/freebsd32_syscall.h
==
--- head/sys/compat/freebsd32/freebsd32_syscall.h   Wed May  1 22:42:42 
2013(r250159)
+++ head/sys/compat/freebsd32/freebsd32_syscall.h   Wed May  1 22:45:04 
2013(r250160)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250159 
2013-05-01 22:42:42Z jilles 
  */
 
 #defineFREEBSD32_SYS_syscall   0
@@ -439,4 +439,5 @@
 #defineFREEBSD32_SYS_connectat 539
 #defineFREEBSD32_SYS_chflagsat 540
 #defineFREEBSD32_SYS_accept4   541
-#defineFREEBSD32_SYS_MAXSYSCALL542
+#defineFREEBSD32_SYS_pipe2 542
+#defineFREEBSD32_SYS_MAXSYSCALL543

Modified: head/sys/compat/freebsd32/freebsd32_syscalls.c
==
--- head/sys/compat/freebsd32/freebsd32_syscalls.c  Wed May  1 22:42:42 
2013(r250159)
+++ head/sys/compat/freebsd32/freebsd32_syscalls.c  Wed May  1 22:45:04 
2013(r250160)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250159 
2013-05-01 22:42:42Z jilles 
  */
 
 const char *freebsd32_syscallnames[] = {
@@ -565,4 +565,5 @@ const char *freebsd32_syscallnames[] = {
connectat,/* 539 = connectat */
chflagsat,/* 540 = chflagsat */
accept4,  /* 541 = accept4 */
+   pipe2,/* 542 = pipe2 */
 };

Modified: head/sys/compat/freebsd32/freebsd32_sysent.c
==
--- head/sys/compat/freebsd32/freebsd32_sysent.cWed May  1 22:42:42 
2013(r250159)
+++ head/sys/compat/freebsd32/freebsd32_sysent.cWed May  1 22:45:04 
2013(r250160)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250154 
2013-05-01 20:10:21Z jilles 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 250159 
2013-05-01 22:42:42Z jilles 
  */
 
 #include opt_compat.h
@@ -602,4 +602,5 @@ struct sysent freebsd32_sysent[] = {
{ AS(connectat_args), (sy_call_t *)sys_connectat, AUE_CONNECTAT, NULL, 
0, 0, 0, SY_THR_STATIC },/* 539 = connectat */
{ AS(chflagsat_args), (sy_call_t *)sys_chflagsat, AUE_CHFLAGSAT, NULL, 
0, 0, 0, SY_THR_STATIC },/* 540 = chflagsat */
{ AS(accept4_args), (sy_call_t *)sys_accept4, AUE_ACCEPT, NULL, 0, 0, 
0, SY_THR_STATIC },   /* 541 = accept4 */
+   { AS(pipe2_args), (sy_call_t *)sys_pipe2, AUE_PIPE, NULL, 0, 0, 0, 
SY_THR_STATIC }, /* 542 = pipe2 */
 };

Modified: head/sys/compat/freebsd32/freebsd32_systrace_args.c
==
--- head/sys/compat/freebsd32/freebsd32_systrace_args.c Wed May  1 22:42:42 
2013(r250159)
+++ head/sys/compat/freebsd32/freebsd32_systrace_args.c Wed May  1 22:45:04 
2013(r250160)
@@ -3170,6 +3170,14 @@ systrace_args(int sysnum, void *params, 
*n_args = 4;
break;
}
+   /* pipe2 */
+   case 542: {
+   struct pipe2_args *p = params;
+   

svn commit: r250161 - head/lib/libc/sys

2013-05-01 Thread Jilles Tjoelker
Author: jilles
Date: Wed May  1 22:47:47 2013
New Revision: 250161
URL: http://svnweb.freebsd.org/changeset/base/250161

Log:
  accept(2), pipe(2): Fix .Dd.

Modified:
  head/lib/libc/sys/accept.2
  head/lib/libc/sys/pipe.2

Modified: head/lib/libc/sys/accept.2
==
--- head/lib/libc/sys/accept.2  Wed May  1 22:45:04 2013(r250160)
+++ head/lib/libc/sys/accept.2  Wed May  1 22:47:47 2013(r250161)
@@ -28,7 +28,7 @@
 .\ @(#)accept.2   8.2 (Berkeley) 12/11/93
 .\ $FreeBSD$
 .\
-.Dd April 22, 2013
+.Dd May 1, 2013
 .Dt ACCEPT 2
 .Os
 .Sh NAME

Modified: head/lib/libc/sys/pipe.2
==
--- head/lib/libc/sys/pipe.2Wed May  1 22:45:04 2013(r250160)
+++ head/lib/libc/sys/pipe.2Wed May  1 22:47:47 2013(r250161)
@@ -28,7 +28,7 @@
 .\ @(#)pipe.2 8.1 (Berkeley) 6/4/93
 .\ $FreeBSD$
 .\
-.Dd March 31, 2013
+.Dd May 1, 2013
 .Dt PIPE 2
 .Os
 .Sh NAME
___
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: r250162 - head/usr.sbin/nfsd

2013-05-01 Thread Rick Macklem
Author: rmacklem
Date: Wed May  1 22:50:45 2013
New Revision: 250162
URL: http://svnweb.freebsd.org/changeset/base/250162

Log:
  Document the fact that an NFSv4 mount against a volume on the same host
  can result in a hung NFS server and is not recommended.
  This is a content change.
  
  MFC after:2 weeks

Modified:
  head/usr.sbin/nfsd/nfsv4.4

Modified: head/usr.sbin/nfsd/nfsv4.4
==
--- head/usr.sbin/nfsd/nfsv4.4  Wed May  1 22:47:47 2013(r250161)
+++ head/usr.sbin/nfsd/nfsv4.4  Wed May  1 22:50:45 2013(r250162)
@@ -24,7 +24,7 @@
 .\
 .\ $FreeBSD$
 .\
-.Dd December 23, 2012
+.Dd May 1, 2013
 .Dt NFSV4 4
 .Os
 .Sh NAME
@@ -287,6 +287,13 @@ and
 daemons at boot time via the ``nfsuserd_flags'' and ``nfscbd_flags''
 .Xr rc.conf 5
 variables.
+.Pp
+NFSv4 mount(s) against exported volume(s) on the same host are not recommended,
+since this can result in a hung NFS server.
+It occurs when an nfsd thread tries to do an NFSv4 VOP_RECLAIM()/Close RPC
+as part of acquiring a new vnode.
+If all other nfsd threads are blocked waiting for lock(s) held by this nfsd
+thread, then there isn't an nfsd thread to service the Close RPC.
 .Sh FILES
 .Bl -tag -width /var/db/nfs-stablerestart.bak -compact
 .It Pa /var/db/nfs-stablerestart
___
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: r250163 - head/sys/sys

2013-05-01 Thread Jilles Tjoelker
Author: jilles
Date: Wed May  1 23:04:29 2013
New Revision: 250163
URL: http://svnweb.freebsd.org/changeset/base/250163

Log:
  Bump __FreeBSD_version for accept4() and pipe2().

Modified:
  head/sys/sys/param.h

Modified: head/sys/sys/param.h
==
--- head/sys/sys/param.hWed May  1 22:50:45 2013(r250162)
+++ head/sys/sys/param.hWed May  1 23:04:29 2013(r250163)
@@ -58,7 +58,7 @@
  * in the range 5 to 9.
  */
 #undef __FreeBSD_version
-#define __FreeBSD_version 131  /* Master, propagated to newvers */
+#define __FreeBSD_version 132  /* Master, propagated to newvers */
 
 /*
  * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD,
___
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: r250164 - head/contrib/bmake

2013-05-01 Thread Simon J. Gerraty
Author: sjg
Date: Wed May  1 23:58:39 2013
New Revision: 250164
URL: http://svnweb.freebsd.org/changeset/base/250164

Log:
  Local hack to allow smooth transition for ports.
  bsd.port.mk can set .MAKE.FreeBSD_UL=yes
  to cause :L and :U to have their old behavior.
  This should be reverted when 8.3 is EOL.
  
  PR:   173299
  Reviewed by:  obrien

Modified:
  head/contrib/bmake/var.c

Modified: head/contrib/bmake/var.c
==
--- head/contrib/bmake/var.cWed May  1 23:04:29 2013(r250163)
+++ head/contrib/bmake/var.cWed May  1 23:58:39 2013(r250164)
@@ -140,6 +140,17 @@ __RCSID($NetBSD: var.c,v 1.173 2013/02/
 #includejob.h
 
 /*
+ * XXX transition hack for FreeBSD ports.
+ * bsd.port.mk can set .MAKE.FreeBSD_UL=yes
+ * to cause us to treat :[LU] as aliases for :t[lu]
+ * To be reverted when ports converts to :t[lu] (when 8.3 is EOL)
+ */
+#define MAKE_FREEBSD_UL .MAKE.FreeBSD_UL
+#ifdef MAKE_FREEBSD_UL
+static int FreeBSD_UL = FALSE;
+#endif
+
+/*
  * This lets us tell if we have replaced the original environ
  * (which we cannot free).
  */
@@ -965,6 +976,11 @@ Var_Set(const char *name, const char *va
setenv(MAKE_LEVEL_SAFE, tmp, 1);
 #endif
 }
+#ifdef MAKE_FREEBSD_UL
+if (strcmp(MAKE_FREEBSD_UL, name) == 0) {
+   FreeBSD_UL = getBoolean(MAKE_FREEBSD_UL, FALSE);
+}
+#endif


  out:
@@ -2660,8 +2676,24 @@ ApplyModifiers(char *nstr, const char *t
free(loop.str);
break;
}
-   case 'D':
case 'U':
+#ifdef MAKE_FREEBSD_UL
+   if (FreeBSD_UL) {
+   int nc = tstr[1];
+
+   /* we have to be careful, since :U is used internally */
+   if (nc == ':' || nc == endc) {
+   char *dp = bmake_strdup(nstr);
+   for (newStr = dp; *dp; dp++)
+   *dp = toupper((unsigned char)*dp);
+   cp = tstr + 1;
+   termc = *cp;
+   break;  /* yes inside the conditional */
+   }
+   /* FALLTHROUGH */
+   }
+#endif
+   case 'D':
{
Buffer  buf;/* Buffer for patterns */
int wantit; /* want data in buffer */
@@ -2721,6 +2753,17 @@ ApplyModifiers(char *nstr, const char *t
break;
}
case 'L':
+#ifdef MAKE_FREEBSD_UL
+   if (FreeBSD_UL) {
+   char *dp = bmake_strdup(nstr);
+   for (newStr = dp; *dp; dp++)
+   *dp = tolower((unsigned char)*dp);
+   cp = tstr + 1;
+   termc = *cp;
+   break;
+   }
+   /* FALLTHROUGH */
+#endif
{
if ((v-flags  VAR_JUNK) != 0)
v-flags |= VAR_KEEP;
___
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: r250165 - head/sys/mips/atheros

2013-05-01 Thread Adrian Chadd
Author: adrian
Date: Thu May  2 00:40:45 2013
New Revision: 250165
URL: http://svnweb.freebsd.org/changeset/base/250165

Log:
  Add the AR933x SoC GPIO pin count limitation.

Modified:
  head/sys/mips/atheros/ar71xx_gpio.c

Modified: head/sys/mips/atheros/ar71xx_gpio.c
==
--- head/sys/mips/atheros/ar71xx_gpio.c Wed May  1 23:58:39 2013
(r250164)
+++ head/sys/mips/atheros/ar71xx_gpio.c Thu May  2 00:40:45 2013
(r250165)
@@ -49,6 +49,7 @@ __FBSDID($FreeBSD$);
 #include mips/atheros/ar71xxreg.h
 #include mips/atheros/ar71xx_setup.h
 #include mips/atheros/ar71xx_gpiovar.h
+#include mips/atheros/ar933xreg.h
 
 #include gpio_if.h
 
@@ -136,6 +137,10 @@ ar71xx_gpio_pin_max(device_t dev, int *m
case AR71XX_SOC_AR7242:
*maxpin = AR724X_GPIO_PINS - 1;
break;
+   case AR71XX_SOC_AR9330:
+   case AR71XX_SOC_AR9331:
+   *maxpin = AR933X_GPIO_COUNT - 1;
+   break;
default:
*maxpin = AR71XX_GPIO_PINS - 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: r250166 - in head/sys: contrib/dev/ath/ath_hal/ar9300 dev/ath/ath_hal dev/ath/ath_hal/ar9003

2013-05-01 Thread Adrian Chadd
Author: adrian
Date: Thu May  2 00:59:39 2013
New Revision: 250166
URL: http://svnweb.freebsd.org/changeset/base/250166

Log:
  Add device identification and probe/attach support for the QCA9565.
  
  The QCA9565 is a 1x1 2.4GHz 11n chip with integrated on-chip bluetooth.
  The AR9300 HAL already has support for this chip; it just wasn't
  included in the probe/attach path.
  
  Tested:
  
  * This commit brought to you over a QCA9565 wifi connection from
FreeBSD.
  * .. ie, basic STA, pings, no iperf or antenna diversity checking just yet.

Modified:
  head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c
  head/sys/dev/ath/ath_hal/ah.c
  head/sys/dev/ath/ath_hal/ah_devid.h
  head/sys/dev/ath/ath_hal/ar9003/ar9300_devid.h

Modified: head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c
==
--- head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c Thu May  2 
00:40:45 2013(r250165)
+++ head/sys/contrib/dev/ath/ath_hal/ar9300/ar9300_attach.c Thu May  2 
00:59:39 2013(r250166)
@@ -4089,6 +4089,8 @@ ar9300_probe(uint16_t vendorid, uint16_t
 return Atheros AR933x;
 case AR9300_DEVID_QCA955X: /* Scorpion */
 return Qualcomm Atheros QCA955x;
+case AR9300_DEVID_QCA9565: /* Aphrodite */
+ return Qualcomm Atheros AR9565;
 default:
 return AH_NULL;
 }

Modified: head/sys/dev/ath/ath_hal/ah.c
==
--- head/sys/dev/ath/ath_hal/ah.c   Thu May  2 00:40:45 2013
(r250165)
+++ head/sys/dev/ath/ath_hal/ah.c   Thu May  2 00:59:39 2013
(r250166)
@@ -139,6 +139,9 @@ ath_hal_mac_name(struct ath_hal *ah)
return 9550;
case AR_SREV_VERSION_AR9485:
return 9485;
+   case AR_SREV_VERSION_QCA9565:
+   /* XXX should say QCA, not AR */
+   return 9565;
}
return ;
 }

Modified: head/sys/dev/ath/ath_hal/ah_devid.h
==
--- head/sys/dev/ath/ath_hal/ah_devid.h Thu May  2 00:40:45 2013
(r250165)
+++ head/sys/dev/ath/ath_hal/ah_devid.h Thu May  2 00:59:39 2013
(r250166)
@@ -91,6 +91,7 @@
 #defineAR9300_DEVID_AR9580_PCIE0x0033
 #defineAR9300_DEVID_AR946X_PCIE0x0034
 #defineAR9300_DEVID_AR9330 0x0035
+#defineAR9300_DEVID_QCA95650x0036
 #defineAR9300_DEVID_QCA955X0x0039
 
 #defineAR_SUBVENDOR_ID_NOG 0x0e11  /* No 11G subvendor ID 
*/

Modified: head/sys/dev/ath/ath_hal/ar9003/ar9300_devid.h
==
--- head/sys/dev/ath/ath_hal/ar9003/ar9300_devid.h  Thu May  2 00:40:45 
2013(r250165)
+++ head/sys/dev/ath/ath_hal/ar9003/ar9300_devid.h  Thu May  2 00:59:39 
2013(r250166)
@@ -48,6 +48,7 @@
 #defineAR_SREV_VERSION_AR9380  0x1C0
 #defineAR_SREV_VERSION_AR9580  0x1C0
 #defineAR_SREV_VERSION_AR9460  0x280
+#defineAR_SREV_VERSION_QCA9565 0x2c0
 
 #defineAR_SREV_VERSION_AR9330  0x200
 #defineAR_SREV_VERSION_AR9340  0x300
___
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: r250167 - in releng/8.4/contrib/sendmail: . cf/cf cf/m4 contrib doc/op include/sm libmilter libsm mailstats makemap praliases rmail src test vacation

2013-05-01 Thread Gregory Neil Shapiro
Author: gshapiro
Date: Thu May  2 01:35:02 2013
New Revision: 250167
URL: http://svnweb.freebsd.org/changeset/base/250167

Log:
  MFC: Merge sendmail 8.14.7 from stable/8
  
  Approved by:  re (delphij)

Added:
  releng/8.4/contrib/sendmail/libsm/t-fget.c
 - copied unchanged from r249868, stable/8/contrib/sendmail/libsm/t-fget.c
Modified:
  releng/8.4/contrib/sendmail/CACerts
  releng/8.4/contrib/sendmail/FREEBSD-upgrade
  releng/8.4/contrib/sendmail/PGPKEYS
  releng/8.4/contrib/sendmail/RELEASE_NOTES
  releng/8.4/contrib/sendmail/cf/cf/submit.cf
  releng/8.4/contrib/sendmail/cf/m4/version.m4
  releng/8.4/contrib/sendmail/contrib/etrn.pl
  releng/8.4/contrib/sendmail/doc/op/op.me
  releng/8.4/contrib/sendmail/include/sm/config.h
  releng/8.4/contrib/sendmail/include/sm/io.h
  releng/8.4/contrib/sendmail/libmilter/Makefile.m4
  releng/8.4/contrib/sendmail/libmilter/sm_gethost.c
  releng/8.4/contrib/sendmail/libsm/Makefile.m4
  releng/8.4/contrib/sendmail/libsm/cf.c
  releng/8.4/contrib/sendmail/libsm/fget.c
  releng/8.4/contrib/sendmail/mailstats/mailstats.c
  releng/8.4/contrib/sendmail/makemap/makemap.c
  releng/8.4/contrib/sendmail/praliases/praliases.c
  releng/8.4/contrib/sendmail/rmail/rmail.c
  releng/8.4/contrib/sendmail/src/Makefile.m4
  releng/8.4/contrib/sendmail/src/alias.c
  releng/8.4/contrib/sendmail/src/collect.c
  releng/8.4/contrib/sendmail/src/conf.c
  releng/8.4/contrib/sendmail/src/control.c
  releng/8.4/contrib/sendmail/src/deliver.c
  releng/8.4/contrib/sendmail/src/main.c
  releng/8.4/contrib/sendmail/src/map.c
  releng/8.4/contrib/sendmail/src/mci.c
  releng/8.4/contrib/sendmail/src/milter.c
  releng/8.4/contrib/sendmail/src/mime.c
  releng/8.4/contrib/sendmail/src/parseaddr.c
  releng/8.4/contrib/sendmail/src/queue.c
  releng/8.4/contrib/sendmail/src/readcf.c
  releng/8.4/contrib/sendmail/src/recipient.c
  releng/8.4/contrib/sendmail/src/savemail.c
  releng/8.4/contrib/sendmail/src/sendmail.h
  releng/8.4/contrib/sendmail/src/sfsasl.c
  releng/8.4/contrib/sendmail/src/srvrsmtp.c
  releng/8.4/contrib/sendmail/src/tls.c
  releng/8.4/contrib/sendmail/src/usersmtp.c
  releng/8.4/contrib/sendmail/src/util.c
  releng/8.4/contrib/sendmail/src/version.c
  releng/8.4/contrib/sendmail/test/Makefile.m4
  releng/8.4/contrib/sendmail/vacation/vacation.c
Directory Properties:
  releng/8.4/contrib/sendmail/   (props changed)

Modified: releng/8.4/contrib/sendmail/CACerts
==
--- releng/8.4/contrib/sendmail/CACerts Thu May  2 00:59:39 2013
(r250166)
+++ releng/8.4/contrib/sendmail/CACerts Thu May  2 01:35:02 2013
(r250167)
@@ -1,4 +1,4 @@
-# $Id: CACerts,v 8.5 2011/05/06 23:05:10 ca Exp $
+# $Id: CACerts,v 8.6 2013/01/18 15:14:17 ca Exp $
 # This file contains some CA certificates that are used to sign the
 # certificates of mail servers of members of the sendmail consortium
 # who may reply to questions etc sent to sendmail.org.
@@ -10,93 +10,93 @@ Certificate:
 Data:
 Version: 3 (0x2)
 Serial Number:
-c2:3c:61:67:3b:0a:cc:5e
-Signature Algorithm: md5WithRSAEncryption
-Issuer: C=US, ST=California, L=Berkeley, O=Endmail Org, OU=MTA, 
CN=Claus Assmann CA RSA 2009/emailAddress=ca+ca-rsa2...@esmtp.org
+f1:41:b3:3d:ba:bd:33:49
+Signature Algorithm: sha1WithRSAEncryption
+Issuer: C=US, ST=California, L=Berkeley, O=Endmail Org, OU=MTA, 
CN=Claus Assmann CA RSA 2012/emailAddress=ca+ca-rsa2...@esmtp.org
 Validity
-Not Before: May 14 04:42:18 2009 GMT
-Not After : May 13 04:42:18 2012 GMT
-Subject: C=US, ST=California, L=Berkeley, O=Endmail Org, OU=MTA, 
CN=Claus Assmann CA RSA 2009/emailAddress=ca+ca-rsa2...@esmtp.org
+Not Before: Mar 10 02:47:46 2012 GMT
+Not After : Mar 10 02:47:46 2015 GMT
+Subject: C=US, ST=California, L=Berkeley, O=Endmail Org, OU=MTA, 
CN=Claus Assmann CA RSA 2012/emailAddress=ca+ca-rsa2...@esmtp.org
 Subject Public Key Info:
 Public Key Algorithm: rsaEncryption
-RSA Public Key: (2048 bit)
-Modulus (2048 bit):
-00:d5:f8:d3:48:38:75:df:2e:6b:8b:c4:8d:1d:41:
-5e:ad:4b:96:3d:48:c2:dc:e5:ff:61:98:95:32:03:
-e9:b6:71:5a:68:31:bc:e1:5c:aa:0e:70:a7:bc:51:
-b7:13:6a:78:54:ae:a6:d0:44:49:1b:5e:37:5b:59:
-20:01:47:a7:ec:41:4c:11:79:8c:25:c1:1b:c0:ed:
-85:b2:de:0f:10:9f:e7:b2:a3:c4:f1:fc:85:51:aa:
-d6:68:49:51:3e:04:e1:eb:e9:cd:87:1b:d0:9d:97:
-7b:4c:e1:1e:b1:6a:be:01:0a:a9:97:9a:50:89:e3:
-66:06:4c:07:cb:7e:99:70:13:e8:b4:9c:e7:e6:52:
-38:c0:64:90:42:d0:f5:cf:22:46:22:60:e9:34:70:
-1d:e3:d1:13:33:3a:31:ba:13:06:a8:c2:34:90:47:
-

svn commit: r250168 - in head: share/man/man4 sys/dev/e1000 sys/dev/ixgb

2013-05-01 Thread Eitan Adler
Author: eadler
Date: Thu May  2 01:36:52 2013
New Revision: 250168
URL: http://svnweb.freebsd.org/changeset/base/250168

Log:
  Update Intel email address.
  
  PR:   docs/175349
  Submitted by: Lars Eggert l...@netapp.com
  Discussed with:   jfv

Modified:
  head/share/man/man4/em.4
  head/share/man/man4/igb.4
  head/share/man/man4/ixgb.4
  head/share/man/man4/ixgbe.4
  head/sys/dev/e1000/README
  head/sys/dev/ixgb/README

Modified: head/share/man/man4/em.4
==
--- head/share/man/man4/em.4Thu May  2 01:35:02 2013(r250167)
+++ head/share/man/man4/em.4Thu May  2 01:36:52 2013(r250168)
@@ -260,7 +260,7 @@ go to the Intel support website at:
 If an issue is identified with the released source code on the supported kernel
 with a supported adapter, email the specific information related to the
 issue to
-.Aq freebsd...@mailbox.intel.com .
+.Aq free...@intel.com .
 .Sh SEE ALSO
 .Xr altq 4 ,
 .Xr arp 4 ,
@@ -280,7 +280,7 @@ device driver first appeared in
 The
 .Nm
 driver was written by
-.An Intel Corporation Aq freebsd...@mailbox.intel.com .
+.An Intel Corporation Aq free...@intel.com .
 .Sh BUGS
 Hardware-assisted VLAN processing is disabled by default.
 You can enable it on an

Modified: head/share/man/man4/igb.4
==
--- head/share/man/man4/igb.4   Thu May  2 01:35:02 2013(r250167)
+++ head/share/man/man4/igb.4   Thu May  2 01:36:52 2013(r250168)
@@ -205,7 +205,7 @@ go to the Intel support website at:
 If an issue is identified with the released source code on the supported kernel
 with a supported adapter, email the specific information related to the
 issue to
-.Aq freebsd...@mailbox.intel.com .
+.Aq free...@intel.com .
 .Sh SEE ALSO
 .Xr altq 4 ,
 .Xr arp 4 ,
@@ -225,4 +225,4 @@ device driver first appeared in
 The
 .Nm
 driver was written by
-.An Intel Corporation Aq freebsd...@mailbox.intel.com .
+.An Intel Corporation Aq free...@intel.com .

Modified: head/share/man/man4/ixgb.4
==
--- head/share/man/man4/ixgb.4  Thu May  2 01:35:02 2013(r250167)
+++ head/share/man/man4/ixgb.4  Thu May  2 01:36:52 2013(r250168)
@@ -102,7 +102,7 @@ go to the Intel support website at:
 If an issue is identified with the released source code on the supported kernel
 with a supported adapter, email the specific information related to the
 issue to
-.Aq freebsd...@mailbox.intel.com .
+.Aq free...@intel.com .
 .Sh SEE ALSO
 .Xr arp 4 ,
 .Xr em 4 ,
@@ -122,4 +122,4 @@ and
 The
 .Nm
 driver was written by
-.An Intel Corporation Aq freebsd...@mailbox.intel.com .
+.An Intel Corporation Aq free...@intel.com .

Modified: head/share/man/man4/ixgbe.4
==
--- head/share/man/man4/ixgbe.4 Thu May  2 01:35:02 2013(r250167)
+++ head/share/man/man4/ixgbe.4 Thu May  2 01:36:52 2013(r250168)
@@ -105,7 +105,7 @@ go to the Intel support website at:
 If an issue is identified with the released source code on the supported kernel
 with a supported adapter, email the specific information related to the
 issue to
-.Aq freebsd...@mailbox.intel.com .
+.Aq free...@intel.com .
 .Sh SEE ALSO
 .Xr altq 4 ,
 .Xr arp 4 ,
@@ -123,4 +123,4 @@ device driver first appeared in
 The
 .Nm
 driver was written by
-.An Intel Corporation Aq freebsd...@mailbox.intel.com .
+.An Intel Corporation Aq free...@intel.com .

Modified: head/sys/dev/e1000/README
==
--- head/sys/dev/e1000/README   Thu May  2 01:35:02 2013(r250167)
+++ head/sys/dev/e1000/README   Thu May  2 01:36:52 2013(r250168)
@@ -389,7 +389,7 @@ For general information and support, go 
 http://support.intel.com
 
 If an issue is identified, support is through email only at:
-freebsd...@mailbox.intel.com
+free...@intel.com
 
 
 License

Modified: head/sys/dev/ixgb/README
==
--- head/sys/dev/ixgb/READMEThu May  2 01:35:02 2013(r250167)
+++ head/sys/dev/ixgb/READMEThu May  2 01:36:52 2013(r250168)
@@ -217,7 +217,7 @@ For general information and support, go 
 
 If an issue is identified with the released source code on the supported
 kernel with a supported adapter, email the specific information related to 
-the issue to freebsd...@mailbox.intel.com.
+the issue to free...@intel.com.
 
 
 
___
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: r250169 - releng/8.4/etc/sendmail

2013-05-01 Thread Gregory Neil Shapiro
Author: gshapiro
Date: Thu May  2 01:39:32 2013
New Revision: 250169
URL: http://svnweb.freebsd.org/changeset/base/250169

Log:
  MFC: Minor changes to force commit these files so new freebsd*.cf files are
   built to use the new sendmail-8.14.7/cf tree.  Merged from stable/8.
  
  Approved by:  re (delphij)

Modified:
  releng/8.4/etc/sendmail/freebsd.mc
  releng/8.4/etc/sendmail/freebsd.submit.mc
Directory Properties:
  releng/8.4/etc/sendmail/   (props changed)

Modified: releng/8.4/etc/sendmail/freebsd.mc
==
--- releng/8.4/etc/sendmail/freebsd.mc  Thu May  2 01:36:52 2013
(r250168)
+++ releng/8.4/etc/sendmail/freebsd.mc  Thu May  2 01:39:32 2013
(r250169)
@@ -41,7 +41,7 @@ divert(-1)
 #  The best documentation for this .mc file is:
 #  /usr/share/sendmail/cf/README or
 #  /usr/src/contrib/sendmail/cf/README
-#
+# 
 
 divert(0)
 VERSIONID(`$FreeBSD$')

Modified: releng/8.4/etc/sendmail/freebsd.submit.mc
==
--- releng/8.4/etc/sendmail/freebsd.submit.mc   Thu May  2 01:36:52 2013
(r250168)
+++ releng/8.4/etc/sendmail/freebsd.submit.mc   Thu May  2 01:39:32 2013
(r250169)
@@ -9,7 +9,6 @@ divert(-1)
 #
 #
 
-
 #
 #  This is the FreeBSD configuration for a set-group-ID sm-msp sendmail
 #  that acts as a initial mail submission program.
___
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: r249605 - head/sys/vm

2013-05-01 Thread David Xu

On 2013/04/18 13:34, Alan Cox wrote:

Author: alc
Date: Thu Apr 18 05:34:33 2013
New Revision: 249605
URL: http://svnweb.freebsd.org/changeset/base/249605

Log:
   When calculating the number of reserved nodes, discount the pages that will
   be used to store the nodes.

   Sponsored by:EMC / Isilon Storage Division

Modified:
   head/sys/vm/vm_radix.c

Modified: head/sys/vm/vm_radix.c
==
--- head/sys/vm/vm_radix.c  Thu Apr 18 05:12:11 2013(r249604)
+++ head/sys/vm/vm_radix.c  Thu Apr 18 05:34:33 2013(r249605)
@@ -360,10 +360,17 @@ vm_radix_node_zone_init(void *mem, int s
  static void
  vm_radix_prealloc(void *arg __unused)
  {
+   int nodes;

-   if (!uma_zone_reserve_kva(vm_radix_node_zone, cnt.v_page_count))
+   /*
+* Calculate the number of reserved nodes, discounting the pages that
+* are needed to store them.
+*/
+   nodes = ((vm_paddr_t)cnt.v_page_count * PAGE_SIZE) / (PAGE_SIZE +
+   sizeof(struct vm_radix_node));
+   if (!uma_zone_reserve_kva(vm_radix_node_zone, nodes))
panic(%s: unable to create new zone, __func__);
-   uma_prealloc(vm_radix_node_zone, cnt.v_page_count);
+   uma_prealloc(vm_radix_node_zone, nodes);
  }
  SYSINIT(vm_radix_prealloc, SI_SUB_KMEM, SI_ORDER_SECOND, vm_radix_prealloc,
  NULL);



FYI, after this change, my network card no longer works, the
driver /sys/dev/if_msk.c reports watchdog timeout, backing out
this change works again for me.

Regards,
David Xu

___
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: r249800 - head/sys/dev/bwn

2013-05-01 Thread John Merryweather Cooper

On 04/29/13 12:42, Adrian Chadd wrote:

On 29 April 2013 09:44, hiren panchasara hi...@freebsd.org wrote:


Does anyone here have bwn hardware that works?


I do not.


Have an expresscard slot? Want some?



adrian
___
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



My bwn in an HP dv9420us laptop worked in 8.x but does not in 9.1.

--
--
John M. Cooper
___
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: r250170 - stable/9/libexec/rtld-elf

2013-05-01 Thread Konstantin Belousov
Author: kib
Date: Thu May  2 04:22:04 2013
New Revision: 250170
URL: http://svnweb.freebsd.org/changeset/base/250170

Log:
  MFC r250075:
  Properly terminate the result string for intermediate results.

Modified:
  stable/9/libexec/rtld-elf/rtld.c
Directory Properties:
  stable/9/libexec/rtld-elf/   (props changed)

Modified: stable/9/libexec/rtld-elf/rtld.c
==
--- stable/9/libexec/rtld-elf/rtld.cThu May  2 01:39:32 2013
(r250169)
+++ stable/9/libexec/rtld-elf/rtld.cThu May  2 04:22:04 2013
(r250170)
@@ -784,7 +784,7 @@ origin_subst_one(char *real, const char 
/*
 * Now, execute the substitution loop.
 */
-   for (p = real, resp = res;;) {
+   for (p = real, resp = res, *resp = '\0';;) {
p1 = strstr(p, kw);
if (p1 != NULL) {
/* Copy the prefix before keyword. */
@@ -793,6 +793,7 @@ origin_subst_one(char *real, const char 
/* Keyword replacement. */
memcpy(resp, subst, subst_len);
resp += subst_len;
+   *resp = '\0';
p = p1 + kw_len;
} else
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: r250171 - stable/8/libexec/rtld-elf

2013-05-01 Thread Konstantin Belousov
Author: kib
Date: Thu May  2 04:23:57 2013
New Revision: 250171
URL: http://svnweb.freebsd.org/changeset/base/250171

Log:
  MFC r250075:
  Properly terminate the result string for intermediate results.

Modified:
  stable/8/libexec/rtld-elf/rtld.c
Directory Properties:
  stable/8/libexec/rtld-elf/   (props changed)

Modified: stable/8/libexec/rtld-elf/rtld.c
==
--- stable/8/libexec/rtld-elf/rtld.cThu May  2 04:22:04 2013
(r250170)
+++ stable/8/libexec/rtld-elf/rtld.cThu May  2 04:23:57 2013
(r250171)
@@ -697,7 +697,7 @@ origin_subst_one(char *real, const char 
/*
 * Now, execute the substitution loop.
 */
-   for (p = real, resp = res;;) {
+   for (p = real, resp = res, *resp = '\0';;) {
p1 = strstr(p, kw);
if (p1 != NULL) {
/* Copy the prefix before keyword. */
@@ -706,6 +706,7 @@ origin_subst_one(char *real, const char 
/* Keyword replacement. */
memcpy(resp, subst, subst_len);
resp += subst_len;
+   *resp = '\0';
p = p1 + kw_len;
} else
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


Re: svn commit: r250121 - in stable/9: . etc share/mk

2013-05-01 Thread Andrey Chernov
On 01.05.2013 2:13, Brooks Davis wrote:
 + Due to the use of the new -l option to install(1) during build
 + and install, you must take care not to directly set the INSTALL
 + make variable in your /etc/make.conf, /etc/src.conf, or on the
 + command line.  If you with to use the -C flag for all installs
 + you may be able to add INSTALL+=-C to /etc/make.conf or
 + /etc/src.conf.

You need to update /usr/src/share/examples/etc/make.conf too, there is
# Compare before install
#INSTALL=install -C

-- 
bitcoin:13fGiNutKNHcVSsgtGQ7bQ5kgUKgEQHn7N
___
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: r250121 - in stable/9: . etc share/mk

2013-05-01 Thread Andrey Chernov
On 01.05.2013 2:13, Brooks Davis wrote:
 +#
 +# install(1) parameters.
 +#
 +HRDLINK?=-l h
 +SYMLINK?=-l s

It is error, there must be no space or - sign.

-- 
bitcoin:13fGiNutKNHcVSsgtGQ7bQ5kgUKgEQHn7N
___
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: r250121 - in stable/9: . etc share/mk

2013-05-01 Thread Andrey Chernov
On 02.05.2013 9:09, Andrey Chernov wrote:
 On 01.05.2013 2:13, Brooks Davis wrote:
 +#
 +# install(1) parameters.
 +#
 +HRDLINK?=   -l h
 +SYMLINK?=   -l s
 
 It is error, there must be no space or - sign.

Sorry my mistake. All right.

-- 
bitcoin:13fGiNutKNHcVSsgtGQ7bQ5kgUKgEQHn7N
___
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