svn commit: r267148 - head
Author: bapt Date: Fri Jun 6 08:05:34 2014 New Revision: 267148 URL: http://svnweb.freebsd.org/changeset/base/267148 Log: Prevent arc commands from overwriting history Modified: head/.arcconfig Modified: head/.arcconfig == --- head/.arcconfig Fri Jun 6 04:09:07 2014(r267147) +++ head/.arcconfig Fri Jun 6 08:05:34 2014(r267148) @@ -1,4 +1,5 @@ { project.name: S, - phabricator.uri : https://phabric.freebsd.org/; + phabricator.uri : https://phabric.freebsd.org/;, + history.immutable : true } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267149 - head/usr.bin/netstat
Author: joel (doc committer) Date: Fri Jun 6 08:42:03 2014 New Revision: 267149 URL: http://svnweb.freebsd.org/changeset/base/267149 Log: Minor mdoc nit. Modified: head/usr.bin/netstat/netstat.1 Modified: head/usr.bin/netstat/netstat.1 == --- head/usr.bin/netstat/netstat.1 Fri Jun 6 08:05:34 2014 (r267148) +++ head/usr.bin/netstat/netstat.1 Fri Jun 6 08:42:03 2014 (r267149) @@ -90,8 +90,8 @@ .Op Fl M Ar core .Op Fl N Ar system .It Nm Fl Q -.Ek .El +.Ek .Sh DESCRIPTION The .Nm ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267150 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 10:40:20 2014 New Revision: 267150 URL: http://svnweb.freebsd.org/changeset/base/267150 Log: prevent a panic when the netdev/ifp is not set in attach (internal c63a7b85) MFC after:3 days Modified: head/sys/dev/netmap/netmap.c Modified: head/sys/dev/netmap/netmap.c == --- head/sys/dev/netmap/netmap.cFri Jun 6 08:42:03 2014 (r267149) +++ head/sys/dev/netmap/netmap.cFri Jun 6 10:40:20 2014 (r267150) @@ -2260,7 +2260,8 @@ netmap_attach(struct netmap_adapter *arg fail: D(fail, arg %p ifp %p na %p, arg, ifp, hwna); - netmap_detach(ifp); + if (ifp) + netmap_detach(ifp); return (hwna ? EINVAL : ENOMEM); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267151 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 10:50:14 2014 New Revision: 267151 URL: http://svnweb.freebsd.org/changeset/base/267151 Log: add checks for invalid buffer pointers and lengths Modified: head/sys/dev/netmap/netmap_vale.c Modified: head/sys/dev/netmap/netmap_vale.c == --- head/sys/dev/netmap/netmap_vale.c Fri Jun 6 10:40:20 2014 (r267150) +++ head/sys/dev/netmap/netmap_vale.c Fri Jun 6 10:50:14 2014 (r267151) @@ -959,6 +959,14 @@ nm_bdg_preflush(struct netmap_vp_adapter ft[ft_i].ft_next = NM_FT_NULL; buf = ft[ft_i].ft_buf = (slot-flags NS_INDIRECT) ? (void *)(uintptr_t)slot-ptr : BDG_NMB(na-up, slot); + if (unlikely(buf == NULL)) { + RD(5, NULL %s buffer pointer from %s slot %d len %d, + (slot-flags NS_INDIRECT) ? INDIRECT : DIRECT, + kring-name, j, ft[ft_i].ft_len); + buf = ft[ft_i].ft_buf = NMB_VA(0); /* the 'null' buffer */ + ft[ft_i].ft_len = 0; + ft[ft_i].ft_flags = 0; + } __builtin_prefetch(buf); ++ft_i; if (slot-flags NS_MOREFRAG) { @@ -1312,6 +1320,7 @@ nm_bdg_flush(struct nm_bdg_fwd *ft, u_in needed = d-bq_len + brddst-bq_len; if (unlikely(dst_na-virt_hdr_len != na-virt_hdr_len)) { + RD(3, virt_hdr_mismatch, src %d len %d, na-virt_hdr_len, dst_na-virt_hdr_len); /* There is a virtio-net header/offloadings mismatch between * source and destination. The slower mismatch datapath will * be used to cope with all the mismatches. @@ -1412,6 +1421,11 @@ retry: /* round to a multiple of 64 */ copy_len = (copy_len + 63) ~63; + if (unlikely(copy_len NETMAP_BUF_SIZE || + copy_len NETMAP_BUF_SIZE)) { + RD(5, invalid len %d, down to 64, (int)copy_len); + copy_len = dst_len = 64; // XXX + } if (ft_p-ft_flags NS_INDIRECT) { if (copyin(src, dst, copy_len)) { // invalid user pointer, pretend len is 0 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267152 - head/sys/dev/i40e
Author: kevlo Date: Fri Jun 6 11:12:19 2014 New Revision: 267152 URL: http://svnweb.freebsd.org/changeset/base/267152 Log: Replace deprecated M_DONTWAIT with M_NOWAIT. Reviewed by: jfv Modified: head/sys/dev/i40e/i40e_txrx.c Modified: head/sys/dev/i40e/i40e_txrx.c == --- head/sys/dev/i40e/i40e_txrx.c Fri Jun 6 10:50:14 2014 (r267151) +++ head/sys/dev/i40e/i40e_txrx.c Fri Jun 6 11:12:19 2014 (r267152) @@ -210,7 +210,7 @@ i40e_xmit(struct i40e_queue *que, struct if (error == EFBIG) { struct mbuf *m; - m = m_defrag(*m_headp, M_DONTWAIT); + m = m_defrag(*m_headp, M_NOWAIT); if (m == NULL) { que-mbuf_defrag_failed++; m_freem(*m_headp); @@ -834,7 +834,7 @@ i40e_refresh_mbufs(struct i40e_queue *qu goto no_split; if (buf-m_head == NULL) { - mh = m_gethdr(M_DONTWAIT, MT_DATA); + mh = m_gethdr(M_NOWAIT, MT_DATA); if (mh == NULL) goto update; } else @@ -861,7 +861,7 @@ i40e_refresh_mbufs(struct i40e_queue *qu no_split: if (buf-m_pack == NULL) { - mp = m_getjcl(M_DONTWAIT, MT_DATA, + mp = m_getjcl(M_NOWAIT, MT_DATA, M_PKTHDR, rxr-mbuf_sz); if (mp == NULL) goto update; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267153 - head/gnu/usr.bin/groff/tmac
Author: brueffer Date: Fri Jun 6 11:36:05 2014 New Revision: 267153 URL: http://svnweb.freebsd.org/changeset/base/267153 Log: Add Lb string for libcuse. Modified: head/gnu/usr.bin/groff/tmac/mdoc.local Modified: head/gnu/usr.bin/groff/tmac/mdoc.local == --- head/gnu/usr.bin/groff/tmac/mdoc.local Fri Jun 6 11:12:19 2014 (r267152) +++ head/gnu/usr.bin/groff/tmac/mdoc.local Fri Jun 6 11:36:05 2014 (r267153) @@ -35,6 +35,7 @@ .ds doc-str-Lb-libarchive Streaming Archive Library (libarchive, \-larchive) .ds doc-str-Lb-libbluetooth Bluetooth User Library (libbluetooth, \-lbluetooth) .ds doc-str-Lb-libcapsicum Capsicum Library (libcapsicum, \-lcapsicum) +.ds doc-str-Lb-libcuse Userland Character Device Library (libcuse, \-lcuse) .ds doc-str-Lb-libedit Line Editor and History Library (libedit, \-ledit) .ds doc-str-Lb-libefi EFI Runtime Services Library (libefi, \-lefi) .ds doc-str-Lb-libelf ELF Parsing Library (libelf, \-lelf) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267154 - head/lib/libcuse
Author: brueffer Date: Fri Jun 6 11:52:30 2014 New Revision: 267154 URL: http://svnweb.freebsd.org/changeset/base/267154 Log: Add missing MLINKs. Modified: head/lib/libcuse/Makefile Modified: head/lib/libcuse/Makefile == --- head/lib/libcuse/Makefile Fri Jun 6 11:36:05 2014(r267153) +++ head/lib/libcuse/Makefile Fri Jun 6 11:52:30 2014(r267154) @@ -40,6 +40,7 @@ LDADD+= ${PTHREAD_LIBS} MLINKS= MLINKS+= cuse.3 cuse_alloc_unit_number.3 +MLINKS+= cuse.3 cuse_alloc_unit_number_by_id.3 MLINKS+= cuse.3 cuse_copy_in.3 MLINKS+= cuse.3 cuse_copy_out.3 MLINKS+= cuse.3 cuse_dev_create.3 @@ -49,7 +50,10 @@ MLINKS+= cuse.3 cuse_dev_get_per_file_ha MLINKS+= cuse.3 cuse_dev_get_priv0.3 MLINKS+= cuse.3 cuse_dev_get_priv1.3 MLINKS+= cuse.3 cuse_dev_set_per_file_handle.3 +MLINKS+= cuse.3 cuse_dev_set_priv0.3 +MLINKS+= cuse.3 cuse_dev_set_priv1.3 MLINKS+= cuse.3 cuse_free_unit_number.3 +MLINKS+= cuse.3 cuse_free_unit_number_by_id.3 MLINKS+= cuse.3 cuse_got_peer_signal.3 MLINKS+= cuse.3 cuse_init.3 MLINKS+= cuse.3 cuse_poll_wakeup.3 @@ -59,6 +63,7 @@ MLINKS+= cuse.3 cuse_uninit.3 MLINKS+= cuse.3 cuse_vmalloc.3 MLINKS+= cuse.3 cuse_is_vmalloc_addr.3 MLINKS+= cuse.3 cuse_vmfree.3 +MLINKS+= cuse.3 cuse_vmoffset.3 MLINKS+= cuse.3 cuse_wait_and_process.3 .include bsd.lib.mk ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267155 - head/lib/libcuse
Author: brueffer Date: Fri Jun 6 12:06:40 2014 New Revision: 267155 URL: http://svnweb.freebsd.org/changeset/base/267155 Log: Mdoc cleanup, typo and grammar fixes. Modified: head/lib/libcuse/cuse.3 Modified: head/lib/libcuse/cuse.3 == --- head/lib/libcuse/cuse.3 Fri Jun 6 11:52:30 2014(r267154) +++ head/lib/libcuse/cuse.3 Fri Jun 6 12:06:40 2014(r267155) @@ -25,271 +25,263 @@ .\ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\ SUCH DAMAGE. .\ -.Dd May 23, 2014 +.Dd June 6, 2014 .Dt CUSE 3 .Os .Sh NAME .Nm libcuse -. .Nd Userland character device library -. -. .Sh LIBRARY -. -. -Userland character device library (libcuse -lcuse) -. -. +.Lb libcuse .Sh SYNOPSIS -. -.Pp To load the required kernel module at boot time, place the following line in .Xr loader.conf 5 : .Bd -literal -offset indent cuse_load=YES .Ed -. .Pp -. .In cuse.h -. -. .Sh DESCRIPTION The .Nm -library contains functions to create a character device in userspace. The +library contains functions to create a character device in userspace. +The .Nm library is thread safe. -. -. .Sh LIBRARY INITIALISATION / DEINITIALISATION -. -.Pp -. .Ft int .Fn cuse_init void This function initialises .Nm . Must be called at the beginning of the program. This function returns 0 on success or a negative value on failure. -See CUSE_ERR_XXX for known error codes. -If the cuse kernel module is not loaded, CUSE_ERR_NOT_LOADED is -returned. -. +See +.Dv CUSE_ERR_XXX +for known error codes. +If the cuse kernel module is not loaded, +.Dv CUSE_ERR_NOT_LOADED +is returned. .Pp -. .Ft int .Fn cuse_uninit void Deinitialise .Nm . Can be called at the end of the application. This function returns 0 on success or a negative value on failure. -See CUSE_ERR_XXX for known error codes. -. -. +See +.Dv CUSE_ERR_XXX +for known error codes. .Sh UNIT MANAGEMENT -. .Ft int .Fn cuse_alloc_unit_number int * This function stores a uniq system unit number at the pointed integer loation. This function returns 0 on success or a negative value on failure. -See CUSE_ERR_XXX for known error codes. -. +See +.Dv CUSE_ERR_XXX +for known error codes. .Pp -. .Ft int .Fn cuse_alloc_unit_number_by_id int * int id -This function stores a uniq system unit number at the pointed +This function stores a unique system unit number at the pointed integer loation. The returned unit number is uniq within the given ID. Valid ID values are defined by the cuse include file. -See the CUSE_ID_XXX() macros for more information. +See the +.Fn CUSE_ID_XXX +macros for more information. This function returns 0 on success or a negative value on failure. -See CUSE_ERR_XXX for known error codes. -. +See +.Dv CUSE_ERR_XXX +for known error codes. .Pp -. .Ft int .Fn cuse_free_unit_number int This function frees the given allocated system unit number. This function returns 0 on success or a negative value on failure. -See CUSE_ERR_XXX for known error codes. -. +See +.Dv CUSE_ERR_XXX +for known error codes. .Pp -. .Ft int .Fn cuse_free_unit_number_by_id int unit int id This function frees the given allocated system unit number belonging to the given ID. If both the unit and id argument is -1, all allocated units will be freed. This function returns 0 on success or a negative value on failure. -See CUSE_ERR_XXX for known error codes. -. -. +See +.Dv CUSE_ERR_XXX +for known error codes. .Sh LIBRARY USAGE -. -. .Ft void * .Fn cuse_vmalloc int size This function allocates .Ar size -bytes of memory. Only memory allocated by this function can be memory -mapped by mmap(). This function returns a valid data pointer on success or -NULL on failure. -. +bytes of memory. +Only memory allocated by this function can be memory +mapped by +.Xr mmap 2 . +This function returns a valid data pointer on success or +.Dv NULL +on failure. .Pp -. .Ft int .Fn cuse_is_vmalloc_addr void * This function returns non-zero if the passed pointer points to a valid -and non-freed allocation, as returned by cuse_vmalloc(). +and non-freed allocation, as returned by +.Fn cuse_vmalloc . Else this function returns zero. -. .Pp -. .Ft void .Fn cuse_vmfree void * -This function frees memory allocated by cuse_vmalloc(). Note that the +This function frees memory allocated by +.Fn cuse_vmalloc . +Note that the cuse library will internally not free the memory until the -cuse_uninit() function is called and that the number of uniq +.Fn cuse_uninit +function is called and that the number of unique allocations is limited. -. -. .Pp -. .Ft unsigned long .Fn cuse_vmoffset void * This function returns the mmap offset that the client must use to access the allocated memory. -. .Pp -. .Ft struct cuse_dev * .Fn cuse_dev_create const struct cuse_methods *mtod void *priv0 void *priv1 uid_t gid_t int permission const char *fmt ... This function creates a new
svn commit: r267156 - stable/10/sys/geom/part
Author: ae Date: Fri Jun 6 12:37:56 2014 New Revision: 267156 URL: http://svnweb.freebsd.org/changeset/base/267156 Log: MFC r266880: Use g_conf_printf_escaped() to escape symbols, which can break an XML tree. Modified: stable/10/sys/geom/part/g_part_apm.c stable/10/sys/geom/part/g_part_gpt.c stable/10/sys/geom/part/g_part_pc98.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/geom/part/g_part_apm.c == --- stable/10/sys/geom/part/g_part_apm.cFri Jun 6 12:06:40 2014 (r267155) +++ stable/10/sys/geom/part/g_part_apm.cFri Jun 6 12:37:56 2014 (r267156) @@ -42,6 +42,7 @@ __FBSDID($FreeBSD$); #include sys/systm.h #include sys/sysctl.h #include geom/geom.h +#include geom/geom_int.h #include geom/part/g_part.h #include g_part_if.h @@ -310,10 +311,14 @@ g_part_apm_dumpconf(struct g_part_table /* confxml: partition entry information */ strncpy(u.name, entry-ent.ent_name, APM_ENT_NAMELEN); u.name[APM_ENT_NAMELEN] = '\0'; - sbuf_printf(sb, %slabel%s/label\n, indent, u.name); + sbuf_printf(sb, %slabel, indent); + g_conf_printf_escaped(sb, %s, u.name); + sbuf_printf(sb, /label\n); strncpy(u.type, entry-ent.ent_type, APM_ENT_TYPELEN); u.type[APM_ENT_TYPELEN] = '\0'; - sbuf_printf(sb, %srawtype%s/rawtype\n, indent, u.type); + sbuf_printf(sb, %srawtype, indent); + g_conf_printf_escaped(sb, %s, u.type); + sbuf_printf(sb, /rawtype\n); } else { /* confxml: scheme information */ } Modified: stable/10/sys/geom/part/g_part_gpt.c == --- stable/10/sys/geom/part/g_part_gpt.cFri Jun 6 12:06:40 2014 (r267155) +++ stable/10/sys/geom/part/g_part_gpt.cFri Jun 6 12:37:56 2014 (r267156) @@ -44,6 +44,7 @@ __FBSDID($FreeBSD$); #include sys/sysctl.h #include sys/uuid.h #include geom/geom.h +#include geom/geom_int.h #include geom/part/g_part.h #include g_part_if.h @@ -1230,16 +1231,16 @@ g_gpt_printf_utf16(struct sbuf *sb, uint /* Write the Unicode character in UTF-8 */ if (ch 0x80) - sbuf_printf(sb, %c, ch); + g_conf_printf_escaped(sb, %c, ch); else if (ch 0x800) - sbuf_printf(sb, %c%c, 0xc0 | (ch 6), + g_conf_printf_escaped(sb, %c%c, 0xc0 | (ch 6), 0x80 | (ch 0x3f)); else if (ch 0x1) - sbuf_printf(sb, %c%c%c, 0xe0 | (ch 12), + g_conf_printf_escaped(sb, %c%c%c, 0xe0 | (ch 12), 0x80 | ((ch 6) 0x3f), 0x80 | (ch 0x3f)); else if (ch 0x20) - sbuf_printf(sb, %c%c%c%c, 0xf0 | (ch 18), - 0x80 | ((ch 12) 0x3f), + g_conf_printf_escaped(sb, %c%c%c%c, 0xf0 | + (ch 18), 0x80 | ((ch 12) 0x3f), 0x80 | ((ch 6) 0x3f), 0x80 | (ch 0x3f)); } } Modified: stable/10/sys/geom/part/g_part_pc98.c == --- stable/10/sys/geom/part/g_part_pc98.c Fri Jun 6 12:06:40 2014 (r267155) +++ stable/10/sys/geom/part/g_part_pc98.c Fri Jun 6 12:37:56 2014 (r267156) @@ -300,7 +300,9 @@ g_part_pc98_dumpconf(struct g_part_table sbuf_printf(sb, xs PC98 xt %u sn %s, type, name); } else { /* confxml: partition entry information */ - sbuf_printf(sb, %slabel%s/label\n, indent, name); + sbuf_printf(sb, %slabel, indent); + g_conf_printf_escaped(sb, %s, name); + sbuf_printf(sb, /label\n); if (entry-ent.dp_mid PC98_MID_BOOTABLE) sbuf_printf(sb, %sattribbootable/attrib\n, indent); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267157 - stable/9/sys/geom/part
Author: ae Date: Fri Jun 6 12:45:11 2014 New Revision: 267157 URL: http://svnweb.freebsd.org/changeset/base/267157 Log: MFC r266880: Use g_conf_printf_escaped() to escape symbols, which can break an XML tree. Approved by: re (gjb) Modified: stable/9/sys/geom/part/g_part_apm.c stable/9/sys/geom/part/g_part_gpt.c stable/9/sys/geom/part/g_part_pc98.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/geom/part/g_part_apm.c == --- stable/9/sys/geom/part/g_part_apm.c Fri Jun 6 12:37:56 2014 (r267156) +++ stable/9/sys/geom/part/g_part_apm.c Fri Jun 6 12:45:11 2014 (r267157) @@ -43,6 +43,7 @@ __FBSDID($FreeBSD$); #include sys/systm.h #include sys/sysctl.h #include geom/geom.h +#include geom/geom_int.h #include geom/part/g_part.h #include g_part_if.h @@ -311,10 +312,14 @@ g_part_apm_dumpconf(struct g_part_table /* confxml: partition entry information */ strncpy(u.name, entry-ent.ent_name, APM_ENT_NAMELEN); u.name[APM_ENT_NAMELEN] = '\0'; - sbuf_printf(sb, %slabel%s/label\n, indent, u.name); + sbuf_printf(sb, %slabel, indent); + g_conf_printf_escaped(sb, %s, u.name); + sbuf_printf(sb, /label\n); strncpy(u.type, entry-ent.ent_type, APM_ENT_TYPELEN); u.type[APM_ENT_TYPELEN] = '\0'; - sbuf_printf(sb, %srawtype%s/rawtype\n, indent, u.type); + sbuf_printf(sb, %srawtype, indent); + g_conf_printf_escaped(sb, %s, u.type); + sbuf_printf(sb, /rawtype\n); } else { /* confxml: scheme information */ } Modified: stable/9/sys/geom/part/g_part_gpt.c == --- stable/9/sys/geom/part/g_part_gpt.c Fri Jun 6 12:37:56 2014 (r267156) +++ stable/9/sys/geom/part/g_part_gpt.c Fri Jun 6 12:45:11 2014 (r267157) @@ -44,6 +44,7 @@ __FBSDID($FreeBSD$); #include sys/sysctl.h #include sys/uuid.h #include geom/geom.h +#include geom/geom_int.h #include geom/part/g_part.h #include g_part_if.h @@ -1217,16 +1218,16 @@ g_gpt_printf_utf16(struct sbuf *sb, uint /* Write the Unicode character in UTF-8 */ if (ch 0x80) - sbuf_printf(sb, %c, ch); + g_conf_printf_escaped(sb, %c, ch); else if (ch 0x800) - sbuf_printf(sb, %c%c, 0xc0 | (ch 6), + g_conf_printf_escaped(sb, %c%c, 0xc0 | (ch 6), 0x80 | (ch 0x3f)); else if (ch 0x1) - sbuf_printf(sb, %c%c%c, 0xe0 | (ch 12), + g_conf_printf_escaped(sb, %c%c%c, 0xe0 | (ch 12), 0x80 | ((ch 6) 0x3f), 0x80 | (ch 0x3f)); else if (ch 0x20) - sbuf_printf(sb, %c%c%c%c, 0xf0 | (ch 18), - 0x80 | ((ch 12) 0x3f), + g_conf_printf_escaped(sb, %c%c%c%c, 0xf0 | + (ch 18), 0x80 | ((ch 12) 0x3f), 0x80 | ((ch 6) 0x3f), 0x80 | (ch 0x3f)); } } Modified: stable/9/sys/geom/part/g_part_pc98.c == --- stable/9/sys/geom/part/g_part_pc98.cFri Jun 6 12:37:56 2014 (r267156) +++ stable/9/sys/geom/part/g_part_pc98.cFri Jun 6 12:45:11 2014 (r267157) @@ -300,7 +300,9 @@ g_part_pc98_dumpconf(struct g_part_table sbuf_printf(sb, xs PC98 xt %u sn %s, type, name); } else { /* confxml: partition entry information */ - sbuf_printf(sb, %slabel%s/label\n, indent, name); + sbuf_printf(sb, %slabel, indent); + g_conf_printf_escaped(sb, %s, name); + sbuf_printf(sb, /label\n); if (entry-ent.dp_mid PC98_MID_BOOTABLE) sbuf_printf(sb, %sattribbootable/attrib\n, indent); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267158 - stable/9/share/man/man7
Author: gjb Date: Fri Jun 6 12:52:44 2014 New Revision: 267158 URL: http://svnweb.freebsd.org/changeset/base/267158 Log: MFC r247791 (eadler): Modernize portions of the ports(7) manual page to reflect pkg(8). Approved by: re (kib) Sponsored by: The FreeBSD Foundation Modified: stable/9/share/man/man7/ports.7 Directory Properties: stable/9/share/man/man7/ (props changed) Modified: stable/9/share/man/man7/ports.7 == --- stable/9/share/man/man7/ports.7 Fri Jun 6 12:45:11 2014 (r267157) +++ stable/9/share/man/man7/ports.7 Fri Jun 6 12:52:44 2014 (r267158) @@ -490,27 +490,17 @@ single file .Bl -tag -width .Pa /usr/ports/Mk/bsd.port.mk -compact .It Pa /usr/ports The default ports directory -.No ( Fx -and -.Ox ) . -.It Pa /usr/pkgsrc -The default ports directory -.Pq Nx . .It Pa /usr/ports/Mk/bsd.port.mk The big Kahuna. .El .Sh SEE ALSO .Xr make 1 , -.Xr pkg_add 1 , -.Xr pkg_create 1 , -.Xr pkg_delete 1 , -.Xr pkg_info 1 , -.Xr pkg_version 1 +.Xr pkg 8 , +.Xr portsnap 8 .Pp The following are part of the ports collection: .Pp .Xr portaudit 1 , -.Xr portcheckout 1 , .Xr portlint 1 .Rs .%B The FreeBSD Handbook ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267159 - head/sbin/geom/class/stripe
Author: pjd Date: Fri Jun 6 13:00:53 2014 New Revision: 267159 URL: http://svnweb.freebsd.org/changeset/base/267159 Log: The 'create' subcommand doesn't have '-h' option. Modified: head/sbin/geom/class/stripe/geom_stripe.c Modified: head/sbin/geom/class/stripe/geom_stripe.c == --- head/sbin/geom/class/stripe/geom_stripe.c Fri Jun 6 12:52:44 2014 (r267158) +++ head/sbin/geom/class/stripe/geom_stripe.c Fri Jun 6 13:00:53 2014 (r267159) @@ -62,7 +62,7 @@ struct g_command class_commands[] = { { 's', stripesize, GSTRIPE_STRIPESIZE, G_TYPE_NUMBER }, G_OPT_SENTINEL }, - [-hv] [-s stripesize] name prov prov ... + [-v] [-s stripesize] name prov prov ... }, { destroy, G_FLAG_VERBOSE, NULL, { ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267160 - head/share/man/man7
Author: gjb Date: Fri Jun 6 13:36:52 2014 New Revision: 267160 URL: http://svnweb.freebsd.org/changeset/base/267160 Log: Dereference portaudit(1), as it is now deprecated and its functionality exists in pkg-audit(8). Submitted by: Ronald Klop ronald-li...@klop.ws MFC after:3 days Sponsored by: The FreeBSD Foundation Modified: head/share/man/man7/ports.7 Modified: head/share/man/man7/ports.7 == --- head/share/man/man7/ports.7 Fri Jun 6 13:00:53 2014(r267159) +++ head/share/man/man7/ports.7 Fri Jun 6 13:36:52 2014(r267160) @@ -25,7 +25,7 @@ .\ .\ $FreeBSD$ .\ -.Dd May 17, 2014 +.Dd June 6, 2014 .Dt PORTS 7 .Os .Sh NAME @@ -458,7 +458,7 @@ If defined, only operate on a port if it If defined, only operate on a port if it can be installed 100% automatically. .It Va DISABLE_VULNERABILITIES If defined, disable check for security vulnerabilities using -.Xr portaudit 1 Pq Pa ports/ports-mgmt/portaudit +.Xr pkg-audit 8 when installing new ports. .It Va NO_IGNORE If defined, allow installation of ports marked as @@ -539,7 +539,7 @@ The big Kahuna. .Pp The following are part of the ports collection: .Pp -.Xr portaudit 1 , +.Xr pkg 7 , .Xr portlint 1 .Rs .%B The FreeBSD Handbook ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267161 - stable/10/lib/libc/stdlib
Author: jilles Date: Fri Jun 6 13:37:40 2014 New Revision: 267161 URL: http://svnweb.freebsd.org/changeset/base/267161 Log: MFC r264417: realpath(): Properly fail . or .. components after non-directories. If realpath() is called on pathnames like /dev/null/. or /dev/null/.., it should fail with [ENOTDIR]. Pathnames like /dev/null/ already failed as they should. Also, put the check for non-directories after lstatting the previous component instead of when the empty component (consecutive or trailing slashes) is detected, saving an lstat() call and some lines of code. PR: 82980 Modified: stable/10/lib/libc/stdlib/realpath.c Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libc/stdlib/realpath.c == --- stable/10/lib/libc/stdlib/realpath.cFri Jun 6 13:36:52 2014 (r267160) +++ stable/10/lib/libc/stdlib/realpath.cFri Jun 6 13:37:40 2014 (r267161) @@ -132,26 +132,7 @@ realpath(const char * __restrict path, c resolved[resolved_len] = '\0'; } if (next_token[0] == '\0') { - /* -* Handle consequential slashes. The path -* before slash shall point to a directory. -* -* Only the trailing slashes are not covered -* by other checks in the loop, but we verify -* the prefix for any (rare) // or /\0 -* occurrence to not implement lookahead. -*/ - if (lstat(resolved, sb) != 0) { - if (m) - free(resolved); - return (NULL); - } - if (!S_ISDIR(sb.st_mode)) { - if (m) - free(resolved); - errno = ENOTDIR; - return (NULL); - } + /* Handle consequential slashes. */ continue; } else if (strcmp(next_token, .) == 0) @@ -236,6 +217,11 @@ realpath(const char * __restrict path, c } } left_len = strlcpy(left, symlink, sizeof(left)); + } else if (!S_ISDIR(sb.st_mode) p != NULL) { + if (m) + free(resolved); + errno = ENOTDIR; + return (NULL); } } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267162 - head/sys/kern
Author: jilles Date: Fri Jun 6 14:49:00 2014 New Revision: 267162 URL: http://svnweb.freebsd.org/changeset/base/267162 Log: ktrace: Use designated initializers for the data_lengths array. In the .o file, this only changes some line numbers (head amd64) because element 0 is no longer explicitly initialized. This should make bugs like FreeBSD-SA-14:12.ktrace less likely. Discussed with: des MFC after:1 week Modified: head/sys/kern/kern_ktrace.c Modified: head/sys/kern/kern_ktrace.c == --- head/sys/kern/kern_ktrace.c Fri Jun 6 13:37:40 2014(r267161) +++ head/sys/kern/kern_ktrace.c Fri Jun 6 14:49:00 2014(r267162) @@ -109,21 +109,20 @@ struct ktr_request { }; static int data_lengths[] = { - 0, /* none */ - offsetof(struct ktr_syscall, ktr_args), /* KTR_SYSCALL */ - sizeof(struct ktr_sysret), /* KTR_SYSRET */ - 0, /* KTR_NAMEI */ - sizeof(struct ktr_genio), /* KTR_GENIO */ - sizeof(struct ktr_psig),/* KTR_PSIG */ - sizeof(struct ktr_csw), /* KTR_CSW */ - 0, /* KTR_USER */ - 0, /* KTR_STRUCT */ - 0, /* KTR_SYSCTL */ - sizeof(struct ktr_proc_ctor), /* KTR_PROCCTOR */ - 0, /* KTR_PROCDTOR */ - sizeof(struct ktr_cap_fail),/* KTR_CAPFAIL */ - sizeof(struct ktr_fault), /* KTR_FAULT */ - sizeof(struct ktr_faultend),/* KTR_FAULTEND */ + [KTR_SYSCALL] = offsetof(struct ktr_syscall, ktr_args), + [KTR_SYSRET] = sizeof(struct ktr_sysret), + [KTR_NAMEI] = 0, + [KTR_GENIO] = sizeof(struct ktr_genio), + [KTR_PSIG] = sizeof(struct ktr_psig), + [KTR_CSW] = sizeof(struct ktr_csw), + [KTR_USER] = 0, + [KTR_STRUCT] = 0, + [KTR_SYSCTL] = 0, + [KTR_PROCCTOR] = sizeof(struct ktr_proc_ctor), + [KTR_PROCDTOR] = 0, + [KTR_CAPFAIL] = sizeof(struct ktr_cap_fail), + [KTR_FAULT] = sizeof(struct ktr_fault), + [KTR_FAULTEND] = sizeof(struct ktr_faultend), }; static STAILQ_HEAD(, ktr_request) ktr_free; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267163 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 14:57:16 2014 New Revision: 267163 URL: http://svnweb.freebsd.org/changeset/base/267163 Log: remove two debugging messages, align comments with the code in our development trunk Modified: head/sys/dev/netmap/netmap_generic.c Modified: head/sys/dev/netmap/netmap_generic.c == --- head/sys/dev/netmap/netmap_generic.cFri Jun 6 14:49:00 2014 (r267162) +++ head/sys/dev/netmap/netmap_generic.cFri Jun 6 14:57:16 2014 (r267163) @@ -81,18 +81,25 @@ __FBSDID($FreeBSD$); #include dev/netmap/netmap_kern.h #include dev/netmap/netmap_mem2.h -#define rtnl_lock() D(rtnl_lock called); -#define rtnl_unlock() D(rtnl_unlock called); +#define rtnl_lock()ND(rtnl_lock called); +#define rtnl_unlock() ND(rtnl_unlock called); #define MBUF_TXQ(m)((m)-m_pkthdr.flowid) #define MBUF_RXQ(m)((m)-m_pkthdr.flowid) #define smp_mb() /* - * mbuf wrappers + * FreeBSD mbuf allocator/deallocator in emulation mode: + * + * We allocate EXT_PACKET mbuf+clusters, but need to set M_NOFREE + * so that the destructor, if invoked, will not free the packet. + *In principle we should set the destructor only on demand, + * but since there might be a race we better do it on allocation. + * As a consequence, we also need to set the destructor or we + * would leak buffers. */ /* - * we allocate an EXT_PACKET + * mbuf wrappers */ #define netmap_get_mbuf(len) m_getcl(M_NOWAIT, MT_DATA, M_PKTHDR|M_NOFREE) @@ -808,5 +815,5 @@ generic_netmap_attach(struct ifnet *ifp) struct netmap_adapter * netmap_getna(if_t ifp) { - return (NA((struct ifnet *)ifp)); + return (NA((struct ifnet *)ifp)); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267164 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 14:57:40 2014 New Revision: 267164 URL: http://svnweb.freebsd.org/changeset/base/267164 Log: rate limit some error messages Modified: head/sys/dev/netmap/netmap_vale.c Modified: head/sys/dev/netmap/netmap_vale.c == --- head/sys/dev/netmap/netmap_vale.c Fri Jun 6 14:57:16 2014 (r267163) +++ head/sys/dev/netmap/netmap_vale.c Fri Jun 6 14:57:40 2014 (r267164) @@ -1072,7 +1072,7 @@ netmap_bdg_learning(char *buf, u_int buf uint64_t smac, dmac; if (buf_len 14) { - D(invalid buf length %d, buf_len); + RD(5, invalid buf length %d, buf_len); return NM_BDG_NOPORT; } dmac = le64toh(*(uint64_t *)(buf)) 0x; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267165 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 14:58:25 2014 New Revision: 267165 URL: http://svnweb.freebsd.org/changeset/base/267165 Log: align comments with the ones in our development trunk Modified: head/sys/dev/netmap/netmap.c head/sys/dev/netmap/netmap_kern.h Modified: head/sys/dev/netmap/netmap.c == --- head/sys/dev/netmap/netmap.cFri Jun 6 14:57:40 2014 (r267164) +++ head/sys/dev/netmap/netmap.cFri Jun 6 14:58:25 2014 (r267165) @@ -270,6 +270,7 @@ netmap_disable_ring(struct netmap_kring } +/* stop or enable all the rings of na */ static void netmap_set_all_rings(struct ifnet *ifp, int stopped) { @@ -303,6 +304,13 @@ netmap_set_all_rings(struct ifnet *ifp, } +/* + * Convenience function used in drivers. Waits for current txsync()s/rxsync()s + * to finish and prevents any new one from starting. Call this before turning + * netmap mode off, or before removing the harware rings (e.g., on module + * onload). As a rule of thumb for linux drivers, this should be placed near + * each napi_disable(). + */ void netmap_disable_all_rings(struct ifnet *ifp) { @@ -310,6 +318,11 @@ netmap_disable_all_rings(struct ifnet *i } +/* + * Convenience function used in drivers. Re-enables rxsync and txsync on the + * adapter's rings In linux drivers, this should be placed near each + * napi_enable(). + */ void netmap_enable_all_rings(struct ifnet *ifp) { @@ -393,6 +406,7 @@ nm_dump_buf(char *p, int len, int lim, c * Fetch configuration from the device, to cope with dynamic * reconfigurations after loading the module. */ +/* call with NMG_LOCK held */ int netmap_update_config(struct netmap_adapter *na) { @@ -447,18 +461,20 @@ netmap_rxsync_compat(struct netmap_kring return na-nm_rxsync(na, kring-ring_id, flags); } +/* kring-nm_sync callback for the host tx ring */ static int netmap_txsync_to_host_compat(struct netmap_kring *kring, int flags) { - (void)flags; + (void)flags; /* unused */ netmap_txsync_to_host(kring-na); return 0; } +/* kring-nm_sync callback for the host rx ring */ static int netmap_rxsync_from_host_compat(struct netmap_kring *kring, int flags) { - (void)flags; + (void)flags; /* unused */ netmap_rxsync_from_host(kring-na, NULL, NULL); return 0; } @@ -489,6 +505,7 @@ netmap_rxsync_from_host_compat(struct ne * Note: for compatibility, host krings are created even when not needed. * The tailroom space is currently used by vale ports for allocating leases. */ +/* call with NMG_LOCK held */ int netmap_krings_create(struct netmap_adapter *na, u_int tailroom) { @@ -567,6 +584,7 @@ netmap_krings_create(struct netmap_adapt /* undo the actions performed by netmap_krings_create */ +/* call with NMG_LOCK held */ void netmap_krings_delete(struct netmap_adapter *na) { @@ -586,6 +604,7 @@ netmap_krings_delete(struct netmap_adapt * on the rings connected to the host so we need to purge * them first. */ +/* call with NMG_LOCK held */ static void netmap_hw_krings_delete(struct netmap_adapter *na) { @@ -598,6 +617,12 @@ netmap_hw_krings_delete(struct netmap_ad } +/* create a new netmap_if for a newly registered fd. + * If this is the first registration of the adapter, + * also create the netmap rings and their in-kernel view, + * the netmap krings. + */ +/* call with NMG_LOCK held */ static struct netmap_if* netmap_if_new(const char *ifname, struct netmap_adapter *na) { @@ -608,17 +633,23 @@ netmap_if_new(const char *ifname, struct return NULL; } - if (na-active_fds) + if (na-active_fds) /* already registered */ goto final; + /* create and init the krings arrays. +* Depending on the adapter, this may also create +* the netmap rings themselves +*/ if (na-nm_krings_create(na)) goto cleanup; + /* create all missing netmap rings */ if (netmap_mem_rings_create(na)) goto cleanup; final: + /* in all cases, create a new netmap if */ nifp = netmap_mem_if_new(ifname, na); if (nifp == NULL) goto cleanup; @@ -638,8 +669,8 @@ cleanup: /* grab a reference to the memory allocator, if we don't have one already. The * reference is taken from the netmap_adapter registered with the priv. - * */ +/* call with NMG_LOCK held */ static int netmap_get_memory_locked(struct netmap_priv_d* p) { @@ -672,6 +703,7 @@ netmap_get_memory_locked(struct netmap_p } +/* call with NMG_LOCK *not* held */ int netmap_get_memory(struct netmap_priv_d* p) { @@ -683,6 +715,7 @@ netmap_get_memory(struct netmap_priv_d* } +/* call with NMG_LOCK held */ static int netmap_have_memory_locked(struct netmap_priv_d* p) { @@ -690,6 +723,7 @@ netmap_have_memory_locked(struct netmap_ } +/* call with NMG_LOCK held
svn commit: r267167 - head/sys/net
Author: luigi Date: Fri Jun 6 15:15:27 2014 New Revision: 267167 URL: http://svnweb.freebsd.org/changeset/base/267167 Log: whitespace change: fix one comment, remove a stale one. Modified: head/sys/net/netmap.h Modified: head/sys/net/netmap.h == --- head/sys/net/netmap.h Fri Jun 6 15:09:08 2014(r267166) +++ head/sys/net/netmap.h Fri Jun 6 15:15:27 2014(r267167) @@ -124,7 +124,7 @@ * space with a parent device. The ifname indicates the parent device, * which must already exist. Flags in nr_flags indicate if we want to * bind the master or slave side, the index (from nr_ringid) - * is just a cookie and does need to be sequential. + * is just a cookie and does not need to be sequential. * * + NIOCREGIF can also attach to 'monitor' rings that replicate * the content of specific rings, also from the same memory space. @@ -228,7 +228,7 @@ struct netmap_slot { * 'head' and 'cur' must be incremented as slots are filled * with new packets to be sent; * 'cur' can be moved further ahead if we need more space - * for new transmissions. + * for new transmissions. XXX todo (2014-03-12) * * In RX rings: * @@ -454,20 +454,6 @@ struct netmap_if { /* * struct nmreq overlays a struct ifreq (just the name) - * - * On input, nr_ringid indicates which rings we are requesting, - * with the low flags for the specific ring number. - * selection FLAGS RING INDEX - * - * all the NIC rings 0x - - * only HOST ring 0x2000 ring index - * single NIC ring 0x4000 - - * all the NIC+HOST rings 0x6000 - - * one pipe ring, master 0x8000 ring index - * *** INVALID 0xA000 - * one pipe ring, slave0xC000 ring index - * *** INVALID 0xE000 - * */ struct nmreq { charnr_name[IFNAMSIZ]; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267168 - head/sys/net
Author: luigi Date: Fri Jun 6 15:17:19 2014 New Revision: 267168 URL: http://svnweb.freebsd.org/changeset/base/267168 Log: misc bugfixes: - stdio.h is needed for fprint() - make memsize uint32_t to avoid errors due to overflow - honor the *XPOLL flagg in NIOCREGIF requests - mmap fails wit MAP_FAILED, not NULL. MFC after:3 days Modified: head/sys/net/netmap_user.h Modified: head/sys/net/netmap_user.h == --- head/sys/net/netmap_user.h Fri Jun 6 15:15:27 2014(r267167) +++ head/sys/net/netmap_user.h Fri Jun 6 15:17:19 2014(r267168) @@ -133,6 +133,7 @@ nm_ring_space(struct netmap_ring *ring) #ifndef HAVE_NETMAP_WITH_LIBS #define HAVE_NETMAP_WITH_LIBS +#include stdio.h #include sys/time.h #include sys/mman.h #include string.h/* memset */ @@ -192,7 +193,7 @@ struct nm_desc { struct nm_desc *self; /* point to self if netmap. */ int fd; void *mem; - int memsize; + uint32_t memsize; int done_mmap; /* set if mem is the result of mmap */ struct netmap_if * const nifp; uint16_t first_tx_ring, last_tx_ring, cur_tx_ring; @@ -404,8 +405,6 @@ nm_open(const char *ifname, const struct errmsg = invalid ringid; goto fail; } - /* add the *XPOLL flags */ - nr_ringid |= new_flags (NETMAP_NO_TX_POLL | NETMAP_DO_RX_POLL); d = (struct nm_desc *)calloc(1, sizeof(*d)); if (d == NULL) { @@ -461,6 +460,9 @@ nm_open(const char *ifname, const struct d-req.nr_flags = parent-req.nr_flags; } } + /* add the *XPOLL flags */ + d-req.nr_ringid |= new_flags (NETMAP_NO_TX_POLL | NETMAP_DO_RX_POLL); + if (ioctl(d-fd, NIOCREGIF, d-req)) { errmsg = NIOCREGIF failed; goto fail; @@ -472,10 +474,11 @@ nm_open(const char *ifname, const struct d-memsize = parent-memsize; d-mem = parent-mem; } else { + /* XXX TODO: check if memsize is too large (or there is overflow) */ d-memsize = d-req.nr_memsize; d-mem = mmap(0, d-memsize, PROT_WRITE | PROT_READ, MAP_SHARED, d-fd, 0); - if (d-mem == NULL) { + if (d-mem == MAP_FAILED) { errmsg = mmap failed; goto fail; } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r266925 - in head/sys: amd64/linux32 i386/linux kern sys
On Sat, May 31, 2014 at 03:01:51PM +, Dmitry Chagin wrote: Author: dchagin Date: Sat May 31 15:01:51 2014 New Revision: 266925 URL: http://svnweb.freebsd.org/changeset/base/266925 Log: To allow to run the interpreter itself add a new ELF branding type. Allow Linux ABI to run ELF interpreter. [..] + /* Some ABI allows to run the interpreter itself. */ + for (i = 0; i MAX_BRANDS; i++) { + bi = elf_brand_list[i]; + if (bi == NULL || bi-flags BI_BRAND_NOTE_MANDATORY) + continue; + if (hdr-e_machine != bi-machine || + (bi-flags BI_CAN_EXEC_INTERP) == 0) + continue; + /* + * Compare the interpreter name not the path to allow run it + * from everywhere. + */ + interp_brand_name = strrchr(bi-interp_path, '/'); + if (interp_brand_name == NULL) + interp_brand_name = bi-interp_path; + interp_len = strlen(interp_brand_name); + fname_name = strrchr(imgp-args-fname, '/'); Don't know about the rest, but this part looks incorrect. fname is NULL (which will crash in strrchr) when fexecve is executed. + if (fname_name == NULL) + fname_name = imgp-args-fname; + fname_len = strlen(fname_name); + if (fname_len interp_len) + continue; + ret = strncmp(fname_name, interp_brand_name, interp_len); + if (ret == 0) + return (bi); + } + -- Mateusz Guzik mjguzik gmail.com ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267169 - head/usr.sbin/bhyve
Author: tychon Date: Fri Jun 6 16:18:37 2014 New Revision: 267169 URL: http://svnweb.freebsd.org/changeset/base/267169 Log: Some devices (e.g. Intel AHCI and NICs) support quad-word access to register pairs where two 32-bit registers make up a larger logical size. Support those access by splitting the quad-word into two double-words. Reviewed by: grehan Modified: head/usr.sbin/bhyve/pci_emul.c Modified: head/usr.sbin/bhyve/pci_emul.c == --- head/usr.sbin/bhyve/pci_emul.c Fri Jun 6 15:17:19 2014 (r267168) +++ head/usr.sbin/bhyve/pci_emul.c Fri Jun 6 16:18:37 2014 (r267169) @@ -375,10 +375,27 @@ pci_emul_mem_handler(struct vmctx *ctx, offset = addr - pdi-pi_bar[bidx].addr; - if (dir == MEM_F_WRITE) - (*pe-pe_barwrite)(ctx, vcpu, pdi, bidx, offset, size, *val); - else - *val = (*pe-pe_barread)(ctx, vcpu, pdi, bidx, offset, size); + if (dir == MEM_F_WRITE) { + if (pdi-pi_bar[bidx].type == PCIBAR_MEM32 size == 8) { + (*pe-pe_barwrite)(ctx, vcpu, pdi, bidx, offset, + 4, *val 0x); + (*pe-pe_barwrite)(ctx, vcpu, pdi, bidx, offset + 4, + 4, *val 32); + } else { + (*pe-pe_barwrite)(ctx, vcpu, pdi, bidx, offset, + size, *val); + } + } else { + if (pdi-pi_bar[bidx].type == PCIBAR_MEM32 size == 8) { + *val = (*pe-pe_barread)(ctx, vcpu, pdi, bidx, +offset, 4); + *val |= (*pe-pe_barread)(ctx, vcpu, pdi, bidx, + offset + 4, 4) 32; + } else { + *val = (*pe-pe_barread)(ctx, vcpu, pdi, bidx, +offset, size); + } + } return (0); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267170 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 16:23:08 2014 New Revision: 267170 URL: http://svnweb.freebsd.org/changeset/base/267170 Log: move netmap_getna() to a freebsd-specific file Modified: head/sys/dev/netmap/netmap_freebsd.c head/sys/dev/netmap/netmap_generic.c Modified: head/sys/dev/netmap/netmap_freebsd.c == --- head/sys/dev/netmap/netmap_freebsd.cFri Jun 6 16:18:37 2014 (r267169) +++ head/sys/dev/netmap/netmap_freebsd.cFri Jun 6 16:23:08 2014 (r267170) @@ -223,6 +223,14 @@ generic_xmit_frame(struct ifnet *ifp, st } +#if __FreeBSD_version = 115 +struct netmap_adapter * +netmap_getna(if_t ifp) +{ + return (NA((struct ifnet *)ifp)); +} +#endif /* __FreeBSD_version = 115 */ + /* * The following two functions are empty until we have a generic * way to extract the info from the ifp Modified: head/sys/dev/netmap/netmap_generic.c == --- head/sys/dev/netmap/netmap_generic.cFri Jun 6 16:18:37 2014 (r267169) +++ head/sys/dev/netmap/netmap_generic.cFri Jun 6 16:23:08 2014 (r267170) @@ -811,9 +811,3 @@ generic_netmap_attach(struct ifnet *ifp) return retval; } - -struct netmap_adapter * -netmap_getna(if_t ifp) -{ - return (NA((struct ifnet *)ifp)); -} ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267171 - in head/sys/arm: at91 freescale/imx ti/am335x
Author: kevlo Date: Fri Jun 6 16:37:42 2014 New Revision: 267171 URL: http://svnweb.freebsd.org/changeset/base/267171 Log: Remove extra semicolons. Modified: head/sys/arm/at91/board_tsc4370.c head/sys/arm/freescale/imx/imx_sdhci.c head/sys/arm/ti/am335x/am335x_lcd.c Modified: head/sys/arm/at91/board_tsc4370.c == --- head/sys/arm/at91/board_tsc4370.c Fri Jun 6 16:23:08 2014 (r267170) +++ head/sys/arm/at91/board_tsc4370.c Fri Jun 6 16:37:42 2014 (r267171) @@ -332,19 +332,19 @@ set_mac_from_idprom(void) DEVOFFSET_BSO_SIGNATURE + sizeof(sig), dev_offset, sizeof(dev_offset)); if (status == -1) - return -1;; + return -1; /* Check for the boot section signature. */ status = eeprom_read(EE_DEV_ADDR, dev_offset + OFFSET_BS_SIGNATURE, sig, sizeof(sig)); if ((status == -1) || (sig != BS_SIGNATURE)) - return -1;; + return -1; } dev_offset += OFFSET_EUI64; /* Read the EUI64 from the device. */ if (eeprom_read(EE_DEV_ADDR, dev_offset, eui64, sizeof(eui64)) == -1) - return -1;; + return -1; /* Transcribe the EUI-64 to a MAC-48. * Modified: head/sys/arm/freescale/imx/imx_sdhci.c == --- head/sys/arm/freescale/imx/imx_sdhci.c Fri Jun 6 16:23:08 2014 (r267170) +++ head/sys/arm/freescale/imx/imx_sdhci.c Fri Jun 6 16:37:42 2014 (r267171) @@ -153,7 +153,7 @@ static struct ofw_compat_data compat_dat {fsl,imx53-esdhc, HWTYPE_ESDHC}, {fsl,imx51-esdhc, HWTYPE_ESDHC}, {NULL, HWTYPE_NONE}, -};; +}; static void imx_sdhc_set_clock(struct imx_sdhci_softc *sc, int enable); static void imx_sdhci_r1bfix_func(void *arg); Modified: head/sys/arm/ti/am335x/am335x_lcd.c == --- head/sys/arm/ti/am335x/am335x_lcd.c Fri Jun 6 16:23:08 2014 (r267170) +++ head/sys/arm/ti/am335x/am335x_lcd.c Fri Jun 6 16:37:42 2014 (r267171) @@ -223,7 +223,7 @@ am335x_lcd_sysctl_backlight(SYSCTL_HANDL int error; int backlight; - backlight = sc-sc_backlight;; + backlight = sc-sc_backlight; error = sysctl_handle_int(oidp, backlight, 0, req); if (error != 0 || req-newptr == NULL) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r266925 - in head/sys: amd64/linux32 i386/linux kern sys
On Fri, Jun 06, 2014 at 05:47:01PM +0200, Mateusz Guzik wrote: On Sat, May 31, 2014 at 03:01:51PM +, Dmitry Chagin wrote: Author: dchagin Date: Sat May 31 15:01:51 2014 New Revision: 266925 URL: http://svnweb.freebsd.org/changeset/base/266925 Log: To allow to run the interpreter itself add a new ELF branding type. Allow Linux ABI to run ELF interpreter. [..] + /* Some ABI allows to run the interpreter itself. */ + for (i = 0; i MAX_BRANDS; i++) { + bi = elf_brand_list[i]; + if (bi == NULL || bi-flags BI_BRAND_NOTE_MANDATORY) + continue; + if (hdr-e_machine != bi-machine || + (bi-flags BI_CAN_EXEC_INTERP) == 0) + continue; + /* +* Compare the interpreter name not the path to allow run it +* from everywhere. +*/ + interp_brand_name = strrchr(bi-interp_path, '/'); + if (interp_brand_name == NULL) + interp_brand_name = bi-interp_path; + interp_len = strlen(interp_brand_name); + fname_name = strrchr(imgp-args-fname, '/'); Don't know about the rest, but this part looks incorrect. fname is NULL (which will crash in strrchr) when fexecve is executed. yes, indeed. will fix, thanks + if (fname_name == NULL) + fname_name = imgp-args-fname; + fname_len = strlen(fname_name); + if (fname_len interp_len) + continue; + ret = strncmp(fname_name, interp_brand_name, interp_len); + if (ret == 0) + return (bi); + } + -- Mateusz Guzik mjguzik gmail.com -- Have fun! chd pgprLIEKONtHK.pgp Description: PGP signature
svn commit: r267172 - in head: . lib/atf/libatf-c lib/atf/libatf-c++ tools/build/mk
Author: jmmv Date: Fri Jun 6 17:05:43 2014 New Revision: 267172 URL: http://svnweb.freebsd.org/changeset/base/267172 Log: Homogenize libatf-* version numbers with upstream. The libatf-* major version numbers in FreeBSD were one version ahead of upstream because, when atf was first imported into FreeBSD, the upstream numbers were not respected. This is just confusing and bound to cause problems down the road. Fix this by taking advantage of the fact that libatf-* are now private and that atf is not yet built by default. However, and unfortunately, a clean build is needed for tests to continue working once make delete-old-libs has been run; hence the note in UPDATING. Modified: head/UPDATING head/lib/atf/libatf-c++/Makefile head/lib/atf/libatf-c/Makefile head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/UPDATING == --- head/UPDATING Fri Jun 6 16:37:42 2014(r267171) +++ head/UPDATING Fri Jun 6 17:05:43 2014(r267172) @@ -31,6 +31,22 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 11 disable the most expensive debugging functionality run ln -s 'abort:false,junk:false' /etc/malloc.conf.) +20140606: + The libatf-c and libatf-c++ major versions were downgraded to 0 and + 1 respectively to match the upstream numbers. They were out of + sync because, when they were originally added to FreeBSD, the + upstream versions were not respected. These libraries are private + and not yet built by default, so renumbering them should be a + non-issue. However, unclean source trees will yield broken test + programs once the operator executes make delete-old-libs after a + make installworld. + + If you are using WITH_TESTS=yes (not the default), wipe the object + tree and rebuild from scratch to prevent spurious test failures. + This is only needed once: the old, misnumbered libraries have been + added to OptionalObsoleteFiles.inc so they will be removed during a + clean upgrade. + 20140512: Clang and llvm have been upgraded to 3.4.1 release. Modified: head/lib/atf/libatf-c++/Makefile == --- head/lib/atf/libatf-c++/MakefileFri Jun 6 16:37:42 2014 (r267171) +++ head/lib/atf/libatf-c++/MakefileFri Jun 6 17:05:43 2014 (r267172) @@ -30,7 +30,7 @@ LIB= atf-c++ PRIVATELIB=true -SHLIB_MAJOR= 2 +SHLIB_MAJOR= 1 # libatf-c++ depends on the C version of the ATF library to build. DPADD= ${LIBATFC} Modified: head/lib/atf/libatf-c/Makefile == --- head/lib/atf/libatf-c/Makefile Fri Jun 6 16:37:42 2014 (r267171) +++ head/lib/atf/libatf-c/Makefile Fri Jun 6 17:05:43 2014 (r267172) @@ -30,7 +30,7 @@ LIB= atf-c PRIVATELIB=true -SHLIB_MAJOR= 1 +SHLIB_MAJOR= 0 ATF= ${.CURDIR:H:H:H}/contrib/atf .PATH: ${ATF} Modified: head/tools/build/mk/OptionalObsoleteFiles.inc == --- head/tools/build/mk/OptionalObsoleteFiles.inc Fri Jun 6 16:37:42 2014(r267171) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Fri Jun 6 17:05:43 2014(r267172) @@ -4112,6 +4112,8 @@ OLD_LIBS+=usr/lib/libatf-c.a OLD_LIBS+=usr/lib/libatf-c.so OLD_LIBS+=usr/lib/libatf-c.so.1 OLD_LIBS+=usr/lib/libatf-c_p.a +OLD_LIBS+=usr/lib/private/libatf-c.so.1 +OLD_LIBS+=usr/lib/private/libatf-c++.so.2 .if ${TARGET_ARCH} == amd64 || ${TARGET_ARCH} == powerpc64 OLD_LIBS+=usr/lib32/libatf-c++.a OLD_LIBS+=usr/lib32/libatf-c++.so @@ -4122,6 +4124,8 @@ OLD_LIBS+=usr/lib32/libatf-c.a OLD_LIBS+=usr/lib32/libatf-c.so OLD_LIBS+=usr/lib32/libatf-c.so.1 OLD_LIBS+=usr/lib32/libatf-c_p.a +OLD_LIBS+=usr/lib32/private/libatf-c.so.1 +OLD_LIBS+=usr/lib32/private/libatf-c++.so.2 .endif OLD_FILES+=usr/libdata/pkgconfig/atf-c++.pc OLD_FILES+=usr/libdata/pkgconfig/atf-c.pc ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267174 - head/usr.bin/rpcgen
Author: bdrewery Date: Fri Jun 6 17:38:37 2014 New Revision: 267174 URL: http://svnweb.freebsd.org/changeset/base/267174 Log: Fix some rpcgen sample file issues. * -Sc was generating code without a return type on main. * -Sm was generating an unusable clean target due to undefined RM. * -Sm was generating clean target with extra preceding space. PR: 185582 Submitted by: Pawel Biernacki pawel.bierna...@gmail.com MFC after:1 week Modified: head/usr.bin/rpcgen/rpc_main.c head/usr.bin/rpcgen/rpc_sample.c Modified: head/usr.bin/rpcgen/rpc_main.c == --- head/usr.bin/rpcgen/rpc_main.c Fri Jun 6 17:38:30 2014 (r267173) +++ head/usr.bin/rpcgen/rpc_main.c Fri Jun 6 17:38:37 2014 (r267174) @@ -878,8 +878,8 @@ $(TARGETS_SVC.c) \n\n); f_print(fout, \t$(CC) -o $(CLIENT) $(OBJECTS_CLNT) \ $(LDLIBS) \n\n); f_print(fout, $(SERVER) : $(OBJECTS_SVC) \n); - f_print(fout, \t$(CC) -o $(SERVER) $(OBJECTS_SVC) $(LDLIBS)\n\n ); - f_print(fout, clean:\n\t $(RM) -f core $(TARGETS) $(OBJECTS_CLNT) \ + f_print(fout, \t$(CC) -o $(SERVER) $(OBJECTS_SVC) $(LDLIBS)\n\n); + f_print(fout, clean:\n\t rm -f core $(TARGETS) $(OBJECTS_CLNT) \ $(OBJECTS_SVC) $(CLIENT) $(SERVER)\n\n); } Modified: head/usr.bin/rpcgen/rpc_sample.c == --- head/usr.bin/rpcgen/rpc_sample.cFri Jun 6 17:38:30 2014 (r267173) +++ head/usr.bin/rpcgen/rpc_sample.cFri Jun 6 17:38:37 2014 (r267174) @@ -270,6 +270,7 @@ write_sample_clnt_main(void) version_list *vp; f_print(fout, \n\n); + f_print(fout, int\n); f_print(fout, main(int argc, char *argv[])\n{\n); f_print(fout, \tchar *host;); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267173 - head/tools/tools/vt/fontcvt
Author: emaste Date: Fri Jun 6 17:38:30 2014 New Revision: 267173 URL: http://svnweb.freebsd.org/changeset/base/267173 Log: Update after r267011: use -h height and -w width args Modified: head/tools/tools/vt/fontcvt/terminus.sh Modified: head/tools/tools/vt/fontcvt/terminus.sh == --- head/tools/tools/vt/fontcvt/terminus.sh Fri Jun 6 17:05:43 2014 (r267172) +++ head/tools/tools/vt/fontcvt/terminus.sh Fri Jun 6 17:38:30 2014 (r267173) @@ -1,10 +1,12 @@ #!/bin/sh +# $FreeBSD$ + for i in 6:12 8:14 8:16 10:18 10:20 11:22 12:24 14:28 16:32 do C=`echo $i | cut -f 1 -d :` R=`echo $i | cut -f 2 -d :` ./fontcvt \ - $C $R \ + -w $C -h $R \ ~/terminus-font-4.36/ter-u${R}n.bdf \ ~/terminus-font-4.36/ter-u${R}b.bdf \ terminus-u${R}.vfnt ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267175 - in stable/10: sys/netinet tests/sys/netinet
Author: asomers Date: Fri Jun 6 17:42:55 2014 New Revision: 267175 URL: http://svnweb.freebsd.org/changeset/base/267175 Log: MFC r263779 Correct ARP update handling when the routes for network interfaces are restricted to a single FIB in a multifib system. Restricting an interface's routes to the FIB to which it is assigned (by setting net.add_addr_allfibs=0) causes ARP updates to fail with arpresolve: can't allocate llinfo for x.x.x.x. This is due to the ARP update code hard coding it's lookup for existing routing entries to FIB 0. sys/netinet/in.c: When dealing with RTM_ADD (add route) requests for an interface, use the interface's assigned FIB instead of the default (FIB 0). sys/netinet/if_ether.c: In arpresolve(), enhance error message generated when an lla_lookup() fails so that the interface causing the error is visible in logs. tests/sys/netinet/fibs_test.sh Clear ATF expected error. Modified: stable/10/sys/netinet/if_ether.c stable/10/sys/netinet/in.c stable/10/tests/sys/netinet/fibs_test.sh Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/netinet/if_ether.c == --- stable/10/sys/netinet/if_ether.cFri Jun 6 17:38:37 2014 (r267174) +++ stable/10/sys/netinet/if_ether.cFri Jun 6 17:42:55 2014 (r267175) @@ -338,8 +338,8 @@ retry: if (la == NULL) { if (flags LLE_CREATE) log(LOG_DEBUG, - arpresolve: can't allocate llinfo for %s\n, - inet_ntoa(SIN(dst)-sin_addr)); + arpresolve: can't allocate llinfo for %s on %s\n, + inet_ntoa(SIN(dst)-sin_addr), ifp-if_xname); m_freem(m); return (EINVAL); } Modified: stable/10/sys/netinet/in.c == --- stable/10/sys/netinet/in.c Fri Jun 6 17:38:37 2014(r267174) +++ stable/10/sys/netinet/in.c Fri Jun 6 17:42:55 2014(r267175) @@ -1303,8 +1303,9 @@ in_lltable_rtcheck(struct ifnet *ifp, u_ KASSERT(l3addr-sa_family == AF_INET, (sin_family %d, l3addr-sa_family)); - /* XXX rtalloc1 should take a const param */ - rt = rtalloc1(__DECONST(struct sockaddr *, l3addr), 0, 0); + /* XXX rtalloc1_fib should take a const param */ + rt = rtalloc1_fib(__DECONST(struct sockaddr *, l3addr), 0, 0, + ifp-if_fib); if (rt == NULL) return (EINVAL); Modified: stable/10/tests/sys/netinet/fibs_test.sh == --- stable/10/tests/sys/netinet/fibs_test.shFri Jun 6 17:38:37 2014 (r267174) +++ stable/10/tests/sys/netinet/fibs_test.shFri Jun 6 17:42:55 2014 (r267175) @@ -55,7 +55,6 @@ arpresolve_checks_interface_fib_head() } arpresolve_checks_interface_fib_body() { - atf_expect_fail kern/167947 arpresolve checks only the default FIB for the interface route # Configure the TAP interfaces to use a RFC5737 nonrouteable addresses # and a non-default fib ADDR0=192.0.2.2 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267176 - head/share/mk
Author: jmmv Date: Fri Jun 6 17:53:05 2014 New Revision: 267176 URL: http://svnweb.freebsd.org/changeset/base/267176 Log: Add the *_TESTS_SH_SED_* functionality to atf.test.mk. This exists already in plain.test.mk and tap.test.mk and should have been added to atf.test.mk too when the feature was first introduced. (It is probably time to address the related TODOs but I will do that separately.) Modified: head/share/mk/atf.test.mk Modified: head/share/mk/atf.test.mk == --- head/share/mk/atf.test.mk Fri Jun 6 17:42:55 2014(r267175) +++ head/share/mk/atf.test.mk Fri Jun 6 17:53:05 2014(r267176) @@ -98,10 +98,14 @@ _TESTS+= ${ATF_TESTS_SH} SCRIPTSDIR_${_T}= ${TESTSDIR} TEST_INTERFACE.${_T}= atf CLEANFILES+= ${_T} ${_T}.tmp +# TODO(jmmv): It seems to me that this SED and SRC functionality should +# exist in bsd.prog.mk along the support for SCRIPTS. Move it there if +# this proves to be useful within the tests. +ATF_TESTS_SH_SED_${_T}?= # empty ATF_TESTS_SH_SRC_${_T}?= ${_T}.sh ${_T}: ${ATF_TESTS_SH_SRC_${_T}} echo '#! /usr/bin/atf-sh' ${.TARGET}.tmp - cat ${.ALLSRC} ${.TARGET}.tmp + cat ${.ALLSRC} | sed ${ATF_TESTS_SH_SED_${_T}} ${.TARGET}.tmp chmod +x ${.TARGET}.tmp mv ${.TARGET}.tmp ${.TARGET} .endfor ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267177 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 18:02:32 2014 New Revision: 267177 URL: http://svnweb.freebsd.org/changeset/base/267177 Log: introduce mbq_lock() and mbq_unlock() for the mbq, so it is easier to buil the same code on linux (this generalizes the change in svn 267142) MFC after:3 days Modified: head/sys/dev/netmap/netmap.c head/sys/dev/netmap/netmap_mbq.c head/sys/dev/netmap/netmap_mbq.h Modified: head/sys/dev/netmap/netmap.c == --- head/sys/dev/netmap/netmap.cFri Jun 6 17:53:05 2014 (r267176) +++ head/sys/dev/netmap/netmap.cFri Jun 6 18:02:32 2014 (r267177) @@ -1050,7 +1050,7 @@ netmap_rxsync_from_host(struct netmap_ad (void)pwait;/* disable unused warnings */ (void)td; - mtx_lock_spin(q-lock); + mbq_lock(q); /* First part: import newly received packets */ n = mbq_len(q); @@ -1092,7 +1092,7 @@ netmap_rxsync_from_host(struct netmap_ad if (kring-rcur == kring-rtail td) /* no bufs available */ selrecord(td, kring-si); - mtx_unlock_spin(q-lock); + mbq_unlock(q); return ret; } @@ -2459,7 +2459,7 @@ netmap_transmit(struct ifnet *ifp, struc * not possible on Linux). * Also avoid overflowing the queue. */ - mtx_lock_spin(q-lock); + mbq_lock(q); space = kring-nr_hwtail - kring-nr_hwcur; if (space 0) @@ -2476,7 +2476,7 @@ netmap_transmit(struct ifnet *ifp, struc m = NULL; error = 0; } - mtx_unlock_spin(q-lock); + mbq_unlock(q); done: if (m) Modified: head/sys/dev/netmap/netmap_mbq.c == --- head/sys/dev/netmap/netmap_mbq.cFri Jun 6 17:53:05 2014 (r267176) +++ head/sys/dev/netmap/netmap_mbq.cFri Jun 6 18:02:32 2014 (r267177) @@ -76,9 +76,9 @@ static inline void __mbq_enqueue(struct void mbq_safe_enqueue(struct mbq *q, struct mbuf *m) { -mtx_lock_spin(q-lock); +mbq_lock(q); __mbq_enqueue(q, m); -mtx_unlock_spin(q-lock); +mbq_unlock(q); } @@ -110,9 +110,9 @@ struct mbuf *mbq_safe_dequeue(struct mbq { struct mbuf *ret; -mtx_lock_spin(q-lock); +mbq_lock(q); ret = __mbq_dequeue(q); -mtx_unlock_spin(q-lock); +mbq_unlock(q); return ret; } Modified: head/sys/dev/netmap/netmap_mbq.h == --- head/sys/dev/netmap/netmap_mbq.hFri Jun 6 17:53:05 2014 (r267176) +++ head/sys/dev/netmap/netmap_mbq.hFri Jun 6 18:02:32 2014 (r267177) @@ -62,7 +62,17 @@ void mbq_enqueue(struct mbq *q, struct m struct mbuf *mbq_dequeue(struct mbq *q); void mbq_purge(struct mbq *q); -/* XXX missing mbq_lock() and mbq_unlock */ +static inline void +mbq_lock(struct mbq *q) +{ + mtx_lock_spin(q-lock); +} + +static inline void +mbq_unlock(struct mbq *q) +{ + mtx_unlock_spin(q-lock); +} void mbq_safe_init(struct mbq *q); void mbq_safe_destroy(struct mbq *q); ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267178 - in head/sys/amd64/vmm: intel io
Author: tychon Date: Fri Jun 6 18:23:49 2014 New Revision: 267178 URL: http://svnweb.freebsd.org/changeset/base/267178 Log: Support guest accesses to %cr8. Reviewed by: neel Modified: head/sys/amd64/vmm/intel/vmx.c head/sys/amd64/vmm/io/vlapic.c head/sys/amd64/vmm/io/vlapic.h Modified: head/sys/amd64/vmm/intel/vmx.c == --- head/sys/amd64/vmm/intel/vmx.c Fri Jun 6 18:02:32 2014 (r267177) +++ head/sys/amd64/vmm/intel/vmx.c Fri Jun 6 18:23:49 2014 (r267178) @@ -83,7 +83,9 @@ __FBSDID($FreeBSD$); (PROCBASED_SECONDARY_CONTROLS | \ PROCBASED_IO_EXITING | \ PROCBASED_MSR_BITMAPS | \ -PROCBASED_CTLS_WINDOW_SETTING) +PROCBASED_CTLS_WINDOW_SETTING | \ +PROCBASED_CR8_LOAD_EXITING | \ +PROCBASED_CR8_STORE_EXITING) #definePROCBASED_CTLS_ZERO_SETTING \ (PROCBASED_CR3_LOAD_EXITING | \ PROCBASED_CR3_STORE_EXITING | \ @@ -714,6 +716,13 @@ vmx_init(int ipinum) procbased_ctls2 = ~PROCBASED2_VIRTUALIZE_X2APIC_MODE; /* +* No need to emulate accesses to %CR8 if virtual +* interrupt delivery is enabled. +*/ + procbased_ctls = ~PROCBASED_CR8_LOAD_EXITING; + procbased_ctls = ~PROCBASED_CR8_STORE_EXITING; + + /* * Check for Posted Interrupts only if Virtual Interrupt * Delivery is enabled. */ @@ -1426,97 +1435,130 @@ vmx_emulate_xsetbv(struct vmx *vmx, int return (HANDLED); } -static int -vmx_emulate_cr_access(struct vmx *vmx, int vcpu, uint64_t exitqual) +static uint64_t +vmx_get_guest_reg(struct vmx *vmx, int vcpu, int ident) { - int cr, vmcs_guest_cr, vmcs_shadow_cr; - uint64_t crval, regval, ones_mask, zeros_mask; const struct vmxctx *vmxctx; - /* We only handle mov to %cr0 or %cr4 at this time */ - if ((exitqual 0xf0) != 0x00) - return (UNHANDLED); + vmxctx = vmx-ctx[vcpu]; - cr = exitqual 0xf; - if (cr != 0 cr != 4) - return (UNHANDLED); + switch (ident) { + case 0: + return (vmxctx-guest_rax); + case 1: + return (vmxctx-guest_rcx); + case 2: + return (vmxctx-guest_rdx); + case 3: + return (vmxctx-guest_rbx); + case 4: + return (vmcs_read(VMCS_GUEST_RSP)); + case 5: + return (vmxctx-guest_rbp); + case 6: + return (vmxctx-guest_rsi); + case 7: + return (vmxctx-guest_rdi); + case 8: + return (vmxctx-guest_r8); + case 9: + return (vmxctx-guest_r9); + case 10: + return (vmxctx-guest_r10); + case 11: + return (vmxctx-guest_r11); + case 12: + return (vmxctx-guest_r12); + case 13: + return (vmxctx-guest_r13); + case 14: + return (vmxctx-guest_r14); + case 15: + return (vmxctx-guest_r15); + default: + panic(invalid vmx register %d, ident); + } +} + +static void +vmx_set_guest_reg(struct vmx *vmx, int vcpu, int ident, uint64_t regval) +{ + struct vmxctx *vmxctx; - regval = 0; /* silence gcc */ vmxctx = vmx-ctx[vcpu]; - /* -* We must use vmcs_write() directly here because vmcs_setreg() will -* call vmclear(vmcs) as a side-effect which we certainly don't want. -*/ - switch ((exitqual 8) 0xf) { + switch (ident) { case 0: - regval = vmxctx-guest_rax; + vmxctx-guest_rax = regval; break; case 1: - regval = vmxctx-guest_rcx; + vmxctx-guest_rcx = regval; break; case 2: - regval = vmxctx-guest_rdx; + vmxctx-guest_rdx = regval; break; case 3: - regval = vmxctx-guest_rbx; + vmxctx-guest_rbx = regval; break; case 4: - regval = vmcs_read(VMCS_GUEST_RSP); + vmcs_write(VMCS_GUEST_RSP, regval); break; case 5: - regval = vmxctx-guest_rbp; + vmxctx-guest_rbp = regval; break; case 6: - regval = vmxctx-guest_rsi; + vmxctx-guest_rsi = regval; break; case 7: - regval = vmxctx-guest_rdi; + vmxctx-guest_rdi = regval; break; case 8: - regval = vmxctx-guest_r8; +
svn commit: r267179 - head/sys/dev/vt/font
Author: emaste Date: Fri Jun 6 18:32:05 2014 New Revision: 267179 URL: http://svnweb.freebsd.org/changeset/base/267179 Log: Clarify statement on font origin Submitted by: Dimitar Zhekov Modified: head/sys/dev/vt/font/vt_font_default.c Modified: head/sys/dev/vt/font/vt_font_default.c == --- head/sys/dev/vt/font/vt_font_default.c Fri Jun 6 18:23:49 2014 (r267178) +++ head/sys/dev/vt/font/vt_font_default.c Fri Jun 6 18:32:05 2014 (r267179) @@ -24,9 +24,9 @@ */ /* - * This is the Terminus BSD Console font, a derivative of Terminus that is - * provided under the 2-clause BSD license for use by the FreeBSD vt(4) - * console. Please contribute any changes back to Mr. Zhekov at + * This is the Terminus BSD Console font. It is identical to the standard + * variant of Terminus Font 8x16, but provided under the 2-clause BSD License + * (FreeBSD License). Please contribute any changes back to Mr. Zhekov at * dimitar.zhe...@gmail.com. */ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267180 - head/sys/dev/netmap
Author: luigi Date: Fri Jun 6 18:36:02 2014 New Revision: 267180 URL: http://svnweb.freebsd.org/changeset/base/267180 Log: better handling of netmap emulation over standard device drivers: plug a potential mbuf leak, and detect bogus drivers that return ENOBUFS even when the packet has been queued. MFC after:3 days Modified: head/sys/dev/netmap/netmap_freebsd.c head/sys/dev/netmap/netmap_generic.c Modified: head/sys/dev/netmap/netmap_freebsd.c == --- head/sys/dev/netmap/netmap_freebsd.cFri Jun 6 18:32:05 2014 (r267179) +++ head/sys/dev/netmap/netmap_freebsd.cFri Jun 6 18:36:02 2014 (r267180) @@ -61,7 +61,8 @@ /* FREEBSD-SPECIFIC ROUTINES == */ -rawsum_t nm_csum_raw(uint8_t *data, size_t len, rawsum_t cur_sum) +rawsum_t +nm_csum_raw(uint8_t *data, size_t len, rawsum_t cur_sum) { /* TODO XXX please use the FreeBSD implementation for this. */ uint16_t *words = (uint16_t *)data; @@ -80,7 +81,8 @@ rawsum_t nm_csum_raw(uint8_t *data, size /* Fold a raw checksum: 'cur_sum' is in host byte order, while the * return value is in network byte order. */ -uint16_t nm_csum_fold(rawsum_t cur_sum) +uint16_t +nm_csum_fold(rawsum_t cur_sum) { /* TODO XXX please use the FreeBSD implementation for this. */ while (cur_sum 16) @@ -89,7 +91,8 @@ uint16_t nm_csum_fold(rawsum_t cur_sum) return htobe16((~cur_sum) 0x); } -uint16_t nm_csum_ipv4(struct nm_iphdr *iph) +uint16_t +nm_csum_ipv4(struct nm_iphdr *iph) { #if 0 return in_cksum_hdr((void *)iph); @@ -98,7 +101,8 @@ uint16_t nm_csum_ipv4(struct nm_iphdr *i #endif } -void nm_csum_tcpudp_ipv4(struct nm_iphdr *iph, void *data, +void +nm_csum_tcpudp_ipv4(struct nm_iphdr *iph, void *data, size_t datalen, uint16_t *check) { #ifdef INET @@ -120,7 +124,8 @@ void nm_csum_tcpudp_ipv4(struct nm_iphdr #endif } -void nm_csum_tcpudp_ipv6(struct nm_ipv6hdr *ip6h, void *data, +void +nm_csum_tcpudp_ipv6(struct nm_ipv6hdr *ip6h, void *data, size_t datalen, uint16_t *check) { #ifdef INET6 @@ -143,7 +148,8 @@ void nm_csum_tcpudp_ipv6(struct nm_ipv6h int netmap_catch_rx(struct netmap_adapter *na, int intercept) { - struct netmap_generic_adapter *gna = (struct netmap_generic_adapter *)na; + struct netmap_generic_adapter *gna = + (struct netmap_generic_adapter *)na; struct ifnet *ifp = na-ifp; if (intercept) { @@ -209,11 +215,29 @@ generic_xmit_frame(struct ifnet *ifp, st { int ret; - m-m_len = m-m_pkthdr.len = 0; + /* +* The mbuf should be a cluster from our special pool, +* so we do not need to do an m_copyback but just copy +* (and eventually, just reference the netmap buffer) +*/ - // copy data to the mbuf - m_copyback(m, 0, len, addr); - // inc refcount. We are alone, so we can skip the atomic + if (*m-m_ext.ref_cnt != 1) { + D(invalid refcnt %d for %p, + *m-m_ext.ref_cnt, m); + panic(in generic_xmit_frame); + } + // XXX the ext_size check is unnecessary if we link the netmap buf + if (m-m_ext.ext_size len) { + RD(5, size %d len %d, m-m_ext.ext_size, len); + len = m-m_ext.ext_size; + } + if (0) { /* XXX seems to have negligible benefits */ + m-m_ext.ext_buf = m-m_data = addr; + } else { + bcopy(addr, m-m_data, len); + } + m-m_len = m-m_pkthdr.len = len; + // inc refcount. All ours, we could skip the atomic atomic_fetchadd_int(m-m_ext.ref_cnt, 1); m-m_flags |= M_FLOWID; m-m_pkthdr.flowid = ring_nr; @@ -238,7 +262,7 @@ netmap_getna(if_t ifp) int generic_find_num_desc(struct ifnet *ifp, unsigned int *tx, unsigned int *rx) { - D(called); + D(called, in tx %d rx %d, *tx, *rx); return 0; } @@ -246,13 +270,14 @@ generic_find_num_desc(struct ifnet *ifp, void generic_find_num_queues(struct ifnet *ifp, u_int *txq, u_int *rxq) { - D(called); + D(called, in txq %d rxq %d, *txq, *rxq); *txq = netmap_generic_rings; *rxq = netmap_generic_rings; } -void netmap_mitigation_init(struct nm_generic_mit *mit, struct netmap_adapter *na) +void +netmap_mitigation_init(struct nm_generic_mit *mit, struct netmap_adapter *na) { ND(called); mit-mit_pending = 0; @@ -260,26 +285,30 @@ void netmap_mitigation_init(struct nm_ge } -void netmap_mitigation_start(struct nm_generic_mit *mit) +void +netmap_mitigation_start(struct nm_generic_mit *mit) { ND(called); } -void netmap_mitigation_restart(struct nm_generic_mit *mit) +void +netmap_mitigation_restart(struct nm_generic_mit *mit) {
svn commit: r267181 - in head: . etc/mtree libexec/atf libexec/atf/atf-check libexec/atf/atf-sh libexec/atf/atf-sh/tests share/mk tools/build/mk usr.bin usr.bin/atf
Author: jmmv Date: Fri Jun 6 18:58:06 2014 New Revision: 267181 URL: http://svnweb.freebsd.org/changeset/base/267181 Log: Move atf-sh from /usr/bin/ to /usr/libexec/ In r266650, we made libatf-c and libatf-c++ private libraries so that no components outside of the source tree could unintendedly depend on them. This change does the same for the atf-sh library by moving the atf-sh interpreter from its public location in /usr/bin/ to the private location in /usr/libexec/. Our build system will ensure that our own test programs use the right binary, but users won't be able to depend on atf-sh by mistake. Committing this now to ride the UPDATING notice added with r267172 today. Added: head/libexec/atf/atf-sh/ - copied from r267172, head/usr.bin/atf/atf-sh/ Deleted: head/usr.bin/atf/ Modified: head/UPDATING head/etc/mtree/BSD.tests.dist head/libexec/atf/Makefile head/libexec/atf/Makefile.inc head/libexec/atf/atf-check/Makefile head/libexec/atf/atf-sh/tests/Makefile head/share/mk/atf.test.mk head/tools/build/mk/OptionalObsoleteFiles.inc head/usr.bin/Makefile Modified: head/UPDATING == --- head/UPDATING Fri Jun 6 18:36:02 2014(r267180) +++ head/UPDATING Fri Jun 6 18:58:06 2014(r267181) @@ -41,11 +41,16 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 11 programs once the operator executes make delete-old-libs after a make installworld. + Additionally, the atf-sh binary was made private by moving it into + /usr/libexec/. Already-built shell test programs will keep the + path to the old binary so they will break after make delete-old + is run. + If you are using WITH_TESTS=yes (not the default), wipe the object tree and rebuild from scratch to prevent spurious test failures. - This is only needed once: the old, misnumbered libraries have been - added to OptionalObsoleteFiles.inc so they will be removed during a - clean upgrade. + This is only needed once: the misnumbered libraries and misplaced + binaries have been added to OptionalObsoleteFiles.inc so they will + be removed during a clean upgrade. 20140512: Clang and llvm have been upgraded to 3.4.1 release. Modified: head/etc/mtree/BSD.tests.dist == --- head/etc/mtree/BSD.tests.dist Fri Jun 6 18:36:02 2014 (r267180) +++ head/etc/mtree/BSD.tests.dist Fri Jun 6 18:58:06 2014 (r267181) @@ -88,6 +88,8 @@ atf atf-check .. +atf-sh +.. .. .. sbin @@ -127,10 +129,6 @@ usr.bin apply .. -atf -atf-sh -.. -.. bmake archives fmt_44bsd Modified: head/libexec/atf/Makefile == --- head/libexec/atf/Makefile Fri Jun 6 18:36:02 2014(r267180) +++ head/libexec/atf/Makefile Fri Jun 6 18:58:06 2014(r267181) @@ -25,6 +25,6 @@ # # $FreeBSD$ -SUBDIR=atf-check tests +SUBDIR=atf-check atf-sh tests .include bsd.subdir.mk Modified: head/libexec/atf/Makefile.inc == --- head/libexec/atf/Makefile.inc Fri Jun 6 18:36:02 2014 (r267180) +++ head/libexec/atf/Makefile.inc Fri Jun 6 18:58:06 2014 (r267181) @@ -28,3 +28,5 @@ CFLAGS+= -DHAVE_CONFIG_H WARNS?=3 + +.include ../Makefile.inc Modified: head/libexec/atf/atf-check/Makefile == --- head/libexec/atf/atf-check/Makefile Fri Jun 6 18:36:02 2014 (r267180) +++ head/libexec/atf/atf-check/Makefile Fri Jun 6 18:58:06 2014 (r267181) @@ -31,7 +31,6 @@ ATF= ${.CURDIR:H:H:H}/contrib/atf .PATH: ${ATF}/atf-sh -BINDIR=/usr/libexec PROG_CXX= atf-check SRCS= atf-check.cpp MAN= atf-check.1 Modified: head/libexec/atf/atf-sh/tests/Makefile == --- head/usr.bin/atf/atf-sh/tests/Makefile Fri Jun 6 17:05:43 2014 (r267172) +++ head/libexec/atf/atf-sh/tests/Makefile Fri Jun 6 18:58:06 2014 (r267181) @@ -2,7 +2,7 @@ .include bsd.init.mk -TESTSDIR= ${TESTSBASE}/usr.bin/atf/atf-sh +TESTSDIR= ${TESTSBASE}/libexec/atf/atf-sh ATF= ${.CURDIR:H:H:H:H}/contrib/atf .PATH: ${ATF}/atf-sh @@ -10,6 +10,8 @@ ATF= ${.CURDIR:H:H:H:H}/contrib/atf ATF_TESTS_SH+= atf_check_test ATF_TESTS_SH+= config_test ATF_TESTS_SH+=
svn commit: r267182 - in head: sbin/geom/class/label sbin/reboot share/man/man4 usr.bin/mkimg
Author: joel (doc committer) Date: Fri Jun 6 19:00:43 2014 New Revision: 267182 URL: http://svnweb.freebsd.org/changeset/base/267182 Log: Minor mdoc improvements. Modified: head/sbin/geom/class/label/glabel.8 head/sbin/reboot/boot_i386.8 head/share/man/man4/mrsas.4 head/share/man/man4/ng_bridge.4 head/share/man/man4/ng_ppp.4 head/share/man/man4/nvme.4 head/usr.bin/mkimg/mkimg.1 Modified: head/sbin/geom/class/label/glabel.8 == --- head/sbin/geom/class/label/glabel.8 Fri Jun 6 18:58:06 2014 (r267181) +++ head/sbin/geom/class/label/glabel.8 Fri Jun 6 19:00:43 2014 (r267182) @@ -235,7 +235,7 @@ and creating label nodes in the .Xr devfs 5 tree. It is sometimes desirable to disable certain label types if they conflict with other classes in complex GEOM topologies. -.Bl +.El .Sh EXIT STATUS Exit status is 0 on success, and 1 if the command fails. .Sh EXAMPLES Modified: head/sbin/reboot/boot_i386.8 == --- head/sbin/reboot/boot_i386.8Fri Jun 6 18:58:06 2014 (r267181) +++ head/sbin/reboot/boot_i386.8Fri Jun 6 19:00:43 2014 (r267182) @@ -113,7 +113,6 @@ boot device, as a hint about available b .Ic ?\ may also be specified as the last segment of a path, in which case the listing will be of the relevant subdirectory.) -.Pp .It Xo .Sm off .Ar bios_drive : interface ( unit , Oo Ar slice , Oc Ar part ) Modified: head/share/man/man4/mrsas.4 == --- head/share/man/man4/mrsas.4 Fri Jun 6 18:58:06 2014(r267181) +++ head/share/man/man4/mrsas.4 Fri Jun 6 19:00:43 2014(r267182) @@ -321,7 +321,7 @@ management interface .Xr mfi 4 , .Xr pci 4 , .Xr device.hints 5 , -.Xt camcontrol 8 +.Xr camcontrol 8 .Sh HISTORY The .Nm Modified: head/share/man/man4/ng_bridge.4 == --- head/share/man/man4/ng_bridge.4 Fri Jun 6 18:58:06 2014 (r267181) +++ head/share/man/man4/ng_bridge.4 Fri Jun 6 19:00:43 2014 (r267182) @@ -139,7 +139,6 @@ The determines how quickly a host must jump from one link to another before we declare a loopback condition. The default is one second. -.Pp .It Dv NGM_BRIDGE_GET_CONFIG Pq Ic getconfig Returns the current configuration as a .Dv struct ng_bridge_config . Modified: head/share/man/man4/ng_ppp.4 == --- head/share/man/man4/ng_ppp.4Fri Jun 6 18:58:06 2014 (r267181) +++ head/share/man/man4/ng_ppp.4Fri Jun 6 19:00:43 2014 (r267182) @@ -385,7 +385,6 @@ struct ng_ppp_node_conf { struct ng_ppp_link_conf links[NG_PPP_MAX_LINKS]; }; .Ed -.Pp .It Dv NGM_PPP_GET_CONFIG Pq Ic getconfig Returns the current configuration as a .Dv struct ng_ppp_node_conf . Modified: head/share/man/man4/nvme.4 == --- head/share/man/man4/nvme.4 Fri Jun 6 18:58:06 2014(r267181) +++ head/share/man/man4/nvme.4 Fri Jun 6 19:00:43 2014(r267182) @@ -85,7 +85,6 @@ the format .Pa /dev/nvmeXnsY . Note that the NVM Express specification starts numbering namespaces at 1, not 0, and this driver follows that convention. -.El .Sh CONFIGURATION By default, .Nm Modified: head/usr.bin/mkimg/mkimg.1 == --- head/usr.bin/mkimg/mkimg.1 Fri Jun 6 18:58:06 2014(r267181) +++ head/usr.bin/mkimg/mkimg.1 Fri Jun 6 19:00:43 2014(r267182) @@ -115,6 +115,12 @@ For a complete list of supported partiti format, or for a detailed description of how to specify partitions, run the .Nm utility without any arguments. +.Sh ENVIRONMENT +.Bl -tag -width TMPDIR -compact +.It Ev TMPDIR +Directory to put temporary files in; default is +.Pa /tmp . +.El .Sh EXAMPLES To create a bootable disk image that is partitioned using the GPT scheme and containing a root file system that was previously created using @@ -159,11 +165,6 @@ For partitioning schemes that feature pa utility supports assigning labels to the partitions specified. In the following example the file system partition is labeled as 'backup': .Dl % mkimg -s gpt -p freebsd-ufs/backup:=file-system.ufs -o gpt.img -.Sh ENVIRONMENT -.Bl -tag -width TMPDIR -compact -.It Ev TMPDIR -Directory to put temporary files in; default is -.Pa /tmp . .Sh SEE ALSO .Xr gpart 8 .Xr makefs 8 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267183 - head/sys/boot/usb
Author: hselasky Date: Fri Jun 6 19:02:45 2014 New Revision: 267183 URL: http://svnweb.freebsd.org/changeset/base/267183 Log: Compilation fixes. Modified: head/sys/boot/usb/bsd_kernel.h Modified: head/sys/boot/usb/bsd_kernel.h == --- head/sys/boot/usb/bsd_kernel.h Fri Jun 6 19:00:43 2014 (r267182) +++ head/sys/boot/usb/bsd_kernel.h Fri Jun 6 19:02:45 2014 (r267183) @@ -38,6 +38,7 @@ #defineisalpha(x) (((x) = 'a' (x) = 'z') || ((x) = 'A' (x) = 'Z')) #defineisdigit(x) ((x) = '0' (x) = '9') #definepanic(...) do { printf(USB PANIC: __VA_ARGS__); while (1) ; } while (0) +#definerebooting 0 #defineM_USB 0 #defineM_USBDEV 0 #defineUSB_PROC_MAX 3 @@ -182,9 +183,10 @@ typedef uint16_t gid_t; typedef uint16_t mode_t; typedef uint8_t *caddr_t; -typedef unsigned long __uintptr_t; +#define_UINTPTR_T_DECLARED typedef unsigned long uintptr_t; +#define_SIZE_T_DECLARED typedef unsigned long size_t; typedef unsigned long u_long; #endif ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267184 - head/release/doc/en_US.ISO8859-1/hardware
Author: brueffer Date: Fri Jun 6 19:10:23 2014 New Revision: 267184 URL: http://svnweb.freebsd.org/changeset/base/267184 Log: Add vte(4) to the hardware notes. MFC after:3 days Modified: head/release/doc/en_US.ISO8859-1/hardware/article.xml Modified: head/release/doc/en_US.ISO8859-1/hardware/article.xml == --- head/release/doc/en_US.ISO8859-1/hardware/article.xml Fri Jun 6 19:02:45 2014(r267183) +++ head/release/doc/en_US.ISO8859-1/hardware/article.xml Fri Jun 6 19:10:23 2014(r267184) @@ -944,6 +944,8 @@ hwlist.vr; + hwlist.vte; + hwlist.vx; hwlist.vxge; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267185 - head/share/man/man4
Author: brueffer Date: Fri Jun 6 20:01:45 2014 New Revision: 267185 URL: http://svnweb.freebsd.org/changeset/base/267185 Log: Minor improvements. MFC after:1 week Modified: head/share/man/man4/xnb.4 Modified: head/share/man/man4/xnb.4 == --- head/share/man/man4/xnb.4 Fri Jun 6 19:10:23 2014(r267184) +++ head/share/man/man4/xnb.4 Fri Jun 6 20:01:45 2014(r267185) @@ -30,7 +30,7 @@ .\ .\ $FreeBSD$ .\ -.Dd January 6, 2012 +.Dd June 6, 2014 .Dt XNB 4 .Os .Sh NAME @@ -116,7 +116,9 @@ machine. However, when a Xennet interface is bridged to a physical interface, a correct checksum must be attached to any packets bound for that physical interface. -Currently, FreeBSD lacks any mechanism for an ethernet device to +Currently, +.Fx +lacks any mechanism for an Ethernet device to inform the OS that newly received packets are valid even though their checksums are not. So if the netfront driver is configured to offload checksum calculations, ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267186 - in stable/10: sys/net sys/netinet tests/sys/netinet
Author: asomers Date: Fri Jun 6 20:35:40 2014 New Revision: 267186 URL: http://svnweb.freebsd.org/changeset/base/267186 Log: MFC changes relating to running multiple interfaces on different fibs but with addresses on the same subnet. MFC r266860 Fix unintended KBI change from r264905. Add _fib versions of ifa_ifwithnet() and ifa_ifwithdstaddr() The legacy functions will call the _fib() versions with RT_ALL_FIBS, preserving legacy behavior. sys/net/if_var.h sys/net/if.c Add legacy-compatible functions as described above. Ensure legacy behavior when RT_ALL_FIBS is passed as fibnum. sys/netinet/in_pcb.c sys/netinet/ip_output.c sys/netinet/ip_options.c sys/net/route.c sys/net/rtsock.c sys/netinet6/nd6.c Call with _fib() functions if we must use a specific fib, or the legacy functions otherwise. tests/sys/netinet/fibs_test.sh tests/sys/netinet/udp_dontroute.c Improve the udp_dontroute test. The bug that this test exercises is that ifa_ifwithnet() will return the wrong address, if multiple interfaces have addresses on the same subnet but with different fibs. The previous version of the test only considered one possible failure mode: that ifa_ifwithnet_fib() might fail to find any suitable address at all. The new version also checks whether ifa_ifwithnet_fib() finds the correct address by checking where the ARP request goes. MFC r264917 Style fixes, mostly trailing whitespace elimination. No functional change. MFC r264905 Fix subnet and default routes on different FIBs on the same subnet. These two bugs are closely related. The root cause is that ifa_ifwithnet does not consider FIBs when searching for an interface address. sys/net/if_var.h sys/net/if.c Add a fib argument to ifa_ifwithnet and ifa_ifwithdstadddr. Those functions will only return an address whose interface fib equals the argument. sys/net/route.c Update calls to ifa_ifwithnet and ifa_ifwithdstaddr with fib arguments. sys/netinet/in.c Update in_addprefix to consider the interface fib when adding prefixes. This will prevent it from not adding a subnet route when one already exists on a different fib. sys/net/rtsock.c sys/netinet/in_pcb.c sys/netinet/ip_output.c sys/netinet/ip_options.c sys/netinet6/nd6.c Add RT_DEFAULT_FIB arguments to ifa_ifwithdstaddr and ifa_ifwithnet. In some cases it there wasn't a clear specific fib number to use. In others, I was unable to test those functions so I chose RT_DEFAULT_FIB to minimize divergence from current behavior. I will fix some of the latter changes along with PR kern/187553. tests/sys/netinet/fibs_test.sh tests/sys/netinet/udp_dontroute.c tests/sys/netinet/Makefile Revert r263738. The udp_dontroute test was right all along. However, bugs kern/187550 and kern/187553 cancelled each other out when it came to this test. Because of kern/187553, ifa_ifwithnet searched the default fib instead of the requested one, but because of kern/187550, there was an applicable subnet route on the default fib. The new test added in r263738 doesn't work right, however. I can verify with dtrace that ifa_ifwithnet returned the wrong address before I applied this commit, but route(8) miraculously found the correct interface to use anyway. I don't know how. Clear expected failure messages for kern/187550 and kern/187552. MFC r263738 tests/sys/netinet/Makefile tests/sys/netinet/fibs.sh Replace fibs:udp_dontroute with fibs:src_addr_selection_by_subnet. The original test was poorly written; it was actually testing kern/167947 instead of the desired kern/187553. The root cause of the bug is that ifa_ifwithnet did not have a fib argument. The new test more directly targets that behavior. tests/sys/netinet/udp_dontroute.c Delete the auxilliary binary used by the old test Modified: stable/10/sys/net/if.c stable/10/sys/net/if_var.h stable/10/sys/net/route.c stable/10/sys/netinet/in.c stable/10/tests/sys/netinet/fibs_test.sh stable/10/tests/sys/netinet/udp_dontroute.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/net/if.c == --- stable/10/sys/net/if.c Fri Jun 6 20:01:45 2014(r267185) +++ stable/10/sys/net/if.c Fri Jun 6 20:35:40 2014(r267186) @@ -1607,7 +1607,7 @@ done: */ /*ARGSUSED*/ struct ifaddr * -ifa_ifwithdstaddr(struct sockaddr *addr) +ifa_ifwithdstaddr_fib(struct sockaddr *addr, int fibnum) { struct ifnet *ifp;
svn commit: r267187 - in head/sys/dev: e1000 ixgbe vmware/vmxnet3
Author: luigi Date: Fri Jun 6 20:49:56 2014 New Revision: 267187 URL: http://svnweb.freebsd.org/changeset/base/267187 Log: make sure if_transmit returns 0 if the mbuf is enqueued. ixgbe/ixv.c still needs a similar fix but it takes a little more restructuring of the code. MFC after:3 days Modified: head/sys/dev/e1000/if_igb.c head/sys/dev/ixgbe/ixgbe.c head/sys/dev/vmware/vmxnet3/if_vmx.c Modified: head/sys/dev/e1000/if_igb.c == --- head/sys/dev/e1000/if_igb.c Fri Jun 6 20:35:40 2014(r267186) +++ head/sys/dev/e1000/if_igb.c Fri Jun 6 20:49:56 2014(r267187) @@ -989,12 +989,12 @@ igb_mq_start(struct ifnet *ifp, struct m if (err) return (err); if (IGB_TX_TRYLOCK(txr)) { - err = igb_mq_start_locked(ifp, txr); + igb_mq_start_locked(ifp, txr); IGB_TX_UNLOCK(txr); } else taskqueue_enqueue(que-tq, txr-txq_task); - return (err); + return (0); } static int Modified: head/sys/dev/ixgbe/ixgbe.c == --- head/sys/dev/ixgbe/ixgbe.c Fri Jun 6 20:35:40 2014(r267186) +++ head/sys/dev/ixgbe/ixgbe.c Fri Jun 6 20:49:56 2014(r267187) @@ -831,12 +831,12 @@ ixgbe_mq_start(struct ifnet *ifp, struct if (err) return (err); if (IXGBE_TX_TRYLOCK(txr)) { - err = ixgbe_mq_start_locked(ifp, txr); + ixgbe_mq_start_locked(ifp, txr); IXGBE_TX_UNLOCK(txr); } else taskqueue_enqueue(que-tq, txr-txq_task); - return (err); + return (0); } static int Modified: head/sys/dev/vmware/vmxnet3/if_vmx.c == --- head/sys/dev/vmware/vmxnet3/if_vmx.cFri Jun 6 20:35:40 2014 (r267186) +++ head/sys/dev/vmware/vmxnet3/if_vmx.cFri Jun 6 20:49:56 2014 (r267187) @@ -2935,7 +2935,6 @@ vmxnet3_txq_mq_start_locked(struct vmxne /* Assume worse case if this mbuf is the head of a chain. */ if (m-m_next != NULL avail VMXNET3_TX_MAXSEGS) { drbr_putback(ifp, br, m); - error = ENOBUFS; break; } @@ -2958,7 +2957,7 @@ vmxnet3_txq_mq_start_locked(struct vmxne txq-vxtxq_watchdog = VMXNET3_WATCHDOG_TIMEOUT; } - return (error); + return (0); } static int ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r267187 - in head/sys/dev: e1000 ixgbe vmware/vmxnet3
Thanks for finally committing this stuff! -a On 6 June 2014 16:49, Luigi Rizzo lu...@freebsd.org wrote: Author: luigi Date: Fri Jun 6 20:49:56 2014 New Revision: 267187 URL: http://svnweb.freebsd.org/changeset/base/267187 Log: make sure if_transmit returns 0 if the mbuf is enqueued. ixgbe/ixv.c still needs a similar fix but it takes a little more restructuring of the code. MFC after:3 days Modified: head/sys/dev/e1000/if_igb.c head/sys/dev/ixgbe/ixgbe.c head/sys/dev/vmware/vmxnet3/if_vmx.c Modified: head/sys/dev/e1000/if_igb.c == --- head/sys/dev/e1000/if_igb.c Fri Jun 6 20:35:40 2014(r267186) +++ head/sys/dev/e1000/if_igb.c Fri Jun 6 20:49:56 2014(r267187) @@ -989,12 +989,12 @@ igb_mq_start(struct ifnet *ifp, struct m if (err) return (err); if (IGB_TX_TRYLOCK(txr)) { - err = igb_mq_start_locked(ifp, txr); + igb_mq_start_locked(ifp, txr); IGB_TX_UNLOCK(txr); } else taskqueue_enqueue(que-tq, txr-txq_task); - return (err); + return (0); } static int Modified: head/sys/dev/ixgbe/ixgbe.c == --- head/sys/dev/ixgbe/ixgbe.c Fri Jun 6 20:35:40 2014(r267186) +++ head/sys/dev/ixgbe/ixgbe.c Fri Jun 6 20:49:56 2014(r267187) @@ -831,12 +831,12 @@ ixgbe_mq_start(struct ifnet *ifp, struct if (err) return (err); if (IXGBE_TX_TRYLOCK(txr)) { - err = ixgbe_mq_start_locked(ifp, txr); + ixgbe_mq_start_locked(ifp, txr); IXGBE_TX_UNLOCK(txr); } else taskqueue_enqueue(que-tq, txr-txq_task); - return (err); + return (0); } static int Modified: head/sys/dev/vmware/vmxnet3/if_vmx.c == --- head/sys/dev/vmware/vmxnet3/if_vmx.cFri Jun 6 20:35:40 2014 (r267186) +++ head/sys/dev/vmware/vmxnet3/if_vmx.cFri Jun 6 20:49:56 2014 (r267187) @@ -2935,7 +2935,6 @@ vmxnet3_txq_mq_start_locked(struct vmxne /* Assume worse case if this mbuf is the head of a chain. */ if (m-m_next != NULL avail VMXNET3_TX_MAXSEGS) { drbr_putback(ifp, br, m); - error = ENOBUFS; break; } @@ -2958,7 +2957,7 @@ vmxnet3_txq_mq_start_locked(struct vmxne txq-vxtxq_watchdog = VMXNET3_WATCHDOG_TIMEOUT; } - return (error); + return (0); } static int ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267188 - in vendor-crypto/openssl/dist: . apps crypto crypto/asn1 crypto/bio crypto/bn crypto/cms crypto/dso crypto/ec crypto/evp crypto/pkcs12 crypto/pkcs7 crypto/rsa crypto/srp crypt...
Author: jkim Date: Fri Jun 6 20:59:29 2014 New Revision: 267188 URL: http://svnweb.freebsd.org/changeset/base/267188 Log: Import OpenSSL 1.0.1h. Approved by: so (delphij) Added: vendor-crypto/openssl/dist/ssl/heartbeat_test.c (contents, props changed) Modified: vendor-crypto/openssl/dist/ACKNOWLEDGMENTS vendor-crypto/openssl/dist/CHANGES vendor-crypto/openssl/dist/FREEBSD-upgrade vendor-crypto/openssl/dist/Makefile vendor-crypto/openssl/dist/NEWS vendor-crypto/openssl/dist/README vendor-crypto/openssl/dist/apps/enc.c vendor-crypto/openssl/dist/apps/ocsp.c vendor-crypto/openssl/dist/apps/req.c vendor-crypto/openssl/dist/apps/s_cb.c vendor-crypto/openssl/dist/apps/s_socket.c vendor-crypto/openssl/dist/apps/smime.c vendor-crypto/openssl/dist/crypto/asn1/a_strnid.c vendor-crypto/openssl/dist/crypto/bio/bss_dgram.c vendor-crypto/openssl/dist/crypto/bn/bn_mont.c vendor-crypto/openssl/dist/crypto/cms/cms_env.c vendor-crypto/openssl/dist/crypto/cms/cms_sd.c vendor-crypto/openssl/dist/crypto/cms/cms_smime.c vendor-crypto/openssl/dist/crypto/dso/dso_dlfcn.c vendor-crypto/openssl/dist/crypto/ec/ec_ameth.c vendor-crypto/openssl/dist/crypto/ec/ec_asn1.c vendor-crypto/openssl/dist/crypto/ec/ec_lcl.h vendor-crypto/openssl/dist/crypto/evp/bio_b64.c vendor-crypto/openssl/dist/crypto/evp/encode.c vendor-crypto/openssl/dist/crypto/opensslv.h vendor-crypto/openssl/dist/crypto/pkcs12/p12_crt.c vendor-crypto/openssl/dist/crypto/pkcs12/p12_kiss.c vendor-crypto/openssl/dist/crypto/pkcs7/pk7_doit.c vendor-crypto/openssl/dist/crypto/pkcs7/pkcs7.h vendor-crypto/openssl/dist/crypto/pkcs7/pkcs7err.c vendor-crypto/openssl/dist/crypto/rsa/rsa_ameth.c vendor-crypto/openssl/dist/crypto/srp/srp_vfy.c vendor-crypto/openssl/dist/crypto/ts/ts_rsp_verify.c vendor-crypto/openssl/dist/crypto/x509v3/v3_purp.c vendor-crypto/openssl/dist/doc/apps/cms.pod vendor-crypto/openssl/dist/doc/apps/enc.pod vendor-crypto/openssl/dist/doc/apps/s_server.pod vendor-crypto/openssl/dist/doc/apps/smime.pod vendor-crypto/openssl/dist/doc/apps/verify.pod vendor-crypto/openssl/dist/doc/apps/version.pod vendor-crypto/openssl/dist/doc/apps/x509v3_config.pod vendor-crypto/openssl/dist/doc/crypto/CMS_decrypt.pod vendor-crypto/openssl/dist/doc/crypto/CONF_modules_free.pod vendor-crypto/openssl/dist/doc/crypto/CONF_modules_load_file.pod vendor-crypto/openssl/dist/doc/crypto/OPENSSL_config.pod vendor-crypto/openssl/dist/doc/crypto/X509_NAME_ENTRY_get_object.pod vendor-crypto/openssl/dist/doc/crypto/X509_STORE_CTX_get_ex_new_index.pod vendor-crypto/openssl/dist/doc/fingerprints.txt vendor-crypto/openssl/dist/doc/ssl/SSL_COMP_add_compression_method.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_add_session.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_load_verify_locations.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_set_client_CA_list.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_set_msg_callback.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_set_options.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_set_session_id_context.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_set_ssl_version.pod vendor-crypto/openssl/dist/doc/ssl/SSL_CTX_use_psk_identity_hint.pod vendor-crypto/openssl/dist/doc/ssl/SSL_accept.pod vendor-crypto/openssl/dist/doc/ssl/SSL_clear.pod vendor-crypto/openssl/dist/doc/ssl/SSL_connect.pod vendor-crypto/openssl/dist/doc/ssl/SSL_do_handshake.pod vendor-crypto/openssl/dist/doc/ssl/SSL_get_peer_cert_chain.pod vendor-crypto/openssl/dist/doc/ssl/SSL_read.pod vendor-crypto/openssl/dist/doc/ssl/SSL_session_reused.pod vendor-crypto/openssl/dist/doc/ssl/SSL_set_fd.pod vendor-crypto/openssl/dist/doc/ssl/SSL_set_session.pod vendor-crypto/openssl/dist/doc/ssl/SSL_shutdown.pod vendor-crypto/openssl/dist/doc/ssl/SSL_write.pod vendor-crypto/openssl/dist/engines/ccgost/gost_ameth.c vendor-crypto/openssl/dist/ssl/Makefile vendor-crypto/openssl/dist/ssl/d1_both.c vendor-crypto/openssl/dist/ssl/d1_lib.c vendor-crypto/openssl/dist/ssl/d1_pkt.c vendor-crypto/openssl/dist/ssl/d1_srvr.c vendor-crypto/openssl/dist/ssl/s3_clnt.c vendor-crypto/openssl/dist/ssl/s3_pkt.c vendor-crypto/openssl/dist/ssl/s3_srvr.c vendor-crypto/openssl/dist/ssl/ssl.h vendor-crypto/openssl/dist/ssl/ssl3.h vendor-crypto/openssl/dist/ssl/ssl_asn1.c vendor-crypto/openssl/dist/ssl/ssl_err.c vendor-crypto/openssl/dist/ssl/ssl_lib.c vendor-crypto/openssl/dist/ssl/t1_enc.c vendor-crypto/openssl/dist/ssl/t1_lib.c Modified: vendor-crypto/openssl/dist/ACKNOWLEDGMENTS == --- vendor-crypto/openssl/dist/ACKNOWLEDGMENTS Fri Jun 6 20:49:56 2014 (r267187) +++ vendor-crypto/openssl/dist/ACKNOWLEDGMENTS Fri Jun 6 20:59:29 2014 (r267188) @@ -10,13 +10,18 @@ OpenSSL project. We would like to identify and thank the following such sponsors for their
svn commit: r267189 - vendor-crypto/openssl/1.0.1h
Author: jkim Date: Fri Jun 6 21:00:19 2014 New Revision: 267189 URL: http://svnweb.freebsd.org/changeset/base/267189 Log: Tag OpenSSL 1.0.1h. Added: vendor-crypto/openssl/1.0.1h/ - copied from r267188, vendor-crypto/openssl/dist/ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r267027 - head/usr.bin/users
On Thu, 5 Jun 2014, Pietro Cerutti wrote: your comments do make sense. I semi-seriously suggest that we get rid of the current implementation and replace it with this. Comments? Not for me, thanks. ... int main(int argc, char **) { struct utmpx *ut; vectorstring names; if (argc 1) { cerr usage: users endl; return (1); } This doesn't give quite the same error handling as the getopt() call, but the C version could use the same simplification. The C version even has dead code for argc and argc. It has almost as many style bugs as the above. setutxent(); while ((ut = getutxent()) != NULL) { if (ut-ut_type != USER_PROCESS) continue; names.push_back(ut-ut_user); } This is simpler, but the C version does much more than needed too. ut_user is now guaranteed to be NUL terminated. The above depends on this, but the current version still uses old code that adds a NUL terminator. This gives minor complications. It should be possible to build an array of pointers and just sort that. However, the getutxent() API is nasty, and is under-documented in FreeBSD. It returns a pointer to static storage (perhaps thread-local), as is common for bad old APIs. This is documented in POSIX, but doesn't seem to be documented in FreeBSD. It is obviously not expected that there be a large number of users (else the serial API would be worse than it is), so a small amount of statically allocated storage should be enough, especially if the application only has to hold the pointers and the database holds the strings. The 4.4BSD-Lite version of user(1) had a fixed limit of 200 users. Memory is free-er than it used to be, especially virtually, so no one would notice the bloat for statically allocating enough for a measly few million users, but in practice a few thousand should be enough. The unformatted output is bad for just 200 users. The above has only C++ default error handling. I know little about C++, but doubt that you it matches the errx() reporting exactly. Of course, realloc() can't fail, especially with only a few million users, so no error handling would work too. If there is a memory shortage, then getutxent() might fail too and its API doesn't even allow determining if there was an error -- the output would be truncated; I prefer a core dump. endutxent(); if (names.size() == 0) { return (0); } The C version can use the same simplifcation (to reduce indentation). sort(begin(names), end(names)); vectorstring::iterator last(unique(begin(names), end(names))); copy(begin(names), last-1, ostream_iteratorstring(cout, )); cout *(last-1) endl; } This is not simpler. I prefer to iterate with a for loop (that is not obfuscated with a macro). The C code is simple and was mostly correct here. Except it has the usual null error checking for printf() failure, and bogus void'ing of the return value. The above seems to duplicate the null error handling. Bruce ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267190 - in vendor-crypto/openssl/dist-0.9.8: . apps crypto crypto/asn1 crypto/bn crypto/cms crypto/ec crypto/engine crypto/err crypto/evp crypto/pkcs12 demos/x509 doc doc/apps doc/cry...
Author: jkim Date: Fri Jun 6 21:38:34 2014 New Revision: 267190 URL: http://svnweb.freebsd.org/changeset/base/267190 Log: Import OpenSSL 0.9.8za. Approved by: so (delphij) Deleted: vendor-crypto/openssl/dist-0.9.8/test/srptest.c vendor-crypto/openssl/dist-0.9.8/test/wp_test.c Modified: vendor-crypto/openssl/dist-0.9.8/ACKNOWLEDGMENTS vendor-crypto/openssl/dist-0.9.8/CHANGES vendor-crypto/openssl/dist-0.9.8/Configure vendor-crypto/openssl/dist-0.9.8/FAQ vendor-crypto/openssl/dist-0.9.8/FREEBSD-upgrade vendor-crypto/openssl/dist-0.9.8/Makefile vendor-crypto/openssl/dist-0.9.8/Makefile.org vendor-crypto/openssl/dist-0.9.8/NEWS vendor-crypto/openssl/dist-0.9.8/README vendor-crypto/openssl/dist-0.9.8/apps/apps.c vendor-crypto/openssl/dist-0.9.8/apps/ocsp.c vendor-crypto/openssl/dist-0.9.8/apps/req.c vendor-crypto/openssl/dist-0.9.8/apps/s_cb.c vendor-crypto/openssl/dist-0.9.8/apps/smime.c vendor-crypto/openssl/dist-0.9.8/crypto/asn1/a_int.c vendor-crypto/openssl/dist-0.9.8/crypto/asn1/a_strnid.c vendor-crypto/openssl/dist-0.9.8/crypto/asn1/t_pkey.c vendor-crypto/openssl/dist-0.9.8/crypto/bn/bn.h vendor-crypto/openssl/dist-0.9.8/crypto/bn/bn_lib.c vendor-crypto/openssl/dist-0.9.8/crypto/bn/bn_mont.c vendor-crypto/openssl/dist-0.9.8/crypto/cms/cms_cd.c vendor-crypto/openssl/dist-0.9.8/crypto/cms/cms_env.c vendor-crypto/openssl/dist-0.9.8/crypto/cms/cms_lib.c vendor-crypto/openssl/dist-0.9.8/crypto/cms/cms_sd.c vendor-crypto/openssl/dist-0.9.8/crypto/cms/cms_smime.c vendor-crypto/openssl/dist-0.9.8/crypto/ec/ec2_mult.c vendor-crypto/openssl/dist-0.9.8/crypto/ec/ec_lib.c vendor-crypto/openssl/dist-0.9.8/crypto/engine/eng_all.c vendor-crypto/openssl/dist-0.9.8/crypto/engine/engine.h vendor-crypto/openssl/dist-0.9.8/crypto/err/err_all.c vendor-crypto/openssl/dist-0.9.8/crypto/err/openssl.ec vendor-crypto/openssl/dist-0.9.8/crypto/evp/bio_b64.c vendor-crypto/openssl/dist-0.9.8/crypto/evp/encode.c vendor-crypto/openssl/dist-0.9.8/crypto/opensslv.h vendor-crypto/openssl/dist-0.9.8/crypto/pkcs12/p12_crt.c vendor-crypto/openssl/dist-0.9.8/crypto/pkcs12/p12_kiss.c vendor-crypto/openssl/dist-0.9.8/crypto/x86cpuid.pl vendor-crypto/openssl/dist-0.9.8/demos/x509/mkreq.c vendor-crypto/openssl/dist-0.9.8/doc/apps/smime.pod vendor-crypto/openssl/dist-0.9.8/doc/apps/verify.pod vendor-crypto/openssl/dist-0.9.8/doc/crypto/CONF_modules_free.pod vendor-crypto/openssl/dist-0.9.8/doc/crypto/CONF_modules_load_file.pod vendor-crypto/openssl/dist-0.9.8/doc/crypto/ERR_get_error.pod vendor-crypto/openssl/dist-0.9.8/doc/crypto/OPENSSL_config.pod vendor-crypto/openssl/dist-0.9.8/doc/crypto/X509_NAME_ENTRY_get_object.pod vendor-crypto/openssl/dist-0.9.8/doc/crypto/ecdsa.pod vendor-crypto/openssl/dist-0.9.8/doc/fingerprints.txt vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_CTX_set_client_CA_list.pod vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_CTX_set_msg_callback.pod vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_CTX_set_options.pod vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_accept.pod vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_connect.pod vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_do_handshake.pod vendor-crypto/openssl/dist-0.9.8/doc/ssl/SSL_shutdown.pod vendor-crypto/openssl/dist-0.9.8/openssl.spec vendor-crypto/openssl/dist-0.9.8/ssl/d1_both.c vendor-crypto/openssl/dist-0.9.8/ssl/d1_lib.c vendor-crypto/openssl/dist-0.9.8/ssl/d1_pkt.c vendor-crypto/openssl/dist-0.9.8/ssl/d1_srvr.c vendor-crypto/openssl/dist-0.9.8/ssl/s23_clnt.c vendor-crypto/openssl/dist-0.9.8/ssl/s3_cbc.c vendor-crypto/openssl/dist-0.9.8/ssl/s3_clnt.c vendor-crypto/openssl/dist-0.9.8/ssl/s3_enc.c vendor-crypto/openssl/dist-0.9.8/ssl/s3_lib.c vendor-crypto/openssl/dist-0.9.8/ssl/s3_pkt.c vendor-crypto/openssl/dist-0.9.8/ssl/s3_srvr.c vendor-crypto/openssl/dist-0.9.8/ssl/ssl.h vendor-crypto/openssl/dist-0.9.8/ssl/ssl3.h vendor-crypto/openssl/dist-0.9.8/ssl/ssl_err.c vendor-crypto/openssl/dist-0.9.8/ssl/ssl_lib.c vendor-crypto/openssl/dist-0.9.8/ssl/ssl_stat.c vendor-crypto/openssl/dist-0.9.8/ssl/ssltest.c vendor-crypto/openssl/dist-0.9.8/ssl/t1_enc.c vendor-crypto/openssl/dist-0.9.8/ssl/t1_lib.c vendor-crypto/openssl/dist-0.9.8/ssl/tls1.h vendor-crypto/openssl/dist-0.9.8/test/Makefile vendor-crypto/openssl/dist-0.9.8/test/cms-test.pl vendor-crypto/openssl/dist-0.9.8/test/mdc2test.c vendor-crypto/openssl/dist-0.9.8/test/testssl vendor-crypto/openssl/dist-0.9.8/util/libeay.num vendor-crypto/openssl/dist-0.9.8/util/pl/VC-32.pl Modified: vendor-crypto/openssl/dist-0.9.8/ACKNOWLEDGMENTS == --- vendor-crypto/openssl/dist-0.9.8/ACKNOWLEDGMENTSFri Jun 6 21:00:19 2014(r267189) +++ vendor-crypto/openssl/dist-0.9.8/ACKNOWLEDGMENTSFri Jun 6 21:38:34 2014(r267190) @@ -10,13 +10,18 @@ OpenSSL project. We
svn commit: r267191 - head/sys/fs/nfsserver
Author: rmacklem Date: Fri Jun 6 21:38:49 2014 New Revision: 267191 URL: http://svnweb.freebsd.org/changeset/base/267191 Log: The new NFS server would not allow a hard link to be created to a symlink. This restriction (which was inherited from OpenBSD) is not required by the NFS RFCs. Since this is allowed by the old NFS server, it is a POLA violation to not allow it. This patch modifies the new NFS server to allow this. Reported by: jhb Reviewed by: jhb MFC after:3 days Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c == --- head/sys/fs/nfsserver/nfs_nfsdserv.cFri Jun 6 21:38:34 2014 (r267190) +++ head/sys/fs/nfsserver/nfs_nfsdserv.cFri Jun 6 21:38:49 2014 (r267191) @@ -1620,13 +1620,6 @@ nfsrvd_link(struct nfsrv_descript *nd, i nd-nd_repstat = NFSERR_INVAL; if (tovp) vrele(tovp); - } else if (vnode_vtype(vp) == VLNK) { - if (nd-nd_flag ND_NFSV2) - nd-nd_repstat = NFSERR_INVAL; - else - nd-nd_repstat = NFSERR_NOTSUPP; - if (tovp) - vrele(tovp); } if (!nd-nd_repstat) { if (nd-nd_flag ND_NFSV4) { ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267192 - vendor-crypto/openssl/0.9.8za
Author: jkim Date: Fri Jun 6 21:39:16 2014 New Revision: 267192 URL: http://svnweb.freebsd.org/changeset/base/267192 Log: Tag OpenSSL 0.9.8za. Added: vendor-crypto/openssl/0.9.8za/ - copied from r267191, vendor-crypto/openssl/dist-0.9.8/ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267193 - in stable/10: sys/net sys/netinet tests/sys/netinet
Author: asomers Date: Fri Jun 6 21:45:14 2014 New Revision: 267193 URL: http://svnweb.freebsd.org/changeset/base/267193 Log: MFC r264887 Fix host and network routes for new interfaces when net.add_addr_allfibs=0 sys/net/route.c In rtinit1, use the interface fib instead of the process fib. The latter wasn't very useful because ifconfig(8) is usually invoked with the default process fib. Changing ifconfig(8) to use setfib(2) would be redundant, because it already sets the interface fib. tests/sys/netinet/fibs_test.sh Clear the expected ATF failure sys/net/if.c Pass the interface fib in calls to rtrequest1_fib and rtalloc1_fib sys/netinet/in.c sys/net/if_var.h Add a fibnum argument to ifa_switch_loopback_route, a subroutine of in_scrubprefix. Pass it the interface fib. Modified: stable/10/sys/net/if.c stable/10/sys/net/route.c stable/10/sys/netinet/in.c stable/10/tests/sys/netinet/fibs_test.sh Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/net/if.c == --- stable/10/sys/net/if.c Fri Jun 6 21:39:16 2014(r267192) +++ stable/10/sys/net/if.c Fri Jun 6 21:45:14 2014(r267193) @@ -1458,7 +1458,7 @@ ifa_add_loopback_route(struct ifaddr *if info.rti_flags = ifa-ifa_flags | RTF_HOST | RTF_STATIC; info.rti_info[RTAX_DST] = ia; info.rti_info[RTAX_GATEWAY] = (struct sockaddr *)null_sdl; - error = rtrequest1_fib(RTM_ADD, info, rt, 0); + error = rtrequest1_fib(RTM_ADD, info, rt, ifa-ifa_ifp-if_fib); if (error == 0 rt != NULL) { RT_LOCK(rt); @@ -1490,7 +1490,7 @@ ifa_del_loopback_route(struct ifaddr *if info.rti_flags = ifa-ifa_flags | RTF_HOST | RTF_STATIC; info.rti_info[RTAX_DST] = ia; info.rti_info[RTAX_GATEWAY] = (struct sockaddr *)null_sdl; - error = rtrequest1_fib(RTM_DELETE, info, NULL, 0); + error = rtrequest1_fib(RTM_DELETE, info, NULL, ifa-ifa_ifp-if_fib); if (error != 0) log(LOG_DEBUG, %s: deletion failed: %u\n, __func__, error); Modified: stable/10/sys/net/route.c == --- stable/10/sys/net/route.c Fri Jun 6 21:39:16 2014(r267192) +++ stable/10/sys/net/route.c Fri Jun 6 21:45:14 2014(r267193) @@ -1543,7 +1543,7 @@ rtinit1(struct ifaddr *ifa, int cmd, int } if (fibnum == RT_ALL_FIBS) { if (rt_add_addr_allfibs == 0 cmd == (int)RTM_ADD) { - startfib = endfib = curthread-td_proc-p_fibnum; + startfib = endfib = ifa-ifa_ifp-if_fib; } else { startfib = 0; endfib = rt_numfibs - 1; Modified: stable/10/sys/netinet/in.c == --- stable/10/sys/netinet/in.c Fri Jun 6 21:39:16 2014(r267192) +++ stable/10/sys/netinet/in.c Fri Jun 6 21:45:14 2014(r267193) @@ -1007,10 +1007,12 @@ in_scrubprefix(struct in_ifaddr *target, (target-ia_flags IFA_RTSELF)) { struct route ia_ro; int freeit = 0; + int fib; bzero(ia_ro, sizeof(ia_ro)); *((struct sockaddr_in *)(ia_ro.ro_dst)) = target-ia_addr; - rtalloc_ign_fib(ia_ro, 0, 0); + fib = target-ia_ifa.ifa_ifp-if_fib; + rtalloc_ign_fib(ia_ro, 0, fib); if ((ia_ro.ro_rt != NULL) (ia_ro.ro_rt-rt_ifp != NULL) (ia_ro.ro_rt-rt_ifp == V_loif)) { RT_LOCK(ia_ro.ro_rt); Modified: stable/10/tests/sys/netinet/fibs_test.sh == --- stable/10/tests/sys/netinet/fibs_test.shFri Jun 6 21:39:16 2014 (r267192) +++ stable/10/tests/sys/netinet/fibs_test.shFri Jun 6 21:45:14 2014 (r267193) @@ -116,7 +116,6 @@ loopback_and_network_routes_on_nondefaul loopback_and_network_routes_on_nondefault_fib_body() { - atf_expect_fail kern/187549 Host and network routes for a new interface appear in the wrong FIB # Configure the TAP interface to use an RFC5737 nonrouteable address # and a non-default fib ADDR=192.0.2.2 ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267194 - in head/share/vt: . keymaps
Author: ray Date: Fri Jun 6 21:58:27 2014 New Revision: 267194 URL: http://svnweb.freebsd.org/changeset/base/267194 Log: Add Ukranian vt(4) keymaps as an example. Sponsored by: The FreeBSD Foundation Added: head/share/vt/keymaps/ head/share/vt/keymaps/Makefile (contents, props changed) head/share/vt/keymaps/ua.kbd (contents, props changed) head/share/vt/keymaps/ua.shift.alt.kbd (contents, props changed) Modified: head/share/vt/Makefile Modified: head/share/vt/Makefile == --- head/share/vt/Makefile Fri Jun 6 21:45:14 2014(r267193) +++ head/share/vt/Makefile Fri Jun 6 21:58:27 2014(r267194) @@ -1,5 +1,5 @@ # $FreeBSD$ -SUBDIR= fonts +SUBDIR= fonts keymaps .include bsd.subdir.mk Added: head/share/vt/keymaps/Makefile == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/vt/keymaps/Makefile Fri Jun 6 21:58:27 2014 (r267194) @@ -0,0 +1,9 @@ +# $FreeBSD$ + +FILES= ua.kbd ua.shift.alt.kbd + +FILESDIR= ${SHAREDIR}/vt/keymaps + +NO_OBJ= + +.include bsd.prog.mk Added: head/share/vt/keymaps/ua.kbd == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/vt/keymaps/ua.kbdFri Jun 6 21:58:27 2014 (r267194) @@ -0,0 +1,242 @@ +# $FreeBSD$ +# alt +# scan cntrl altalt cntrl lock +# code base shift cntrl shift altshift cntrl shift state +# -- + 000 nopnopnopnopnopnopnopnop O + 001 escescescescescescdebug nop O + 002 '1''!'nopnop'1''!'nopnop O + 003 '2''@'nulnul'2'''nulnul O + 004 '3''#'nopnop'3''/'nopnop O + 005 '4''$'nopnop'4''$'nopnop O + 006 '5''%'nopnop'5'':'nopnop O + 007 '6''^'rs rs '6'','rs rs O + 008 '7'''nopnop'7''.'nopnop O + 009 '8''*'nopnop'8'';'nopnop O + 010 '9''('nopnop'9''?'nopnop O + 011 '0'')'nopnop'0''%'nopnop O + 012 '-''_'ns ns '-''_'ns ns O + 013 '=''+'nopnop'=''+'nopnop O + 014 bs bs deldelbs bs deldel O + 015 ht btab nopnopbtab btab nopnop O + 016 'q''Q'dc1dc110811049dc1dc1 C + 017 'w''W'etbetb10941062etbetb C + 018 'e''E'enqenq10911059enqenq C + 019 'r''R'dc2dc210821050dc2dc2 C + 020 't''T'dc4dc410771045dc4dc4 C + 021 'y''Y'em em 10851053em em C + 022 'u''U'naknak10751043naknak C + 023 'i''I'ht ht 10961064ht ht C + 024 'o''O'si si 10971065si si C + 025 'p''P'dledle10791047dledle C + 026 '[''{'escesc10931061escesc O + 027 ']''}'gs gs 103110981066 O + 028 cr cr nl nl cr cr nl nl O + 029 lctrl lctrl lctrl lctrl lctrl lctrl lctrl lctrl O + 030 'a''A'sohsoh10921060sohsoh C + 031 's''S'dc3dc31110103010991067 C + 032 'd''D'eoteot10741042eoteot C + 033 'f''F'ackack10721040ackack C + 034 'g''G'belbel10871055belbel C + 035 'h''H'bs bs 10881056bs bs C + 036 'j''J'nl nl 10861054nl nl C + 037 'k''K'vt vt 10831051vt vt C + 038 'l''L'ff ff 10761044ff ff C + 039 ';'':'nopnop10781046nopnop O + 040 '''''nopnop1108102811011069 O + 041 '`''~'nopnop1169116811051025 O + 042 lshift lshift lshift lshift lshift lshift lshift lshift O + 043 '\''|'fs fs '\''|'fs fs O + 044 'z''Z'subsub11031071subsub C + 045 'x''X'cancan10951063cancan C + 046 'c'
svn commit: r267195 - in stable/10: sys/netinet tests/sys/netinet
Author: asomers Date: Fri Jun 6 22:14:25 2014 New Revision: 267195 URL: http://svnweb.freebsd.org/changeset/base/267195 Log: MFC changes related to PR kern/189089. Unlike CURRENT, stable/10 does not panic when you attempt to remove the IP address. But it still fails to remove the address. MFC r265094 Add regression test for PR kern/189088. MFC r265092 Fix a panic when removing an IP address from an interface, if the same address exists on another interface. The panic was introduced by change 264887, which changed the fibnum parameter in the call to rtalloc1_fib() in ifa_switch_loopback_route() from RT_DEFAULT_FIB to RT_ALL_FIBS. The solution is to use the interface fib in that call. For the majority of users, that will be equivalent to the legacy behavior. Modified: stable/10/sys/netinet/in.c stable/10/tests/sys/netinet/fibs_test.sh Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/netinet/in.c == --- stable/10/sys/netinet/in.c Fri Jun 6 21:58:27 2014(r267194) +++ stable/10/sys/netinet/in.c Fri Jun 6 22:14:25 2014(r267195) @@ -987,11 +987,9 @@ in_scrubprefix(struct in_ifaddr *target, { struct in_ifaddr *ia; struct in_addr prefix, mask, p, m; - int error = 0, fibnum; + int error = 0; struct sockaddr_in prefix0, mask0; - fibnum = rt_add_addr_allfibs ? RT_ALL_FIBS : target-ia_ifp-if_fib; - /* * Remove the loopback route to the interface address. * The useloopback setting is not consulted because if the @@ -1046,6 +1044,10 @@ in_scrubprefix(struct in_ifaddr *target, } if ((target-ia_flags IFA_ROUTE) == 0) { + int fibnum; + + fibnum = rt_add_addr_allfibs ? RT_ALL_FIBS : + target-ia_ifp-if_fib; rt_addrmsg(RTM_DELETE, target-ia_ifa, fibnum); return (0); } Modified: stable/10/tests/sys/netinet/fibs_test.sh == --- stable/10/tests/sys/netinet/fibs_test.shFri Jun 6 21:58:27 2014 (r267194) +++ stable/10/tests/sys/netinet/fibs_test.shFri Jun 6 22:14:25 2014 (r267195) @@ -213,6 +213,98 @@ default_route_with_multiple_fibs_on_same } +# Regression test for PR kern/189089 +# Create two tap interfaces and assign them both the same IP address but with +# different netmasks, and both on the default FIB. Then remove one's IP +# address. Hopefully the machine won't panic. +atf_test_case same_ip_multiple_ifaces_fib0 cleanup +same_ip_multiple_ifaces_fib0_head() +{ + atf_set descr Can remove an IP alias from an interface when the same IP is also assigned to another interface. + atf_set require.user root + atf_set require.config fibs +} +same_ip_multiple_ifaces_fib0_body() +{ + ADDR=192.0.2.2 + MASK0=24 + MASK1=32 + + # Unlike most of the tests in this file, this is applicable regardless + # of net.add_addr_allfibs + + # Setup the interfaces, then remove one alias. It should not panic. + setup_tap 0 ${ADDR} ${MASK0} + TAP0=${TAP} + setup_tap 0 ${ADDR} ${MASK1} + TAP1=${TAP} + ifconfig ${TAP1} -alias ${ADDR} + + # Do it again, in the opposite order. It should not panic. + setup_tap 0 ${ADDR} ${MASK0} + TAP0=${TAP} + setup_tap 0 ${ADDR} ${MASK1} + TAP1=${TAP} + ifconfig ${TAP0} -alias ${ADDR} +} +same_ip_multiple_ifaces_fib0_cleanup() +{ + cleanup_tap +} + +# Regression test for PR kern/189088 +# Test that removing an IP address works even if the same IP is assigned to a +# different interface, on a different FIB. Tests the same code that whose +# panic was regressed by same_ip_multiple_ifaces_fib0. +# Create two tap interfaces and assign them both the same IP address but with +# different netmasks, and on different FIBs. Then remove one's IP +# address. Hopefully the machine won't panic. Also, the IP's hostroute should +# dissappear from the correct fib. +atf_test_case same_ip_multiple_ifaces cleanup +same_ip_multiple_ifaces_head() +{ + atf_set descr Can remove an IP alias from an interface when the same IP is also assigned to another interface, on non-default FIBs. + atf_set require.user root + atf_set require.config fibs +} +same_ip_multiple_ifaces_body() +{ + atf_expect_fail kern/189088 Assigning the same IP to multiple interfaces in different FIBs creates a host route for only one + ADDR=192.0.2.2 + MASK0=24 + MASK1=32 + + # Unlike most of the tests in this file, this is applicable regardless + # of net.add_addr_allfibs + get_fibs 2 + + # Setup the interfaces, then remove one alias. It should not panic. + setup_tap ${FIB0} ${ADDR} ${MASK0} +
svn commit: r267196 - head/bin/ps
Author: pluknet Date: Fri Jun 6 22:52:11 2014 New Revision: 267196 URL: http://svnweb.freebsd.org/changeset/base/267196 Log: Add support for inspecting process flags set in p_flag2. Reviewed by: jhb MFC after:1 week Modified: head/bin/ps/keyword.c head/bin/ps/ps.1 Modified: head/bin/ps/keyword.c == --- head/bin/ps/keyword.c Fri Jun 6 22:14:25 2014(r267195) +++ head/bin/ps/keyword.c Fri Jun 6 22:52:11 2014(r267196) @@ -87,8 +87,10 @@ static VAR var[] = { {etimes, ELAPSED, NULL, USER, elapseds, 0, CHAR, NULL, 0}, {euid, , uid, 0, NULL, 0, CHAR, NULL, 0}, {f, F, NULL, 0, kvar, KOFF(ki_flag), INT, x, 0}, + {f2, F2, NULL, 0, kvar, KOFF(ki_flag2), INT, 08x, 0}, {fib, FIB, NULL, 0, kvar, KOFF(ki_fibnum), INT, d, 0}, {flags, , f, 0, NULL, 0, CHAR, NULL, 0}, + {flags2, , f2, 0, NULL, 0, CHAR, NULL, 0}, {gid, GID, NULL, 0, kvar, KOFF(ki_groups), UINT, UIDFMT, 0}, {group, GROUP, NULL, LJUST, egroupname, 0, CHAR, NULL, 0}, {ignored, , sigignore, 0, NULL, 0, CHAR, NULL, 0}, Modified: head/bin/ps/ps.1 == --- head/bin/ps/ps.1Fri Jun 6 22:14:25 2014(r267195) +++ head/bin/ps/ps.1Fri Jun 6 22:52:11 2014(r267196) @@ -29,7 +29,7 @@ .\ @(#)ps.1 8.3 (Berkeley) 4/18/94 .\ $FreeBSD$ .\ -.Dd May 2, 2014 +.Dd June 6, 2014 .Dt PS 1 .Os .Sh NAME @@ -340,6 +340,15 @@ the include file .It Dv P_SWAPPINGIN Ta No 0x4000 Ta Process is being swapped in .It Dv P_PPTRACE Ta No 0x8000 Ta Vforked child issued ptrace(PT_TRACEME) .El +.It Cm flags2 +The flags kept in +.Va p_flag2 +associated with the process as in +the include file +.In sys/proc.h : +.Bl -column P2_INHERIT_PROTECTED 0x0001 +.It Dv P2_INHERIT_PROTECTED Ta No 0x0001 Ta New children get P_PROTECTED +.El .It Cm label The MAC label of the process. .It Cm lim @@ -534,6 +543,9 @@ default FIB number, see .It Cm flags the process flags, in hexadecimal (alias .Cm f ) +.It Cm flags2 +the additional set of process flags, in hexadecimal (alias +.Cm f2 ) .It Cm gid effective group ID (alias .Cm egid ) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267197 - in head/sys/boot/fdt/dts: . arm mips powerpc
Author: rpaulo Date: Fri Jun 6 23:53:59 2014 New Revision: 267197 URL: http://svnweb.freebsd.org/changeset/base/267197 Log: Add Makefiles to automatically test all the DTS files. There are several broken DTS files right now in the arm directory. Added: head/sys/boot/fdt/dts/Makefile (contents, props changed) head/sys/boot/fdt/dts/Makefile.inc (contents, props changed) head/sys/boot/fdt/dts/arm/Makefile (contents, props changed) head/sys/boot/fdt/dts/mips/Makefile (contents, props changed) head/sys/boot/fdt/dts/powerpc/Makefile (contents, props changed) Added: head/sys/boot/fdt/dts/Makefile == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/Makefile Fri Jun 6 23:53:59 2014 (r267197) @@ -0,0 +1,5 @@ +# $FreeBSD$ + +SUBDIR=arm mips powerpc + +.include bsd.subdir.mk Added: head/sys/boot/fdt/dts/Makefile.inc == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/Makefile.inc Fri Jun 6 23:53:59 2014 (r267197) @@ -0,0 +1,7 @@ +# $FreeBSD$ + +test-dts: +.for dts in ${DTS} + dtc -I dts -O dtb -o /dev/null ${dts} +.endfor + Added: head/sys/boot/fdt/dts/arm/Makefile == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/arm/Makefile Fri Jun 6 23:53:59 2014 (r267197) @@ -0,0 +1,7 @@ +# $FreeBSD$ + +DTS!=ls *.dts + +all: test-dts + +.include bsd.init.mk Added: head/sys/boot/fdt/dts/mips/Makefile == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/mips/Makefile Fri Jun 6 23:53:59 2014 (r267197) @@ -0,0 +1,7 @@ +# $FreeBSD$ + +DTS!=ls *.dts + +all: test-dts + +.include bsd.init.mk Added: head/sys/boot/fdt/dts/powerpc/Makefile == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/powerpc/Makefile Fri Jun 6 23:53:59 2014 (r267197) @@ -0,0 +1,7 @@ +# $FreeBSD$ + +DTS!=ls *.dts + +all: test-dts + +.include bsd.init.mk ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267198 -
Author: imp Date: Sat Jun 7 02:30:10 2014 New Revision: 267198 URL: http://svnweb.freebsd.org/changeset/base/267198 Log: Add WITH*, *.mk and *.inc patterns to the list. Modified: Directory Properties: / (props changed) ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267199 - head/sys/boot/fdt/dts
Author: rpaulo Date: Sat Jun 7 02:38:13 2014 New Revision: 267199 URL: http://svnweb.freebsd.org/changeset/base/267199 Log: Fix the script to run make_dtb.sh instead of just dtc. Modified: head/sys/boot/fdt/dts/Makefile.inc Modified: head/sys/boot/fdt/dts/Makefile.inc == --- head/sys/boot/fdt/dts/Makefile.inc Sat Jun 7 02:30:10 2014 (r267198) +++ head/sys/boot/fdt/dts/Makefile.inc Sat Jun 7 02:38:13 2014 (r267199) @@ -1,7 +1,10 @@ # $FreeBSD$ +SYSDIR?=${.CURDIR}/../../../.. + test-dts: .for dts in ${DTS} - dtc -I dts -O dtb -o /dev/null ${dts} + @env MACHINE=`basename ${.CURDIR}` ${SYSDIR}/tools/fdt/make_dtb.sh ${SYSDIR} ${dts} /tmp + .endfor ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267200 - in stable/10: lib/libthr/thread libexec/rtld-elf
Author: kib Date: Sat Jun 7 02:45:24 2014 New Revision: 267200 URL: http://svnweb.freebsd.org/changeset/base/267200 Log: MFC r266609: Change the _rtld_atfork() to lock the bind lock in write mode. Modified: stable/10/lib/libthr/thread/thr_fork.c stable/10/lib/libthr/thread/thr_rtld.c stable/10/libexec/rtld-elf/rtld_lock.c Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libthr/thread/thr_fork.c == --- stable/10/lib/libthr/thread/thr_fork.c Sat Jun 7 02:38:13 2014 (r267199) +++ stable/10/lib/libthr/thread/thr_fork.c Sat Jun 7 02:45:24 2014 (r267200) @@ -57,6 +57,7 @@ * */ +#include sys/syscall.h #include namespace.h #include errno.h #include link.h @@ -174,8 +175,15 @@ _fork(void) was_threaded = 0; } - /* Fork a new process: */ - if ((ret = __sys_fork()) == 0) { + /* +* Fork a new process. +* There is no easy way to pre-resolve the __sys_fork symbol +* without performing the fork. Use the syscall(2) +* indirection, the syscall symbol is resolved in +* _thr_rtld_init() with side-effect free call. +*/ + ret = syscall(SYS_fork); + if (ret == 0) { /* Child process */ errsave = errno; curthread-cancel_pending = 0; @@ -250,6 +258,5 @@ _fork(void) } errno = errsave; - /* Return the process ID: */ return (ret); } Modified: stable/10/lib/libthr/thread/thr_rtld.c == --- stable/10/lib/libthr/thread/thr_rtld.c Sat Jun 7 02:38:13 2014 (r267199) +++ stable/10/lib/libthr/thread/thr_rtld.c Sat Jun 7 02:45:24 2014 (r267200) @@ -32,10 +32,12 @@ */ #include sys/cdefs.h #include sys/mman.h +#include sys/syscall.h #include link.h #include stdlib.h #include string.h +#include libc_private.h #include rtld_lock.h #include thr_private.h @@ -207,7 +209,24 @@ _thr_rtld_init(void) li.thread_set_flag = _thr_rtld_set_flag; li.thread_clr_flag = _thr_rtld_clr_flag; li.at_fork = NULL; - + + /* +* Preresolve the symbols needed for the fork interposer. We +* call _rtld_atfork_pre() and _rtld_atfork_post() with NULL +* argument to indicate that no actual locking inside the +* functions should happen. Neither rtld compat locks nor +* libthr rtld locks cannot work there: +* - compat locks do not handle the case of two locks taken +* in write mode (the signal mask for the thread is corrupted); +* - libthr locks would work, but locked rtld_bind_lock prevents +* symbol resolution for _rtld_atfork_post. +*/ + _rtld_atfork_pre(NULL); + _rtld_atfork_post(NULL); + _malloc_prefork(); + _malloc_postfork(); + syscall(SYS_getpid); + /* mask signals, also force to resolve __sys_sigprocmask PLT */ _thr_signal_block(curthread); _rtld_thread_init(li); Modified: stable/10/libexec/rtld-elf/rtld_lock.c == --- stable/10/libexec/rtld-elf/rtld_lock.c Sat Jun 7 02:38:13 2014 (r267199) +++ stable/10/libexec/rtld-elf/rtld_lock.c Sat Jun 7 02:45:24 2014 (r267200) @@ -365,8 +365,19 @@ _rtld_atfork_pre(int *locks) { RtldLockState ls[2]; + if (locks == NULL) + return; + + /* +* Warning: this does not work with the rtld compat locks +* above, since the thread signal mask is corrupted (set to +* all signals blocked) if two locks are taken in write mode. +* The caller of the _rtld_atfork_pre() must provide the +* working implementation of the locks, and libthr locks are +* fine. +*/ wlock_acquire(rtld_phdr_lock, ls[0]); - rlock_acquire(rtld_bind_lock, ls[1]); + wlock_acquire(rtld_bind_lock, ls[1]); /* XXXKIB: I am really sorry for this. */ locks[0] = ls[1].lockstate; @@ -378,6 +389,9 @@ _rtld_atfork_post(int *locks) { RtldLockState ls[2]; + if (locks == NULL) + return; + bzero(ls, sizeof(ls)); ls[0].lockstate = locks[2]; ls[1].lockstate = locks[0]; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267201 - stable/10/usr.bin/yes
Author: kib Date: Sat Jun 7 02:49:39 2014 New Revision: 267201 URL: http://svnweb.freebsd.org/changeset/base/267201 Log: MFC r267067: Cross-reference jot(1) and seq(1). MFC r267098 (by pluknet): mdoc: drop the trailing dot from the xref list. Modified: stable/10/usr.bin/yes/yes.1 Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/yes/yes.1 == --- stable/10/usr.bin/yes/yes.1 Sat Jun 7 02:45:24 2014(r267200) +++ stable/10/usr.bin/yes/yes.1 Sat Jun 7 02:49:39 2014(r267201) @@ -28,7 +28,7 @@ .\ @(#)yes.1 8.1 (Berkeley) 6/6/93 .\ $FreeBSD$ .\ -.Dd June 6, 1993 +.Dd June 4, 2014 .Dt YES 1 .Os .Sh NAME @@ -45,6 +45,9 @@ utility outputs or, by default, .Dq y , forever. +.Sh SEE ALSO +.Xr jot 1 , +.Xr seq 1 .Sh HISTORY The .Nm ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r267202 - in head/sys/boot/fdt/dts: arm powerpc
Author: rpaulo Date: Sat Jun 7 02:55:53 2014 New Revision: 267202 URL: http://svnweb.freebsd.org/changeset/base/267202 Log: Mov p2041rdb.dts, p3041ds.dts, and p5020ds.dts to the powerpc directory. Added: head/sys/boot/fdt/dts/powerpc/p2041rdb.dts - copied unchanged from r267196, head/sys/boot/fdt/dts/arm/p2041rdb.dts head/sys/boot/fdt/dts/powerpc/p3041ds.dts - copied unchanged from r267196, head/sys/boot/fdt/dts/arm/p3041ds.dts head/sys/boot/fdt/dts/powerpc/p5020ds.dts - copied unchanged from r267196, head/sys/boot/fdt/dts/arm/p5020ds.dts Deleted: head/sys/boot/fdt/dts/arm/p2041rdb.dts head/sys/boot/fdt/dts/arm/p3041ds.dts head/sys/boot/fdt/dts/arm/p5020ds.dts Copied: head/sys/boot/fdt/dts/powerpc/p2041rdb.dts (from r267196, head/sys/boot/fdt/dts/arm/p2041rdb.dts) == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/powerpc/p2041rdb.dts Sat Jun 7 02:55:53 2014 (r267202, copy of r267196, head/sys/boot/fdt/dts/arm/p2041rdb.dts) @@ -0,0 +1,490 @@ +/* + * P2041RDB Device Tree Source + * + * Copyright 2011 Freescale Semiconductor Inc. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * 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. + * * Neither the name of Freescale Semiconductor nor the + * names of its contributors may be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * + * ALTERNATIVELY, this software may be distributed under the terms of the + * GNU General Public License (GPL) as published by the Free Software + * Foundation, either version 2 of that License or (at your option) any + * later version. + * + * THIS SOFTWARE IS PROVIDED BY Freescale Semiconductor ``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 Freescale Semiconductor 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$ */ + +/include/ p2041si.dtsi + +/ { + model = fsl,P2041RDB; + compatible = fsl,P2041RDB; + #address-cells = 2; + #size-cells = 2; + interrupt-parent = mpic; + + aliases { + phy_rgmii_0 = phy_rgmii_0; + phy_rgmii_1 = phy_rgmii_1; + phy_sgmii_2 = phy_sgmii_2; + phy_sgmii_3 = phy_sgmii_3; + phy_sgmii_4 = phy_sgmii_4; + phy_sgmii_1c = phy_sgmii_1c; + phy_sgmii_1d = phy_sgmii_1d; + phy_sgmii_1e = phy_sgmii_1e; + phy_sgmii_1f = phy_sgmii_1f; + phy_xgmii_2 = phy_xgmii_2; + }; + + memory { + device_type = memory; + reg = 0x 0x 0x 0x8000; + }; + + dcsr: dcsr@f { + ranges = 0x 0xf 0x 0x01008000; + }; + + bman-portals@ff400 { + bman-portal@0 { + cpu-handle = cpu0; + }; + bman-portal@4000 { + cpu-handle = cpu1; + }; + bman-portal@8000 { + cpu-handle = cpu2; + }; + bman-portal@c000 { + cpu-handle = cpu3; + }; + bman-portal@1 { + }; + bman-portal@14000 { + }; + bman-portal@18000 { + }; + bman-portal@1c000 { + }; + bman-portal@2 { + }; + bman-portal@24000 { + }; + + buffer-pool@0 { + compatible = fsl,p2041-bpool, fsl,bpool; + fsl,bpid = 0; + fsl,bpool-cfg = 0 0x100 0 1 0 0x100; + }; + }; + + qman-portals@ff420 { + qportal0: qman-portal@0 { + cpu-handle =
svn commit: r267203 - stable/9/usr.bin/yes
Author: kib Date: Sat Jun 7 03:39:12 2014 New Revision: 267203 URL: http://svnweb.freebsd.org/changeset/base/267203 Log: MFC r267067: Cross-reference jot(1) and seq(1). MFC r267098 (by pluknet): mdoc: drop the trailing dot from the xref list. Approved by: re (gjb) Modified: stable/9/usr.bin/yes/yes.1 Directory Properties: stable/9/usr.bin/yes/ (props changed) Modified: stable/9/usr.bin/yes/yes.1 == --- stable/9/usr.bin/yes/yes.1 Sat Jun 7 02:55:53 2014(r267202) +++ stable/9/usr.bin/yes/yes.1 Sat Jun 7 03:39:12 2014(r267203) @@ -28,7 +28,7 @@ .\ @(#)yes.1 8.1 (Berkeley) 6/6/93 .\ $FreeBSD$ .\ -.Dd June 6, 1993 +.Dd June 4, 2014 .Dt YES 1 .Os .Sh NAME @@ -45,6 +45,9 @@ utility outputs or, by default, .Dq y , forever. +.Sh SEE ALSO +.Xr jot 1 , +.Xr seq 1 .Sh HISTORY The .Nm ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org