Re: svn commit: r276195 - in head: . lib/libxo

2014-12-25 Thread Garrett Cooper

> On Dec 24, 2014, at 19:56, Alfred Perlstein  wrote:
> 
> 
> On 12/24/14 7:36 PM, Garrett Cooper wrote:
>>> On Dec 24, 2014, at 19:15, Alfred Perlstein  wrote:
>>> 
>>> Author: alfred
>>> Date: Thu Dec 25 03:15:56 2014
>>> New Revision: 276195
>>> URL: https://svnweb.freebsd.org/changeset/base/276195
>>> 
>>> Log:
>>>  Move libxo to /lib
>>> 
>>>  Update ObsoleteFiles to reflect libxo move.
>>> 
>>>  Reviewed by: ngie
>>>  Differential Revision: https://reviews.freebsd.org/D1370
>>> 
>>> Modified:
>>>  head/ObsoleteFiles.inc
>>>  head/lib/libxo/Makefile
>>> 
>>> Modified: head/ObsoleteFiles.inc
>>> ==
>>> --- head/ObsoleteFiles.incThu Dec 25 02:17:17 2014(r276194)
>>> +++ head/ObsoleteFiles.incThu Dec 25 03:15:56 2014(r276195)
>>> @@ -38,6 +38,9 @@
>>> #   xargs -n1 | sort | uniq -d;
>>> # done
>>> 
>>> +# 20141224: libxo moved to /lib
>>> +OLD_FILES+=usr/lib/libxo.a
>>> +OLD_FILES+=usr/lib/libxo_p.a
>> This should actually be the .so file only. Static libraries are always in 
>> /usr/lib .
>> 
>> Sorry for not being explicit about this (I'm currently writing from the 
>> boonies so bandwidth is limited) :/.
>> 
>> 
> 
> I think the .so gets clobbered with a symlink, so it should be fine?
> 
> Meaning that after I moved the lib to /lib this is what I see in /usr/lib:
> /usr/src/contrib/libxo % ls -l /usr/lib/libxo*
> -r--r--r--  1 root  wheel  83764 Dec 24 19:31 /usr/lib/libxo.a
> lrwxr-xr-x  1 root  wheel 15 Dec 24 19:31 /usr/lib/libxo.so -> 
> /lib/libxo.so.0
> -r--r--r--  1 root  wheel  95164 Dec 24 19:31 /usr/lib/libxo_p.a
> 
> 
> Or should I reference it explicitly?
> 
> What is the end result here?

There isn't a leftover versioned .so in /usr/lib ?
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


Re: svn commit: r276195 - in head: . lib/libxo

2014-12-25 Thread Konstantin Belousov
On Wed, Dec 24, 2014 at 11:04:01PM -0800, Garrett Cooper wrote:
> 
> > On Dec 24, 2014, at 19:56, Alfred Perlstein  wrote:
> > 
> > 
> > On 12/24/14 7:36 PM, Garrett Cooper wrote:
> >>> On Dec 24, 2014, at 19:15, Alfred Perlstein  wrote:
> >>> 
> >>> Author: alfred
> >>> Date: Thu Dec 25 03:15:56 2014
> >>> New Revision: 276195
> >>> URL: https://svnweb.freebsd.org/changeset/base/276195
> >>> 
> >>> Log:
> >>>  Move libxo to /lib
> >>> 
> >>>  Update ObsoleteFiles to reflect libxo move.
> >>> 
> >>>  Reviewed by: ngie
> >>>  Differential Revision: https://reviews.freebsd.org/D1370
> >>> 
> >>> Modified:
> >>>  head/ObsoleteFiles.inc
> >>>  head/lib/libxo/Makefile
> >>> 
> >>> Modified: head/ObsoleteFiles.inc
> >>> ==
> >>> --- head/ObsoleteFiles.incThu Dec 25 02:17:17 2014(r276194)
> >>> +++ head/ObsoleteFiles.incThu Dec 25 03:15:56 2014(r276195)
> >>> @@ -38,6 +38,9 @@
> >>> #   xargs -n1 | sort | uniq -d;
> >>> # done
> >>> 
> >>> +# 20141224: libxo moved to /lib
> >>> +OLD_FILES+=usr/lib/libxo.a
> >>> +OLD_FILES+=usr/lib/libxo_p.a
> >> This should actually be the .so file only. Static libraries are always in 
> >> /usr/lib .
> >> 
> >> Sorry for not being explicit about this (I'm currently writing from the 
> >> boonies so bandwidth is limited) :/.
> >> 
> >> 
> > 
> > I think the .so gets clobbered with a symlink, so it should be fine?
> > 
> > Meaning that after I moved the lib to /lib this is what I see in /usr/lib:
> > /usr/src/contrib/libxo % ls -l /usr/lib/libxo*
> > -r--r--r--  1 root  wheel  83764 Dec 24 19:31 /usr/lib/libxo.a
> > lrwxr-xr-x  1 root  wheel 15 Dec 24 19:31 /usr/lib/libxo.so -> 
> > /lib/libxo.so.0
> > -r--r--r--  1 root  wheel  95164 Dec 24 19:31 /usr/lib/libxo_p.a
> > 
> > 
> > Or should I reference it explicitly?
> > 
> > What is the end result here?
> 
> There isn't a leftover versioned .so in /usr/lib ?
usr/lib/libxo.so.0 (without leading slash) must go into OLD_LIBS.
It is all explained in the first paragraph of the file comment.
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


Re: svn commit: r276188 - head/sys/netipsec

2014-12-25 Thread Bjoern A. Zeeb

> On 24 Dec 2014, at 18:34 , Andrey V. Elsukov  wrote:
> 
> Author: ae
> Date: Wed Dec 24 18:34:56 2014
> New Revision: 276188
> URL: https://svnweb.freebsd.org/changeset/base/276188
> 
> Log:
>  Rename ip4_def_policy variable to def_policy. It is used by both IPv4 and
>  IPv6. Initialize it only once in def_policy_init(). Remove its
>  initialization from key_init() and make it static.
> 
>  Remove several fields from struct secpolicy:
>  * lock - it isn't so useful having mutex in the structure, but the only
>thing we do with it is initialization and destroying.
>  * state - it has only two values - DEAD and ALIVE. Instead of take a lock
>and change the state to DEAD, then take lock again in GC function and
>delete policy from the chain - keep in the chain only ALIVE policies.
>  * scangen - it was used in GC function to protect from sending several
>SADB_SPDEXPIRE messages for one SPD entry. Now we don't keep DEAD entries
>in the chain and there is no need to have scangen variable.
> 
>  Use TAILQ to implement SPD entries chain. Use rmlock to protect access
>  to SPD entries chain. Protect all SP lookup with RLOCK, and use WLOCK
>  when we are inserting (or removing) SP entry in the chain.
> 
>  Instead of using pattern "LOCK(); refcnt++; UNLOCK();", use refcount(9)
>  API to implement refcounting in SPD. Merge code from key_delsp() and
>  _key_delsp() into _key_freesp(). And use KEY_FREESP() macro in all cases
>  when we want to release reference or just delete SP entry.
> 
>  Obtained from:   Yandex LLC
>  Sponsored by:Yandex LLC
> 
> Modified:
>  head/sys/netipsec/ipsec.c
>  head/sys/netipsec/ipsec.h
>  head/sys/netipsec/key.c
>  head/sys/netipsec/key_debug.c

This broke VIMAGE kernel builds.

And I’ll repeat what I said before:  I appreciate all your work but at the same 
time I remain massively worried by major change commits to security subsystems 
without any Reviewed by: lines.  Please use appropriate ways to get extra pairs 
of eyes.

Happy holidays!

Bjoern

— 
Bjoern A. Zeeb  Charles Haddon Spurgeon:
"Friendship is one of the sweetest joys of life.  Many might have failed
 beneath the bitterness of their trial  had they not found a friend."

___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

svn commit: r276199 - head/sys/netipsec

2014-12-25 Thread Andrey V. Elsukov
Author: ae
Date: Thu Dec 25 13:38:51 2014
New Revision: 276199
URL: https://svnweb.freebsd.org/changeset/base/276199

Log:
  Fix VIMAGE build.

Modified:
  head/sys/netipsec/key.c

Modified: head/sys/netipsec/key.c
==
--- head/sys/netipsec/key.c Thu Dec 25 04:41:43 2014(r276198)
+++ head/sys/netipsec/key.c Thu Dec 25 13:38:51 2014(r276199)
@@ -7608,7 +7608,7 @@ key_destroy(void)
TAILQ_INIT(&drainq);
SPTREE_WLOCK();
for (i = 0; i < IPSEC_DIR_MAX; i++) {
-   TAILQ_CONCAT(&drainq, &V_sptree[dir], chain);
+   TAILQ_CONCAT(&drainq, &V_sptree[i], chain);
}
SPTREE_WUNLOCK();
sp = TAILQ_FIRST(&drainq);
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276200 - head/sys/kern

2014-12-25 Thread Rick Macklem
Author: rmacklem
Date: Thu Dec 25 14:44:04 2014
New Revision: 276200
URL: https://svnweb.freebsd.org/changeset/base/276200

Log:
  Fix the comment introduced in r276192 so that it clearly
  states that the change is needed to avoid a deadlock.
  
  Suggested by: kib
  MFC after:1 week

Modified:
  head/sys/kern/vfs_default.c

