svn commit: r305864 - head/sys/ddb

2016-09-15 Thread Bruce Evans
Author: bde
Date: Fri Sep 16 06:31:10 2016
New Revision: 305864
URL: https://svnweb.freebsd.org/changeset/base/305864

Log:
  Statically initialize the run mode to the one that will become
  current on first entry.  This fixes a spurious "Stepping aborted"
  message when the first entry is for a breakpoint.
  
  Don't reset to the run mode to STEP_NONE when stopping, and remove
  STEP_NONE.  This mode was never really used, except transiently to
  mis-decide whether to print the message on first entry.

Modified:
  head/sys/ddb/db_run.c

Modified: head/sys/ddb/db_run.c
==
--- head/sys/ddb/db_run.c   Fri Sep 16 05:33:08 2016(r305863)
+++ head/sys/ddb/db_run.c   Fri Sep 16 06:31:10 2016(r305864)
@@ -48,14 +48,13 @@ __FBSDID("$FreeBSD$");
 #include 
 #include 
 
-static int db_run_mode;
-#defineSTEP_NONE   0
 #defineSTEP_ONCE   1
 #defineSTEP_RETURN 2
 #defineSTEP_CALLT  3
 #defineSTEP_CONTINUE   4
 #defineSTEP_INVISIBLE  5
 #defineSTEP_COUNT  6
+static int db_run_mode = STEP_CONTINUE;
 
 static booldb_sstep_multiple;
 static booldb_sstep_print;
@@ -150,7 +149,6 @@ db_stop_at_pc(int type, int code, bool *
 #endif
if (db_run_mode != STEP_CONTINUE && !IS_SSTEP_TRAP(type, code)) {
printf("Stepping aborted\n");
-   db_run_mode = STEP_NONE;
return (true);
}
 
@@ -203,7 +201,6 @@ db_stop_at_pc(int type, int code, bool *
return (false); /* continue */
}
}
-   db_run_mode = STEP_NONE;
return (true);
 }
 
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305863 - head/sbin/natd

2016-09-15 Thread Marcelo Araujo
Author: araujo
Date: Fri Sep 16 05:33:08 2016
New Revision: 305863
URL: https://svnweb.freebsd.org/changeset/base/305863

Log:
  Invert calloc(3) argument order.
  
  Reviewed by:  ed.
  MFC after:4 weeks.
  Differential Revision:https://reviews.freebsd.org/D7902

Modified:
  head/sbin/natd/natd.c

Modified: head/sbin/natd/natd.c
==
--- head/sbin/natd/natd.c   Fri Sep 16 04:58:37 2016(r305862)
+++ head/sbin/natd/natd.c   Fri Sep 16 05:33:08 2016(r305863)
@@ -2006,7 +2006,7 @@ NewInstance(const char *name)
}
}
ninstance++;
-   ip = calloc(sizeof *ip, 1);
+   ip = calloc(1, sizeof(*ip));
ip->name = strdup(name);
ip->la = LibAliasInit (ip->la);
ip->assignAliasAddr = 0;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305862 - in head/sys: amd64/amd64 i386/i386

2016-09-15 Thread Bruce Evans
Author: bde
Date: Fri Sep 16 04:58:37 2016
New Revision: 305862
URL: https://svnweb.freebsd.org/changeset/base/305862

Log:
  (1) Ifdef the new dr6 variable for KDB.
  
  While here, avoid using the old variable 'code' and remove it
  in trap().  ('code' was meant for holding things like %dr6,
  but is too small to hold %dr6 on amd64 and was reduced to an
  obfuscation of tf_err, with early truncation on amd64.)
  
  Submitted by: Michael Butler (imb@...)

Modified:
  head/sys/amd64/amd64/trap.c
  head/sys/i386/i386/trap.c

Modified: head/sys/amd64/amd64/trap.c
==
--- head/sys/amd64/amd64/trap.c Fri Sep 16 04:28:31 2016(r305861)
+++ head/sys/amd64/amd64/trap.c Fri Sep 16 04:58:37 2016(r305862)
@@ -176,8 +176,10 @@ trap(struct trapframe *frame)
 #endif
struct thread *td = curthread;
struct proc *p = td->td_proc;
+#ifdef KDB
register_t dr6;
-   int i = 0, ucode = 0, code;
+#endif
+   int i = 0, ucode = 0;
u_int type;
register_t addr = 0;
ksiginfo_t ksi;
@@ -259,8 +261,6 @@ trap(struct trapframe *frame)
}
}
 
-   code = frame->tf_err;
-
if (TRAPF_USERMODE(frame)) {
/* user trap */
 
@@ -378,7 +378,7 @@ trap(struct trapframe *frame)
 #ifdef DEV_ISA
case T_NMI:
/* machine/parity/power fail/"kitchen sink" faults */
-   if (isa_nmi(code) == 0) {
+   if (isa_nmi(frame->tf_err) == 0) {
 #ifdef KDB
/*
 * NMI can be hooked up to a pushbutton
@@ -564,7 +564,7 @@ trap(struct trapframe *frame)
 #ifdef DEV_ISA
case T_NMI:
/* machine/parity/power fail/"kitchen sink" faults */
-   if (isa_nmi(code) == 0) {
+   if (isa_nmi(frame->tf_err) == 0) {
 #ifdef KDB
/*
 * NMI can be hooked up to a pushbutton

Modified: head/sys/i386/i386/trap.c
==
--- head/sys/i386/i386/trap.c   Fri Sep 16 04:28:31 2016(r305861)
+++ head/sys/i386/i386/trap.c   Fri Sep 16 04:58:37 2016(r305862)
@@ -189,8 +189,10 @@ trap(struct trapframe *frame)
 #endif
struct thread *td = curthread;
struct proc *p = td->td_proc;
+#ifdef KDB
register_t dr6;
-   int i = 0, ucode = 0, code;
+#endif
+   int i = 0, ucode = 0;
u_int type;
register_t addr = 0;
vm_offset_t eva;
@@ -293,7 +295,6 @@ trap(struct trapframe *frame)
}
}
eva = 0;
-   code = frame->tf_err;
if (type == T_PAGEFLT) {
/*
 * For some Cyrix CPUs, %cr2 is clobbered by
@@ -467,7 +468,7 @@ user_trctrap_out:
goto userout;
 #else /* !POWERFAIL_NMI */
/* machine/parity/power fail/"kitchen sink" faults */
-   if (isa_nmi(code) == 0) {
+   if (isa_nmi(frame->tf_err) == 0) {
 #ifdef KDB
/*
 * NMI can be hooked up to a pushbutton
@@ -730,7 +731,7 @@ kernel_trctrap:
goto out;
 #else /* !POWERFAIL_NMI */
/* machine/parity/power fail/"kitchen sink" faults */
-   if (isa_nmi(code) == 0) {
+   if (isa_nmi(frame->tf_err) == 0) {
 #ifdef KDB
/*
 * NMI can be hooked up to a pushbutton
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r305860 - head/sbin/ifconfig

2016-09-15 Thread Marcelo Araujo
Ooops!

Forgot to add the review link:
https://reviews.freebsd.org/D7615

Best,

2016-09-16 12:22 GMT+08:00 Marcelo Araujo :

> Author: araujo
> Date: Fri Sep 16 04:22:21 2016
> New Revision: 305860
> URL: https://svnweb.freebsd.org/changeset/base/305860
>
> Log:
>   Add an option called "random" that combined with "ether" can generate a
>   random MAC address for an Ethernet interface.
>
>   PR:   211984
>   Submitted by: pi@
>   Reviewed by:  gnn, cem, jhb, lidl, rpokala, wblock
>   Approved by:  wblock (manpages)
>
> Modified:
>   head/sbin/ifconfig/af_link.c
>   head/sbin/ifconfig/ifconfig.8
>
> Modified: head/sbin/ifconfig/af_link.c
> 
> ==
> --- head/sbin/ifconfig/af_link.cFri Sep 16 04:12:32 2016
> (r305859)
> +++ head/sbin/ifconfig/af_link.cFri Sep 16 04:22:21 2016
> (r305860)
> @@ -90,13 +90,23 @@ link_getaddr(const char *addr, int which
>
> if (which != ADDR)
> errx(1, "can't set link-level netmask or broadcast");
> -   if ((temp = malloc(strlen(addr) + 2)) == NULL)
> -   errx(1, "malloc failed");
> -   temp[0] = ':';
> -   strcpy(temp + 1, addr);
> -   sdl.sdl_len = sizeof(sdl);
> -   link_addr(temp, &sdl);
> -   free(temp);
> +   if (!strcmp(addr, "random")) {
> +   sdl.sdl_len = sizeof(sdl);
> +   sdl.sdl_alen = ETHER_ADDR_LEN;
> +   sdl.sdl_nlen = 0;
> +   sdl.sdl_family = AF_LINK;
> +   arc4random_buf(&sdl.sdl_data, ETHER_ADDR_LEN);
> +   /* Non-multicast and claim it is a hardware address */
> +   sdl.sdl_data[0] &= 0xfc;
> +   } else {
> +   if ((temp = malloc(strlen(addr) + 2)) == NULL)
> +   errx(1, "malloc failed");
> +   temp[0] = ':';
> +   strcpy(temp + 1, addr);
> +   sdl.sdl_len = sizeof(sdl);
> +   link_addr(temp, &sdl);
> +   free(temp);
> +   }
> if (sdl.sdl_alen > sizeof(sa->sa_data))
> errx(1, "malformed link-level address");
> sa->sa_family = AF_LINK;
>
> Modified: head/sbin/ifconfig/ifconfig.8
> 
> ==
> --- head/sbin/ifconfig/ifconfig.8   Fri Sep 16 04:12:32 2016
> (r305859)
> +++ head/sbin/ifconfig/ifconfig.8   Fri Sep 16 04:22:21 2016
> (r305860)
> @@ -28,7 +28,7 @@
>  .\" From: @(#)ifconfig.8   8.3 (Berkeley) 1/5/94
>  .\" $FreeBSD$
>  .\"
> -.Dd June 8, 2016
> +.Dd September 17, 2016
>  .Dt IFCONFIG 8
>  .Os
>  .Sh NAME
> @@ -145,6 +145,12 @@ is specified as a series of colon-separa
>  This can be used to, for example,
>  set a new MAC address on an Ethernet interface, though the
>  mechanism used is not Ethernet specific.
> +Use the
> +.Pq Dq random
> +keyword to set a randomly generated MAC address.
> +A randomly-generated MAC address might be the same as one already in use
> +in the network.
> +Such duplications are extremely unlikely.
>  If the interface is already
>  up when this option is used, it will be briefly brought down and
>  then brought back up again in order to ensure that the receive
> @@ -254,7 +260,7 @@ Display subnet masks in dotted quad nota
>  .br
>  255.255.0.0 or 255.255.255.192
>  .It Sy hex
> -Display subnet masks in hexidecimal, for example:
> +Display subnet masks in hexadecimal, for example:
>  .br
>  0x or 0xffc0
>  .El
> @@ -2615,13 +2621,13 @@ and
>  .Cm vlandev
>  must both be set at the same time.
>  .It Cm vlanpcp Ar priority_code_point
> -Priority code point
> +Priority code point
>  .Pq Dv PCP
>  is an 3-bit field which refers to the IEEE 802.1p
>  class of service and maps to the frame priority level.
>  .Pp
>  Values in order of priority are:
> -.Cm 1
> +.Cm 1
>  .Pq Dv Background (lowest) ,
>  .Cm 0
>  .Pq Dv Best effort (default) ,
> @@ -2759,7 +2765,7 @@ interface to send the frame directly to
>  broadcasting the frame to the multicast group.
>  This is the default.
>  .It Fl vxlanlearn
> -The forwarding table is not populated by recevied packets.
> +The forwarding table is not populated by received packets.
>  .It Cm vxlanflush
>  Delete all dynamically-learned addresses from the forwarding table.
>  .It Cm vxlanflushall
> ___
> svn-src-h...@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/svn-src-head
> To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
>



-- 

-- 
Marcelo Araujo(__)ara...@freebsd.org
\\\'',)http://www.FreeBSD.org    \/  \ ^
Power To Server. .\. /_)
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305861 - in head/sbin: geom/class/multipath ggate/ggatec ggate/ggated ggate/ggatel hastctl hastd iscontrol mdmfs mount_nfs nandfs nvmecontrol

2016-09-15 Thread Allan Jude
Author: allanjude
Date: Fri Sep 16 04:28:31 2016
New Revision: 305861
URL: https://svnweb.freebsd.org/changeset/base/305861

Log:
  Add missing history sections to a number of storage related man pages
  
  gmultipath.8: Add HISTORY
Adjust sentences with bad phrases picked up by igor
  
  ggatec.8: Add HISTORY
  
  ggated.8: Add HISTORY
  
  ggatel.8: Add HISTORY
Seperate out sentence as advised by igor.
  
  hastctl.8: Add HISTORY
  
  hastd.8: Add HISTORY
Fix sentence highlighted by igor.
  
  iscontrol.8: Add HISTORY
  
  mdmfs.8: Add HISTORY
Address issues raised by igor
  
  mount_nfs.8: Add HISTORY
Not sure where mount_nfs first showed up, but the verison used
in the BSD's originates from 4.4BSD according to CSRG archive.
  
Though commercial offerings from Sun and others covers older
systems, eg 
https://groups.google.com/forum/#!topic/net.unix-wizards/lMe7aQikqJI
  
  nandfs.8: Add HISTORY
Adjust sentence in description to address bad phrase highlighted
by igor.
  
  nvmecontrol.8: Add HISTORY
  
  PR:   212491
  PR:   212498
  PR:   212499
  PR:   212500
  PR:   212501
  PR:   212502
  PR:   212505
  PR:   212508
  PR:   212540
  PR:   212543
  PR:   212546
  Submitted by: Sevan Janiyan 

Modified:
  head/sbin/geom/class/multipath/gmultipath.8
  head/sbin/ggate/ggatec/ggatec.8
  head/sbin/ggate/ggated/ggated.8
  head/sbin/ggate/ggatel/ggatel.8
  head/sbin/hastctl/hastctl.8
  head/sbin/hastd/hastd.8
  head/sbin/iscontrol/iscontrol.8
  head/sbin/mdmfs/mdmfs.8
  head/sbin/mount_nfs/mount_nfs.8
  head/sbin/nandfs/nandfs.8
  head/sbin/nvmecontrol/nvmecontrol.8

Modified: head/sbin/geom/class/multipath/gmultipath.8
==
--- head/sbin/geom/class/multipath/gmultipath.8 Fri Sep 16 04:22:21 2016
(r305860)
+++ head/sbin/geom/class/multipath/gmultipath.8 Fri Sep 16 04:28:31 2016
(r305861)
@@ -24,7 +24,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd July 18, 2015
+.Dd September 8, 2016
 .Dt GMULTIPATH 8
 .Os
 .Sh NAME
@@ -255,12 +255,11 @@ When this occurs, that path is marked FA
 in a list is selected as active and the failed I/O reissued.
 In Active/Active mode all paths not marked FAIL may handle I/O at the same 
time.
 Requests are distributed between paths to equalize load.
-For capable devices it allows to utilize the bandwidth of all paths.
+For capable devices it allows the utilisation of the bandwidth available on 
all paths.
 In Active/Read mode all paths not marked FAIL may handle reads at the same 
time,
 but unlike in Active/Active mode only one path handles write requests at any
-point in time.
-It allows to closer follow the original write request order if the layer above
-needs it for data consistency (not waiting for requisite write completion
+point in time; closely following the original write request order if the layer
+above needs it for data consistency (not waiting for requisite write completion
 before sending dependent write).
 .Pp
 When new devices are added to the system the
@@ -368,6 +367,11 @@ geom_multipath_load="YES"
 .Xr mount 8 ,
 .Xr newfs 8 ,
 .Xr sysctl 8
+.Sh HISTORY
+The
+.Nm
+utility first appeared in
+.Fx 7.0
 .Sh AUTHORS
 .An Matthew Jacob Aq Mt mja...@freebsd.org
 .An Alexander Motin Aq Mt m...@freebsd.org

Modified: head/sbin/ggate/ggatec/ggatec.8
==
--- head/sbin/ggate/ggatec/ggatec.8 Fri Sep 16 04:22:21 2016
(r305860)
+++ head/sbin/ggate/ggatec/ggatec.8 Fri Sep 16 04:28:31 2016
(r305861)
@@ -24,7 +24,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd August 25, 2016
+.Dd September 8, 2016
 .Dt GGATEC 8
 .Os
 .Sh NAME
@@ -173,6 +173,11 @@ client# mount_cd9660 /dev/ggate0 /cdrom
 .Xr ggated 8 ,
 .Xr ggatel 8 ,
 .Xr mount_cd9660 8
+.Sh HISTORY
+The
+.Nm
+utility appeared in
+.Fx 5.3 .
 .Sh AUTHORS
 The
 .Nm

Modified: head/sbin/ggate/ggated/ggated.8
==
--- head/sbin/ggate/ggated/ggated.8 Fri Sep 16 04:22:21 2016
(r305860)
+++ head/sbin/ggate/ggated/ggated.8 Fri Sep 16 04:28:31 2016
(r305861)
@@ -24,7 +24,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd August 25, 2016
+.Dd September 8, 2016
 .Dt GGATED 8
 .Os
 .Sh NAME
@@ -116,6 +116,11 @@ Export CD-ROM device and a file:
 .Xr geom 4 ,
 .Xr ggatec 8 ,
 .Xr ggatel 8
+.Sh HISTORY
+The
+.Nm
+utility appeared in
+.Fx 5.3 .
 .Sh AUTHORS
 The
 .Nm

Modified: head/sbin/ggate/ggatel/ggatel.8
==
--- head/sbin/ggate/ggatel/ggatel.8 Fri Sep 16 04:22:21 2016
(r305860)
+++ head/sbin/ggate/ggatel/ggatel.8 Fri Sep 16 04:28:31 2016
(r305861)
@@ -24,7 +24,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd July 14, 2015
+.Dd September 8, 2016
 .Dt

svn commit: r305860 - head/sbin/ifconfig

2016-09-15 Thread Marcelo Araujo
Author: araujo
Date: Fri Sep 16 04:22:21 2016
New Revision: 305860
URL: https://svnweb.freebsd.org/changeset/base/305860

Log:
  Add an option called "random" that combined with "ether" can generate a
  random MAC address for an Ethernet interface.
  
  PR:   211984
  Submitted by: pi@
  Reviewed by:  gnn, cem, jhb, lidl, rpokala, wblock
  Approved by:  wblock (manpages)

Modified:
  head/sbin/ifconfig/af_link.c
  head/sbin/ifconfig/ifconfig.8

Modified: head/sbin/ifconfig/af_link.c
==
--- head/sbin/ifconfig/af_link.cFri Sep 16 04:12:32 2016
(r305859)
+++ head/sbin/ifconfig/af_link.cFri Sep 16 04:22:21 2016
(r305860)
@@ -90,13 +90,23 @@ link_getaddr(const char *addr, int which
 
if (which != ADDR)
errx(1, "can't set link-level netmask or broadcast");
-   if ((temp = malloc(strlen(addr) + 2)) == NULL)
-   errx(1, "malloc failed");
-   temp[0] = ':';
-   strcpy(temp + 1, addr);
-   sdl.sdl_len = sizeof(sdl);
-   link_addr(temp, &sdl);
-   free(temp);
+   if (!strcmp(addr, "random")) {
+   sdl.sdl_len = sizeof(sdl);
+   sdl.sdl_alen = ETHER_ADDR_LEN;
+   sdl.sdl_nlen = 0;
+   sdl.sdl_family = AF_LINK;
+   arc4random_buf(&sdl.sdl_data, ETHER_ADDR_LEN);
+   /* Non-multicast and claim it is a hardware address */
+   sdl.sdl_data[0] &= 0xfc;
+   } else {
+   if ((temp = malloc(strlen(addr) + 2)) == NULL)
+   errx(1, "malloc failed");
+   temp[0] = ':';
+   strcpy(temp + 1, addr);
+   sdl.sdl_len = sizeof(sdl);
+   link_addr(temp, &sdl);
+   free(temp);
+   }
if (sdl.sdl_alen > sizeof(sa->sa_data))
errx(1, "malformed link-level address");
sa->sa_family = AF_LINK;

Modified: head/sbin/ifconfig/ifconfig.8
==
--- head/sbin/ifconfig/ifconfig.8   Fri Sep 16 04:12:32 2016
(r305859)
+++ head/sbin/ifconfig/ifconfig.8   Fri Sep 16 04:22:21 2016
(r305860)
@@ -28,7 +28,7 @@
 .\" From: @(#)ifconfig.8   8.3 (Berkeley) 1/5/94
 .\" $FreeBSD$
 .\"
-.Dd June 8, 2016
+.Dd September 17, 2016
 .Dt IFCONFIG 8
 .Os
 .Sh NAME
@@ -145,6 +145,12 @@ is specified as a series of colon-separa
 This can be used to, for example,
 set a new MAC address on an Ethernet interface, though the
 mechanism used is not Ethernet specific.
+Use the
+.Pq Dq random
+keyword to set a randomly generated MAC address.
+A randomly-generated MAC address might be the same as one already in use
+in the network.
+Such duplications are extremely unlikely.
 If the interface is already
 up when this option is used, it will be briefly brought down and
 then brought back up again in order to ensure that the receive
@@ -254,7 +260,7 @@ Display subnet masks in dotted quad nota
 .br
 255.255.0.0 or 255.255.255.192
 .It Sy hex
-Display subnet masks in hexidecimal, for example:
+Display subnet masks in hexadecimal, for example:
 .br
 0x or 0xffc0
 .El
@@ -2615,13 +2621,13 @@ and
 .Cm vlandev
 must both be set at the same time.
 .It Cm vlanpcp Ar priority_code_point
-Priority code point 
+Priority code point
 .Pq Dv PCP
 is an 3-bit field which refers to the IEEE 802.1p
 class of service and maps to the frame priority level.
 .Pp
 Values in order of priority are:
-.Cm 1 
+.Cm 1
 .Pq Dv Background (lowest) ,
 .Cm 0
 .Pq Dv Best effort (default) ,
@@ -2759,7 +2765,7 @@ interface to send the frame directly to 
 broadcasting the frame to the multicast group.
 This is the default.
 .It Fl vxlanlearn
-The forwarding table is not populated by recevied packets.
+The forwarding table is not populated by received packets.
 .It Cm vxlanflush
 Delete all dynamically-learned addresses from the forwarding table.
 .It Cm vxlanflushall
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305859 - head/sbin/umount

2016-09-15 Thread Allan Jude
Author: allanjude
Date: Fri Sep 16 04:12:32 2016
New Revision: 305859
URL: https://svnweb.freebsd.org/changeset/base/305859

Log:
  sbin/umount/umount.8: Amend HISTORY
  
  umount first appeared in V1, confirmed using TUHS archive
  http://minnie.tuhs.org/cgi-bin/utree.pl?file=V1/man/man1/umount.1
  
  PR:   212554
  Submitted by: Sevan Janiyan 

Modified:
  head/sbin/umount/umount.8

Modified: head/sbin/umount/umount.8
==
--- head/sbin/umount/umount.8   Fri Sep 16 04:11:04 2016(r305858)
+++ head/sbin/umount/umount.8   Fri Sep 16 04:12:32 2016(r305859)
@@ -28,7 +28,7 @@
 .\" @(#)umount.8   8.2 (Berkeley) 5/8/95
 .\" $FreeBSD$
 .\"
-.Dd July 7, 2016
+.Dd September 10, 2016
 .Dt UMOUNT 8
 .Os
 .Sh NAME
@@ -158,4 +158,4 @@ file system table
 A
 .Nm
 utility appeared in
-.At v6 .
+.At v1 .
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305858 - head/sbin/reboot

2016-09-15 Thread Allan Jude
Author: allanjude
Date: Fri Sep 16 04:11:04 2016
New Revision: 305858
URL: https://svnweb.freebsd.org/changeset/base/305858

Log:
  sbin/reboot/reboot.8: Amend HISTORY
  
  A standalone reboot utility showed up in 4.0BSD, in AT&T UNIX init has a
  case for reboot and is present in the version shipped with V5
  
  either way, current entry is incorrect.
  
  PR:   212548
  Submitted by: Sevan Janiyan 

Modified:
  head/sbin/reboot/reboot.8

Modified: head/sbin/reboot/reboot.8
==
--- head/sbin/reboot/reboot.8   Fri Sep 16 04:08:34 2016(r305857)
+++ head/sbin/reboot/reboot.8   Fri Sep 16 04:11:04 2016(r305858)
@@ -28,7 +28,7 @@
 .\"@(#)reboot.88.1 (Berkeley) 6/9/93
 .\" $FreeBSD$
 .\"
-.Dd Dec 12, 2015
+.Dd September 10, 2016
 .Dt REBOOT 8
 .Os
 .Sh NAME
@@ -165,4 +165,4 @@ reboot -r
 A
 .Nm
 utility appeared in
-.At v6 .
+.Bx 4.0 .
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305857 - head/sbin/rcorder

2016-09-15 Thread Allan Jude
Author: allanjude
Date: Fri Sep 16 04:08:34 2016
New Revision: 305857
URL: https://svnweb.freebsd.org/changeset/base/305857

Log:
  sbin/rcorder/rcorder.8: Amend HISTORY
  
  rcorder appeared in FreeBSD 5.0.
  Address issues raised by igor.
  
  PR:   212547
  Submitted by: Sevan Janiyan 

Modified:
  head/sbin/rcorder/rcorder.8

Modified: head/sbin/rcorder/rcorder.8
==
--- head/sbin/rcorder/rcorder.8 Fri Sep 16 03:36:43 2016(r305856)
+++ head/sbin/rcorder/rcorder.8 Fri Sep 16 04:08:34 2016(r305857)
@@ -1,7 +1,7 @@
 .\"$NetBSD: rcorder.8,v 1.3 2000/07/17 14:16:22 mrg Exp $
 .\"
 .\" Copyright (c) 1998
-.\"Perry E. Metzger.  All rights reserved.
+.\"Perry E. Metzger.  All rights reserved.
 .\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
@@ -31,7 +31,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd August 5, 2011
+.Dd September 10, 2016
 .Dt RCORDER 8
 .Os
 .Sh NAME
@@ -160,8 +160,11 @@ processing the stated file.
 .Sh HISTORY
 The
 .Nm
-utility first appeared in
+utility appeared in
 .Nx 1.5 .
+.Nm
+utility first appeared in
+.Fx 5.0 .
 .Sh AUTHORS
 .An -nosplit
 Written by
@@ -172,7 +175,7 @@ and
 The
 .Dq Li REQUIRE
 keyword is misleading:
-It doesn't describe which daemons have to be running before a script
+It does not describe which daemons have to be running before a script
 will be started.
 It describes which scripts must be placed before it in
 the dependency ordering.
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305856 - head/sys/compat/linprocfs

2016-09-15 Thread Mateusz Guzik
Author: mjg
Date: Fri Sep 16 03:36:43 2016
New Revision: 305856
URL: https://svnweb.freebsd.org/changeset/base/305856

Log:
  linprocfs: garbage collect meminfo fields not present in linux
  
  In particular memshared not only does not exist in linux, it was
  extremely expensive to calculate.

Modified:
  head/sys/compat/linprocfs/linprocfs.c

Modified: head/sys/compat/linprocfs/linprocfs.c
==
--- head/sys/compat/linprocfs/linprocfs.c   Fri Sep 16 03:04:48 2016
(r305855)
+++ head/sys/compat/linprocfs/linprocfs.c   Fri Sep 16 03:36:43 2016
(r305856)
@@ -144,12 +144,10 @@ linprocfs_domeminfo(PFS_FILL_ARGS)
unsigned long memtotal; /* total memory in bytes */
unsigned long memused;  /* used memory in bytes */
unsigned long memfree;  /* free memory in bytes */
-   unsigned long memshared;/* shared memory ??? */
unsigned long buffers, cached;  /* buffer / cache memory ??? */
unsigned long long swaptotal;   /* total swap space in bytes */
unsigned long long swapused;/* used swap space in bytes */
unsigned long long swapfree;/* free swap space in bytes */
-   vm_object_t object;
int i, j;
 
memtotal = physmem * PAGE_SIZE;
@@ -169,13 +167,6 @@ linprocfs_domeminfo(PFS_FILL_ARGS)
swaptotal = (unsigned long long)i * PAGE_SIZE;
swapused = (unsigned long long)j * PAGE_SIZE;
swapfree = swaptotal - swapused;
-   memshared = 0;
-   mtx_lock(&vm_object_list_mtx);
-   TAILQ_FOREACH(object, &vm_object_list, object_list)
-   if (object->shadow_count > 1)
-   memshared += object->resident_page_count;
-   mtx_unlock(&vm_object_list_mtx);
-   memshared *= PAGE_SIZE;
/*
 * We'd love to be able to write:
 *
@@ -188,21 +179,14 @@ linprocfs_domeminfo(PFS_FILL_ARGS)
cached = vm_cnt.v_cache_count * PAGE_SIZE;
 
sbuf_printf(sb,
-   "total:used:free:  shared: buffers:  cached:\n"
-   "Mem:  %lu %lu %lu %lu %lu %lu\n"
-   "Swap: %llu %llu %llu\n"
"MemTotal: %9lu kB\n"
"MemFree:  %9lu kB\n"
-   "MemShared:%9lu kB\n"
"Buffers:  %9lu kB\n"
"Cached:   %9lu kB\n"
"SwapTotal:%9llu kB\n"
"SwapFree: %9llu kB\n",
-   memtotal, memused, memfree, memshared, buffers, cached,
-   swaptotal, swapused, swapfree,
-   B2K(memtotal), B2K(memfree),
-   B2K(memshared), B2K(buffers), B2K(cached),
-   B2K(swaptotal), B2K(swapfree));
+   B2K(memtotal), B2K(memfree), B2K(buffers),
+   B2K(cached), B2K(swaptotal), B2K(swapfree));
 
return (0);
 }
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305855 - head/lib/libc/stdlib

2016-09-15 Thread Marcel Moolenaar
Author: marcel
Date: Fri Sep 16 03:04:48 2016
New Revision: 305855
URL: https://svnweb.freebsd.org/changeset/base/305855

Log:
  When MAKEOBJDIRPREFIX points to a case-insensitive file system, the
  build can break when different source files create the same object
  files (case-insensitivity speaking).  This is the case for _Exit.c
  and _exit.s.  Compile _Exit.c as C99_Exit.c
  
  Reviewed by:  sjg@
  MFC after:completion
  Sponsored by: Bracket Computing
  Differential Revision:https://reviews.freebsd.org/D7893

Modified:
  head/lib/libc/stdlib/Makefile.inc

Modified: head/lib/libc/stdlib/Makefile.inc
==
--- head/lib/libc/stdlib/Makefile.inc   Fri Sep 16 01:38:22 2016
(r305854)
+++ head/lib/libc/stdlib/Makefile.inc   Fri Sep 16 03:04:48 2016
(r305855)
@@ -4,7 +4,7 @@
 # machine-independent stdlib sources
 .PATH: ${LIBC_SRCTOP}/${LIBC_ARCH}/stdlib ${LIBC_SRCTOP}/stdlib
 
-MISRCS+=_Exit.c a64l.c abort.c abs.c atexit.c atof.c atoi.c atol.c atoll.c \
+MISRCS+=C99_Exit.c a64l.c abort.c abs.c atexit.c atof.c atoi.c atol.c atoll.c \
bsearch.c cxa_thread_atexit.c div.c exit.c getenv.c getopt.c 
getopt_long.c \
getsubopt.c hcreate.c hcreate_r.c hdestroy_r.c heapsort.c heapsort_b.c \
hsearch_r.c imaxabs.c imaxdiv.c \
@@ -16,6 +16,13 @@ MISRCS+=_Exit.c a64l.c abort.c abs.c ate
strtol.c strtoll.c strtoq.c strtoul.c strtonum.c strtoull.c \
 strtoumax.c strtouq.c system.c tdelete.c tfind.c tsearch.c twalk.c
 
+# Work around an issue on case-insensitive file systems.
+# libc has both _Exit.c and _exit.s and they both yield
+# _exit.o (case insensitively speaking).
+CLEANFILES+=C99_Exit.c
+C99_Exit.c: ${LIBC_SRCTOP}/stdlib/_Exit.c .NOMETA
+   ln -sf ${.ALLSRC} ${.TARGET}
+
 SYM_MAPS+= ${LIBC_SRCTOP}/stdlib/Symbol.map
 
 # machine-dependent stdlib sources
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r305634 - head/share/mk

2016-09-15 Thread Simon J. Gerraty
Bryan Drewery  wrote:
> On 9/9/16 5:37 PM, Simon J. Gerraty wrote:
> > Bryan Drewery  wrote:
> > 
> >>> +# some targets involve old pre-built targets
> >>> +# ignore mtime of shell
> >>> +# and mtime of makefiles does not matter in meta mode
> >>> +.MAKE.META.IGNORE_PATHS += \
> >>> +${MAKEFILE} \
> >>> +${SHELL} \
> >>> +${SYS_MK_DIR}
> >>
> >> I think it could be problematic to ignore *.mk changes.  The build

> Can you at least wrap it in something like .if
> !defined(META_CONSIDER_MK_FILES) ?

How about META_IGNORE_MAKEFILES ?
Could even be an option ie. -DWITHOUT_META_IGNORE_MAKEFILES to disable?
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305854 - in head/sys/boot/efi/loader/arch: amd64 arm64 i386

2016-09-15 Thread Ed Maste
Author: emaste
Date: Fri Sep 16 01:38:22 2016
New Revision: 305854
URL: https://svnweb.freebsd.org/changeset/base/305854

Log:
  Use arch-specific .text padding fill value in EFI loaders
  
  The fill pattern was previously an ia64 instruction sequence. Presumably
  ia64's linker script was copied as a starting point.
  
  MFC after:1 week
  Sponsored by: The FreeBSD Foundation

Modified:
  head/sys/boot/efi/loader/arch/amd64/ldscript.amd64
  head/sys/boot/efi/loader/arch/arm64/ldscript.arm64
  head/sys/boot/efi/loader/arch/i386/ldscript.i386

Modified: head/sys/boot/efi/loader/arch/amd64/ldscript.amd64
==
--- head/sys/boot/efi/loader/arch/amd64/ldscript.amd64  Fri Sep 16 00:14:26 
2016(r305853)
+++ head/sys/boot/efi/loader/arch/amd64/ldscript.amd64  Fri Sep 16 01:38:22 
2016(r305854)
@@ -19,7 +19,7 @@ SECTIONS
 /* .gnu.warning sections are handled specially by elf32.em. */
 *(.gnu.warning)
 *(.plt)
-  } =0x00300100700201000400
+  } =0xCC
   . = ALIGN(4096);
   .data: {
 *(.rodata .rodata.* .gnu.linkonce.r.*)

Modified: head/sys/boot/efi/loader/arch/arm64/ldscript.arm64
==
--- head/sys/boot/efi/loader/arch/arm64/ldscript.arm64  Fri Sep 16 00:14:26 
2016(r305853)
+++ head/sys/boot/efi/loader/arch/arm64/ldscript.arm64  Fri Sep 16 01:38:22 
2016(r305854)
@@ -15,7 +15,7 @@ SECTIONS
 /* .gnu.warning sections are handled specially by elf32.em. */
 *(.gnu.warning)
 *(.plt)
-  } =0x00300100700201000400
+  } =0xD420
   . = ALIGN(16);
   .data: {
 *(.rodata .rodata.* .gnu.linkonce.r.*)

Modified: head/sys/boot/efi/loader/arch/i386/ldscript.i386
==
--- head/sys/boot/efi/loader/arch/i386/ldscript.i386Fri Sep 16 00:14:26 
2016(r305853)
+++ head/sys/boot/efi/loader/arch/i386/ldscript.i386Fri Sep 16 01:38:22 
2016(r305854)
@@ -14,7 +14,7 @@ SECTIONS
 /* .gnu.warning sections are handled specially by elf32.em. */
 *(.gnu.warning)
 *(.plt)
-  } =0x00300100700201000400
+  } =0xCC
   . = ALIGN(4096);
   .data: {
 *(.rodata .rodata.* .gnu.linkonce.r.*)
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305853 - in stable/10: share/man/man4 sys/kern

2016-09-15 Thread Hiren Panchasara
Author: hiren
Date: Fri Sep 16 00:14:26 2016
New Revision: 305853
URL: https://svnweb.freebsd.org/changeset/base/305853

Log:
  MFC r301522 (by bz)
  
  Implement a `show panic` command to DDB which will helpfully print the
  panic string again if set, in case it scrolled out of the active
  window.  This avoids having to remember the symbol name.
  
  Also add a show callout  command to DDB in order to inspect
  some struct callout fields in case of panics in the callout code.
  This may help to see if there was memory corruption or to further
  ease debugging problems.
  
  No objection by:bz

Modified:
  stable/10/share/man/man4/ddb.4
  stable/10/sys/kern/kern_shutdown.c
  stable/10/sys/kern/kern_timeout.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/share/man/man4/ddb.4
==
--- stable/10/share/man/man4/ddb.4  Fri Sep 16 00:08:37 2016
(r305852)
+++ stable/10/share/man/man4/ddb.4  Fri Sep 16 00:14:26 2016
(r305853)
@@ -611,6 +611,13 @@ See the
 header file for more details on the exact meaning of the structure fields.
 .\"
 .Pp
+.It Ic show Cm callout Ar addr
+Show information about the callout structure
+.Vt struct callout
+present at
+.Ar addr .
+.\"
+.Pp
 .It Ic show Cm cbstat
 Show brief information about the TTY subsystem.
 .\"
@@ -839,6 +846,10 @@ option is specified the
 complete object is printed.
 .\"
 .Pp
+.It Ic show Cm panic
+Print the panic message if set.
+.\"
+.Pp
 .It Ic show Cm page
 Show statistics on VM pages.
 .\"

Modified: stable/10/sys/kern/kern_shutdown.c
==
--- stable/10/sys/kern/kern_shutdown.c  Fri Sep 16 00:08:37 2016
(r305852)
+++ stable/10/sys/kern/kern_shutdown.c  Fri Sep 16 00:14:26 2016
(r305853)
@@ -1031,3 +1031,14 @@ mkdumpheader(struct kerneldumpheader *kd
strlcpy(kdh->panicstring, panicstr, sizeof(kdh->panicstring));
kdh->parity = kerneldump_parity(kdh);
 }
+
+#ifdef DDB
+DB_SHOW_COMMAND(panic, db_show_panic)
+{
+
+   if (panicstr == NULL)
+   db_printf("panicstr not set\n");
+   else
+   db_printf("panic: %s\n", panicstr);
+}
+#endif

Modified: stable/10/sys/kern/kern_timeout.c
==
--- stable/10/sys/kern/kern_timeout.c   Fri Sep 16 00:08:37 2016
(r305852)
+++ stable/10/sys/kern/kern_timeout.c   Fri Sep 16 00:14:26 2016
(r305853)
@@ -39,6 +39,7 @@ __FBSDID("$FreeBSD$");
 
 #include "opt_callout_profiling.h"
 #include "opt_kdtrace.h"
+#include "opt_ddb.h"
 #if defined(__arm__)
 #include "opt_timer.h"
 #endif
@@ -60,6 +61,11 @@ __FBSDID("$FreeBSD$");
 #include 
 #include 
 
+#ifdef DDB
+#include 
+#include 
+#endif
+
 #ifdef SMP
 #include 
 #endif
@@ -1576,3 +1582,34 @@ SYSCTL_PROC(_kern, OID_AUTO, callout_sta
 CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_MPSAFE,
 0, 0, sysctl_kern_callout_stat, "I",
 "Dump immediate statistic snapshot of the scheduled callouts");
+
+#ifdef DDB
+static void
+_show_callout(struct callout *c)
+{
+
+   db_printf("callout %p\n", c);
+#defineC_DB_PRINTF(f, e)   db_printf("   %s = " f "\n", #e, c->e);
+   db_printf("   &c_links = %p\n", &(c->c_links));
+   C_DB_PRINTF("%" PRId64, c_time);
+   C_DB_PRINTF("%" PRId64, c_precision);
+   C_DB_PRINTF("%p",   c_arg);
+   C_DB_PRINTF("%p",   c_func);
+   C_DB_PRINTF("%p",   c_lock);
+   C_DB_PRINTF("%#x",  c_flags);
+   C_DB_PRINTF("%#x",  c_iflags);
+   C_DB_PRINTF("%d",   c_cpu);
+#undef C_DB_PRINTF
+}
+
+DB_SHOW_COMMAND(callout, db_show_callout)
+{
+
+   if (!have_addr) {
+   db_printf("usage: show callout \n");
+   return;
+   }
+
+   _show_callout((struct callout *)addr);
+}
+#endif /* DDB */
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305852 - in head/sys: dev/cxgbe dev/cxgbe/firmware modules/cxgbe modules/cxgbe/if_cc modules/cxgbe/if_ccv

2016-09-15 Thread Navdeep Parhar
Author: np
Date: Fri Sep 16 00:08:37 2016
New Revision: 305852
URL: https://svnweb.freebsd.org/changeset/base/305852

Log:
  cxgbe(4): Attach to cards with the Terminator 6 ASIC.  T6 cards will
  come up as 't6nex' nexus devices with 'cc' ports hanging off them.
  
  The T6 firmware and configuration files will be added as soon as they
  are released.  For now the driver will try to work with whatever
  firmware and configuration is on the card's flash.
  
  Sponsored by: Chelsio Communications

Added:
  head/sys/dev/cxgbe/if_cc.c   (contents, props changed)
  head/sys/dev/cxgbe/if_ccv.c   (contents, props changed)
  head/sys/modules/cxgbe/if_cc/
  head/sys/modules/cxgbe/if_cc/Makefile   (contents, props changed)
  head/sys/modules/cxgbe/if_ccv/
  head/sys/modules/cxgbe/if_ccv/Makefile   (contents, props changed)
Modified:
  head/sys/dev/cxgbe/adapter.h
  head/sys/dev/cxgbe/firmware/t4fw_interface.h
  head/sys/dev/cxgbe/t4_iov.c
  head/sys/dev/cxgbe/t4_main.c
  head/sys/dev/cxgbe/t4_tracer.c
  head/sys/dev/cxgbe/t4_vf.c
  head/sys/modules/cxgbe/Makefile

Modified: head/sys/dev/cxgbe/adapter.h
==
--- head/sys/dev/cxgbe/adapter.hThu Sep 15 22:31:49 2016
(r305851)
+++ head/sys/dev/cxgbe/adapter.hFri Sep 16 00:08:37 2016
(r305852)
@@ -752,10 +752,20 @@ struct sge {
struct hw_buf_info hw_buf_info[SGE_FLBUF_SIZES];
 };
 
+struct devnames {
+   const char *nexus_name;
+   const char *ifnet_name;
+   const char *vi_ifnet_name;
+   const char *pf03_drv_name;
+   const char *vf_nexus_name;
+   const char *vf_ifnet_name;
+};
+
 struct adapter {
SLIST_ENTRY(adapter) link;
device_t dev;
struct cdev *cdev;
+   const struct devnames *names;
 
/* PCIe register resources */
int regs_rid;
@@ -1117,6 +1127,7 @@ int t4_os_pci_restore_state(struct adapt
 void t4_os_portmod_changed(const struct adapter *, int);
 void t4_os_link_changed(struct adapter *, int, int, int);
 void t4_iterate(void (*)(struct adapter *, void *), void *);
+void t4_init_devnames(struct adapter *);
 void t4_add_adapter(struct adapter *);
 int t4_detach_common(device_t);
 int t4_filter_rpl(struct sge_iq *, const struct rss_header *, struct mbuf *);

Modified: head/sys/dev/cxgbe/firmware/t4fw_interface.h
==
--- head/sys/dev/cxgbe/firmware/t4fw_interface.hThu Sep 15 22:31:49 
2016(r305851)
+++ head/sys/dev/cxgbe/firmware/t4fw_interface.hFri Sep 16 00:08:37 
2016(r305852)
@@ -9215,6 +9215,11 @@ enum {
T5FW_VERSION_MINOR  = 0x05,
T5FW_VERSION_MICRO  = 0x25,
T5FW_VERSION_BUILD  = 0x00,
+
+   T6FW_VERSION_MAJOR  = 0x00,
+   T6FW_VERSION_MINOR  = 0x00,
+   T6FW_VERSION_MICRO  = 0x00,
+   T6FW_VERSION_BUILD  = 0x00,
 };
 
 enum {

Added: head/sys/dev/cxgbe/if_cc.c
==
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ head/sys/dev/cxgbe/if_cc.c  Fri Sep 16 00:08:37 2016(r305852)
@@ -0,0 +1,44 @@
+/*-
+ * Copyright (c) 2016 Chelsio Communications, Inc.
+ * All rights reserved.
+ * Written by: Navdeep Parhar 
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *notice, this list of conditions and the following disclaimer in the
+ *documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include 
+__FBSDID("$FreeBSD$");
+
+#include 
+#include 
+#include 
+
+static int
+mod_event(module_t mod, int cmd, void *arg)
+{
+
+   return (0);
+}
+static moduledata_t if_cc_mod = {"if_cc", mod_event};
+DECLARE_MODULE(if_cc, if_cc_mod, SI_SUB_EXEC, SI_ORDER_ANY);
+MODULE_VERSION(if_cc, 1);
+MODULE_DEPEND(i

svn commit: r305851 - head/sys/dev/cxgbe

2016-09-15 Thread Navdeep Parhar
Author: np
Date: Thu Sep 15 22:31:49 2016
New Revision: 305851
URL: https://svnweb.freebsd.org/changeset/base/305851

Log:
  Whitespace nits.

Modified:
  head/sys/dev/cxgbe/t4_iov.c
  head/sys/dev/cxgbe/t4_vf.c

Modified: head/sys/dev/cxgbe/t4_iov.c
==
--- head/sys/dev/cxgbe/t4_iov.c Thu Sep 15 22:27:00 2016(r305850)
+++ head/sys/dev/cxgbe/t4_iov.c Thu Sep 15 22:31:49 2016(r305851)
@@ -97,7 +97,7 @@ static intt4iov_attach_child(device_t d
 static int
 t4iov_probe(device_t dev)
 {
-   uint16_t d; 
+   uint16_t d;
size_t i;
 
d = pci_get_device(dev);
@@ -114,7 +114,7 @@ t4iov_probe(device_t dev)
 static int
 t5iov_probe(device_t dev)
 {
-   uint16_t d; 
+   uint16_t d;
size_t i;
 
d = pci_get_device(dev);

Modified: head/sys/dev/cxgbe/t4_vf.c
==
--- head/sys/dev/cxgbe/t4_vf.c  Thu Sep 15 22:27:00 2016(r305850)
+++ head/sys/dev/cxgbe/t4_vf.c  Thu Sep 15 22:31:49 2016(r305851)
@@ -124,7 +124,7 @@ static struct cdevsw t4vf_cdevsw = {
 static int
 t4vf_probe(device_t dev)
 {
-   uint16_t d; 
+   uint16_t d;
size_t i;
 
d = pci_get_device(dev);
@@ -140,7 +140,7 @@ t4vf_probe(device_t dev)
 static int
 t5vf_probe(device_t dev)
 {
-   uint16_t d; 
+   uint16_t d;
size_t i;
 
d = pci_get_device(dev);
@@ -653,7 +653,7 @@ t4vf_attach(device_t dev)
pi->vi[0].dev = pi->dev;
device_set_softc(pi->dev, pi);
}
-   
+
/*
 * Interrupt type, # of interrupts, # of rx/tx queues, etc.
 */
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305850 - head/sys/net80211

2016-09-15 Thread Andriy Voskoboinyk
Author: avos
Date: Thu Sep 15 22:27:00 2016
New Revision: 305850
URL: https://svnweb.freebsd.org/changeset/base/305850

Log:
  net80211: allow to override SWCRYPT/SWMIC bits in the driver
  
  Add IEEE80211_KEY_SWCRYPT / IEEE80211_KEY_SWMIC bits to the
  IEEE80211_KEY_DEVICE mask - as a result, those bits will be preserved
  during group key handshake.
  
  A driver can override them in iv_key_alloc() for some keys in case
  when hardware crypto support is not possible. As an example:
   - multi-vap without multicast key search support;
   - IBSS RSN for devices w/ fixed storage for group keys;
  
  Tested with RTL8188EU (AP, sw crypto) and
  RTL8821AU (STA, sw crypto for group keys + hw crypto for pairwise keys)
  
  Reviewed by:  adrian
  Differential Revision:https://reviews.freebsd.org/D7901

Modified:
  head/sys/net80211/ieee80211_crypto.h

Modified: head/sys/net80211/ieee80211_crypto.h
==
--- head/sys/net80211/ieee80211_crypto.hThu Sep 15 18:30:53 2016
(r305849)
+++ head/sys/net80211/ieee80211_crypto.hThu Sep 15 22:27:00 2016
(r305850)
@@ -101,13 +101,15 @@ struct ieee80211_key {
 #defineIEEE80211_KEY_COMMON/* common flags passed in by 
apps */\
(IEEE80211_KEY_XMIT | IEEE80211_KEY_RECV | IEEE80211_KEY_GROUP | \
 IEEE80211_KEY_NOREPLAY)
-#defineIEEE80211_KEY_DEVICE/* flags owned by device driver 
*/\
-   (IEEE80211_KEY_DEVKEY|IEEE80211_KEY_CIPHER0|IEEE80211_KEY_CIPHER1)
 
 #defineIEEE80211_KEY_SWCRYPT \
(IEEE80211_KEY_SWENCRYPT | IEEE80211_KEY_SWDECRYPT)
 #defineIEEE80211_KEY_SWMIC (IEEE80211_KEY_SWENMIC | 
IEEE80211_KEY_SWDEMIC)
 
+#define IEEE80211_KEY_DEVICE   /* flags owned by device driver */\
+   (IEEE80211_KEY_DEVKEY|IEEE80211_KEY_CIPHER0|IEEE80211_KEY_CIPHER1| \
+IEEE80211_KEY_SWCRYPT|IEEE80211_KEY_SWMIC)
+
 #defineIEEE80211_KEY_BITS \
"\20\1XMIT\2RECV\3GROUP\4SWENCRYPT\5SWDECRYPT\6SWENMIC\7SWDEMIC" \
"\10DEVKEY\11CIPHER0\12CIPHER1"
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


We have a slight error in your account information

2016-09-15 Thread PayPal Support .

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


Re: svn commit: r305824 - in head/sys: contrib/ipfilter/netinet kern net netinet netinet6 netipsec sys

2016-09-15 Thread Ngie Cooper

> On Sep 15, 2016, at 06:46, Kevin Lo  wrote:

...

> Bumped(r305833), thanks.

Thanks :)!
-Ngie
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305849 - head/sys/amd64/include

2016-09-15 Thread Bruce Evans
Author: bde
Date: Thu Sep 15 18:30:53 2016
New Revision: 305849
URL: https://svnweb.freebsd.org/changeset/base/305849

Log:
  Decode some REX prefixes in inst_call().  This makes the 'next' and
  'until' commands work in more cases.

Modified:
  head/sys/amd64/include/db_machdep.h

Modified: head/sys/amd64/include/db_machdep.h
==
--- head/sys/amd64/include/db_machdep.h Thu Sep 15 17:37:30 2016
(r305848)
+++ head/sys/amd64/include/db_machdep.h Thu Sep 15 18:30:53 2016
(r305849)
@@ -69,14 +69,15 @@ do {\
 
 #defineI_CALL  0xe8
 #defineI_CALLI 0xff
+#definei_calli(ins)(((ins)&0xff) == I_CALLI && ((ins)&0x3800) == 
0x1000)
 #defineI_RET   0xc3
 #defineI_IRET  0xcf
+#definei_rex(ins)  (((ins) & 0xff) == 0x41 || ((ins) & 0xff) == 
0x43)
 
 #defineinst_trap_return(ins)   (((ins)&0xff) == I_IRET)
 #defineinst_return(ins)(((ins)&0xff) == I_RET)
-#defineinst_call(ins)  (((ins)&0xff) == I_CALL || \
-(((ins)&0xff) == I_CALLI && \
- ((ins)&0x3800) == 0x1000))
+#defineinst_call(ins)  (((ins)&0xff) == I_CALL || i_calli(ins) 
|| \
+(i_calli((ins) >> 8) && i_rex(ins)))
 #define inst_load(ins) 0
 #define inst_store(ins)0
 
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305848 - in stable/11/sys: arm/include sys

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:37:30 2016
New Revision: 305848
URL: https://svnweb.freebsd.org/changeset/base/305848

Log:
  MFC r303677: Move/add ARM ELF PHDR types to elf_common.h

Modified:
  stable/11/sys/arm/include/elf.h
  stable/11/sys/sys/elf_common.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/arm/include/elf.h
==
--- stable/11/sys/arm/include/elf.h Thu Sep 15 17:36:43 2016
(r305847)
+++ stable/11/sys/arm/include/elf.h Thu Sep 15 17:37:30 2016
(r305848)
@@ -55,9 +55,6 @@ __ElfType(Auxinfo);
 
 #defineELF_MACHINE_OK(x) ((x) == EM_ARM)
 
-/* Unwind info section type */
-#definePT_ARM_EXIDX (PT_LOPROC + 1)
-
 /*
  * Relocation types.
  */

Modified: stable/11/sys/sys/elf_common.h
==
--- stable/11/sys/sys/elf_common.h  Thu Sep 15 17:36:43 2016
(r305847)
+++ stable/11/sys/sys/elf_common.h  Thu Sep 15 17:37:30 2016
(r305848)
@@ -511,6 +511,8 @@ typedef struct {
 #definePT_HISUNW   0x6fff
 #definePT_HIOS 0x6fff  /* Last OS-specific. */
 #definePT_LOPROC   0x7000  /* First processor-specific 
type. */
+#definePT_ARM_ARCHEXT  0x7000  /* ARM arch compat information. 
*/
+#definePT_ARM_EXIDX0x7001  /* ARM exception unwind tables. 
*/
 #definePT_HIPROC   0x7fff  /* Last processor-specific 
type. */
 
 /* Values for p_flags. */
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305847 - stable/11/sys/sys

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:36:43 2016
New Revision: 305847
URL: https://svnweb.freebsd.org/changeset/base/305847

Log:
  MFC r303670: Add ELFOSABI_ARM_AEABI ELF OSABI constant

Modified:
  stable/11/sys/sys/elf_common.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/sys/elf_common.h
==
--- stable/11/sys/sys/elf_common.h  Thu Sep 15 17:34:14 2016
(r305846)
+++ stable/11/sys/sys/elf_common.h  Thu Sep 15 17:36:43 2016
(r305847)
@@ -171,6 +171,7 @@ typedef struct {
 #defineELFOSABI_AROS   15  /* Amiga Research OS */
 #defineELFOSABI_FENIXOS16  /* FenixOS */
 #defineELFOSABI_CLOUDABI   17  /* Nuxi CloudABI */
+#defineELFOSABI_ARM_AEABI  64  /* ARM EABI */
 #defineELFOSABI_ARM97  /* ARM */
 #defineELFOSABI_STANDALONE 255 /* Standalone (embedded) 
application */
 
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305846 - stable/11/sys/dev/kbd

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:34:14 2016
New Revision: 305846
URL: https://svnweb.freebsd.org/changeset/base/305846

Log:
  MFC r303335: apply some style(9) to kbd: make function name start in column 1

Modified:
  stable/11/sys/dev/kbd/kbd.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/dev/kbd/kbd.c
==
--- stable/11/sys/dev/kbd/kbd.c Thu Sep 15 17:30:01 2016(r305845)
+++ stable/11/sys/dev/kbd/kbd.c Thu Sep 15 17:34:14 2016(r305846)
@@ -284,8 +284,8 @@ kbd_unregister(keyboard_t *kbd)
 }
 
 /* find a function table by the driver name */
-keyboard_switch_t
-*kbd_get_switch(char *driver)
+keyboard_switch_t *
+kbd_get_switch(char *driver)
 {
const keyboard_driver_t **list;
const keyboard_driver_t *p;
@@ -419,8 +419,8 @@ kbd_change_callback(keyboard_t *kbd, voi
 }
 
 /* get a keyboard structure */
-keyboard_t
-*kbd_get_keyboard(int index)
+keyboard_t *
+kbd_get_keyboard(int index)
 {
if ((index < 0) || (index >= keyboards))
return (NULL);
@@ -1118,8 +1118,8 @@ fkey_change_ok(fkeytab_t *oldkey, fkeyar
 #endif
 
 /* get a pointer to the string associated with the given function key */
-u_char
-*genkbd_get_fkeystr(keyboard_t *kbd, int fkey, size_t *len)
+u_char *
+genkbd_get_fkeystr(keyboard_t *kbd, int fkey, size_t *len)
 {
if (kbd == NULL)
return (NULL);
@@ -1131,8 +1131,8 @@ u_char
 }
 
 /* diagnostic dump */
-static char
-*get_kbd_type_name(int type)
+static char *
+get_kbd_type_name(int type)
 {
static struct {
int type;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305845 - in stable/11/sys/boot/efi: boot1 loader

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:30:01 2016
New Revision: 305845
URL: https://svnweb.freebsd.org/changeset/base/305845

Log:
  MFC r305160: Set UEFI boot loader PE/COFF timestamps to known value for 
reproducible builds
  
  Sponsored by: The FreeBSD Foundation

Modified:
  stable/11/sys/boot/efi/boot1/Makefile
  stable/11/sys/boot/efi/loader/Makefile
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/boot/efi/boot1/Makefile
==
--- stable/11/sys/boot/efi/boot1/Makefile   Thu Sep 15 17:28:03 2016
(r305844)
+++ stable/11/sys/boot/efi/boot1/Makefile   Thu Sep 15 17:30:01 2016
(r305845)
@@ -84,11 +84,15 @@ EFI_TARGET= efi-app-ia32
 EFI_TARGET=binary
 .endif
 
+# Arbitrarily set the PE/COFF header timestamps to 1 Jan 2016 00:00:00
+# for build reproducibility.
+SOURCE_DATE_EPOCH?=1451606400
 boot1.efi: ${PROG}
if ${NM} ${.ALLSRC} | grep ' U '; then \
echo "Undefined symbols in ${.ALLSRC}"; \
exit 1; \
fi
+   SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH} \
${OBJCOPY} -j .peheader -j .text -j .sdata -j .data \
-j .dynamic -j .dynsym -j .rel.dyn \
-j .rela.dyn -j .reloc -j .eh_frame \

Modified: stable/11/sys/boot/efi/loader/Makefile
==
--- stable/11/sys/boot/efi/loader/Makefile  Thu Sep 15 17:28:03 2016
(r305844)
+++ stable/11/sys/boot/efi/loader/Makefile  Thu Sep 15 17:30:01 2016
(r305845)
@@ -128,11 +128,15 @@ EFI_TARGET=   efi-app-ia32
 EFI_TARGET=binary
 .endif
 
+# Arbitrarily set the PE/COFF header timestamps to 1 Jan 2016 00:00:00
+# for build reproducibility.
+SOURCE_DATE_EPOCH?=1451606400
 loader.efi: ${PROG}
if ${NM} ${.ALLSRC} | grep ' U '; then \
echo "Undefined symbols in ${.ALLSRC}"; \
exit 1; \
fi
+   SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH} \
${OBJCOPY} -j .peheader -j .text -j .sdata -j .data \
-j .dynamic -j .dynsym -j .rel.dyn \
-j .rela.dyn -j .reloc -j .eh_frame -j set_Xcommand_set \
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305844 - in stable/11: contrib/elftoolchain/common contrib/elftoolchain/elfcopy contrib/elftoolchain/elfdump contrib/elftoolchain/libelf contrib/elftoolchain/libelftc contrib/elftoolch...

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:28:03 2016
New Revision: 305844
URL: https://svnweb.freebsd.org/changeset/base/305844

Log:
  MFC r305130: Update to ELF Tool Chain r3490
  
  Improvements include:
   * readelf: report all relocation types in rel/rela for MIPS N64
   * readelf: add ELFOSABI_ARM_AEABI
   * elfdump: add ELFOSABI_ARM_AEABI and ELFOSABI_ARM
   * Add recent RISC-V relocations
   * elfcopy: use elftc_timestamp, to support SOURCE_DATE_EPOCH
  
  MFC r305155: readelf: silence GCC 4.2.1 uninitialized variable warning
  
  Sponsored by: The FreeBSD Foundation

Added:
  stable/11/contrib/elftoolchain/libelftc/elftc_timestamp.3
 - copied unchanged from r305130, 
head/contrib/elftoolchain/libelftc/elftc_timestamp.3
  stable/11/contrib/elftoolchain/libelftc/elftc_timestamp.c
 - copied unchanged from r305130, 
head/contrib/elftoolchain/libelftc/elftc_timestamp.c
Modified:
  stable/11/contrib/elftoolchain/common/elfdefinitions.h
  stable/11/contrib/elftoolchain/elfcopy/archive.c
  stable/11/contrib/elftoolchain/elfcopy/ascii.c
  stable/11/contrib/elftoolchain/elfcopy/pe.c
  stable/11/contrib/elftoolchain/elfdump/elfdump.c
  stable/11/contrib/elftoolchain/libelf/elf_flagdata.3
  stable/11/contrib/elftoolchain/libelftc/Makefile
  stable/11/contrib/elftoolchain/libelftc/elftc_bfd_find_target.3
  stable/11/contrib/elftoolchain/libelftc/elftc_reloc_type_str.c
  stable/11/contrib/elftoolchain/libelftc/libelftc.h
  stable/11/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c
  stable/11/contrib/elftoolchain/libelftc/libelftc_dem_gnu3.c
  stable/11/contrib/elftoolchain/readelf/readelf.1
  stable/11/contrib/elftoolchain/readelf/readelf.c
  stable/11/lib/libelftc/Makefile
  stable/11/lib/libelftc/elftc_version.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/elftoolchain/common/elfdefinitions.h
==
--- stable/11/contrib/elftoolchain/common/elfdefinitions.h  Thu Sep 15 
17:25:52 2016(r305843)
+++ stable/11/contrib/elftoolchain/common/elfdefinitions.h  Thu Sep 15 
17:28:03 2016(r305844)
@@ -23,7 +23,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $Id: elfdefinitions.h 3455 2016-05-09 13:47:29Z emaste $
+ * $Id: elfdefinitions.h 3485 2016-08-18 13:38:52Z emaste $
  */
 
 /*
@@ -2091,7 +2091,10 @@ _ELF_DEFINE_RELOC(R_RISCV_GNU_VTINHERIT,
 _ELF_DEFINE_RELOC(R_RISCV_GNU_VTENTRY, 42) \
 _ELF_DEFINE_RELOC(R_RISCV_ALIGN,   43) \
 _ELF_DEFINE_RELOC(R_RISCV_RVC_BRANCH,  44) \
-_ELF_DEFINE_RELOC(R_RISCV_RVC_JUMP,45)
+_ELF_DEFINE_RELOC(R_RISCV_RVC_JUMP,45) \
+_ELF_DEFINE_RELOC(R_RISCV_RVC_LUI, 46) \
+_ELF_DEFINE_RELOC(R_RISCV_GPREL_I, 47) \
+_ELF_DEFINE_RELOC(R_RISCV_GPREL_S, 48)
 
 #define_ELF_DEFINE_SPARC_RELOCATIONS() \
 _ELF_DEFINE_RELOC(R_SPARC_NONE,0)  \

Modified: stable/11/contrib/elftoolchain/elfcopy/archive.c
==
--- stable/11/contrib/elftoolchain/elfcopy/archive.cThu Sep 15 17:25:52 
2016(r305843)
+++ stable/11/contrib/elftoolchain/elfcopy/archive.cThu Sep 15 17:28:03 
2016(r305844)
@@ -38,7 +38,7 @@
 
 #include "elfcopy.h"
 
-ELFTC_VCSID("$Id: archive.c 3287 2015-12-31 16:58:48Z emaste $");
+ELFTC_VCSID("$Id: archive.c 3490 2016-08-31 00:12:22Z emaste $");
 
 #define _ARMAG_LEN 8   /* length of ar magic string */
 #define _ARHDR_LEN 60  /* length of ar header */
@@ -440,6 +440,7 @@ ac_write_objs(struct elfcopy *ecp, int o
struct archive  *a;
struct archive_entry*entry;
struct ar_obj   *obj;
+   time_t   timestamp;
int  nr;
 
if ((a = archive_write_new()) == NULL)
@@ -450,7 +451,9 @@ ac_write_objs(struct elfcopy *ecp, int o
/* Write the archive symbol table, even if it's empty. */
entry = archive_entry_new();
archive_entry_copy_pathname(entry, "/");
-   archive_entry_set_mtime(entry, time(NULL), 0);
+   if (elftc_timestamp(×tamp) != 0)
+   err(EXIT_FAILURE, "elftc_timestamp");
+   archive_entry_set_mtime(entry, timestamp, 0);
archive_entry_set_size(entry, (ecp->s_cnt + 1) * sizeof(uint32_t) +
ecp->s_sn_sz);
AC(archive_write_header(a, entry));

Modified: stable/11/contrib/elftoolchain/elfcopy/ascii.c
==
--- stable/11/contrib/elftoolchain/elfcopy/ascii.c  Thu Sep 15 17:25:52 
2016(r305843)
+++ stable/11/contrib/elftoolchain/elfcopy/ascii.c  Thu Sep 15 17:28:03 
2016(r305844)
@@ -36,7 +36,7 @@
 
 #include "elfcopy.h"
 
-ELFTC_VCSID("$Id: ascii.c 3446 2016-05-03 01:31:17Z emaste $");
+ELFTC_VCSI

svn commit: r305843 - in head/sys/mips: include mips

2016-09-15 Thread Brooks Davis
Author: brooks
Date: Thu Sep 15 17:25:52 2016
New Revision: 305843
URL: https://svnweb.freebsd.org/changeset/base/305843

Log:
  The TLS offset is a property of the process ABI.
  
  Move to a per-proc TLS offset rather than incorrectly keying off the
  presense of freebsd32 compability in the kernel.
  
  Reviewed by:  adrian, sbruno
  Obtained from:CheriBSD
  Sponsored by: DARPA, AFRL
  Differential Revision:https://reviews.freebsd.org/D7843

Modified:
  head/sys/mips/include/proc.h
  head/sys/mips/mips/cpu.c
  head/sys/mips/mips/freebsd32_machdep.c
  head/sys/mips/mips/genassym.c
  head/sys/mips/mips/pm_machdep.c
  head/sys/mips/mips/swtch.S
  head/sys/mips/mips/sys_machdep.c
  head/sys/mips/mips/trap.c
  head/sys/mips/mips/vm_machdep.c

Modified: head/sys/mips/include/proc.h
==
--- head/sys/mips/include/proc.hThu Sep 15 17:25:11 2016
(r305842)
+++ head/sys/mips/include/proc.hThu Sep 15 17:25:52 2016
(r305843)
@@ -62,6 +62,7 @@ struct mdthread {
int md_pc_count;/* performance counter */
int md_pc_spill;/* performance counter spill */
void*md_tls;
+   size_t  md_tls_tcb_offset;  /* TCB offset */
 #ifdef CPU_CNMIPS
struct octeon_cop2_state*md_cop2; /* kernel context */
struct octeon_cop2_state*md_ucop2; /* userland context */

Modified: head/sys/mips/mips/cpu.c
==
--- head/sys/mips/mips/cpu.cThu Sep 15 17:25:11 2016(r305842)
+++ head/sys/mips/mips/cpu.cThu Sep 15 17:25:52 2016(r305843)
@@ -71,13 +71,12 @@ struct mips_cpuinfo cpuinfo;
 #   define _LOAD_T0_MDTLS_A1 \
 _ENCODE_INSN(OP_LD, A1, T0, 0, offsetof(struct thread, td_md.md_tls))
 
-#   if defined(COMPAT_FREEBSD32)
-#   define _ADDIU_V0_T0_TLS_OFFSET \
-_ENCODE_INSN(OP_DADDIU, T0, V0, 0, (TLS_TP_OFFSET + TLS_TCB_SIZE32))
-#   else
-#   define _ADDIU_V0_T0_TLS_OFFSET \
-_ENCODE_INSN(OP_DADDIU, T0, V0, 0, (TLS_TP_OFFSET + TLS_TCB_SIZE))
-#   endif /* ! COMPAT_FREEBSD32 */
+#   define _LOAD_T0_MDTLS_TCV_OFFSET_A1 \
+_ENCODE_INSN(OP_LD, A1, T1, 0, \
+offsetof(struct thread, td_md.md_tls_tcb_offset))
+
+#   define _ADDU_V0_T0_T1 \
+_ENCODE_INSN(0, T0, T1, V0, OP_DADDU)
 
 #   define _MTC0_V0_USERLOCAL \
 _ENCODE_INSN(OP_COP0, OP_DMT, V0, 4, 2)
@@ -86,8 +85,14 @@ struct mips_cpuinfo cpuinfo;
 
 #   define _LOAD_T0_MDTLS_A1 \
 _ENCODE_INSN(OP_LW, A1, T0, 0, offsetof(struct thread, td_md.md_tls))
-#   define _ADDIU_V0_T0_TLS_OFFSET \
-_ENCODE_INSN(OP_ADDIU, T0, V0, 0, (TLS_TP_OFFSET + TLS_TCB_SIZE))
+
+#   define _LOAD_T0_MDTLS_TCV_OFFSET_A1 \
+_ENCODE_INSN(OP_LW, A1, T1, 0, \
+offsetof(struct thread, td_md.md_tls_tcb_offset))
+
+#   define _ADDU_V0_T0_T1 \
+_ENCODE_INSN(0, T0, T1, V0, OP_ADDU)
+
 #   define _MTC0_V0_USERLOCAL \
 _ENCODE_INSN(OP_COP0, OP_MT, V0, 4, 2)
 
@@ -111,8 +116,9 @@ remove_userlocal_code(uint32_t *cpu_swit
if (instructp[0] == _JR_RA)
panic("%s: Unable to patch cpu_switch().", __func__);
if (instructp[0] == _LOAD_T0_MDTLS_A1 &&
-   instructp[1] == _ADDIU_V0_T0_TLS_OFFSET &&
-   instructp[2] == _MTC0_V0_USERLOCAL) {
+   instructp[1] == _LOAD_T0_MDTLS_TCV_OFFSET_A1 &&
+   instructp[2] == _ADDU_V0_T0_T1 &&
+   instructp[3] == _MTC0_V0_USERLOCAL) {
instructp[0] = _JR_RA;
instructp[1] = _NOP;
break;

Modified: head/sys/mips/mips/freebsd32_machdep.c
==
--- head/sys/mips/mips/freebsd32_machdep.c  Thu Sep 15 17:25:11 2016
(r305842)
+++ head/sys/mips/mips/freebsd32_machdep.c  Thu Sep 15 17:25:52 2016
(r305843)
@@ -61,6 +61,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -138,6 +139,8 @@ freebsd32_exec_setregs(struct thread *td
 * Clear extended address space bit for userland.
 */
td->td_frame->sr &= ~MIPS_SR_UX;
+
+   td->td_md.md_tls_tcb_offset = TLS_TP_OFFSET + TLS_TCB_SIZE32;
 }
 
 int

Modified: head/sys/mips/mips/genassym.c
==
--- head/sys/mips/mips/genassym.c   Thu Sep 15 17:25:11 2016
(r305842)
+++ head/sys/mips/mips/genassym.c   Thu Sep 15 17:25:52 2016
(r305843)
@@ -74,12 +74,7 @@ ASSYM(TD_FLAGS, offsetof(struct thread, 
 ASSYM(TD_LOCK, offsetof(struct thread, td_lock));
 ASSYM(TD_MDFLAGS, offsetof(struct thread, td_md.md_flags));
 ASSYM(TD_MDTLS, offsetof(struct thread, td_md.md_tls));
-
-#if defined(__mips_n64) && defined(COMPAT_FREEBSD32)
-ASSYM(TLS_TCB_OFFS

svn commit: r305842 - stable/11/contrib/elftoolchain/elfcopy

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:25:11 2016
New Revision: 305842
URL: https://svnweb.freebsd.org/changeset/base/305842

Log:
  MFC r304191: elfcopy: correct comment typo
  
  (Missed in r305838)

Modified:
  stable/11/contrib/elftoolchain/elfcopy/ascii.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/elftoolchain/elfcopy/ascii.c
==
--- stable/11/contrib/elftoolchain/elfcopy/ascii.c  Thu Sep 15 17:24:39 
2016(r305841)
+++ stable/11/contrib/elftoolchain/elfcopy/ascii.c  Thu Sep 15 17:25:11 
2016(r305842)
@@ -251,7 +251,7 @@ create_elf_from_srec(struct elfcopy *ecp
sec_index = 1;
sec_addr = entry = 0;
while (fgets(line, _LINE_BUFSZ, ifp) != NULL) {
-   sz = 0; /* Silence GCC 5.3 unintialized variable warning */
+   sz = 0; /* Silence GCC 5.3 uninitialized variable warning */
if (line[0] == '\r' || line[0] == '\n')
continue;
if (line[0] == '$' && line[1] == '$') {
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305841 - head/bin/cat

2016-09-15 Thread Andrey A. Chernov
Author: ache
Date: Thu Sep 15 17:24:39 2016
New Revision: 305841
URL: https://svnweb.freebsd.org/changeset/base/305841

Log:
  Implement multibyte encoding support for -v with fallback
  
  MFC after:  7 days

Modified:
  head/bin/cat/cat.c

Modified: head/bin/cat/cat.c
==
--- head/bin/cat/cat.c  Thu Sep 15 17:24:23 2016(r305840)
+++ head/bin/cat/cat.c  Thu Sep 15 17:24:39 2016(r305841)
@@ -64,6 +64,8 @@ __FBSDID("$FreeBSD$");
 #include 
 #include 
 #include 
+#include 
+#include 
 
 static int bflag, eflag, lflag, nflag, sflag, tflag, vflag;
 static int rval;
@@ -207,6 +209,7 @@ static void
 cook_cat(FILE *fp)
 {
int ch, gobble, line, prev;
+   wint_t wch;
 
/* Reset EOF condition on stdin. */
if (fp == stdin && feof(stdin))
@@ -239,18 +242,40 @@ cook_cat(FILE *fp)
continue;
}
} else if (vflag) {
-   if (!isascii(ch) && !isprint(ch)) {
+   (void)ungetc(ch, fp);
+   /*
+* Our getwc(3) doesn't change file position
+* on error.
+*/
+   if ((wch = getwc(fp)) == WEOF) {
+   if (ferror(fp) && errno == EILSEQ) {
+   clearerr(fp);
+   /* Resync attempt. */
+   memset(&fp->_mbstate, 0, 
sizeof(mbstate_t));
+   if ((ch = getc(fp)) == EOF)
+   break;
+   wch = ch;
+   goto ilseq;
+   } else
+   break;
+   }
+   if (!iswascii(wch) && !iswprint(wch)) {
+ilseq:
if (putchar('M') == EOF || putchar('-') == EOF)
break;
-   ch = toascii(ch);
+   wch = toascii(wch);
}
-   if (iscntrl(ch)) {
-   if (putchar('^') == EOF ||
-   putchar(ch == '\177' ? '?' :
-   ch | 0100) == EOF)
+   if (iswcntrl(wch)) {
+   ch = toascii(wch);
+   ch = (ch == '\177') ? '?' : (ch | 0100);
+   if (putchar('^') == EOF || putchar(ch) == EOF)
break;
continue;
}
+   if (putwchar(wch) == WEOF)
+   break;
+   ch = -1;
+   continue;
}
if (putchar(ch) == EOF)
break;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305840 - in head/sys: amd64/amd64 amd64/include ddb i386/i386 i386/include

2016-09-15 Thread Bruce Evans
Author: bde
Date: Thu Sep 15 17:24:23 2016
New Revision: 305840
URL: https://svnweb.freebsd.org/changeset/base/305840

Log:
  Abort single stepping in ddb if the trap is not for single-stepping.
  This is not very easy to do, since ddb didn't know when traps are
  for single-stepping.  It more or less assumed that traps are either
  breakpoints or single-step, but even for x86 this became inadequate
  with the release of the i386 in ~1986, and FreeBSD passes it other
  trap types for NMIs and panics.
  
  On x86, teach ddb when a trap is for single stepping using the %dr6
  register.  Unknown traps are now treated almost the same as breakpoints
  instead of as the same as single-steps.  Previously, the classification
  of breakpoints was almost correct and everything else was unknown so
  had to be treated as a single-step.  Now the classification of single-
  steps is precise, the classification of breakpoints is almost correct
  (as before) and everything else is unknown and treated like a
  breakpoint.
  
  This fixes:
  - breakpoints not set by ddb, including the main one in kdb_enter(),
were treated as single-steps and not stopped on when stepping
(except for the usual, simple case of a step with residual count 1).
As special cases, kdb_enter() didn't stop for fatal traps or panics
  - similarly for "hardware breakpoints".
  
  Use a new MD macro IS_SSTEP_TRAP(type, code) to code to classify
  single-steps.  This is excessively complicated for bug-for-bug and
  backwards compatibilty.  Design errors apparently started in Mach
  in ~1990 or perhaps in the FreeBSD interface in ~1993.  Common trap
  types like single steps should have a unique MI code (like the TRAP*
  codes for user SIGTRAP) so that debuggers don't need macros like
  IS_SSTEP_TRAP() to decode them.  But 'type' is actually an ambiguous
  MD trap number, and code was always 0 (now it is (int)%dr6 on x86).
  So it was impossible to determine the trap type from the args.
  Global variables had to be used.
  
  There is already a classification macro db_pc_is_single_step(), but
  this just gets in the way.  It is only used to recover from bugs in
  IS_BREAKPOINT_TRAP().  On some arches, IS_BREAKPOINT_TRAP() just
  duplicates the ambiguity in 'type' and misclassifies single-steps as
  breakpoints.  It defaults to 'false', which is the opposite of what is
  needed for bug-for-bug compatibility.
  
  When this is cleaned up, MI classification bits should be passed in
  'code'.  This could be done now for positive-logic bits, since 'code'
  was always 0, but some negative logic is needed for compatibility so
  a simple MI classificition is not usable yet.
  
  After reading %dr6, clear the single-step bit in it so that the type
  of the next debugger trap can be decoded.  This is a little
  ddb-specific.  ddb doesn't understand the need to clear this bit and
  doing it before calling kdb is easiest.  gdb would need to reverse
  this to support hardware breakpoints, but it just doesn't support
  them now since gdbstub doesn't support %dr*.
  
  Fix a bug involving %dr6: when emulating a single-step trap for vm86,
  set the bit for it in %dr6.  Userland debuggers need this.  ddb now
  needs this for vm86 bios calls.  The bit gets copied to 'code' then
  cleared again.
  
  Fix related style bugs:
  - when clearing bits for hardware breakpoints in %dr6, spell the mask
as ~0xf on both amd64 and i386 to get the correct number of bits
using sign extension and not need a comment about using the wrong
mask on amd64 (amd64 traps for invalid results but clearing the
reserved top bits didn't trap since they are 0).
  - rewrite my old wrong comments about using %dr6 for ddb watchpoints.

Modified:
  head/sys/amd64/amd64/trap.c
  head/sys/amd64/include/db_machdep.h
  head/sys/ddb/db_run.c
  head/sys/i386/i386/trap.c
  head/sys/i386/include/db_machdep.h

Modified: head/sys/amd64/amd64/trap.c
==
--- head/sys/amd64/amd64/trap.c Thu Sep 15 17:24:11 2016(r305839)
+++ head/sys/amd64/amd64/trap.c Thu Sep 15 17:24:23 2016(r305840)
@@ -176,6 +176,7 @@ trap(struct trapframe *frame)
 #endif
struct thread *td = curthread;
struct proc *p = td->td_proc;
+   register_t dr6;
int i = 0, ucode = 0, code;
u_int type;
register_t addr = 0;
@@ -540,8 +541,7 @@ trap(struct trapframe *frame)
 * Reset breakpoint bits because the
 * processor doesn't
 */
-   /* XXX check upper bits here */
-   load_dr6(rdr6() & 0xfff0);
+   load_dr6(rdr6() & ~0xf);
goto out;
}
/*
@@ -553,7 +553,10 @@ trap(struct trapframe *frame)
 * Otherwise, debugger trap

svn commit: r305839 - stable/11/contrib/elftoolchain/libelftc

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:24:11 2016
New Revision: 305839
URL: https://svnweb.freebsd.org/changeset/base/305839

Log:
  MFC r304160: elfcopy: add elf64-littleaarch64 output target support

Modified:
  stable/11/contrib/elftoolchain/libelftc/elftc_bfd_find_target.3
  stable/11/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/elftoolchain/libelftc/elftc_bfd_find_target.3
==
--- stable/11/contrib/elftoolchain/libelftc/elftc_bfd_find_target.3 Thu Sep 
15 17:23:14 2016(r305838)
+++ stable/11/contrib/elftoolchain/libelftc/elftc_bfd_find_target.3 Thu Sep 
15 17:24:11 2016(r305839)
@@ -89,6 +89,7 @@ Known descriptor names and their propert
 .It Li elf64-ia64-big Ta ELF Ta MSB Ta 64
 .It Li elf64-ia64-little Ta ELF Ta LSB Ta 64
 .It Li elf64-little Ta ELF Ta LSB Ta 64
+.It Li elf64-littleaarch64 Ta ELF Ta LSB Ta 64
 .It Li elf64-littlemips Ta ELF Ta LSB Ta 64
 .It Li elf64-powerpc Ta ELF Ta MSB Ta 64
 .It Li elf64-powerpcle Ta ELF Ta LSB Ta 64

Modified: stable/11/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c
==
--- stable/11/contrib/elftoolchain/libelftc/libelftc_bfdtarget.cThu Sep 
15 17:23:14 2016(r305838)
+++ stable/11/contrib/elftoolchain/libelftc/libelftc_bfdtarget.cThu Sep 
15 17:24:11 2016(r305839)
@@ -250,6 +250,14 @@ struct _Elftc_Bfd_Target _libelftc_targe
},
 
{
+   .bt_name  = "elf64-littleaarch64",
+   .bt_type  = ETF_ELF,
+   .bt_byteorder = ELFDATA2LSB,
+   .bt_elfclass  = ELFCLASS64,
+   .bt_machine   = EM_AARCH64,
+   },
+
+   {
.bt_name  = "elf64-littlemips",
.bt_type  = ETF_ELF,
.bt_byteorder = ELFDATA2LSB,
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305838 - stable/11/contrib/elftoolchain/elfcopy

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:23:14 2016
New Revision: 305838
URL: https://svnweb.freebsd.org/changeset/base/305838

Log:
  MFC r304151: elfcopy: silence GCC 5.3 unitialized variable warning
  
  Although it's a false positive there is little cost to initializing it
  always.

Modified:
  stable/11/contrib/elftoolchain/elfcopy/ascii.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/elftoolchain/elfcopy/ascii.c
==
--- stable/11/contrib/elftoolchain/elfcopy/ascii.c  Thu Sep 15 17:22:35 
2016(r305837)
+++ stable/11/contrib/elftoolchain/elfcopy/ascii.c  Thu Sep 15 17:23:14 
2016(r305838)
@@ -251,6 +251,7 @@ create_elf_from_srec(struct elfcopy *ecp
sec_index = 1;
sec_addr = entry = 0;
while (fgets(line, _LINE_BUFSZ, ifp) != NULL) {
+   sz = 0; /* Silence GCC 5.3 unintialized variable warning */
if (line[0] == '\r' || line[0] == '\n')
continue;
if (line[0] == '$' && line[1] == '$') {
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305837 - stable/11/contrib/elftoolchain/readelf

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 17:22:35 2016
New Revision: 305837
URL: https://svnweb.freebsd.org/changeset/base/305837

Log:
  MFC r303674: readelf: report ARM program and section header types

Modified:
  stable/11/contrib/elftoolchain/readelf/readelf.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/elftoolchain/readelf/readelf.c
==
--- stable/11/contrib/elftoolchain/readelf/readelf.cThu Sep 15 17:05:54 
2016(r305836)
+++ stable/11/contrib/elftoolchain/readelf/readelf.cThu Sep 15 17:22:35 
2016(r305837)
@@ -343,7 +343,7 @@ static const char *note_type_openbsd(uns
 static const char *note_type_unknown(unsigned int nt);
 static const char *note_type_xen(unsigned int nt);
 static const char *option_kind(uint8_t kind);
-static const char *phdr_type(unsigned int ptype);
+static const char *phdr_type(unsigned int mach, unsigned int ptype);
 static const char *ppc_abi_fp(uint64_t fp);
 static const char *ppc_abi_vector(uint64_t vec);
 static void readelf_usage(int status);
@@ -622,10 +622,24 @@ elf_ver(unsigned int ver)
 }
 
 static const char *
-phdr_type(unsigned int ptype)
+phdr_type(unsigned int mach, unsigned int ptype)
 {
static char s_ptype[32];
 
+   if (ptype >= PT_LOPROC && ptype <= PT_HIPROC) {
+   switch (mach) {
+   case EM_ARM:
+   switch (ptype) {
+   case PT_ARM_ARCHEXT: return "ARM_ARCHEXT";
+   case PT_ARM_EXIDX: return "ARM_EXIDX";
+   }
+   break;
+   }
+   snprintf(s_ptype, sizeof(s_ptype), "LOPROC+%#x",
+   ptype - PT_LOPROC);
+   return (s_ptype);
+   }
+
switch (ptype) {
case PT_NULL: return "NULL";
case PT_LOAD: return "LOAD";
@@ -639,10 +653,7 @@ phdr_type(unsigned int ptype)
case PT_GNU_STACK: return "GNU_STACK";
case PT_GNU_RELRO: return "GNU_RELRO";
default:
-   if (ptype >= PT_LOPROC && ptype <= PT_HIPROC)
-   snprintf(s_ptype, sizeof(s_ptype), "LOPROC+%#x",
-   ptype - PT_LOPROC);
-   else if (ptype >= PT_LOOS && ptype <= PT_HIOS)
+   if (ptype >= PT_LOOS && ptype <= PT_HIOS)
snprintf(s_ptype, sizeof(s_ptype), "LOOS+%#x",
ptype - PT_LOOS);
else
@@ -659,6 +670,15 @@ section_type(unsigned int mach, unsigned
 
if (stype >= SHT_LOPROC && stype <= SHT_HIPROC) {
switch (mach) {
+   case EM_ARM:
+   switch (stype) {
+   case SHT_ARM_EXIDX: return "ARM_EXIDX";
+   case SHT_ARM_PREEMPTMAP: return "ARM_PREEMPTMAP";
+   case SHT_ARM_ATTRIBUTES: return "ARM_ATTRIBUTES";
+   case SHT_ARM_DEBUGOVERLAY: return "ARM_DEBUGOVERLAY";
+   case SHT_ARM_OVERLAYSECTION: return 
"ARM_OVERLAYSECTION";
+   }
+   break;
case EM_X86_64:
switch (stype) {
case SHT_X86_64_UNWIND: return "X86_64_UNWIND";
@@ -2273,9 +2293,10 @@ dump_phdr(struct readelf *re)
 
 #definePH_HDR  "Type", "Offset", "VirtAddr", "PhysAddr", "FileSiz",
\
"MemSiz", "Flg", "Align"
-#definePH_CT   phdr_type(phdr.p_type), (uintmax_t)phdr.p_offset,   
\
-   (uintmax_t)phdr.p_vaddr, (uintmax_t)phdr.p_paddr,   \
-   (uintmax_t)phdr.p_filesz, (uintmax_t)phdr.p_memsz,  \
+#definePH_CT   phdr_type(re->ehdr.e_machine, phdr.p_type), 
\
+   (uintmax_t)phdr.p_offset, (uintmax_t)phdr.p_vaddr,  \
+   (uintmax_t)phdr.p_paddr, (uintmax_t)phdr.p_filesz,  \
+   (uintmax_t)phdr.p_memsz,\
phdr.p_flags & PF_R ? 'R' : ' ',\
phdr.p_flags & PF_W ? 'W' : ' ',\
phdr.p_flags & PF_X ? 'E' : ' ',\
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305836 - in head/sys: amd64/amd64 amd64/include compat/linprocfs i386/include x86/include x86/x86

2016-09-15 Thread John Baldwin
Author: jhb
Date: Thu Sep 15 17:05:54 2016
New Revision: 305836
URL: https://svnweb.freebsd.org/changeset/base/305836

Log:
  Remove 'cpu' and 'cpu_class' on amd64.
  
  The 'cpu' and 'cpu_class' variables were always set to the same value
  on amd64 and are legacy holdovers from i386.  Remove them entirely on
  amd64.
  
  Reviewed by:  imp, kib (older version)
  Differential Revision:https://reviews.freebsd.org/D7888

Modified:
  head/sys/amd64/amd64/machdep.c
  head/sys/amd64/include/cputypes.h
  head/sys/compat/linprocfs/linprocfs.c
  head/sys/i386/include/cputypes.h
  head/sys/i386/include/md_var.h
  head/sys/x86/include/cputypes.h
  head/sys/x86/include/x86_var.h
  head/sys/x86/x86/identcpu.c

Modified: head/sys/amd64/amd64/machdep.c
==
--- head/sys/amd64/amd64/machdep.c  Thu Sep 15 15:32:40 2016
(r305835)
+++ head/sys/amd64/amd64/machdep.c  Thu Sep 15 17:05:54 2016
(r305836)
@@ -269,7 +269,6 @@ cpu_startup(dummy)
 */
startrtclock();
printcpuinfo();
-   panicifcpuunsupported();
 
/*
 * Display physical memory if SMBIOS reports reasonable amount.

Modified: head/sys/amd64/include/cputypes.h
==
--- head/sys/amd64/include/cputypes.h   Thu Sep 15 15:32:40 2016
(r305835)
+++ head/sys/amd64/include/cputypes.h   Thu Sep 15 17:05:54 2016
(r305836)
@@ -1,48 +1,6 @@
 /*-
- * Copyright (c) 1993 Christopher G. Demetriou
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *notice, this list of conditions and the following disclaimer in the
- *documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- *derived from this software without specific prior written permission
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- * $FreeBSD$
+ * This file is in the public domain.
  */
-
-#ifndef _MACHINE_CPUTYPES_H_
-#define_MACHINE_CPUTYPES_H_
+/* $FreeBSD$ */
 
 #include 
-
-/*
- * Classes of processor.
- */
-#defineCPUCLASS_X860   /* X86 */
-#defineCPUCLASS_K8 1   /* K8 AMD64 class */
-
-/*
- * Kinds of processor.
- */
-#defineCPU_X86 0   /* Intel */
-#defineCPU_CLAWHAMMER  1   /* AMD Clawhammer */
-#defineCPU_SLEDGEHAMMER2   /* AMD Sledgehammer */
-
-#endif /* !_MACHINE_CPUTYPES_H_ */

Modified: head/sys/compat/linprocfs/linprocfs.c
==
--- head/sys/compat/linprocfs/linprocfs.c   Thu Sep 15 15:32:40 2016
(r305835)
+++ head/sys/compat/linprocfs/linprocfs.c   Thu Sep 15 17:05:54 2016
(r305836)
@@ -218,7 +218,7 @@ linprocfs_docpuinfo(PFS_FILL_ARGS)
char model[128];
uint64_t freq;
size_t size;
-   int class, fqmhz, fqkhz;
+   int fqmhz, fqkhz;
int i;
 
/*
@@ -235,33 +235,6 @@ linprocfs_docpuinfo(PFS_FILL_ARGS)
"3dnowext", "3dnow"
};
 
-   switch (cpu_class) {
-#ifdef __i386__
-   case CPUCLASS_286:
-   class = 2;
-   break;
-   case CPUCLASS_386:
-   class = 3;
-   break;
-   case CPUCLASS_486:
-   class = 4;
-   break;
-   case CPUCLASS_586:
-   class = 5;
-   break;
-   case CPUCLASS_686:
-   class = 6;
-   break;
-   default:
-   class = 0;
-   break;
-#else /* __amd64__ */
-   default:
-   class = 15;
-   break;
-#endif
-   }
-
hw_model[0] = CTL_HW;
hw_model[1] = HW_MODEL;
model[0] = '\0';
@@ -286,7 +259,7 @@ linprocfs_docpuinfo(PFS_FILL_AR

svn commit: r305834 - head/sys/fs/nullfs

2016-09-15 Thread Edward Tomasz Napierala
Author: trasz
Date: Thu Sep 15 13:57:37 2016
New Revision: 305834
URL: https://svnweb.freebsd.org/changeset/base/305834

Log:
  Change the getnewvnode(9) tag for nullfs from "null" to "nullfs".
  It's more consistent, and besides, the "null" alone looks weird.
  
  MFC after:1 month

Modified:
  head/sys/fs/nullfs/null_subr.c

Modified: head/sys/fs/nullfs/null_subr.c
==
--- head/sys/fs/nullfs/null_subr.c  Thu Sep 15 13:40:36 2016
(r305833)
+++ head/sys/fs/nullfs/null_subr.c  Thu Sep 15 13:57:37 2016
(r305834)
@@ -238,7 +238,7 @@ null_nodeget(mp, lowervp, vpp)
 */
xp = malloc(sizeof(struct null_node), M_NULLFSNODE, M_WAITOK);
 
-   error = getnewvnode("null", mp, &null_vnodeops, &vp);
+   error = getnewvnode("nullfs", mp, &null_vnodeops, &vp);
if (error) {
vput(lowervp);
free(xp, M_NULLFSNODE);
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r305824 - in head/sys: contrib/ipfilter/netinet kern net netinet netinet6 netipsec sys

2016-09-15 Thread Kevin Lo
On Thu, Sep 15, 2016 at 12:58:33AM -0700, Ngie Cooper (yaneurabeya) wrote:
> 
> > On Sep 15, 2016, at 00:41, Kevin Lo  wrote:
> > 
> > Author: kevlo
> > Date: Thu Sep 15 07:41:48 2016
> > New Revision: 305824
> > URL: https://svnweb.freebsd.org/changeset/base/305824
> > 
> > Log:
> >  Remove the 4.3BSD compatible macro m_copy(), use m_copym() instead.
> > 
> >  Reviewed by:   gnn
> >  Differential Revision: https://reviews.freebsd.org/D7878
> > 
> > Modified:
> >  head/sys/contrib/ipfilter/netinet/fil.c
> >  head/sys/contrib/ipfilter/netinet/ip_compat.h
> >  head/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c
> >  head/sys/kern/uipc_socket.c
> >  head/sys/net/if_arcsubr.c
> >  head/sys/net/if_fddisubr.c
> >  head/sys/net/if_iso88025subr.c
> >  head/sys/net/raw_usrreq.c
> >  head/sys/netinet/ip_input.c
> >  head/sys/netinet/ip_mroute.c
> >  head/sys/netinet/raw_ip.c
> >  head/sys/netinet/tcp_output.c
> >  head/sys/netinet/udp_usrreq.c
> >  head/sys/netinet6/icmp6.c
> >  head/sys/netinet6/ip6_forward.c
> >  head/sys/netinet6/ip6_mroute.c
> >  head/sys/netinet6/ip6_output.c
> >  head/sys/netinet6/raw_ip6.c
> >  head/sys/netinet6/udp6_usrreq.c
> >  head/sys/netipsec/keysock.c
> >  head/sys/sys/mbuf.h
> 
> Bump __FreeBSD_version for the change (just in case something’s using the 
> #define elsewhere)?

Bumped(r305833), thanks.

> Thanks!
> -Ngie

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

svn commit: r305833 - head/sys/sys

2016-09-15 Thread Kevin Lo
Author: kevlo
Date: Thu Sep 15 13:40:36 2016
New Revision: 305833
URL: https://svnweb.freebsd.org/changeset/base/305833

Log:
  Bump __FreeBSD_version for r305824.
  
  Suggested by: ngie

Modified:
  head/sys/sys/param.h

Modified: head/sys/sys/param.h
==
--- head/sys/sys/param.hThu Sep 15 13:16:20 2016(r305832)
+++ head/sys/sys/param.hThu Sep 15 13:40:36 2016(r305833)
@@ -58,7 +58,7 @@
  * in the range 5 to 9.
  */
 #undef __FreeBSD_version
-#define __FreeBSD_version 127  /* Master, propagated to newvers */
+#define __FreeBSD_version 128  /* Master, propagated to newvers */
 
 /*
  * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD,
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305832 - head/sys/kern

2016-09-15 Thread Ed Maste
Author: emaste
Date: Thu Sep 15 13:16:20 2016
New Revision: 305832
URL: https://svnweb.freebsd.org/changeset/base/305832

Log:
  Renumber license clauses in sys/kern to avoid skipping #3

Modified:
  head/sys/kern/kern_acct.c
  head/sys/kern/kern_clock.c
  head/sys/kern/kern_cons.c
  head/sys/kern/kern_descrip.c
  head/sys/kern/kern_exit.c
  head/sys/kern/kern_fork.c
  head/sys/kern/kern_ktrace.c
  head/sys/kern/kern_lockf.c
  head/sys/kern/kern_malloc.c
  head/sys/kern/kern_mib.c
  head/sys/kern/kern_proc.c
  head/sys/kern/kern_prot.c
  head/sys/kern/kern_resource.c
  head/sys/kern/kern_sendfile.c
  head/sys/kern/kern_shutdown.c
  head/sys/kern/kern_sig.c
  head/sys/kern/kern_synch.c
  head/sys/kern/kern_sysctl.c
  head/sys/kern/kern_time.c
  head/sys/kern/kern_timeout.c
  head/sys/kern/kern_xxx.c
  head/sys/kern/sched_4bsd.c
  head/sys/kern/subr_autoconf.c
  head/sys/kern/subr_blist.c
  head/sys/kern/subr_clock.c
  head/sys/kern/subr_hash.c
  head/sys/kern/subr_log.c
  head/sys/kern/subr_mchain.c
  head/sys/kern/subr_param.c
  head/sys/kern/subr_pcpu.c
  head/sys/kern/subr_prf.c
  head/sys/kern/subr_prof.c
  head/sys/kern/subr_rtc.c
  head/sys/kern/subr_scanf.c
  head/sys/kern/subr_uio.c
  head/sys/kern/sys_generic.c
  head/sys/kern/sys_socket.c
  head/sys/kern/tty_compat.c
  head/sys/kern/tty_info.c
  head/sys/kern/uipc_domain.c
  head/sys/kern/uipc_mbuf.c
  head/sys/kern/uipc_mbuf2.c
  head/sys/kern/uipc_sockbuf.c
  head/sys/kern/uipc_socket.c
  head/sys/kern/uipc_syscalls.c
  head/sys/kern/uipc_usrreq.c
  head/sys/kern/vfs_cache.c
  head/sys/kern/vfs_cluster.c
  head/sys/kern/vfs_default.c
  head/sys/kern/vfs_export.c
  head/sys/kern/vfs_init.c
  head/sys/kern/vfs_lookup.c
  head/sys/kern/vfs_mount.c
  head/sys/kern/vfs_mountroot.c
  head/sys/kern/vfs_subr.c
  head/sys/kern/vfs_syscalls.c
  head/sys/kern/vfs_vnops.c
  head/sys/kern/vnode_if.src

Modified: head/sys/kern/kern_acct.c
==
--- head/sys/kern/kern_acct.c   Thu Sep 15 08:38:53 2016(r305831)
+++ head/sys/kern/kern_acct.c   Thu Sep 15 13:16:20 2016(r305832)
@@ -18,7 +18,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.
  *

Modified: head/sys/kern/kern_clock.c
==
--- head/sys/kern/kern_clock.c  Thu Sep 15 08:38:53 2016(r305831)
+++ head/sys/kern/kern_clock.c  Thu Sep 15 13:16:20 2016(r305832)
@@ -15,7 +15,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.
  *

Modified: head/sys/kern/kern_cons.c
==
--- head/sys/kern/kern_cons.c   Thu Sep 15 08:38:53 2016(r305831)
+++ head/sys/kern/kern_cons.c   Thu Sep 15 13:16:20 2016(r305832)
@@ -18,7 +18,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.
  *

Modified: head/sys/kern/kern_descrip.c
==
--- head/sys/kern/kern_descrip.cThu Sep 15 08:38:53 2016
(r305831)
+++ head/sys/kern/kern_descrip.cThu Sep 15 13:16:20 2016
(r305832)
@@ -15,7 +15,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 so

svn commit: r305831 - stable/8/sys/dev/usb/input

2016-09-15 Thread Hans Petter Selasky
Author: hselasky
Date: Thu Sep 15 08:38:53 2016
New Revision: 305831
URL: https://svnweb.freebsd.org/changeset/base/305831

Log:
  MFC r305590:
  Correctly map the USB mouse tilt delta values into buttons 5 and 6
  instead of 3 and 4 which is used for the scroll wheel, according to
  X.org.
  
  PR:   170358

Modified:
  stable/8/sys/dev/usb/input/ums.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)
  stable/8/sys/dev/usb/   (props changed)

Modified: stable/8/sys/dev/usb/input/ums.c
==
--- stable/8/sys/dev/usb/input/ums.cThu Sep 15 08:37:20 2016
(r305830)
+++ stable/8/sys/dev/usb/input/ums.cThu Sep 15 08:38:53 2016
(r305831)
@@ -288,9 +288,9 @@ ums_intr_callback(struct usb_xfer *xfer,
 
/* translate T-axis into button presses until further */
if (dt > 0)
-   buttons |= 1UL << 3;
+   buttons |= 1UL << 5;
else if (dt < 0)
-   buttons |= 1UL << 4;
+   buttons |= 1UL << 6;
 
sc->sc_status.button = buttons;
sc->sc_status.dx += dx;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305830 - stable/9/sys/dev/usb/input

2016-09-15 Thread Hans Petter Selasky
Author: hselasky
Date: Thu Sep 15 08:37:20 2016
New Revision: 305830
URL: https://svnweb.freebsd.org/changeset/base/305830

Log:
  MFC r305590:
  Correctly map the USB mouse tilt delta values into buttons 5 and 6
  instead of 3 and 4 which is used for the scroll wheel, according to
  X.org.
  
  PR:   170358

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

Modified: stable/9/sys/dev/usb/input/ums.c
==
--- stable/9/sys/dev/usb/input/ums.cThu Sep 15 08:35:46 2016
(r305829)
+++ stable/9/sys/dev/usb/input/ums.cThu Sep 15 08:37:20 2016
(r305830)
@@ -288,9 +288,9 @@ ums_intr_callback(struct usb_xfer *xfer,
 
/* translate T-axis into button presses until further */
if (dt > 0)
-   buttons |= 1UL << 3;
+   buttons |= 1UL << 5;
else if (dt < 0)
-   buttons |= 1UL << 4;
+   buttons |= 1UL << 6;
 
sc->sc_status.button = buttons;
sc->sc_status.dx += dx;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305829 - stable/10/sys/dev/usb/input

2016-09-15 Thread Hans Petter Selasky
Author: hselasky
Date: Thu Sep 15 08:35:46 2016
New Revision: 305829
URL: https://svnweb.freebsd.org/changeset/base/305829

Log:
  MFC r305590:
  Correctly map the USB mouse tilt delta values into buttons 5 and 6
  instead of 3 and 4 which is used for the scroll wheel, according to
  X.org.
  
  PR:   170358

Modified:
  stable/10/sys/dev/usb/input/ums.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/usb/input/ums.c
==
--- stable/10/sys/dev/usb/input/ums.c   Thu Sep 15 08:34:16 2016
(r305828)
+++ stable/10/sys/dev/usb/input/ums.c   Thu Sep 15 08:35:46 2016
(r305829)
@@ -288,9 +288,9 @@ ums_intr_callback(struct usb_xfer *xfer,
 
/* translate T-axis into button presses until further */
if (dt > 0)
-   buttons |= 1UL << 3;
+   buttons |= 1UL << 5;
else if (dt < 0)
-   buttons |= 1UL << 4;
+   buttons |= 1UL << 6;
 
sc->sc_status.button = buttons;
sc->sc_status.dx += dx;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305828 - stable/11/sys/dev/usb/input

2016-09-15 Thread Hans Petter Selasky
Author: hselasky
Date: Thu Sep 15 08:34:16 2016
New Revision: 305828
URL: https://svnweb.freebsd.org/changeset/base/305828

Log:
  MFC r305590:
  Correctly map the USB mouse tilt delta values into buttons 5 and 6
  instead of 3 and 4 which is used for the scroll wheel, according to
  X.org.
  
  PR:   170358

Modified:
  stable/11/sys/dev/usb/input/ums.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/dev/usb/input/ums.c
==
--- stable/11/sys/dev/usb/input/ums.c   Thu Sep 15 08:30:47 2016
(r305827)
+++ stable/11/sys/dev/usb/input/ums.c   Thu Sep 15 08:34:16 2016
(r305828)
@@ -288,9 +288,9 @@ ums_intr_callback(struct usb_xfer *xfer,
 
/* translate T-axis into button presses until further */
if (dt > 0)
-   buttons |= 1UL << 3;
+   buttons |= 1UL << 5;
else if (dt < 0)
-   buttons |= 1UL << 4;
+   buttons |= 1UL << 6;
 
sc->sc_status.button = buttons;
sc->sc_status.dx += dx;
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305827 - head/sys/dev/cxgbe

2016-09-15 Thread Navdeep Parhar
Author: np
Date: Thu Sep 15 08:30:47 2016
New Revision: 305827
URL: https://svnweb.freebsd.org/changeset/base/305827

Log:
  cxgbe(4): Use the interface's viid to calculate the PF/VF/VFValid fields
  to use in tx work requests.

Modified:
  head/sys/dev/cxgbe/t4_sge.c

Modified: head/sys/dev/cxgbe/t4_sge.c
==
--- head/sys/dev/cxgbe/t4_sge.c Thu Sep 15 08:26:59 2016(r305826)
+++ head/sys/dev/cxgbe/t4_sge.c Thu Sep 15 08:30:47 2016(r305827)
@@ -3253,8 +3253,9 @@ alloc_nm_txq(struct vi_info *vi, struct 
nm_txq->nid = idx;
nm_txq->iqidx = iqidx;
nm_txq->cpl_ctrl0 = htobe32(V_TXPKT_OPCODE(CPL_TX_PKT) |
-   V_TXPKT_INTF(pi->tx_chan) | V_TXPKT_VF_VLD(1) |
-   V_TXPKT_VF(vi->viid));
+   V_TXPKT_INTF(pi->tx_chan) | V_TXPKT_PF(G_FW_VIID_PFN(vi->viid)) |
+   V_TXPKT_VF(G_FW_VIID_VIN(vi->viid)) |
+   V_TXPKT_VF_VLD(G_FW_VIID_VIVLD(vi->viid)));
 
snprintf(name, sizeof(name), "%d", idx);
oid = SYSCTL_ADD_NODE(&vi->ctx, children, OID_AUTO, name, CTLFLAG_RD,
@@ -3620,8 +3621,10 @@ alloc_txq(struct vi_info *vi, struct sge
V_TXPKT_INTF(pi->tx_chan));
else
txq->cpl_ctrl0 = htobe32(V_TXPKT_OPCODE(CPL_TX_PKT) |
-   V_TXPKT_INTF(pi->tx_chan) | V_TXPKT_VF_VLD(1) |
-   V_TXPKT_VF(vi->viid));
+   V_TXPKT_INTF(pi->tx_chan) |
+   V_TXPKT_PF(G_FW_VIID_PFN(vi->viid)) |
+   V_TXPKT_VF(G_FW_VIID_VIN(vi->viid)) |
+   V_TXPKT_VF_VLD(G_FW_VIID_VIVLD(vi->viid)));
txq->tc_idx = -1;
txq->sdesc = malloc(eq->sidx * sizeof(struct tx_sdesc), M_CXGBE,
M_ZERO | M_WAITOK);
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305826 - stable/10/sys/x86/x86

2016-09-15 Thread Konstantin Belousov
Author: kib
Date: Thu Sep 15 08:26:59 2016
New Revision: 305826
URL: https://svnweb.freebsd.org/changeset/base/305826

Log:
  MFC r305744:
  Fix typo in comment.

Modified:
  stable/10/sys/x86/x86/identcpu.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/x86/x86/identcpu.c
==
--- stable/10/sys/x86/x86/identcpu.cThu Sep 15 08:25:13 2016
(r305825)
+++ stable/10/sys/x86/x86/identcpu.cThu Sep 15 08:26:59 2016
(r305826)
@@ -1683,7 +1683,7 @@ print_AMD_info(void)
 * As long as that bug pops up very rarely (intensive machine usage
 * on other operating systems generally generates one unexplainable
 * crash any 2 months) and as long as a model specific fix would be
-* impratical at this stage, print out a warning string if the broken
+* impractical at this stage, print out a warning string if the broken
 * model and family are identified.
 */
if (CPUID_TO_FAMILY(cpu_id) == 0xf && CPUID_TO_MODEL(cpu_id) >= 0x20 &&
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


svn commit: r305825 - stable/11/sys/x86/x86

2016-09-15 Thread Konstantin Belousov
Author: kib
Date: Thu Sep 15 08:25:13 2016
New Revision: 305825
URL: https://svnweb.freebsd.org/changeset/base/305825

Log:
  MFC r305744:
  Fix typo in comment.

Modified:
  stable/11/sys/x86/x86/identcpu.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/x86/x86/identcpu.c
==
--- stable/11/sys/x86/x86/identcpu.cThu Sep 15 07:41:48 2016
(r305824)
+++ stable/11/sys/x86/x86/identcpu.cThu Sep 15 08:25:13 2016
(r305825)
@@ -1725,7 +1725,7 @@ print_AMD_info(void)
 * As long as that bug pops up very rarely (intensive machine usage
 * on other operating systems generally generates one unexplainable
 * crash any 2 months) and as long as a model specific fix would be
-* impratical at this stage, print out a warning string if the broken
+* impractical at this stage, print out a warning string if the broken
 * model and family are identified.
 */
if (CPUID_TO_FAMILY(cpu_id) == 0xf && CPUID_TO_MODEL(cpu_id) >= 0x20 &&
___
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r305824 - in head/sys: contrib/ipfilter/netinet kern net netinet netinet6 netipsec sys

2016-09-15 Thread Ngie Cooper (yaneurabeya)

> On Sep 15, 2016, at 00:41, Kevin Lo  wrote:
> 
> Author: kevlo
> Date: Thu Sep 15 07:41:48 2016
> New Revision: 305824
> URL: https://svnweb.freebsd.org/changeset/base/305824
> 
> Log:
>  Remove the 4.3BSD compatible macro m_copy(), use m_copym() instead.
> 
>  Reviewed by: gnn
>  Differential Revision:   https://reviews.freebsd.org/D7878
> 
> Modified:
>  head/sys/contrib/ipfilter/netinet/fil.c
>  head/sys/contrib/ipfilter/netinet/ip_compat.h
>  head/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c
>  head/sys/kern/uipc_socket.c
>  head/sys/net/if_arcsubr.c
>  head/sys/net/if_fddisubr.c
>  head/sys/net/if_iso88025subr.c
>  head/sys/net/raw_usrreq.c
>  head/sys/netinet/ip_input.c
>  head/sys/netinet/ip_mroute.c
>  head/sys/netinet/raw_ip.c
>  head/sys/netinet/tcp_output.c
>  head/sys/netinet/udp_usrreq.c
>  head/sys/netinet6/icmp6.c
>  head/sys/netinet6/ip6_forward.c
>  head/sys/netinet6/ip6_mroute.c
>  head/sys/netinet6/ip6_output.c
>  head/sys/netinet6/raw_ip6.c
>  head/sys/netinet6/udp6_usrreq.c
>  head/sys/netipsec/keysock.c
>  head/sys/sys/mbuf.h

Bump __FreeBSD_version for the change (just in case something’s using the 
#define elsewhere)?
Thanks!
-Ngie


signature.asc
Description: Message signed with OpenPGP using GPGMail


svn commit: r305824 - in head/sys: contrib/ipfilter/netinet kern net netinet netinet6 netipsec sys

2016-09-15 Thread Kevin Lo
Author: kevlo
Date: Thu Sep 15 07:41:48 2016
New Revision: 305824
URL: https://svnweb.freebsd.org/changeset/base/305824

Log:
  Remove the 4.3BSD compatible macro m_copy(), use m_copym() instead.
  
  Reviewed by:  gnn
  Differential Revision:https://reviews.freebsd.org/D7878

Modified:
  head/sys/contrib/ipfilter/netinet/fil.c
  head/sys/contrib/ipfilter/netinet/ip_compat.h
  head/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c
  head/sys/kern/uipc_socket.c
  head/sys/net/if_arcsubr.c
  head/sys/net/if_fddisubr.c
  head/sys/net/if_iso88025subr.c
  head/sys/net/raw_usrreq.c
  head/sys/netinet/ip_input.c
  head/sys/netinet/ip_mroute.c
  head/sys/netinet/raw_ip.c
  head/sys/netinet/tcp_output.c
  head/sys/netinet/udp_usrreq.c
  head/sys/netinet6/icmp6.c
  head/sys/netinet6/ip6_forward.c
  head/sys/netinet6/ip6_mroute.c
  head/sys/netinet6/ip6_output.c
  head/sys/netinet6/raw_ip6.c
  head/sys/netinet6/udp6_usrreq.c
  head/sys/netipsec/keysock.c
  head/sys/sys/mbuf.h

Modified: head/sys/contrib/ipfilter/netinet/fil.c
==
--- head/sys/contrib/ipfilter/netinet/fil.c Thu Sep 15 02:48:56 2016
(r305823)
+++ head/sys/contrib/ipfilter/netinet/fil.c Thu Sep 15 07:41:48 2016
(r305824)
@@ -3226,7 +3226,7 @@ filterdone:
fdp = fin->fin_dif;
if ((fdp != NULL) && (fdp->fd_ptr != NULL) &&
(fdp->fd_ptr != (void *)-1)) {
-   mc = M_COPY(fin->fin_m);
+   mc = M_COPYM(fin->fin_m);
if (mc != NULL)
ipf_fastroute(mc, &mc, fin, fdp);
}

Modified: head/sys/contrib/ipfilter/netinet/ip_compat.h
==
--- head/sys/contrib/ipfilter/netinet/ip_compat.h   Thu Sep 15 02:48:56 
2016(r305823)
+++ head/sys/contrib/ipfilter/netinet/ip_compat.h   Thu Sep 15 07:41:48 
2016(r305824)
@@ -211,7 +211,7 @@ struct  ether_addr {
 #  define  MSGDSIZE(m) mbufchainlen(m)
 #  define  M_LEN(m)(m)->m_len
 #  define  M_ADJ(m,x)  m_adj(m, x)
-#  define  M_COPY(x)   m_copy((x), 0, M_COPYALL)
+#  define  M_COPYM(x)  m_copym((x), 0, M_COPYALL, M_NOWAIT)
 #  define  M_DUP(m)m_dup(m, M_NOWAIT)
 #  define  IPF_PANIC(x,y)  if (x) { printf y; panic("ipf_panic"); }
 typedef struct mbuf mb_t;
@@ -366,7 +366,7 @@ typedef struct  mb_s{
 # define   MSGDSIZE(m) msgdsize(m)
 # define   M_LEN(m)(m)->mb_len
 # define   M_ADJ(m,x)  (m)->mb_len += x
-# define   M_COPY(m)   dupmbt(m)
+# define   M_COPYM(m)  dupmbt(m)
 # define   M_DUP(m)dupmbt(m)
 # define   GETKTIME(x) gettimeofday((struct timeval *)(x), NULL)
 # define   MTOD(m, t)  ((t)(m)->mb_data)

Modified: head/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c
==
--- head/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c  Thu Sep 15 02:48:56 
2016(r305823)
+++ head/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c  Thu Sep 15 07:41:48 
2016(r305824)
@@ -920,7 +920,7 @@ ipf_fastroute(m0, mpp, fin, fdp)
mhip->ip_off |= IP_MF;
mhip->ip_len = htons((u_short)(len + mhlen));
*mnext = m;
-   m->m_next = m_copy(m0, off, len);
+   m->m_next = m_copym(m0, off, len, M_NOWAIT);
if (m->m_next == 0) {
error = ENOBUFS;/* ??? */
goto sendorfree;

Modified: head/sys/kern/uipc_socket.c
==
--- head/sys/kern/uipc_socket.c Thu Sep 15 02:48:56 2016(r305823)
+++ head/sys/kern/uipc_socket.c Thu Sep 15 07:41:48 2016(r305824)
@@ -1640,7 +1640,8 @@ dontblock:
do {
if (flags & MSG_PEEK) {
if (controlp != NULL) {
-   *controlp = m_copy(m, 0, m->m_len);
+   *controlp = m_copym(m, 0, m->m_len,
+   M_NOWAIT);
controlp = &(*controlp)->m_next;
}
m = m->m_next;

Modified: head/sys/net/if_arcsubr.c
==
--- head/sys/net/if_arcsubr.c   Thu Sep 15 02:48:56 2016(r305823)
+++ head/sys/net/if_arcsubr.c   Thu Sep 15 07:41:48 2016(r305824)
@@ -225,7 +225,7 @@ arc_output(struct ifnet *ifp, struct mbu
 
if ((ifp->if_flags & IFF_SIMPLEX) && (loop_copy != -1)) {
if ((m->m_flags & M_BCAST) || (loop_copy > 0)) {
-   struct mbuf *n = m_copy(m, 0