Modified: head/sys/kern/vfs_default.c
==
--- head/sys/kern/vfs_default.c Thu Dec 25 13:38:51 2014(r276199)
+++ head/sys/kern/vfs_default.c Thu Dec 25 14:44:04 2014(r276200)
@@ -407,9 +407,10 @@ vop_stdadvlock(struct vop_advlock_args *
vp = ap->a_vp;
if (ap->a_fl->l_whence == SEEK_END) {
/*
-* The NFSv4 server will LOR/deadlock if a vn_lock() call
-* is done on vp. Fortunately, vattr.va_size is only
-* needed for SEEK_END and the NFSv4 server only uses SEEK_SET.
+* The NFSv4 server must avoid doing a vn_lock() here, since it
+* can deadlock the nfsd threads, due to a LOR.  Fortunately
+* the NFSv4 server always uses SEEK_SET and this code is
+* only required for the SEEK_END case.
 */
vn_lock(vp, LK_SHARED | LK_RETRY);
error = VOP_GETATTR(vp, &vattr, curthread->td_ucred);
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276201 - head/share/man/man9

2014-12-25 Thread Kevin Lo
Author: kevlo
Date: Thu Dec 25 15:17:57 2014
New Revision: 276201
URL: https://svnweb.freebsd.org/changeset/base/276201

Log:
  Replace CC_VAR with CCV, since the CC_VAR macro doesn't exist.
  While here, add MLINK for CCV.9 and DECLARE_CC_MODULE.9.

Modified:
  head/share/man/man9/Makefile
  head/share/man/man9/mod_cc.9

Modified: head/share/man/man9/Makefile
==
--- head/share/man/man9/MakefileThu Dec 25 14:44:04 2014
(r276200)
+++ head/share/man/man9/MakefileThu Dec 25 15:17:57 2014
(r276201)
@@ -1080,6 +1080,8 @@ MLINKS+=microuptime.9 binuptime.9 \
microuptime.9 sbinuptime.9
 MLINKS+=mi_switch.9 cpu_switch.9 \
mi_switch.9 cpu_throw.9
+MLINKS+=mod_cc.9 CCV.9 \
+   mod_cc.9 DECLARE_CC_MODULE.9
 MLINKS+=mtx_pool.9 mtx_pool_alloc.9 \
mtx_pool.9 mtx_pool_create.9 \
mtx_pool.9 mtx_pool_destroy.9 \

Modified: head/share/man/man9/mod_cc.9
==
--- head/share/man/man9/mod_cc.9Thu Dec 25 14:44:04 2014
(r276200)
+++ head/share/man/man9/mod_cc.9Thu Dec 25 15:17:57 2014
(r276201)
@@ -31,19 +31,19 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd September 15, 2011
+.Dd December 25, 2014
 .Dt MOD_CC 9
 .Os
 .Sh NAME
 .Nm mod_cc ,
 .Nm DECLARE_CC_MODULE ,
-.Nm CC_VAR
+.Nm CCV
 .Nd Modular Congestion Control
 .Sh SYNOPSIS
 .In netinet/cc.h
 .In netinet/cc/cc_module.h
 .Fn DECLARE_CC_MODULE "ccname" "ccalgo"
-.Fn CC_VAR "ccv" "what"
+.Fn CCV "ccv" "what"
 .Sh DESCRIPTION
 The
 .Nm
@@ -223,7 +223,7 @@ To aid the eventual transition towards t
 the transport protocol's data structures is strongly discouraged.
 However, it is inevitable at the current time to require access to some of 
these
 variables, and so the
-.Fn CC_VAR
+.Fn CCV
 macro exists as a convenience accessor.
 The
 .Fa ccv
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276202 - head/sys/arm/include

2014-12-25 Thread Ian Lepore
Author: ian
Date: Thu Dec 25 16:36:02 2014
New Revision: 276202
URL: https://svnweb.freebsd.org/changeset/base/276202

Log:
  Stylish changes... put tabs where they need to be in macros, move lines
  around so that related things are more grouped together, rewrite comments.
  
  No functional changes, this is all so that the functional changes in the
  next commit will stand out.

Modified:
  head/sys/arm/include/asm.h

Modified: head/sys/arm/include/asm.h
==
--- head/sys/arm/include/asm.h  Thu Dec 25 15:17:57 2014(r276201)
+++ head/sys/arm/include/asm.h  Thu Dec 25 16:36:02 2014(r276202)
@@ -58,6 +58,22 @@
 #endif
 
 /*
+ * gas/arm uses @ as a single comment character and thus cannot be used here.
+ * It recognises the # instead of an @ symbol in .type directives.
+ */
+#define_ASM_TYPE_FUNCTION  #function
+#define_ASM_TYPE_OBJECT#object
+
+/* XXX Is this still the right prologue for profiling? */
+#ifdef GPROF
+#define_PROF_PROLOGUE  \
+   mov ip, lr; \
+   bl __mcount
+#else
+#define_PROF_PROLOGUE
+#endif
+
+/*
  * EENTRY()/EEND() mark "extra" entry/exit points from a function.
  * The unwind info cannot handle the concept of a nested function, or a 
function
  * with multiple .fnstart directives, but some of our assembler code is written
@@ -69,25 +85,9 @@
 #define_EENTRY(x)  .globl x; .type x,_ASM_TYPE_FUNCTION; x:
 #define_EEND(x)/* nothing */
 
-/*
- * gas/arm uses @ as a single comment character and thus cannot be used here
- * Instead it recognised the # instead of an @ symbols in .type directives
- * We define a couple of macros so that assembly code will not be dependent
- * on one or the other.
- */
-#define _ASM_TYPE_FUNCTION #function
-#define _ASM_TYPE_OBJECT   #object
-#define GLOBAL(X) .globl x
-#define_ENTRY(x) \
-   .text; _ALIGN_TEXT; _EENTRY(x) _FNSTART
-#define_END(x) .size x, . - x; _FNEND
-
-#ifdef GPROF
-#  define _PROF_PROLOGUE   \
-   mov ip, lr; bl __mcount
-#else
-# define _PROF_PROLOGUE
-#endif
+#defineGLOBAL(X)   .globl x
+#define_ENTRY(x)   .text; _ALIGN_TEXT; _EENTRY(x) _FNSTART
+#define_END(x) .size x, . - x; _FNEND
 
 #defineENTRY(y)_ENTRY(_C_LABEL(y)); _PROF_PROLOGUE
 #defineEENTRY(y)   _EENTRY(_C_LABEL(y));
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276203 - head/sys/arm/include

2014-12-25 Thread Ian Lepore
Author: ian
Date: Thu Dec 25 16:43:15 2014
New Revision: 276203
URL: https://svnweb.freebsd.org/changeset/base/276203

Log:
  Fix the GLOBAL macro so it works (upper vs lowercase X), use it in _EENTRY.

Modified:
  head/sys/arm/include/asm.h

Modified: head/sys/arm/include/asm.h
==
--- head/sys/arm/include/asm.h  Thu Dec 25 16:36:02 2014(r276202)
+++ head/sys/arm/include/asm.h  Thu Dec 25 16:43:15 2014(r276203)
@@ -82,10 +82,11 @@
  * basically just a label that you can jump to.  The EEND() macro does nothing
  * at all, except document the exit point associated with the same-named entry.
  */
-#define_EENTRY(x)  .globl x; .type x,_ASM_TYPE_FUNCTION; x:
+#defineGLOBAL(x)   .global x
+
+#define_EENTRY(x)  GLOBAL(x); .type x,_ASM_TYPE_FUNCTION; x:
 #define_EEND(x)/* nothing */
 
-#defineGLOBAL(X)   .globl x
 #define_ENTRY(x)   .text; _ALIGN_TEXT; _EENTRY(x) _FNSTART
 #define_END(x) .size x, . - x; _FNEND
 
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276204 - head/sys/arm/include

2014-12-25 Thread Ian Lepore
Author: ian
Date: Thu Dec 25 16:49:33 2014
New Revision: 276204
URL: https://svnweb.freebsd.org/changeset/base/276204

Log:
  Create 'L' variants of all the ENTRY macros for file-static/local symbols.
  
  If it seems like this is getting out of hand, I quite agree.  I wonder if
  it's safe, here in the 21st century, to lose the distinction between C and
  ASM symbols?

Modified:
  head/sys/arm/include/asm.h

Modified: head/sys/arm/include/asm.h
==
--- head/sys/arm/include/asm.h  Thu Dec 25 16:43:15 2014(r276203)
+++ head/sys/arm/include/asm.h  Thu Dec 25 16:49:33 2014(r276204)
@@ -75,6 +75,7 @@
 
 /*
  * EENTRY()/EEND() mark "extra" entry/exit points from a function.
+ * LEENTRY()/LEEND() are the the same for local symbols.
  * The unwind info cannot handle the concept of a nested function, or a 
function
  * with multiple .fnstart directives, but some of our assembler code is written
  * with multiple labels to allow entry at several points.  The EENTRY() macro
@@ -84,11 +85,15 @@
  */
 #defineGLOBAL(x)   .global x
 
-#define_EENTRY(x)  GLOBAL(x); .type x,_ASM_TYPE_FUNCTION; x:
-#define_EEND(x)/* nothing */
-
-#define_ENTRY(x)   .text; _ALIGN_TEXT; _EENTRY(x) _FNSTART
-#define_END(x) .size x, . - x; _FNEND
+#define_LEENTRY(x) .type x,_ASM_TYPE_FUNCTION; x:
+#define_LEEND(x)   /* nothing */
+#define_EENTRY(x)  GLOBAL(x); _LEENTRY(x)
+#define_EEND(x)_LEEND(x)
+
+#define_LENTRY(x)  .text; _ALIGN_TEXT; _LEENTRY(x); _FNSTART
+#define_LEND(x).size x, . - x; _FNEND
+#define_ENTRY(x)   .text; _ALIGN_TEXT; _EENTRY(x); _FNSTART
+#define_END(x) _LEND(x)
 
 #defineENTRY(y)_ENTRY(_C_LABEL(y)); _PROF_PROLOGUE
 #defineEENTRY(y)   _EENTRY(_C_LABEL(y));
@@ -97,11 +102,17 @@
 #defineEND(y)  _END(_C_LABEL(y))
 #defineEEND(y) _EEND(_C_LABEL(y))
 #defineASENTRY(y)  _ENTRY(_ASM_LABEL(y)); _PROF_PROLOGUE
+#defineASLENTRY(y) _LENTRY(_ASM_LABEL(y)); _PROF_PROLOGUE
 #defineASEENTRY(y) _EENTRY(_ASM_LABEL(y));
+#defineASLEENTRY(y)_LEENTRY(_ASM_LABEL(y));
 #defineASENTRY_NP(y)   _ENTRY(_ASM_LABEL(y))
+#defineASLENTRY_NP(y)  _LENTRY(_ASM_LABEL(y))
 #defineASEENTRY_NP(y)  _EENTRY(_ASM_LABEL(y))
+#defineASLEENTRY_NP(y) _LEENTRY(_ASM_LABEL(y))
 #defineASEND(y)_END(_ASM_LABEL(y))
+#defineASLEND(y)   _LEND(_ASM_LABEL(y))
 #defineASEEND(y)   _EEND(_ASM_LABEL(y))
+#defineASLEEND(y)  _LEEND(_ASM_LABEL(y))
 
 #defineASMSTR  .asciz
 
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276206 - in head/sys/arm: arm include

2014-12-25 Thread Ian Lepore
Author: ian
Date: Thu Dec 25 17:06:58 2014
New Revision: 276206
URL: https://svnweb.freebsd.org/changeset/base/276206

Log:
  For data and instruction prefetch aborts, call the same handler in the C
  code, passing a 0/1 flag that indicates which type of abort it was.  This
  sets the stage for unifying the handling of page faults in a single routine.
  
  Submitted by: Svatopluk Kraus ,
  Michal Meloun http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276207 - in head/sys: arm/ti boot/fdt/dts/arm

2014-12-25 Thread Luiz Otavio O Souza
Author: loos
Date: Thu Dec 25 17:28:26 2014
New Revision: 276207
URL: https://svnweb.freebsd.org/changeset/base/276207

Log:
  Add interrupt support for GPIO pins on OMAP4 and AM335x.
  
  This enables the use of GPIO pins as interrupt sources for kernel devices
  directly attached to gpiobus (userland notification will be added soon).
  
  The use of gpio interrupts for other kernel devices will be possible when
  intrng is complete.
  
  All GPIO pins can be set to trigger on:
  
  - active-low;
  - active-high;
  - rising edge;
  - falling edge.
  
  Tested on:Beaglebone-black

Modified:
  head/sys/arm/ti/ti_gpio.c
  head/sys/arm/ti/ti_gpio.h
  head/sys/boot/fdt/dts/arm/am335x.dtsi

Modified: head/sys/arm/ti/ti_gpio.c
==
--- head/sys/arm/ti/ti_gpio.c   Thu Dec 25 17:06:58 2014(r276206)
+++ head/sys/arm/ti/ti_gpio.c   Thu Dec 25 17:28:26 2014(r276207)
@@ -1,6 +1,6 @@
 /*-
- * Copyright (c) 2011
- * Ben Gray .
+ * Copyright (c) 2011 Ben Gray .
+ * Copyright (c) 2014 Luiz Otavio O Souza .
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -26,17 +26,8 @@
  */
 
 /**
- * Very simple GPIO (general purpose IO) driver module for TI OMAP SoC's.
- *
- * Currently this driver only does the basics, get a value on a pin & set a
- * value on a pin. Hopefully over time I'll expand this to be a bit more 
generic
- * and support interrupts and other various bits on the SoC can do ... in 
the
- * meantime this is all you get.
- *
- * Beware the OMA datasheet(s) lists GPIO banks 1-6, whereas I've used 0-5 
here
- * in the code.
- *
- *
+ * Beware that the OMAP4 datasheet(s) lists GPIO banks 1-6, whereas the code
+ * here uses 0-5.
  */
 
 #include 
@@ -52,6 +43,7 @@ __FBSDID("$FreeBSD$");
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -120,6 +112,8 @@ __FBSDID("$FreeBSD$");
 #defineTI_GPIO_BANK(p) ((p) / PINS_PER_BANK)
 #defineTI_GPIO_MASK(p) (1U << ((p) % PINS_PER_BANK))
 
+static struct ti_gpio_softc *ti_gpio_sc = NULL;
+
 static u_int
 ti_max_gpio_banks(void)
 {
@@ -228,14 +222,14 @@ static struct resource_spec ti_gpio_irq_
 /**
  * Macros for driver mutex locking
  */
-#defineTI_GPIO_LOCK(_sc)   mtx_lock(&(_sc)->sc_mtx)
-#defineTI_GPIO_UNLOCK(_sc) mtx_unlock(&(_sc)->sc_mtx)
+#defineTI_GPIO_LOCK(_sc)   mtx_lock_spin(&(_sc)->sc_mtx)
+#defineTI_GPIO_UNLOCK(_sc) mtx_unlock_spin(&(_sc)->sc_mtx)
 #defineTI_GPIO_LOCK_INIT(_sc)  \
-   mtx_init(&_sc->sc_mtx, device_get_nameunit(_sc->sc_dev), \
-   "ti_gpio", MTX_DEF)
-#defineTI_GPIO_LOCK_DESTROY(_sc)   mtx_destroy(&_sc->sc_mtx)
-#defineTI_GPIO_ASSERT_LOCKED(_sc)  mtx_assert(&_sc->sc_mtx, 
MA_OWNED)
-#defineTI_GPIO_ASSERT_UNLOCKED(_sc)mtx_assert(&_sc->sc_mtx, 
MA_NOTOWNED)
+   mtx_init(&_sc->sc_mtx, device_get_nameunit((_sc)->sc_dev), \
+   "ti_gpio", MTX_SPIN)
+#defineTI_GPIO_LOCK_DESTROY(_sc)   mtx_destroy(&(_sc)->sc_mtx)
+#defineTI_GPIO_ASSERT_LOCKED(_sc)  mtx_assert(&(_sc)->sc_mtx, 
MA_OWNED)
+#defineTI_GPIO_ASSERT_UNLOCKED(_sc)mtx_assert(&(_sc)->sc_mtx, 
MA_NOTOWNED)
 
 /**
  * ti_gpio_read_4 - reads a 32-bit value from one of the GPIO registers
@@ -279,6 +273,41 @@ ti_gpio_intr_clr(struct ti_gpio_softc *s
ti_gpio_write_4(sc, bank, TI_GPIO_IRQSTATUS_CLR_1, mask);
 }
 
+static inline void
+ti_gpio_intr_set(struct ti_gpio_softc *sc, unsigned int bank, uint32_t mask)
+{
+
+   /*
+* On OMAP4 we unmask only the MPU interrupt and on AM335x we
+* also activate only the first interrupt.
+*/
+   ti_gpio_write_4(sc, bank, TI_GPIO_IRQSTATUS_SET_0, mask);
+}
+
+static inline void
+ti_gpio_intr_ack(struct ti_gpio_softc *sc, unsigned int bank, uint32_t mask)
+{
+
+   /*
+* Acknowledge the interrupt on both registers even if we use only
+* the first one.
+*/
+   ti_gpio_write_4(sc, bank, TI_GPIO_IRQSTATUS_0, mask);
+   ti_gpio_write_4(sc, bank, TI_GPIO_IRQSTATUS_1, mask);
+}
+
+static inline uint32_t
+ti_gpio_intr_status(struct ti_gpio_softc *sc, unsigned int bank)
+{
+   uint32_t reg;
+
+   /* Get the status from both registers. */
+   reg = ti_gpio_read_4(sc, bank, TI_GPIO_IRQSTATUS_0);
+   reg |= ti_gpio_read_4(sc, bank, TI_GPIO_IRQSTATUS_1);
+
+   return (reg);
+}
+
 /**
  * ti_gpio_pin_max - Returns the maximum number of GPIO pins
  * @dev: gpio device handle
@@ -575,20 +604,39 @@ ti_gpio_pin_toggle(device_t dev, uint32_
  * ti_gpio_intr - ISR for all GPIO modules
  * @arg: the soft context pointer
  *
- * Unsused
- *
  * LOCKING:
  * Internally locks the context
  *
  */
-static void
+static int
 ti_gpio_intr(void *

svn commit: r276208 - in head/sys: amd64/conf conf

2014-12-25 Thread Poul-Henning Kamp
Author: phk
Date: Thu Dec 25 17:50:04 2014
New Revision: 276208
URL: https://svnweb.freebsd.org/changeset/base/276208

Log:
  Use compiled in default keymaps which are available both in syscons and vt.

Modified:
  head/sys/amd64/conf/NOTES
  head/sys/conf/NOTES

Modified: head/sys/amd64/conf/NOTES
==
--- head/sys/amd64/conf/NOTES   Thu Dec 25 17:28:26 2014(r276207)
+++ head/sys/amd64/conf/NOTES   Thu Dec 25 17:50:04 2014(r276208)
@@ -215,7 +215,7 @@ hint.atkbd.0.irq="1"
 
 # Options for atkbd:
 optionsATKBD_DFLT_KEYMAP   # specify the built-in keymap
-makeoptionsATKBD_DFLT_KEYMAP=jp.106
+makeoptionsATKBD_DFLT_KEYMAP=fr.dvorak
 
 # `flags' for atkbd:
 #   0x01Force detection of keyboard, else we always assume a keyboard

Modified: head/sys/conf/NOTES
==
--- head/sys/conf/NOTES Thu Dec 25 17:28:26 2014(r276207)
+++ head/sys/conf/NOTES Thu Dec 25 17:50:04 2014(r276208)
@@ -2785,7 +2785,7 @@ options   U3G_DEBUG
 
 # options for ukbd:
 optionsUKBD_DFLT_KEYMAP# specify the built-in keymap
-makeoptionsUKBD_DFLT_KEYMAP=it.iso
+makeoptionsUKBD_DFLT_KEYMAP=jp.pc98
 
 # options for uplcom:
 optionsUPLCOM_INTR_INTERVAL=100# interrupt pipe interval
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276209 - head

2014-12-25 Thread Alfred Perlstein
Author: alfred
Date: Thu Dec 25 17:53:43 2014
New Revision: 276209
URL: https://svnweb.freebsd.org/changeset/base/276209

Log:
  Fix OLD_LIBS for libxo moved to /lib
  
  Pointed out by: kib

Modified:
  head/ObsoleteFiles.inc

Modified: head/ObsoleteFiles.inc
==
--- head/ObsoleteFiles.inc  Thu Dec 25 17:50:04 2014(r276208)
+++ head/ObsoleteFiles.inc  Thu Dec 25 17:53:43 2014(r276209)
@@ -39,8 +39,7 @@
 # done
 
 # 20141224: libxo moved to /lib
-OLD_FILES+=usr/lib/libxo.a
-OLD_FILES+=usr/lib/libxo_p.a
+OLD_LIBS+=usr/lib/libxo.so.0
 # 20141223: remove in6_gif.h, in_gif.h and if_stf.h
 OLD_FILES+=usr/include/net/if_stf.h
 OLD_FILES+=usr/include/netinet/in_gif.h
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276210 - head/tools/tools/sysbuild

2014-12-25 Thread Poul-Henning Kamp
Author: phk
Date: Thu Dec 25 17:54:22 2014
New Revision: 276210
URL: https://svnweb.freebsd.org/changeset/base/276210

Log:
  Create the PKG_DIR if it is missing

Modified:
  head/tools/tools/sysbuild/sysbuild.sh

Modified: head/tools/tools/sysbuild/sysbuild.sh
==
--- head/tools/tools/sysbuild/sysbuild.sh   Thu Dec 25 17:53:43 2014
(r276209)
+++ head/tools/tools/sysbuild/sysbuild.sh   Thu Dec 25 17:54:22 2014
(r276210)
@@ -219,6 +219,10 @@ ports_build() (
 
ports_recurse . $PORTS_WE_WANT 
 
+   if [ "x${PKG_DIR}" != "x" ] ; then
+   mkdir -p ${PKG_DIR}
+   fi
+
# Now build & install them
for p in `cat /tmp/_.plist`
do
@@ -231,9 +235,7 @@ ports_build() (
 
(
cd $p
-   make clean ${PORTS_OPTS}
-   make all ${PORTS_OPTS}
-   make install ${PORTS_OPTS}
+   make clean all install ${PORTS_OPTS}
) > _.$b 2>&1 < /dev/null
continue
fi
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


Re: svn commit: r276148 - in head: . sys/net sys/netinet sys/netinet6

2014-12-25 Thread Jilles Tjoelker
On Tue, Dec 23, 2014 at 04:17:38PM +, Andrey V. Elsukov wrote:
> Author: ae
> Date: Tue Dec 23 16:17:37 2014
> New Revision: 276148
> URL: https://svnweb.freebsd.org/changeset/base/276148

> Log:
>   Remove in_gif.h and in6_gif.h files. They only contain function
>   declarations used by gif(4). Instead declare these functions in C files.
>   Also make some variables static.

Although making things static where possible is good, moving extern
declarations to C files adds duplication and loses compile-time checking
that the functions' calls match their definitions
(output/encapcheck/attach).

> [snip]
> Modified: head/sys/net/if_gif.c
> ==
> --- head/sys/net/if_gif.c Tue Dec 23 16:00:25 2014(r276147)
> +++ head/sys/net/if_gif.c Tue Dec 23 16:17:37 2014(r276148)
> @@ -72,7 +72,6 @@ __FBSDID("$FreeBSD$");
>  #include 
>  #ifdef   INET
>  #include 
> -#include 
>  #include 
>  #endif   /* INET */
>  
> @@ -85,7 +84,6 @@ __FBSDID("$FreeBSD$");
>  #include 
>  #include 
>  #include 
> -#include 
>  #include 
>  #endif /* INET6 */
>  
> @@ -120,6 +118,16 @@ void (*ng_gif_input_orphan_p)(struct ifn
>  void (*ng_gif_attach_p)(struct ifnet *ifp);
>  void (*ng_gif_detach_p)(struct ifnet *ifp);
>  
> +#ifdef INET
> +extern int in_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
> +extern int in_gif_encapcheck(const struct mbuf *, int, int, void *);
> +extern int in_gif_attach(struct gif_softc *);
> +#endif
> +#ifdef INET6
> +extern int in6_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
> +extern int in6_gif_encapcheck(const struct mbuf *, int, int, void *);
> +extern int in6_gif_attach(struct gif_softc *);
> +#endif
>  static int   gif_set_tunnel(struct ifnet *, struct sockaddr *,
>  struct sockaddr *);
>  static void  gif_delete_tunnel(struct ifnet *);
> 
> Modified: head/sys/netinet/in_gif.c
> ==
> --- head/sys/netinet/in_gif.c Tue Dec 23 16:00:25 2014(r276147)
> +++ head/sys/netinet/in_gif.c Tue Dec 23 16:17:37 2014(r276148)
> @@ -57,7 +57,6 @@ __FBSDID("$FreeBSD$");
>  #include 
>  #include 
>  #include 
> -#include 
>  #include 
>  #include 
>  #include 
> @@ -68,11 +67,16 @@ __FBSDID("$FreeBSD$");
>  
>  #include 
>  
> +int in_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
> +int in_gif_encapcheck(const struct mbuf *, int, int, void *);
> +int in_gif_attach(struct gif_softc *);
> +
>  static int gif_validate4(const struct ip *, struct gif_softc *,
>   struct ifnet *);
> +static int in_gif_input(struct mbuf **, int *, int);
>  
>  extern  struct domain inetdomain;
> -struct protosw in_gif_protosw = {
> +static struct protosw in_gif_protosw = {
>   .pr_type =  SOCK_RAW,
>   .pr_domain =&inetdomain,
>   .pr_protocol =  0/* IPPROTO_IPV[46] */,
> @@ -83,7 +87,8 @@ struct protosw in_gif_protosw = {
>   .pr_usrreqs =   &rip_usrreqs
>  };
>  
> -VNET_DEFINE(int, ip_gif_ttl) = GIF_TTL;
> +#define GIF_TTL  30
> +static VNET_DEFINE(int, ip_gif_ttl) = GIF_TTL;
>  #define  V_ip_gif_ttlVNET(ip_gif_ttl)
>  SYSCTL_INT(_net_inet_ip, IPCTL_GIF_TTL, gifttl, CTLFLAG_VNET | CTLFLAG_RW,
>   &VNET_NAME(ip_gif_ttl), 0, "");
> @@ -133,7 +138,7 @@ in_gif_output(struct ifnet *ifp, struct 
>   return (ip_output(m, NULL, NULL, 0, NULL, NULL));
>  }
>  
> -int
> +static int
>  in_gif_input(struct mbuf **mp, int *offp, int proto)
>  {
>   struct mbuf *m = *mp;
> 
> Modified: head/sys/netinet6/in6_gif.c
> ==
> --- head/sys/netinet6/in6_gif.c   Tue Dec 23 16:00:25 2014
> (r276147)
> +++ head/sys/netinet6/in6_gif.c   Tue Dec 23 16:17:37 2014
> (r276148)
> @@ -64,7 +64,6 @@ __FBSDID("$FreeBSD$");
>  #ifdef INET6
>  #include 
>  #include 
> -#include 
>  #include 
>  #endif
>  #include 
> @@ -74,18 +73,24 @@ __FBSDID("$FreeBSD$");
>  
>  #include 
>  
> -VNET_DEFINE(int, ip6_gif_hlim) = GIF_HLIM;
> +#define GIF_HLIM 30
> +static VNET_DEFINE(int, ip6_gif_hlim) = GIF_HLIM;
>  #define  V_ip6_gif_hlim  VNET(ip6_gif_hlim)
>  
>  SYSCTL_DECL(_net_inet6_ip6);
>  SYSCTL_INT(_net_inet6_ip6, IPV6CTL_GIF_HLIM, gifhlim, CTLFLAG_VNET | 
> CTLFLAG_RW,
>  &VNET_NAME(ip6_gif_hlim), 0, "");
>  
> +int in6_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
> +int in6_gif_encapcheck(const struct mbuf *, int, int, void *);
> +int in6_gif_attach(struct gif_softc *);
> +
>  static int gif_validate6(const struct ip6_hdr *, struct gif_softc *,
>struct ifnet *);
> +static int in6_gif_input(struct mbuf **, int *, int);
>  
>  extern  struct domain inet6domain;
> -struct protosw in6_gif_protosw = {
> +static struct protosw in6_gif_protosw = {
>   .pr_type =  SOCK_RAW,
>   

svn commit: r276212 - head/sys/arm/include

2014-12-25 Thread Ian Lepore
Author: ian
Date: Thu Dec 25 19:08:39 2014
New Revision: 276212
URL: https://svnweb.freebsd.org/changeset/base/276212

Log:
  Add macros for asm barrier instructions with arch-specific implementations.

Modified:
  head/sys/arm/include/asm.h

Modified: head/sys/arm/include/asm.h
==
--- head/sys/arm/include/asm.h  Thu Dec 25 18:22:22 2014(r276211)
+++ head/sys/arm/include/asm.h  Thu Dec 25 19:08:39 2014(r276212)
@@ -39,6 +39,7 @@
 #ifndef _MACHINE_ASM_H_
 #define _MACHINE_ASM_H_
 #include 
+#include 
 
 #define_C_LABEL(x) x
 #define_ASM_LABEL(x)   x
@@ -221,4 +222,18 @@
 # define RETc(c) mov##cpc, lr
 #endif
 
+#if __ARM_ARCH >= 7
+#define ISBisb
+#define DSBdsb
+#define DMBdmb
+#elif __ARM_ARCH == 6
+#define ISBmcr CP15_CP15ISB
+#define DSBmcr CP15_CP15DSB
+#define DMBmcr CP15_CP15DMB
+#else
+#define ISBmcr CP15_CP15ISB
+#define DSBmcr CP15_CP15DSB/* DSB and DMB are the */
+#define DMBmcr CP15_CP15DSB/* same prior to v6.*/
+#endif
+
 #endif /* !_MACHINE_ASM_H_ */
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


Re: svn commit: r276195 - in head: . lib/libxo

2014-12-25 Thread Garrett Cooper

> On Dec 25, 2014, at 02:21, Konstantin Belousov  wrote:
> 
>> On Wed, Dec 24, 2014 at 11:04:01PM -0800, Garrett Cooper wrote:
>> 
>>> On Dec 24, 2014, at 19:56, Alfred Perlstein  wrote:
>>> 
>>> 
>>> On 12/24/14 7:36 PM, Garrett Cooper wrote:

...

>> There isn't a leftover versioned .so in /usr/lib ?
> usr/lib/libxo.so.0 (without leading slash) must go into OLD_LIBS.
> It is all explained in the first paragraph of the file comment.

+1 to what kib said :)..
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276214 - in head: . include lib share/man/man4 share/mk sys/conf sys/dev/ieee488 tools/build/mk tools/build/options

2014-12-25 Thread Poul-Henning Kamp
Author: phk
Date: Thu Dec 25 20:15:13 2014
New Revision: 276214
URL: https://svnweb.freebsd.org/changeset/base/276214

Log:
  Deorbit the IEEE-488/GPIB support.

Deleted:
  head/share/man/man4/gpib.4
  head/share/man/man4/pcii.4
  head/share/man/man4/tnt4882.4
  head/sys/dev/ieee488/ibfoo.c
  head/sys/dev/ieee488/ibfoo_int.h
  head/sys/dev/ieee488/pcii.c
  head/sys/dev/ieee488/tnt4882.c
  head/sys/dev/ieee488/tnt4882.h
  head/sys/dev/ieee488/ugpib.h
  head/sys/dev/ieee488/upd7210.c
  head/sys/dev/ieee488/upd7210.h
  head/tools/build/options/WITHOUT_GPIB
Modified:
  head/ObsoleteFiles.inc
  head/include/Makefile
  head/lib/Makefile
  head/share/man/man4/Makefile
  head/share/mk/src.opts.mk
  head/sys/conf/NOTES
  head/sys/conf/files
  head/tools/build/mk/OptionalObsoleteFiles.inc

Modified: head/ObsoleteFiles.inc
==
--- head/ObsoleteFiles.inc  Thu Dec 25 19:22:02 2014(r276213)
+++ head/ObsoleteFiles.inc  Thu Dec 25 20:15:13 2014(r276214)
@@ -38,6 +38,29 @@
 #   xargs -n1 | sort | uniq -d;
 # done
 
+# 20141226: Remove gpib/ieee488
+OLD_FILES+=usr/include/dev/ieee488/ibfoo_int.h
+OLD_FILES+=usr/include/dev/ieee488/tnt4882.h
+OLD_FILES+=usr/include/dev/ieee488/ugpib.h
+OLD_FILES+=usr/include/dev/ieee488/upd7210.h
+OLD_DIRS+=usr/include/dev/ieee488
+OLD_FILES+=usr/include/gpib/gpib.h
+OLD_DIRS+=usr/include/gpib
+OLD_FILES+=usr/lib/libgpib.a
+OLD_FILES+=usr/lib/libgpib_p.a
+OLD_FILES+=usr/lib/libgpib.so
+OLD_LIBS+=usr/lib/libgpib.so.3
+OLD_FILES+=usr/lib/libgpib_p.a
+OLD_FILES+=share/man/man4/pcii.4.gz
+OLD_FILES+=share/man/man4/gpib.4.gz
+OLD_FILES+=share/man/man4/tnt4882.4.gz
+.if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "powerpc64"
+OLD_FILES+=usr/lib32/libgpib.a
+OLD_FILES+=usr/lib32/libgpib_p.a
+OLD_FILES+=usr/lib32/libgpib.so
+OLD_LIBS+=usr/lib32/libgpib.so.3
+.endif
+
 # 20141224: libxo moved to /lib
 OLD_LIBS+=usr/lib/libxo.so.0
 # 20141223: remove in6_gif.h, in_gif.h and if_stf.h

Modified: head/include/Makefile
==
--- head/include/Makefile   Thu Dec 25 19:22:02 2014(r276213)
+++ head/include/Makefile   Thu Dec 25 20:15:13 2014(r276214)
@@ -42,7 +42,7 @@ LDIRS=bsm cam geom net net80211 netgrap
 LSUBDIRS=  cam/ata cam/scsi \
dev/acpica dev/agp dev/an dev/bktr dev/ciss dev/filemon dev/firewire \
dev/hwpmc \
-   dev/ic dev/iicbus ${_dev_ieee488} dev/io dev/lmc dev/mfi dev/nvme \
+   dev/ic dev/iicbus dev/io dev/lmc dev/mfi dev/nvme \
dev/ofw dev/pbio dev/pci ${_dev_powermac_nvram} dev/ppbus dev/smbus \
dev/speaker dev/usb dev/utopia dev/vkbd dev/wi \
fs/cuse \
@@ -63,10 +63,6 @@ LSUBSUBDIRS= dev/mpt/mpilib
 _dev_powermac_nvram=   dev/powermac_nvram
 .endif
 
-.if ${MK_GPIB} != "no"
-_dev_ieee488=  dev/ieee488
-.endif
-
 .if ${MK_GSSAPI} != "no"
 SUBDIR+=   gssapi
 INCS+= gssapi.h

Modified: head/lib/Makefile
==
--- head/lib/Makefile   Thu Dec 25 19:22:02 2014(r276213)
+++ head/lib/Makefile   Thu Dec 25 20:15:13 2014(r276214)
@@ -52,7 +52,6 @@ SUBDIR=   ${SUBDIR_ORDERED} \
libfetch \
libfigpar \
libgeom \
-   ${_libgpib} \
libgpio \
${_libgssapi} \
${_librpcsec_gss} \
@@ -195,10 +194,6 @@ _cuse= libcuse
 _libelftc= libelftc
 .endif
 
-.if ${MK_GPIB} != "no"
-_libgpib=  libgpib
-.endif
-
 .if ${MK_GSSAPI} != "no"
 _libgssapi=libgssapi
 _librpcsec_gss=librpcsec_gss

Modified: head/share/man/man4/Makefile
==
--- head/share/man/man4/MakefileThu Dec 25 19:22:02 2014
(r276213)
+++ head/share/man/man4/MakefileThu Dec 25 20:15:13 2014
(r276214)
@@ -156,7 +156,6 @@ MAN=aac.4 \
geom_uncompress.4 \
geom_uzip.4 \
gif.4 \
-   gpib.4 \
gpio.4 \
gpioiic.4 \
gpioled.4 \
@@ -372,7 +371,6 @@ MAN=aac.4 \
pci.4 \
pcib.4 \
pcic.4 \
-   pcii.4 \
pcm.4 \
pcn.4 \
${_pf.4} \
@@ -495,7 +493,6 @@ MAN=aac.4 \
ti.4 \
timecounters.4 \
tl.4 \
-   tnt4882.4 \
${_tpm.4} \
trm.4 \
tty.4 \

Modified: head/share/mk/src.opts.mk
==
--- head/share/mk/src.opts.mk   Thu Dec 25 19:22:02 2014(r276213)
+++ head/share/mk/src.opts.mk   Thu Dec 25 20:15:13 2014(r276214)
@@ -85,7 +85,6 @@ __DEFAULT_YES_OPTIONS = \
 GDB \
 GNU \
 GNU_GREP_COMPAT \
-GPIB \
 GPIO \
 GPL_DTC \
 GROFF \

Modified: head/sys/conf/NOTES
==
--- head/sys/c

Re: svn commit: r276195 - in head: . lib/libxo

2014-12-25 Thread Alfred Perlstein


On 12/25/14 12:07 PM, Garrett Cooper wrote:

On Dec 25, 2014, at 02:21, Konstantin Belousov  wrote:


On Wed, Dec 24, 2014 at 11:04:01PM -0800, Garrett Cooper wrote:


On Dec 24, 2014, at 19:56, Alfred Perlstein  wrote:


On 12/24/14 7:36 PM, Garrett Cooper wrote:

...


There isn't a leftover versioned .so in /usr/lib ?

usr/lib/libxo.so.0 (without leading slash) must go into OLD_LIBS.
It is all explained in the first paragraph of the file comment.

+1 to what kib said :)..

I *think* i fixed it, but tbh the docs in that file make very little 
sense to the layperson.


The suggested sanity scripts should be either make(1) targets, or 
perhaps scripts in /usr/share to run, not inline comments.


Having a "make sanity-obsolete" would be nice.

-Alfred


___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


Re: svn commit: r276123 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs

2014-12-25 Thread Will Andrews
Why was the original condition there? It may not be documented in a
commenf, but presumably there is a reason. Did you ask the original author
of the code in question?

--Will.


On Tuesday, December 23, 2014, Steven Hartland  wrote:

> Author: smh
> Date: Tue Dec 23 09:31:24 2014
> New Revision: 276123
> URL: https://svnweb.freebsd.org/changeset/base/276123
>
> Log:
>   Always sync the global ZFS config cache to reflect the new mosconfig
>
>   This fixes out of date zpool.cache for root pools, which can cause issues
>   such as confusion of zdb etc.
>
>   MFC after:1 month
>
> Modified:
>   head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_config.c
>
> Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_config.c
>
> ==
> --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_config.c
> Tue Dec 23 08:51:30 2014(r276122)
> +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_config.c
> Tue Dec 23 09:31:24 2014(r276123)
> @@ -536,8 +536,7 @@ spa_config_update(spa_t *spa, int what)
> /*
>  * Update the global config cache to reflect the new mosconfig.
>  */
> -   if (!spa->spa_is_root)
> -   spa_config_sync(spa, B_FALSE, what !=
> SPA_CONFIG_UPDATE_POOL);
> +   spa_config_sync(spa, B_FALSE, what != SPA_CONFIG_UPDATE_POOL);
>
> if (what == SPA_CONFIG_UPDATE_POOL)
> spa_config_update(spa, SPA_CONFIG_UPDATE_VDEVS);
>
>
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


Re: svn commit: r276123 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs

2014-12-25 Thread Steven Hartland
I checked when I initially investigated the issue and it was added when 
ZFS boot support was originally incorporated into Solaris.


FreeBSD's ZFS boot support outstrips illumos upstream, not even 
requiring the cache file, and when initially discussed with others it 
was thought the most likely reason for the conditional was some sort of 
incompatibility with their original implementation.


I've already raised the issue upstream 
(https://www.illumos.org/issues/5472) so if anything comes of that I'll 
update.


In the mean time I've not been able to produce any issues with the 
change, even after sitting in our production tree for a number of 
months, and it does fix the issues reported by others due to out of date 
cache files.


Regards
Steve

On 25/12/2014 21:10, Will Andrews wrote:
Why was the original condition there? It may not be documented in a 
commenf, but presumably there is a reason. Did you ask the original 
author of the code in question?


--Will.


On Tuesday, December 23, 2014, Steven Hartland > wrote:


Author: smh
Date: Tue Dec 23 09:31:24 2014
New Revision: 276123
URL: https://svnweb.freebsd.org/changeset/base/276123

Log:
  Always sync the global ZFS config cache to reflect the new mosconfig

  This fixes out of date zpool.cache for root pools, which can
cause issues
  such as confusion of zdb etc.

  MFC after:1 month

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

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

==
---
head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_config.c  
Tue Dec 23 08:51:30 2014(r276122)

+++
head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_config.c  
Tue Dec 23 09:31:24 2014(r276123)

@@ -536,8 +536,7 @@ spa_config_update(spa_t *spa, int what)
/*
 * Update the global config cache to reflect the new
mosconfig.
 */
-   if (!spa->spa_is_root)
-   spa_config_sync(spa, B_FALSE, what !=
SPA_CONFIG_UPDATE_POOL);
+   spa_config_sync(spa, B_FALSE, what != SPA_CONFIG_UPDATE_POOL);

if (what == SPA_CONFIG_UPDATE_POOL)
spa_config_update(spa, SPA_CONFIG_UPDATE_VDEVS);



___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276215 - in head/sys: net netinet netinet6

2014-12-25 Thread Andrey V. Elsukov
Author: ae
Date: Thu Dec 25 21:32:37 2014
New Revision: 276215
URL: https://svnweb.freebsd.org/changeset/base/276215

Log:
  Extern declarations in C files loses compile-time checking that
  the functions' calls match their definitions. Move them to header files.
  
  Reviewed by:  jilles (previous version)

Modified:
  head/sys/net/if_gif.c
  head/sys/net/if_gif.h
  head/sys/net/if_gre.c
  head/sys/net/if_gre.h
  head/sys/netinet/in_gif.c
  head/sys/netinet/ip_gre.c
  head/sys/netinet6/in6_gif.c
  head/sys/netinet6/ip6_gre.c

Modified: head/sys/net/if_gif.c
==
--- head/sys/net/if_gif.c   Thu Dec 25 20:15:13 2014(r276214)
+++ head/sys/net/if_gif.c   Thu Dec 25 21:32:37 2014(r276215)
@@ -118,16 +118,6 @@ void   (*ng_gif_input_orphan_p)(struct ifn
 void   (*ng_gif_attach_p)(struct ifnet *ifp);
 void   (*ng_gif_detach_p)(struct ifnet *ifp);
 
-#ifdef INET
-extern int in_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
-extern int in_gif_encapcheck(const struct mbuf *, int, int, void *);
-extern int in_gif_attach(struct gif_softc *);
-#endif
-#ifdef INET6
-extern int in6_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
-extern int in6_gif_encapcheck(const struct mbuf *, int, int, void *);
-extern int in6_gif_attach(struct gif_softc *);
-#endif
 static int gif_set_tunnel(struct ifnet *, struct sockaddr *,
 struct sockaddr *);
 static voidgif_delete_tunnel(struct ifnet *);

Modified: head/sys/net/if_gif.h
==
--- head/sys/net/if_gif.h   Thu Dec 25 20:15:13 2014(r276214)
+++ head/sys/net/if_gif.h   Thu Dec 25 21:32:37 2014(r276215)
@@ -114,6 +114,16 @@ void gif_input(struct mbuf *, struct ifn
 int gif_output(struct ifnet *, struct mbuf *, const struct sockaddr *,
   struct route *);
 int gif_encapcheck(const struct mbuf *, int, int, void *);
+#ifdef INET
+int in_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
+int in_gif_encapcheck(const struct mbuf *, int, int, void *);
+int in_gif_attach(struct gif_softc *);
+#endif
+#ifdef INET6
+int in6_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
+int in6_gif_encapcheck(const struct mbuf *, int, int, void *);
+int in6_gif_attach(struct gif_softc *);
+#endif
 #endif /* _KERNEL */
 
 #define GIFGOPTS   _IOWR('i', 150, struct ifreq)

Modified: head/sys/net/if_gre.c
==
--- head/sys/net/if_gre.c   Thu Dec 25 20:15:13 2014(r276214)
+++ head/sys/net/if_gre.c   Thu Dec 25 21:32:37 2014(r276215)
@@ -119,16 +119,6 @@ static int gre_set_tunnel(struct ifnet *
 struct sockaddr *);
 static voidgre_delete_tunnel(struct ifnet *);
 
-intgre_input(struct mbuf **, int *, int);
-#ifdef INET
-extern int in_gre_attach(struct gre_softc *);
-extern int in_gre_output(struct mbuf *, int, int);
-#endif
-#ifdef INET6
-extern int in6_gre_attach(struct gre_softc *);
-extern int in6_gre_output(struct mbuf *, int, int);
-#endif
-
 SYSCTL_DECL(_net_link);
 static SYSCTL_NODE(_net_link, IFT_TUNNEL, gre, CTLFLAG_RW, 0,
 "Generic Routing Encapsulation");

Modified: head/sys/net/if_gre.h
==
--- head/sys/net/if_gre.h   Thu Dec 25 20:15:13 2014(r276214)
+++ head/sys/net/if_gre.h   Thu Dec 25 21:32:37 2014(r276215)
@@ -100,6 +100,15 @@ struct gre_softc {
 #definegre_oip gre_gihdr->gi_ip
 #definegre_oip6gre_gi6hdr->gi6_ip6
 
+intgre_input(struct mbuf **, int *, int);
+#ifdef INET
+intin_gre_attach(struct gre_softc *);
+intin_gre_output(struct mbuf *, int, int);
+#endif
+#ifdef INET6
+intin6_gre_attach(struct gre_softc *);
+intin6_gre_output(struct mbuf *, int, int);
+#endif
 /*
  * CISCO uses special type for GRE tunnel created as part of WCCP
  * connection, while in fact those packets are just IPv4 encapsulated

Modified: head/sys/netinet/in_gif.c
==
--- head/sys/netinet/in_gif.c   Thu Dec 25 20:15:13 2014(r276214)
+++ head/sys/netinet/in_gif.c   Thu Dec 25 21:32:37 2014(r276215)
@@ -67,10 +67,6 @@ __FBSDID("$FreeBSD$");
 
 #include 
 
-int in_gif_output(struct ifnet *, struct mbuf *, int, uint8_t);
-int in_gif_encapcheck(const struct mbuf *, int, int, void *);
-int in_gif_attach(struct gif_softc *);
-
 static int gif_validate4(const struct ip *, struct gif_softc *,
struct ifnet *);
 static int in_gif_input(struct mbuf **, int *, int);

Modified: head/sys/netinet/ip_gre.c
==
--- head/sys/netinet/ip_gre.c   Thu Dec 25 20:15:13 2014(r276214)
+++ head/sys/netinet/ip_gre.

svn commit: r276218 - head/usr.bin/patch

2014-12-25 Thread Pedro F. Giffuni
Author: pfg
Date: Thu Dec 25 21:51:28 2014
New Revision: 276218
URL: https://svnweb.freebsd.org/changeset/base/276218

Log:
  patch: Bring in xstrdup and use it when appropriate.
  
  The function savestr allows NULL return values during Plan A patching so in
  case of out of memory conditions, Plan B can step in.  In many cases, NULL
  value is not properly handled, so use xstrdup here (it's outside Plan A/B
  patching, which means that even Plan B relies on successful operations).
  
  Clean up some whitespaces while here
  
  Obtained from:OpenBSD
  MFC after:2 weeks

Modified:
  head/usr.bin/patch/patch.c
  head/usr.bin/patch/pch.c
  head/usr.bin/patch/util.c
  head/usr.bin/patch/util.h

Modified: head/usr.bin/patch/patch.c
==
--- head/usr.bin/patch/patch.c  Thu Dec 25 21:34:29 2014(r276217)
+++ head/usr.bin/patch/patch.c  Thu Dec 25 21:51:28 2014(r276218)
@@ -23,7 +23,7 @@
  * -C option added in 1998, original code by Marc Espie, based on FreeBSD
  * behaviour
  *
- * $OpenBSD: patch.c,v 1.52 2014/11/26 18:34:51 millert Exp $
+ * $OpenBSD: patch.c,v 1.54 2014/12/13 10:31:07 tobias Exp $
  * $FreeBSD$
  *
  */
@@ -215,13 +215,13 @@ main(int argc, char *argv[])
for (open_patch_file(filearg[1]); there_is_another_patch();
reinitialize_almost_everything()) {
/* for each patch in patch file */
-   
+
patch_seen = true;
 
warn_on_invalid_line = true;
 
if (outname == NULL)
-   outname = savestr(filearg[0]);
+   outname = xstrdup(filearg[0]);
 
/* for ed script just up and do it and exit */
if (diff_type == ED_DIFF) {
@@ -416,7 +416,7 @@ main(int argc, char *argv[])
}
set_signals(1);
}
-   
+
if (!patch_seen)
error = 2;
 
@@ -514,10 +514,10 @@ get_some_switches(void)
/* FALLTHROUGH */
case 'z':
/* must directly follow 'b' case for backwards compat */
-   simple_backup_suffix = savestr(optarg);
+   simple_backup_suffix = xstrdup(optarg);
break;
case 'B':
-   origprae = savestr(optarg);
+   origprae = xstrdup(optarg);
break;
case 'c':
diff_type = CONTEXT_DIFF;
@@ -555,7 +555,7 @@ get_some_switches(void)
case 'i':
if (++filec == MAXFILEC)
fatal("too many file arguments\n");
-   filearg[filec] = savestr(optarg);
+   filearg[filec] = xstrdup(optarg);
break;
case 'l':
canonicalize = true;
@@ -567,7 +567,7 @@ get_some_switches(void)
noreverse = true;
break;
case 'o':
-   outname = savestr(optarg);
+   outname = xstrdup(optarg);
break;
case 'p':
strippath = atoi(optarg);
@@ -611,12 +611,12 @@ get_some_switches(void)
Argv += optind;
 
if (Argc > 0) {
-   filearg[0] = savestr(*Argv++);
+   filearg[0] = xstrdup(*Argv++);
Argc--;
while (Argc > 0) {
if (++filec == MAXFILEC)
fatal("too many file arguments\n");
-   filearg[filec] = savestr(*Argv++);
+   filearg[filec] = xstrdup(*Argv++);
Argc--;
}
}

Modified: head/usr.bin/patch/pch.c
==
--- head/usr.bin/patch/pch.cThu Dec 25 21:34:29 2014(r276217)
+++ head/usr.bin/patch/pch.cThu Dec 25 21:51:28 2014(r276218)
@@ -205,14 +205,14 @@ there_is_another_patch(void)
while (filearg[0] == NULL) {
if (force || batch) {
say("No file to patch.  Skipping...\n");
-   filearg[0] = savestr(bestguess);
+   filearg[0] = xstrdup(bestguess);
skip_rest_of_patch = true;
return true;
}
ask("File to patch: ");
if (*buf != '\n') {
free(bestguess);
-   bestguess = savestr(buf);
+   bestguess = xstrdup(buf);
filearg[0] = fetchname(buf, &exists, 0);
}
if (!exists) {
@@ -319,7 +319,7 @@ intuit_diff_type(void)
else if (strnEQ(s, "Prereq:", 7)) {

svn commit: r276219 - in head: contrib/mdocml lib/libmandoc usr.bin/mandoc

2014-12-25 Thread Baptiste Daroussin
Author: bapt
Date: Thu Dec 25 21:56:56 2014
New Revision: 276219
URL: https://svnweb.freebsd.org/changeset/base/276219

Log:
  Update mandoc to 1.13.2

Added:
  head/contrib/mdocml/mandoc_headers.3
 - copied unchanged from r276217, vendor/mdocml/dist/mandoc_headers.3
Modified:
  head/contrib/mdocml/INSTALL
  head/contrib/mdocml/LICENSE
  head/contrib/mdocml/Makefile
  head/contrib/mdocml/Makefile.depend
  head/contrib/mdocml/NEWS
  head/contrib/mdocml/TODO
  head/contrib/mdocml/compat_fts.c
  head/contrib/mdocml/compat_reallocarray.c
  head/contrib/mdocml/compat_strcasestr.c
  head/contrib/mdocml/compat_strsep.c
  head/contrib/mdocml/config.h
  head/contrib/mdocml/configure
  head/contrib/mdocml/configure.local.example
  head/contrib/mdocml/example.style.css
  head/contrib/mdocml/html.c
  head/contrib/mdocml/html.h
  head/contrib/mdocml/libman.h
  head/contrib/mdocml/libmandoc.h
  head/contrib/mdocml/libmdoc.h
  head/contrib/mdocml/libroff.h
  head/contrib/mdocml/main.c
  head/contrib/mdocml/main.h
  head/contrib/mdocml/man.h
  head/contrib/mdocml/man_hash.c
  head/contrib/mdocml/man_html.c
  head/contrib/mdocml/man_term.c
  head/contrib/mdocml/mandoc.1
  head/contrib/mdocml/mandoc.h
  head/contrib/mdocml/mandoc_aux.h
  head/contrib/mdocml/mandocdb.c
  head/contrib/mdocml/manpath.h
  head/contrib/mdocml/mansearch.3
  head/contrib/mdocml/mansearch.c
  head/contrib/mdocml/mansearch.h
  head/contrib/mdocml/mansearch_const.c
  head/contrib/mdocml/mdoc.7
  head/contrib/mdocml/mdoc.h
  head/contrib/mdocml/mdoc_html.c
  head/contrib/mdocml/mdoc_macro.c
  head/contrib/mdocml/mdoc_man.c
  head/contrib/mdocml/mdoc_term.c
  head/contrib/mdocml/mdoc_validate.c
  head/contrib/mdocml/msec.c
  head/contrib/mdocml/out.c
  head/contrib/mdocml/out.h
  head/contrib/mdocml/read.c
  head/contrib/mdocml/roff.7
  head/contrib/mdocml/st.in
  head/contrib/mdocml/term.c
  head/contrib/mdocml/term.h
  head/contrib/mdocml/term_ps.c
  head/lib/libmandoc/Makefile
  head/usr.bin/mandoc/Makefile
Directory Properties:
  head/contrib/mdocml/   (props changed)

Modified: head/contrib/mdocml/INSTALL
==
--- head/contrib/mdocml/INSTALL Thu Dec 25 21:51:28 2014(r276218)
+++ head/contrib/mdocml/INSTALL Thu Dec 25 21:56:56 2014(r276219)
@@ -1,13 +1,12 @@
-$Id: INSTALL,v 1.5 2014/08/18 13:27:47 kristaps Exp $
+$Id: INSTALL,v 1.9 2014/12/11 07:44:46 schwarze Exp $
 
 About mdocml, the portable mandoc distribution
 --
 The mandoc manpage compiler toolset is a suite of tools compiling
 mdoc(7), the roff(7) macro language of choice for BSD manual pages,
 and man(7), the predominant historical language for UNIX manuals.
-The toolset does not yet implement man(1); that is only scheduled
-for the next release, 1.13.2.  It can, however, already serve to
-translate source manpages to the output displayed by man(1).
+Since the present version 1.13.2, it includes a man(1) manual viewer
+in addition to the apropos(1) manual page search tool.
 For general information, see .
 
 In this document, we describe the installation and deployment of
@@ -22,7 +21,7 @@ tech@ mailing list, too.
 
 Enjoy using the mandoc toolset!
 
-Ingo Schwarze, Karlsruhe, August 2014
+Ingo Schwarze, Karlsruhe, December 2014
 
 
 Installation
@@ -59,8 +58,8 @@ should work.  If the build fails, look a
 and go back to step 2.
 
 4. Run "make -n install" and check whether everything will be
-installed to the intended places.  Otherwise, put some *DIR variables
-into "configure.local" and go back to step�2.
+installed to the intended places.  Otherwise, put some *DIR or *NM*
+variables into "configure.local" and go back to step�2.
 
 5. Run "sudo make install".  If you intend to build a binary
 package using some kind of fake root mechanism, you may need a
@@ -70,14 +69,14 @@ in the "Makefile" to understand how DEST
 6. To set up a man.cgi(8) server, read its manual page.
 
 7. To use mandoc(1) as your man(1) formatter, read the "Deployment"
-section below.
+sections below.
 
 
 Understanding mandoc dependencies
 -
-The mandoc(1), preconv(1), and demandoc(1) utilities have no external
-dependencies.  However, makewhatis(8) and apropos(1) depend on the
-following software:
+The mandoc(1) and demandoc(1) utilities have no external dependencies.
+However, makewhatis(8), apropos(1), and man(1) depend on the following
+software:
 
 1. The SQLite database system, see .
 The recommended version of SQLite is 3.8.4.3 or newer.  The mandoc
@@ -89,14 +88,14 @@ fails due to the missing sqlite3_errstr(
 problems, apropos(1) is fully usable with SQLite 3.7.5.  Versions
 older than 3.7.5 may or may not work, they have not been tested.
 
-1.2. The fts(3) directory traversion functions.
+2. The fts(3) directory traversion functions.
 If your system does not have them, the bundled compatibility ver

svn commit: r276220 - head/usr.bin/man

2014-12-25 Thread Baptiste Daroussin
Author: bapt
Date: Thu Dec 25 22:04:16 2014
New Revision: 276220
URL: https://svnweb.freebsd.org/changeset/base/276220

Log:
  mandoc -Tlocale is now the default, no need to enforce it anymore

Modified:
  head/usr.bin/man/man.sh

Modified: head/usr.bin/man/man.sh
==
--- head/usr.bin/man/man.sh Thu Dec 25 21:56:56 2014(r276219)
+++ head/usr.bin/man/man.sh Thu Dec 25 22:04:16 2014(r276220)
@@ -312,7 +312,7 @@ man_display_page() {
fi
 
testline="mandoc -Tlint -Werror 2>/dev/null"
-   pipeline="mandoc -Tlocale | $MANPAGER"
+   pipeline="mandoc | $MANPAGER"
 
if ! eval "$cattool $manpage | $testline" ;then
if which -s groff; then
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276221 - head/sys/fs/nfsclient

2014-12-25 Thread Rick Macklem
Author: rmacklem
Date: Thu Dec 25 22:29:37 2014
New Revision: 276221
URL: https://svnweb.freebsd.org/changeset/base/276221

Log:
  Delete some duplicate code that was harmless because
  exactly the same code is at the end of the nfscl_checksattr()
  function that is called just before it. As such, this code
  had already been executed and didn't do anything.
  
  MFC after:1 week

Modified:
  head/sys/fs/nfsclient/nfs_clvnops.c

Modified: head/sys/fs/nfsclient/nfs_clvnops.c
==
--- head/sys/fs/nfsclient/nfs_clvnops.c Thu Dec 25 22:04:16 2014
(r276220)
+++ head/sys/fs/nfsclient/nfs_clvnops.c Thu Dec 25 22:29:37 2014
(r276221)
@@ -1606,20 +1606,6 @@ again:
}
} else if (NFS_ISV34(dvp) && (fmode & O_EXCL)) {
if (nfscl_checksattr(vap, &nfsva)) {
-   /*
-* We are normally called with only a partially
-* initialized VAP. Since the NFSv3 spec says that
-* the server may use the file attributes to
-* store the verifier, the spec requires us to do a
-* SETATTR RPC. FreeBSD servers store the verifier in
-* atime, but we can't really assume that all servers
-* will so we ensure that our SETATTR sets both atime
-* and mtime.
-*/
-   if (vap->va_mtime.tv_sec == VNOVAL)
-   vfs_timestamp(&vap->va_mtime);
-   if (vap->va_atime.tv_sec == VNOVAL)
-   vap->va_atime = vap->va_mtime;
error = nfsrpc_setattr(newvp, vap, NULL, cnp->cn_cred,
cnp->cn_thread, &nfsva, &attrflag, NULL);
if (error && (vap->va_uid != (uid_t)VNOVAL ||
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276224 - head/sys/modules/if_gif

2014-12-25 Thread Bjoern A. Zeeb
Author: bz
Date: Fri Dec 26 00:01:00 2014
New Revision: 276224
URL: https://svnweb.freebsd.org/changeset/base/276224

Log:
  Let's see if we can fix the NOINET if_gif(4) module build after r276215
  going by example.

Modified:
  head/sys/modules/if_gif/Makefile

Modified: head/sys/modules/if_gif/Makefile
==
--- head/sys/modules/if_gif/MakefileThu Dec 25 23:57:31 2014
(r276223)
+++ head/sys/modules/if_gif/MakefileFri Dec 26 00:01:00 2014
(r276224)
@@ -6,7 +6,11 @@ SYSDIR?=${.CURDIR}/../..
 .PATH: ${SYSDIR}/net ${SYSDIR}/netinet ${SYSDIR}/netinet6
 
 KMOD=  if_gif
-SRCS=  if_gif.c in_gif.c opt_inet.h opt_inet6.h
+SRCS=  if_gif.c opt_inet.h opt_inet6.h
+
+.if ${MK_INET_SUPPORT} != "no"
+SRCS+= in_gif.c
+.endif
 
 .if ${MK_INET6_SUPPORT} != "no"
 SRCS+= in6_gif.c
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276226 - head/cddl/contrib/opensolaris/cmd/zpool

2014-12-25 Thread Steven Hartland
Author: smh
Date: Fri Dec 26 01:12:02 2014
New Revision: 276226
URL: https://svnweb.freebsd.org/changeset/base/276226

Log:
  Enhancements to zpool upgrade processing
  
  Introduce a seperate phase to list all unavailable pools when listing
  pools to upgrade. This avoids confusing output when displaying older
  and disabled feature pools. These existing phases now silently skip
  unavailable pools.
  
  Introduce cb_unavail to upgrade_cbdata_t which enables the final
  output for zpool list to correctly detail if all pools or only all
  available pools where up-to-date on version / features.
  
  Correct the type of upgrade_cbdata_t.cb_first from int -> boolean_t.
  
  Change the pool iteration when upgrading named pools to include
  unavailable pools and update upgrade_one so it doesn't try to upgrade
  unavailable pools but warns about them. This allows the correct error
  to be displayed as well as upgrades with available and unavailable
  pools intermixed to partially complete.
  
  Also correct some missing trailing \n's from output in upgrade_one.
  
  MFC after:1 month
  X-MFC-With:   r276194

Modified:
  head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.c

Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.c
==
--- head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.cFri Dec 26 
00:10:08 2014(r276225)
+++ head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.cFri Dec 26 
01:12:02 2014(r276226)
@@ -4509,11 +4509,12 @@ zpool_do_status(int argc, char **argv)
 }
 
 typedef struct upgrade_cbdata {
-   int cb_first;
-   charcb_poolname[ZPOOL_MAXNAMELEN];
-   int cb_argc;
-   uint64_t cb_version;
-   char**cb_argv;
+   boolean_t   cb_first;
+   boolean_t   cb_unavail;
+   charcb_poolname[ZPOOL_MAXNAMELEN];
+   int cb_argc;
+   uint64_tcb_version;
+   char**cb_argv;
 } upgrade_cbdata_t;
 
 #ifdef __FreeBSD__
@@ -4631,7 +4632,8 @@ upgrade_cb(zpool_handle_t *zhp, void *ar
 
if (zpool_get_state(zhp) == POOL_STATE_UNAVAIL) {
(void) fprintf(stderr, gettext("cannot upgrade '%s': pool is "
-   "currently unavailable\n\n"), zpool_get_name(zhp));
+   "currently unavailable.\n\n"), zpool_get_name(zhp));
+   cbp->cb_unavail = B_TRUE;
/* Allow iteration to continue. */
return (0);
}
@@ -4697,12 +4699,41 @@ upgrade_cb(zpool_handle_t *zhp, void *ar
 }
 
 static int
+upgrade_list_unavail(zpool_handle_t *zhp, void *arg)
+{
+   upgrade_cbdata_t *cbp = arg;
+
+   if (zpool_get_state(zhp) == POOL_STATE_UNAVAIL) {
+   if (cbp->cb_first) {
+   (void) fprintf(stderr, gettext("The following pools "
+   "are unavailable and cannot be upgraded as this "
+   "time.\n\n"));
+   (void) fprintf(stderr, gettext("POOL\n"));
+   (void) fprintf(stderr, gettext("\n"));
+   cbp->cb_first = B_FALSE;
+   }
+   (void) printf(gettext("%s\n"), zpool_get_name(zhp));
+   cbp->cb_unavail = B_TRUE;
+   }
+   return (0);
+}
+
+static int
 upgrade_list_older_cb(zpool_handle_t *zhp, void *arg)
 {
upgrade_cbdata_t *cbp = arg;
nvlist_t *config;
uint64_t version;
 
+   if (zpool_get_state(zhp) == POOL_STATE_UNAVAIL) {
+   /*
+* This will have been reported by upgrade_list_unavail so
+* just allow iteration to continue.
+*/
+   cbp->cb_unavail = B_TRUE;
+   return (0);
+   }
+
config = zpool_get_config(zhp, NULL);
verify(nvlist_lookup_uint64(config, ZPOOL_CONFIG_VERSION,
&version) == 0);
@@ -4737,10 +4768,11 @@ upgrade_list_disabled_cb(zpool_handle_t 
uint64_t version;
 
if (zpool_get_state(zhp) == POOL_STATE_UNAVAIL) {
-   (void) fprintf(stderr, gettext("cannot check supported "
-   "features on '%s': pool is currently unavailable\n\n"),
-   zpool_get_name(zhp));
-   /* Allow iteration to continue. */
+   /*
+* This will have been reported by upgrade_list_unavail so
+* just allow iteration to continue.
+*/
+   cbp->cb_unavail = B_TRUE;
return (0);
}
 
@@ -4797,10 +4829,17 @@ upgrade_one(zpool_handle_t *zhp, void *d
uint64_t cur_version;
int ret;
 
+   if (zpool_get_state(zhp) == POOL_STATE_UNAVAIL) {
+   (void) fprintf(stderr, gettext("cannot upgrade '%s': pool is "
+   "is currently unavailable.\n\n"), zpool_get_name(zhp));
+   cbp->cb_unavail = B_TRUE;
+

svn commit: r276227 - in head/share/man: man4 man9

2014-12-25 Thread Kevin Lo
Author: kevlo
Date: Fri Dec 26 01:48:44 2014
New Revision: 276227
URL: https://svnweb.freebsd.org/changeset/base/276227

Log:
  Mention cc_cdg.

Modified:
  head/share/man/man4/mod_cc.4
  head/share/man/man9/mod_cc.9

Modified: head/share/man/man4/mod_cc.4
==
--- head/share/man/man4/mod_cc.4Fri Dec 26 01:12:02 2014
(r276226)
+++ head/share/man/man4/mod_cc.4Fri Dec 26 01:48:44 2014
(r276227)
@@ -30,7 +30,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd September 15, 2011
+.Dd December 26, 2014
 .Dt MOD_CC 4
 .Os
 .Sh NAME
@@ -75,6 +75,7 @@ one of the names listed by the
 MIB variable.
 .El
 .Sh SEE ALSO
+.Xr cc_cdg 4 ,
 .Xr cc_chd 4 ,
 .Xr cc_cubic 4 ,
 .Xr cc_hd 4 ,

Modified: head/share/man/man9/mod_cc.9
==
--- head/share/man/man9/mod_cc.9Fri Dec 26 01:12:02 2014
(r276226)
+++ head/share/man/man9/mod_cc.9Fri Dec 26 01:48:44 2014
(r276227)
@@ -31,7 +31,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd December 25, 2014
+.Dd December 26, 2014
 .Dt MOD_CC 9
 .Os
 .Sh NAME
@@ -290,6 +290,7 @@ by the value of the congestion window.
 Algorithms should use the absence of this flag being set to avoid accumulating
 a large difference between the congestion window and send window.
 .Sh SEE ALSO
+.Xr cc_cdg 4 ,
 .Xr cc_chd 4 ,
 .Xr cc_cubic 4 ,
 .Xr cc_hd 4 ,
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276228 - head/contrib/binutils/gas

2014-12-25 Thread Pedro F. Giffuni
Author: pfg
Date: Fri Dec 26 03:03:41 2014
New Revision: 276228
URL: https://svnweb.freebsd.org/changeset/base/276228

Log:
  gas: use memmove instead of bogus memcpy.
  
  partial_where points into the buffer that begins with buffer_start
  so we need to use memmove() to handle the overlap.
  Sourceware-PR 11456.
  
  Obtained from:OpenBSD (CVS rev. 1.2)
  MFC after:3 days

Modified:
  head/contrib/binutils/gas/input-scrub.c

Modified: head/contrib/binutils/gas/input-scrub.c
==
--- head/contrib/binutils/gas/input-scrub.c Fri Dec 26 01:48:44 2014
(r276227)
+++ head/contrib/binutils/gas/input-scrub.c Fri Dec 26 03:03:41 2014
(r276228)
@@ -335,7 +335,7 @@ input_scrub_next_buffer (char **bufp)
 
   if (partial_size)
 {
-  memcpy (buffer_start + BEFORE_SIZE, partial_where,
+  memmove (buffer_start + BEFORE_SIZE, partial_where,
  (unsigned int) partial_size);
   memcpy (buffer_start + BEFORE_SIZE, save_source, AFTER_SIZE);
 }
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276229 - head/contrib/binutils/gas

2014-12-25 Thread Pedro F. Giffuni
Author: pfg
Date: Fri Dec 26 04:33:53 2014
New Revision: 276229
URL: https://svnweb.freebsd.org/changeset/base/276229

Log:
  Backport fix for binutils 11867: .quad directive not assembled correctly
  
  Alan Modra (and Alan's employer) graciously permitted use of his patch
  under GPLv2.
  
  Obtained from:OpenBSD
  MFC after:5 days

Modified:
  head/contrib/binutils/gas/expr.c
  head/contrib/binutils/gas/read.c

Modified: head/contrib/binutils/gas/expr.c
==
--- head/contrib/binutils/gas/expr.cFri Dec 26 03:03:41 2014
(r276228)
+++ head/contrib/binutils/gas/expr.cFri Dec 26 04:33:53 2014
(r276229)
@@ -1040,6 +1040,15 @@ operand (expressionS *expressionP, enum 
  {
for (i = 0; i < expressionP->X_add_number; ++i)
  generic_bignum[i] = ~generic_bignum[i];
+
+   /* Extend the bignum to at least the size of .octa.  */
+   if (expressionP->X_add_number < SIZE_OF_LARGE_NUMBER)
+ {
+   expressionP->X_add_number = SIZE_OF_LARGE_NUMBER;
+   for (; i < expressionP->X_add_number; ++i)
+ generic_bignum[i] = ~(LITTLENUM_TYPE) 0;
+ }
+
if (c == '-')
  for (i = 0; i < expressionP->X_add_number; ++i)
{
@@ -1050,14 +1059,12 @@ operand (expressionS *expressionP, enum 
  }
else if (c == '!')
  {
-   int nonzero = 0;
for (i = 0; i < expressionP->X_add_number; ++i)
- {
-   if (generic_bignum[i])
- nonzero = 1;
-   generic_bignum[i] = 0;
- }
-   generic_bignum[0] = nonzero;
+ if (generic_bignum[i] != 0)
+   break;
+   expressionP->X_add_number = i >= expressionP->X_add_number;
+   expressionP->X_op = O_constant;
+   expressionP->X_unsigned = 1;
  }
  }
else if (expressionP->X_op != O_illegal

Modified: head/contrib/binutils/gas/read.c
==
--- head/contrib/binutils/gas/read.cFri Dec 26 03:03:41 2014
(r276228)
+++ head/contrib/binutils/gas/read.cFri Dec 26 04:33:53 2014
(r276229)
@@ -4117,15 +4117,32 @@ emit_expr (expressionS *exp, unsigned in
   unsigned int size;
   LITTLENUM_TYPE *nums;
 
-  know (nbytes % CHARS_PER_LITTLENUM == 0);
-
   size = exp->X_add_number * CHARS_PER_LITTLENUM;
   if (nbytes < size)
{
- as_warn (_("bignum truncated to %d bytes"), nbytes);
+ int i = nbytes / CHARS_PER_LITTLENUM;
+ if (i != 0)
+   {
+ LITTLENUM_TYPE sign = 0;
+ if ((generic_bignum[--i]
+  & (1 << (LITTLENUM_NUMBER_OF_BITS - 1))) != 0)
+   sign = ~(LITTLENUM_TYPE) 0;
+ while (++i < exp->X_add_number)
+   if (generic_bignum[i] != sign)
+ break;
+   }
+ if (i < exp->X_add_number)
+   as_warn (_("bignum truncated to %d bytes"), nbytes);
  size = nbytes;
}
 
+  if (nbytes == 1)
+   {
+ md_number_to_chars (p, (valueT) generic_bignum[0], 1);
+ return;
+   }
+  know (nbytes % CHARS_PER_LITTLENUM == 0);
+
   if (target_big_endian)
{
  while (nbytes > size)
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276230 - head/contrib/ee

2014-12-25 Thread Baptiste Daroussin
Author: bapt
Date: Fri Dec 26 07:34:42 2014
New Revision: 276230
URL: https://svnweb.freebsd.org/changeset/base/276230

Log:
  Fix .TH having too many arguments

Modified:
  head/contrib/ee/ee.1

Modified: head/contrib/ee/ee.1
==
--- head/contrib/ee/ee.1Fri Dec 26 04:33:53 2014(r276229)
+++ head/contrib/ee/ee.1Fri Dec 26 07:34:42 2014(r276230)
@@ -7,7 +7,7 @@
 .\"  $Header: /home/hugh/sources/old_ae/RCS/ee.1,v 1.22 2001/12/16 04:49:27 
hugh Exp $
 .\"
 .\"
-.TH ee 1 "" "" "" ""
+.TH ee 1 "" "" ""
 .SH NAME
 ee \- easy editor
 .SH SYNOPSIS
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"


svn commit: r276231 - head/contrib/bzip2

2014-12-25 Thread Baptiste Daroussin
Author: bapt
Date: Fri Dec 26 07:36:42 2014
New Revision: 276231
URL: https://svnweb.freebsd.org/changeset/base/276231

Log:
  Remove unknown macro

Modified:
  head/contrib/bzip2/bzip2.1

Modified: head/contrib/bzip2/bzip2.1
==
--- head/contrib/bzip2/bzip2.1  Fri Dec 26 07:34:42 2014(r276230)
+++ head/contrib/bzip2/bzip2.1  Fri Dec 26 07:36:42 2014(r276231)
@@ -1,4 +1,3 @@
-.PU
 .TH bzip2 1
 .SH NAME
 bzip2, bunzip2 \- a block-sorting file compressor, v1.0.6
___
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"