From owner-svn-src-stable-11@freebsd.org Sun Sep 6 10:23:14 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9647C3CD0A5; Sun, 6 Sep 2020 10:23:14 +0000 (UTC) (envelope-from zec@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BknYZ3W2sz3TGc; Sun, 6 Sep 2020 10:23:14 +0000 (UTC) (envelope-from zec@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 43FFBD3A5; Sun, 6 Sep 2020 10:23:14 +0000 (UTC) (envelope-from zec@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 086ANEpf090127; Sun, 6 Sep 2020 10:23:14 GMT (envelope-from zec@FreeBSD.org) Received: (from zec@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 086ANDIU090124; Sun, 6 Sep 2020 10:23:13 GMT (envelope-from zec@FreeBSD.org) Message-Id: <202009061023.086ANDIU090124@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zec set sender to zec@FreeBSD.org using -f From: Marko Zec Date: Sun, 6 Sep 2020 10:23:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365375 - in stable/11: share/man/man4 sys/conf sys/dev/sume sys/modules sys/modules/sume X-SVN-Group: stable-11 X-SVN-Commit-Author: zec X-SVN-Commit-Paths: in stable/11: share/man/man4 sys/conf sys/dev/sume sys/modules sys/modules/sume X-SVN-Commit-Revision: 365375 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Sep 2020 10:23:14 -0000 Author: zec Date: Sun Sep 6 10:23:13 2020 New Revision: 365375 URL: https://svnweb.freebsd.org/changeset/base/365375 Log: MFC r364973: Driver for 4x10Gb Ethernet reference NIC FPGA design for NetFPGA SUME development board. Submitted by: Denis Salopek Reviewed by: zec, bz (src); rgrimes, bcr (manpages) Sponsored by: Google Summer of Code 2020 Differential Revision: https://reviews.freebsd.org/D26074 Added: stable/11/share/man/man4/sume.4 - copied unchanged from r364973, head/share/man/man4/sume.4 stable/11/sys/dev/sume/ - copied from r364973, head/sys/dev/sume/ stable/11/sys/modules/sume/ - copied from r364973, head/sys/modules/sume/ Modified: stable/11/share/man/man4/Makefile stable/11/sys/conf/files.amd64 stable/11/sys/modules/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/share/man/man4/Makefile ============================================================================== --- stable/11/share/man/man4/Makefile Sun Sep 6 10:18:59 2020 (r365374) +++ stable/11/share/man/man4/Makefile Sun Sep 6 10:23:13 2020 (r365375) @@ -533,6 +533,7 @@ MAN= aac.4 \ stf.4 \ stg.4 \ stge.4 \ + ${_sume.4} \ sym.4 \ syncache.4 \ syncer.4 \ @@ -884,12 +885,14 @@ _qlxgbe.4= qlxgbe.4 _qlnxe.4= qlnxe.4 _sfxge.4= sfxge.4 _smartpqi.4= smartpqi.4 +_sume.4= sume.4 MLINKS+=qlxge.4 if_qlxge.4 MLINKS+=qlxgb.4 if_qlxgb.4 MLINKS+=qlxgbe.4 if_qlxgbe.4 MLINKS+=qlnxe.4 if_qlnxe.4 MLINKS+=sfxge.4 if_sfxge.4 +MLINKS+=sume.4 if_sume.4 .if ${MK_BHYVE} != "no" _bhyve.4= bhyve.4 Copied: stable/11/share/man/man4/sume.4 (from r364973, head/share/man/man4/sume.4) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/share/man/man4/sume.4 Sun Sep 6 10:23:13 2020 (r365375, copy of r364973, head/share/man/man4/sume.4) @@ -0,0 +1,98 @@ +.\"- +.\" SPDX-License-Identifier: BSD-2-Clause-FreeBSD +.\" +.\" Copyright (c) 2020 Denis Salopek +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +.\" POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD$ +.\" +.Dd August 30, 2020 +.Dt SUME 4 +.Os +.Sh NAME +.Nm sume +.Nd "NetFPGA SUME 4x10Gb Ethernet driver" +.Sh SYNOPSIS +To compile this driver into the kernel, place the following lines +in your kernel configuration file: +.Bd -ragged -offset indent +.Cd "device sume" +.Ed +.Pp +Alternatively, to load the driver as a module at boot time, place +the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_sume_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for NetFPGA SUME Virtex-7 FPGA Development Board +with the reference NIC bitstream loaded onto it. +The HDL design for the reference NIC project uses the RIFFA based DMA +engine to communicate with the host machine over PCIe. +Every packet is transmitted to / from the board via a single DMA +transaction, taking up to two or three interrupts per one transaction +which yields low performance. +.Pp +There is no support for Jumbo frames as the hardware is capable of +dealing only with frames with maximum size of 1514 bytes. +The hardware does not support multicast filtering, provides no checksums, +and offers no other offloading. +.Sh SEE ALSO +.Xr arp 4 , +.Xr netgraph 4 , +.Xr netintro 4 , +.Xr ng_ether 4 , +.Xr vlan 4 , +.Xr ifconfig 8 +.Sh AUTHORS +The Linux +.Nm +driver was originally written by +.An -nosplit +.An Bjoern A. Zeeb . +The +.Fx version and this manual page were written by +.An Denis Salopek +as a GSoC project. +More information about the project can be found here: +.Pa https://wiki.freebsd.org/SummerOfCode2020Projects/NetFPGA_SUME_Driver +.Sh BUGS +The reference NIC hardware design provides no mechanism for quiescing +inbound traffic from interfaces configured as DOWN. +All packets from administratively disabled interfaces are transferred to +main memory, leaving the driver with the task of dropping such packets, +thus consuming PCI bandwidth, interrupts and CPU cycles in vain. +.Pp +Pre-built FPGA bitstream from the NetFPGA project may not work correctly. +At higher RX packet rates, the newly incoming packets can overwrite the +ones in an internal FIFO so the packets would arrive in main memory +corrupted, until a physical reset of the board. +.Pp +Occasionally, the driver can get stuck in a non-IDLE TX state due to +a missed interrupt. +The driver includes a watchdog function which monitors for such a +condition and resets the board automatically. +For more details, visit the NetFPGA SUME project site. Modified: stable/11/sys/conf/files.amd64 ============================================================================== --- stable/11/sys/conf/files.amd64 Sun Sep 6 10:18:59 2020 (r365374) +++ stable/11/sys/conf/files.amd64 Sun Sep 6 10:23:13 2020 (r365375) @@ -467,6 +467,7 @@ dev/smartpqi/smartpqi_response.c optional smartpqi dev/smartpqi/smartpqi_sis.c optional smartpqi dev/smartpqi/smartpqi_tag.c optional smartpqi dev/speaker/spkr.c optional speaker +dev/sume/if_sume.c optional sume dev/syscons/apm/apm_saver.c optional apm_saver apm dev/syscons/scterm-teken.c optional sc dev/syscons/scvesactl.c optional sc vga vesa Modified: stable/11/sys/modules/Makefile ============================================================================== --- stable/11/sys/modules/Makefile Sun Sep 6 10:18:59 2020 (r365374) +++ stable/11/sys/modules/Makefile Sun Sep 6 10:23:13 2020 (r365375) @@ -374,6 +374,7 @@ SUBDIR= \ ${_stg} \ stge \ ${_streams} \ + ${_sume} \ ${_svr4} \ ${_sym} \ ${_syscons} \ @@ -735,6 +736,7 @@ _ntb= ntb _pms= pms _qlxge= qlxge _qlxgb= qlxgb +_sume= sume .if ${MK_SOURCELESS_UCODE} != "no" _qlxgbe= qlxgbe _qlnx= qlnx From owner-svn-src-stable-11@freebsd.org Mon Sep 7 10:49:43 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 8C5293EE887; Mon, 7 Sep 2020 10:49:43 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BlQ5g3BLSz3y1y; Mon, 7 Sep 2020 10:49:43 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 50D9E1DFEB; Mon, 7 Sep 2020 10:49:43 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087Anhvd092720; Mon, 7 Sep 2020 10:49:43 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087AngTP092718; Mon, 7 Sep 2020 10:49:42 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009071049.087AngTP092718@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 7 Sep 2020 10:49:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365410 - in stable/11/sys/dev/mlx5: . mlx5_core X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: in stable/11/sys/dev/mlx5: . mlx5_core X-SVN-Commit-Revision: 365410 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 10:49:43 -0000 Author: kib Date: Mon Sep 7 10:49:42 2020 New Revision: 365410 URL: https://svnweb.freebsd.org/changeset/base/365410 Log: MFC r364999: mlx5_core: Import PDDR register definitions Modified: stable/11/sys/dev/mlx5/driver.h stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h stable/11/sys/dev/mlx5/mlx5_ifc.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/mlx5/driver.h ============================================================================== --- stable/11/sys/dev/mlx5/driver.h Mon Sep 7 10:37:44 2020 (r365409) +++ stable/11/sys/dev/mlx5/driver.h Mon Sep 7 10:49:42 2020 (r365410) @@ -143,6 +143,7 @@ enum { MLX5_REG_PMPE = 0x5010, MLX5_REG_PMAOS = 0x5012, MLX5_REG_PPLM = 0x5023, + MLX5_REG_PDDR = 0x5031, MLX5_REG_PBSR = 0x5038, MLX5_REG_PCAM = 0x507f, MLX5_REG_NODE_DESC = 0x6001, Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h Mon Sep 7 10:37:44 2020 (r365409) +++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h Mon Sep 7 10:49:42 2020 (r365410) @@ -79,6 +79,35 @@ enum mlx5_semaphore_space_address { struct mlx5_core_dev; +enum mlx5_pddr_page_select { + MLX5_PDDR_OPERATIONAL_INFO_PAGE = 0x0, + MLX5_PDDR_TROUBLESHOOTING_INFO_PAGE = 0x1, + MLX5_PDDR_MODULE_INFO_PAGE = 0x3, +}; + +enum mlx5_pddr_monitor_opcodes { + MLX5_LINK_NO_ISSUE_OBSERVED = 0x0, + MLX5_LINK_PORT_CLOSED = 0x1, + MLX5_LINK_AN_FAILURE = 0x2, + MLX5_LINK_TRAINING_FAILURE = 0x5, + MLX5_LINK_LOGICAL_MISMATCH = 0x9, + MLX5_LINK_REMOTE_FAULT_INDICATION = 0xe, + MLX5_LINK_BAD_SIGNAL_INTEGRITY = 0xf, + MLX5_LINK_CABLE_COMPLIANCE_CODE_MISMATCH = 0x10, + MLX5_LINK_INTERNAL_ERR = 0x17, + MLX5_LINK_INFO_NOT_AVAIL = 0x3ff, + MLX5_LINK_CABLE_UNPLUGGED = 0x400, + MLX5_LINK_LONG_RANGE_FOR_NON_MLX_CABLE = 0x401, + MLX5_LINK_BUS_STUCK = 0x402, + MLX5_LINK_UNSUPP_EEPROM = 0x403, + MLX5_LINK_PART_NUM_LIST = 0x404, + MLX5_LINK_UNSUPP_CABLE = 0x405, + MLX5_LINK_MODULE_TEMP_SHUTDOWN = 0x406, + MLX5_LINK_SHORTED_CABLE = 0x407, + MLX5_LINK_POWER_BUDGET_EXCEEDED = 0x408, + MLX5_LINK_MNG_FORCED_DOWN = 0x409, +}; + int mlx5_query_hca_caps(struct mlx5_core_dev *dev); int mlx5_query_board_id(struct mlx5_core_dev *dev); int mlx5_query_qcam_reg(struct mlx5_core_dev *mdev, u32 *qcam, Modified: stable/11/sys/dev/mlx5/mlx5_ifc.h ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_ifc.h Mon Sep 7 10:37:44 2020 (r365409) +++ stable/11/sys/dev/mlx5/mlx5_ifc.h Mon Sep 7 10:49:42 2020 (r365410) @@ -848,23 +848,6 @@ struct mlx5_ifc_pddr_module_info_bits { u8 reserved_at_4c0[0x300]; }; -union mlx5_ifc_pddr_operation_info_page_pddr_phy_info_page_pddr_troubleshooting_page_pddr_module_info_auto_bits { - struct mlx5_ifc_pddr_module_info_bits pddr_module_info; - u8 reserved_at_0[0x7c0]; -}; - -struct mlx5_ifc_pddr_reg_bits { - u8 reserved_at_0[0x8]; - u8 local_port[0x8]; - u8 pnat[0x2]; - u8 reserved_at_12[0xe]; - - u8 reserved_at_20[0x18]; - u8 page_select[0x8]; - - union mlx5_ifc_pddr_operation_info_page_pddr_phy_info_page_pddr_troubleshooting_page_pddr_module_info_auto_bits page_data; -}; - struct mlx5_ifc_per_protocol_networking_offload_caps_bits { u8 csum_cap[0x1]; u8 vlan_cap[0x1]; @@ -8630,7 +8613,10 @@ struct mlx5_ifc_pcam_regs_5000_to_507f_bits { u8 port_access_reg_cap_mask_127_to_96[0x20]; u8 port_access_reg_cap_mask_95_to_64[0x20]; - u8 port_access_reg_cap_mask_63_to_36[0x1c]; + u8 reserved_at_40[0xe]; + u8 pddr[0x1]; + u8 reserved_at_4f[0xd]; + u8 pplm[0x1]; u8 port_access_reg_cap_mask_34_to_32[0x3]; @@ -10182,6 +10168,46 @@ struct mlx5_ifc_mpcnt_reg_ext_bits { u8 reserved_at_21[0x1f]; union mlx5_ifc_mpcnt_reg_counter_set_auto_ext_bits counter_set; +}; + +struct mlx5_ifc_monitor_opcodes_layout_bits { + u8 reserved_at_0[0x10]; + u8 monitor_opcode[0x10]; +}; + +union mlx5_ifc_pddr_status_opcode_bits { + struct mlx5_ifc_monitor_opcodes_layout_bits monitor_opcodes; + u8 reserved_at_0[0x20]; +}; + +struct mlx5_ifc_troubleshooting_info_page_layout_bits { + u8 reserved_at_0[0x10]; + u8 group_opcode[0x10]; + + union mlx5_ifc_pddr_status_opcode_bits status_opcode; + + u8 user_feedback_data[0x10]; + u8 user_feedback_index[0x10]; + + u8 status_message[0x760]; +}; + +union mlx5_ifc_pddr_page_data_bits { + struct mlx5_ifc_troubleshooting_info_page_layout_bits troubleshooting_info_page; + struct mlx5_ifc_pddr_module_info_bits pddr_module_info; + u8 reserved_at_0[0x7c0]; +}; + +struct mlx5_ifc_pddr_reg_bits { + u8 reserved_at_0[0x8]; + u8 local_port[0x8]; + u8 pnat[0x2]; + u8 reserved_at_12[0xe]; + + u8 reserved_at_20[0x18]; + u8 page_select[0x8]; + + union mlx5_ifc_pddr_page_data_bits page_data; }; enum { From owner-svn-src-stable-11@freebsd.org Mon Sep 7 10:50:18 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E6A463EE83C; Mon, 7 Sep 2020 10:50:18 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BlQ6L5rj1z3yMc; Mon, 7 Sep 2020 10:50:18 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 91FDD1DFEC; Mon, 7 Sep 2020 10:50:18 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087AoI2R092841; Mon, 7 Sep 2020 10:50:18 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087AoI0A092839; Mon, 7 Sep 2020 10:50:18 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009071050.087AoI0A092839@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 7 Sep 2020 10:50:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365411 - in stable/11/sys/dev/mlx5: . mlx5_core X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: in stable/11/sys/dev/mlx5: . mlx5_core X-SVN-Commit-Revision: 365411 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 10:50:19 -0000 Author: kib Date: Mon Sep 7 10:50:17 2020 New Revision: 365411 URL: https://svnweb.freebsd.org/changeset/base/365411 Log: MFC r365000: mlx5_core: add mlx5_query_pddr(). Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c stable/11/sys/dev/mlx5/mlx5_ifc.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c Mon Sep 7 10:49:42 2020 (r365410) +++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c Mon Sep 7 10:50:17 2020 (r365411) @@ -1175,19 +1175,29 @@ out: return err; } +static int mlx5_query_pddr(struct mlx5_core_dev *mdev, + u8 local_port, int page_select, u32 *out, int outlen) +{ + u32 in[MLX5_ST_SZ_DW(pddr_reg)] = {0}; + + if (!MLX5_CAP_PCAM_REG(mdev, pddr)) + return -EOPNOTSUPP; + + MLX5_SET(pddr_reg, in, local_port, local_port); + MLX5_SET(pddr_reg, in, page_select, page_select); + + return mlx5_core_access_reg(mdev, in, sizeof(in), out, outlen, MLX5_REG_PDDR, 0, 0); +} + int mlx5_query_pddr_range_info(struct mlx5_core_dev *mdev, u8 local_port, u8 *is_er_type) { u32 pddr_reg[MLX5_ST_SZ_DW(pddr_reg)] = {}; - int sz = MLX5_ST_SZ_BYTES(pddr_reg); int error; u8 ecc; u8 ci; - MLX5_SET(pddr_reg, pddr_reg, local_port, local_port); - MLX5_SET(pddr_reg, pddr_reg, page_select, 3 /* module info page */); - - error = mlx5_core_access_reg(mdev, pddr_reg, sz, pddr_reg, sz, - MLX5_ACCESS_REG_SUMMARY_CTRL_ID_PDDR, 0, 0); + error = mlx5_query_pddr(mdev, local_port, MLX5_PDDR_MODULE_INFO_PAGE, + pddr_reg, sizeof(pddr_reg)); if (error != 0) return (error); Modified: stable/11/sys/dev/mlx5/mlx5_ifc.h ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_ifc.h Mon Sep 7 10:49:42 2020 (r365410) +++ stable/11/sys/dev/mlx5/mlx5_ifc.h Mon Sep 7 10:50:17 2020 (r365411) @@ -756,10 +756,6 @@ struct mlx5_ifc_flow_table_nic_cap_bits { u8 reserved_1[0x7200]; }; -enum { - MLX5_ACCESS_REG_SUMMARY_CTRL_ID_PDDR = 0x5031, -}; - struct mlx5_ifc_pddr_module_info_bits { u8 cable_technology[0x8]; u8 cable_breakout[0x8]; From owner-svn-src-stable-11@freebsd.org Mon Sep 7 10:50:48 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 96E313EE855; Mon, 7 Sep 2020 10:50:48 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BlQ6w3RkNz3ydT; Mon, 7 Sep 2020 10:50:48 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 5AEF71E32C; Mon, 7 Sep 2020 10:50:48 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087AomkX092919; Mon, 7 Sep 2020 10:50:48 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087Aol68092914; Mon, 7 Sep 2020 10:50:47 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009071050.087Aol68092914@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 7 Sep 2020 10:50:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365412 - in stable/11/sys/dev/mlx5: mlx5_core mlx5_en X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: in stable/11/sys/dev/mlx5: mlx5_core mlx5_en X-SVN-Commit-Revision: 365412 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 10:50:48 -0000 Author: kib Date: Mon Sep 7 10:50:47 2020 New Revision: 365412 URL: https://svnweb.freebsd.org/changeset/base/365412 Log: MFC r365001: mlx5en: Implement SIOCGIFDOWNREASON. Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c stable/11/sys/dev/mlx5/mlx5_en/mlx5_en_main.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h Mon Sep 7 10:50:17 2020 (r365411) +++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_core.h Mon Sep 7 10:50:47 2020 (r365412) @@ -127,6 +127,9 @@ void mlx5_core_event(struct mlx5_core_dev *dev, enum m void mlx5_enter_error_state(struct mlx5_core_dev *dev, bool force); void mlx5_disable_device(struct mlx5_core_dev *dev); void mlx5_recover_device(struct mlx5_core_dev *dev); +int mlx5_query_pddr_troubleshooting_info(struct mlx5_core_dev *mdev, + u16 *monitor_opcode, + u8 *status_message, size_t sm_len); int mlx5_register_device(struct mlx5_core_dev *dev); void mlx5_unregister_device(struct mlx5_core_dev *dev); Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c Mon Sep 7 10:50:17 2020 (r365411) +++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_port.c Mon Sep 7 10:50:47 2020 (r365412) @@ -1221,6 +1221,31 @@ int mlx5_query_pddr_range_info(struct mlx5_core_dev *m } EXPORT_SYMBOL_GPL(mlx5_query_pddr_range_info); +int mlx5_query_pddr_troubleshooting_info(struct mlx5_core_dev *mdev, + u16 *monitor_opcode, u8 *status_message, size_t sm_len) +{ + int outlen = MLX5_ST_SZ_BYTES(pddr_reg); + u32 out[MLX5_ST_SZ_DW(pddr_reg)] = {0}; + int err; + + err = mlx5_query_pddr(mdev, MLX5_PDDR_TROUBLESHOOTING_INFO_PAGE, 1, + out, outlen); + if (err != 0) + return err; + if (monitor_opcode != NULL) { + *monitor_opcode = MLX5_GET(pddr_reg, out, + page_data.troubleshooting_info_page.status_opcode. + monitor_opcodes); + } + if (status_message != NULL) { + strlcpy(status_message, + MLX5_ADDR_OF(pddr_reg, out, + page_data.troubleshooting_info_page.status_message), + sm_len); + } + return (0); +} + int mlx5_query_mfrl_reg(struct mlx5_core_dev *mdev, u8 *reset_level) { Modified: stable/11/sys/dev/mlx5/mlx5_en/mlx5_en_main.c ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_en/mlx5_en_main.c Mon Sep 7 10:50:17 2020 (r365411) +++ stable/11/sys/dev/mlx5/mlx5_en/mlx5_en_main.c Mon Sep 7 10:50:47 2020 (r365412) @@ -3077,6 +3077,7 @@ mlx5e_ioctl(struct ifnet *ifp, u_long command, caddr_t { struct mlx5e_priv *priv; struct ifreq *ifr; + struct ifdownreason *ifdr; struct ifi2creq i2c; int error = 0; int mask = 0; @@ -3328,6 +3329,16 @@ out: error = copyout(&i2c, ifr_data_get_ptr(ifr), sizeof(i2c)); err_i2c: PRIV_UNLOCK(priv); + break; + case SIOCGIFDOWNREASON: + ifdr = (struct ifdownreason *)data; + bzero(ifdr->ifdr_msg, sizeof(ifdr->ifdr_msg)); + PRIV_LOCK(priv); + error = -mlx5_query_pddr_troubleshooting_info(priv->mdev, NULL, + ifdr->ifdr_msg, sizeof(ifdr->ifdr_msg)); + PRIV_UNLOCK(priv); + if (error == 0) + ifdr->ifdr_reason = IFDR_REASON_MSG; break; default: From owner-svn-src-stable-11@freebsd.org Mon Sep 7 10:51:19 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DE7CD3EEB8E; Mon, 7 Sep 2020 10:51:19 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BlQ7W5X3fz3ybk; Mon, 7 Sep 2020 10:51:19 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id A28FE1DFFC; Mon, 7 Sep 2020 10:51:19 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087ApJm6096050; Mon, 7 Sep 2020 10:51:19 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087ApJAN096049; Mon, 7 Sep 2020 10:51:19 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009071051.087ApJAN096049@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 7 Sep 2020 10:51:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365413 - stable/11/sys/dev/mlx5/mlx5_core X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/11/sys/dev/mlx5/mlx5_core X-SVN-Commit-Revision: 365413 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 10:51:19 -0000 Author: kib Date: Mon Sep 7 10:51:19 2020 New Revision: 365413 URL: https://svnweb.freebsd.org/changeset/base/365413 Log: MFC r365002: mlx5 sriov: add error message for failed MAC programming on VF. Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Mon Sep 7 10:50:47 2020 (r365412) +++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Mon Sep 7 10:51:19 2020 (r365413) @@ -1820,6 +1820,11 @@ mlx5_iov_add_vf(device_t dev, uint16_t vfnum, const nv &mac_size); error = -mlx5_eswitch_set_vport_mac(priv->eswitch, vfnum + 1, __DECONST(u8 *, mac)); + if (error != 0) { + mlx5_core_err(core_dev, + "setting MAC for VF %d failed, error %d\n", + vfnum + 1, error); + } } error = -mlx5_eswitch_set_vport_state(priv->eswitch, vfnum + 1, From owner-svn-src-stable-11@freebsd.org Mon Sep 7 10:51:49 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9C0883EEC10; Mon, 7 Sep 2020 10:51:49 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BlQ853jvrz3yyL; Mon, 7 Sep 2020 10:51:49 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 6343E1DDEE; Mon, 7 Sep 2020 10:51:49 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087ApnTo097374; Mon, 7 Sep 2020 10:51:49 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087Apn2v097361; Mon, 7 Sep 2020 10:51:49 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009071051.087Apn2v097361@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 7 Sep 2020 10:51:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365414 - stable/11/sys/dev/mlx5/mlx5_core X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/11/sys/dev/mlx5/mlx5_core X-SVN-Commit-Revision: 365414 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 10:51:49 -0000 Author: kib Date: Mon Sep 7 10:51:48 2020 New Revision: 365414 URL: https://svnweb.freebsd.org/changeset/base/365414 Log: MFC r365003: mlx5 sriov: Add controls for VFs to set port/node GUIDs. Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c ============================================================================== --- stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Mon Sep 7 10:51:19 2020 (r365413) +++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Mon Sep 7 10:51:48 2020 (r365414) @@ -179,6 +179,8 @@ static struct mlx5_profile profiles[] = { #ifdef PCI_IOV static const char iov_mac_addr_name[] = "mac-addr"; +static const char iov_node_guid_name[] = "node-guid"; +static const char iov_port_guid_name[] = "port-guid"; #endif static int set_dma_caps(struct pci_dev *pdev) @@ -1605,6 +1607,10 @@ static int init_one(struct pci_dev *pdev, vf_schema = pci_iov_schema_alloc_node(); pci_iov_schema_add_unicast_mac(vf_schema, iov_mac_addr_name, 0, NULL); + pci_iov_schema_add_uint64(vf_schema, iov_node_guid_name, + 0, 0); + pci_iov_schema_add_uint64(vf_schema, iov_port_guid_name, + 0, 0); err = pci_iov_attach(bsddev, pf_schema, vf_schema); if (err != 0) { device_printf(bsddev, @@ -1806,6 +1812,7 @@ mlx5_iov_add_vf(device_t dev, uint16_t vfnum, const nv struct mlx5_priv *priv; const void *mac; size_t mac_size; + uint64_t node_guid, port_guid; int error; pdev = device_get_softc(dev); @@ -1823,6 +1830,28 @@ mlx5_iov_add_vf(device_t dev, uint16_t vfnum, const nv if (error != 0) { mlx5_core_err(core_dev, "setting MAC for VF %d failed, error %d\n", + vfnum + 1, error); + } + } + + if (nvlist_exists_number(vf_config, iov_node_guid_name)) { + node_guid = nvlist_get_number(vf_config, iov_node_guid_name); + error = -mlx5_modify_nic_vport_node_guid(core_dev, vfnum + 1, + node_guid); + if (error != 0) { + mlx5_core_err(core_dev, + "modifying node GUID for VF %d failed, error %d\n", + vfnum + 1, error); + } + } + + if (nvlist_exists_number(vf_config, iov_port_guid_name)) { + port_guid = nvlist_get_number(vf_config, iov_port_guid_name); + error = -mlx5_modify_nic_vport_port_guid(core_dev, vfnum + 1, + port_guid); + if (error != 0) { + mlx5_core_err(core_dev, + "modifying port GUID for VF %d failed, error %d\n", vfnum + 1, error); } } From owner-svn-src-stable-11@freebsd.org Mon Sep 7 19:29:08 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B13C13D4E9D; Mon, 7 Sep 2020 19:29:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Bldd04Kk8z4cF3; Mon, 7 Sep 2020 19:29:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 78B732451B; Mon, 7 Sep 2020 19:29:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087JT8XA023323; Mon, 7 Sep 2020 19:29:08 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087JT7Kc023321; Mon, 7 Sep 2020 19:29:07 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009071929.087JT7Kc023321@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Mon, 7 Sep 2020 19:29:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365426 - in stable: 11/lib/libclang_rt/fuzzer 11/lib/libclang_rt/profile 11/lib/libclang_rt/xray 12/lib/libclang_rt/fuzzer 12/lib/libclang_rt/profile 12/lib/libclang_rt/xray X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/lib/libclang_rt/fuzzer 11/lib/libclang_rt/profile 11/lib/libclang_rt/xray 12/lib/libclang_rt/fuzzer 12/lib/libclang_rt/profile 12/lib/libclang_rt/xray X-SVN-Commit-Revision: 365426 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 19:29:08 -0000 Author: dim Date: Mon Sep 7 19:29:06 2020 New Revision: 365426 URL: https://svnweb.freebsd.org/changeset/base/365426 Log: MFC r364081: Follow-up to r358851 (llvm-project 10.0.0-rc3 import), where I added subdirectories for compiler-rt's internal fuzzer, profile and xray headers, but forgot to add installing those headers themselves. Modified: stable/11/lib/libclang_rt/fuzzer/Makefile stable/11/lib/libclang_rt/profile/Makefile stable/11/lib/libclang_rt/xray/Makefile Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/lib/libclang_rt/fuzzer/Makefile stable/12/lib/libclang_rt/profile/Makefile stable/12/lib/libclang_rt/xray/Makefile Directory Properties: stable/12/ (props changed) Modified: stable/11/lib/libclang_rt/fuzzer/Makefile ============================================================================== --- stable/11/lib/libclang_rt/fuzzer/Makefile Mon Sep 7 18:47:25 2020 (r365425) +++ stable/11/lib/libclang_rt/fuzzer/Makefile Mon Sep 7 19:29:06 2020 (r365426) @@ -23,4 +23,8 @@ SRCS+= fuzzer/FuzzerUtil.cpp SRCS+= fuzzer/FuzzerUtilLinux.cpp SRCS+= fuzzer/FuzzerUtilPosix.cpp +.PATH: ${CRTSRC}/include/fuzzer +INCSDIR= ${CLANGDIR}/include/fuzzer +INCS+= FuzzedDataProvider.h + .include Modified: stable/11/lib/libclang_rt/profile/Makefile ============================================================================== --- stable/11/lib/libclang_rt/profile/Makefile Mon Sep 7 18:47:25 2020 (r365425) +++ stable/11/lib/libclang_rt/profile/Makefile Mon Sep 7 19:29:06 2020 (r365426) @@ -25,4 +25,8 @@ SRCS+= profile/InstrProfilingUtil.c SRCS+= profile/InstrProfilingValue.c SRCS+= profile/InstrProfilingWriter.c +.PATH: ${CRTSRC}/include/profile +INCSDIR= ${CLANGDIR}/include/profile +INCS+= InstrProfData.inc + .include Modified: stable/11/lib/libclang_rt/xray/Makefile ============================================================================== --- stable/11/lib/libclang_rt/xray/Makefile Mon Sep 7 18:47:25 2020 (r365425) +++ stable/11/lib/libclang_rt/xray/Makefile Mon Sep 7 19:29:06 2020 (r365426) @@ -41,4 +41,10 @@ SRCS+= xray/xray_trampoline_x86_64.S SRCS+= xray/xray_utils.cpp SRCS+= xray/xray_x86_64.cpp +.PATH: ${CRTSRC}/include/xray +INCSDIR= ${CLANGDIR}/include/xray +INCS+= xray_interface.h +INCS+= xray_log_interface.h +INCS+= xray_records.h + .include From owner-svn-src-stable-11@freebsd.org Mon Sep 7 19:35:33 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 56EAF3D4F4A; Mon, 7 Sep 2020 19:35:33 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BldmP1hjyz4cvh; Mon, 7 Sep 2020 19:35:33 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 1D9CA2462B; Mon, 7 Sep 2020 19:35:33 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087JZWoP029152; Mon, 7 Sep 2020 19:35:32 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087JZVZV029146; Mon, 7 Sep 2020 19:35:31 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009071935.087JZVZV029146@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Mon, 7 Sep 2020 19:35:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365427 - in stable: 11/contrib/llvm-project/openmp/runtime/src 11/share/mk 12/contrib/llvm-project/openmp/runtime/src 12/share/mk X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/llvm-project/openmp/runtime/src 11/share/mk 12/contrib/llvm-project/openmp/runtime/src 12/share/mk X-SVN-Commit-Revision: 365427 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 19:35:33 -0000 Author: dim Date: Mon Sep 7 19:35:30 2020 New Revision: 365427 URL: https://svnweb.freebsd.org/changeset/base/365427 Log: MFC r364732: Merge commit cde8f4c16 from llvm git (by me): Move special va_list handling to kmp_os.h Instead of copying and pasting the same #ifdef expressions in multiple places, define a type and a pair of macros in kmp_os.h, to handle whether va_list is pointer-like or not: * kmp_va_list is the type to use for __kmp_fork_call() * kmp_va_deref() dereferences a va_list, if necessary * kmp_va_addr_of() takes the address of a va_list, if necessary Also add FreeBSD to the list of OSes that has a non pointer-like va_list. This can now be easily extended to other OSes too. Reviewed By: AndreyChurbanov Differential Revision: https://reviews.llvm.org/D86397 This should enable building of LLVM's OpenMP on AArch64. Addition to share/mk will follow in a subsequent commit. PR: 248864 MFC r364733: After r364732, we can now enable MK_OPENMP for aarch64 by default. PR: 248864 Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp.h stable/11/contrib/llvm-project/openmp/runtime/src/kmp_csupport.cpp stable/11/contrib/llvm-project/openmp/runtime/src/kmp_gsupport.cpp stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h stable/11/contrib/llvm-project/openmp/runtime/src/kmp_runtime.cpp stable/11/share/mk/src.opts.mk Directory Properties: stable/11/ (props changed) stable/11/contrib/llvm-project/openmp/ (props changed) Changes in other areas also in this revision: Modified: stable/12/contrib/llvm-project/openmp/runtime/src/kmp.h stable/12/contrib/llvm-project/openmp/runtime/src/kmp_csupport.cpp stable/12/contrib/llvm-project/openmp/runtime/src/kmp_gsupport.cpp stable/12/contrib/llvm-project/openmp/runtime/src/kmp_os.h stable/12/contrib/llvm-project/openmp/runtime/src/kmp_runtime.cpp stable/12/share/mk/src.opts.mk Directory Properties: stable/12/ (props changed) Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp.h ============================================================================== --- stable/11/contrib/llvm-project/openmp/runtime/src/kmp.h Mon Sep 7 19:29:06 2020 (r365426) +++ stable/11/contrib/llvm-project/openmp/runtime/src/kmp.h Mon Sep 7 19:35:30 2020 (r365427) @@ -3463,13 +3463,7 @@ enum fork_context_e { extern int __kmp_fork_call(ident_t *loc, int gtid, enum fork_context_e fork_context, kmp_int32 argc, microtask_t microtask, launch_t invoker, -/* TODO: revert workaround for Intel(R) 64 tracker #96 */ -#if (KMP_ARCH_ARM || KMP_ARCH_X86_64 || KMP_ARCH_AARCH64) && KMP_OS_LINUX - va_list *ap -#else - va_list ap -#endif - ); + kmp_va_list ap); extern void __kmp_join_call(ident_t *loc, int gtid #if OMPT_SUPPORT Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp_csupport.cpp ============================================================================== --- stable/11/contrib/llvm-project/openmp/runtime/src/kmp_csupport.cpp Mon Sep 7 19:29:06 2020 (r365426) +++ stable/11/contrib/llvm-project/openmp/runtime/src/kmp_csupport.cpp Mon Sep 7 19:35:30 2020 (r365427) @@ -308,13 +308,7 @@ void __kmpc_fork_call(ident_t *loc, kmp_int32 argc, km __kmp_fork_call(loc, gtid, fork_context_intel, argc, VOLATILE_CAST(microtask_t) microtask, // "wrapped" task VOLATILE_CAST(launch_t) __kmp_invoke_task_func, -/* TODO: revert workaround for Intel(R) 64 tracker #96 */ -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - &ap -#else - ap -#endif - ); + kmp_va_addr_of(ap)); #if INCLUDE_SSC_MARKS SSC_MARK_JOINING(); #endif @@ -408,16 +402,10 @@ void __kmpc_fork_teams(ident_t *loc, kmp_int32 argc, k KMP_DEBUG_ASSERT(this_thr->th.th_teams_size.nteams >= 1); KMP_DEBUG_ASSERT(this_thr->th.th_teams_size.nth >= 1); - __kmp_fork_call(loc, gtid, fork_context_intel, argc, - VOLATILE_CAST(microtask_t) - __kmp_teams_master, // "wrapped" task - VOLATILE_CAST(launch_t) __kmp_invoke_teams_master, -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - &ap -#else - ap -#endif - ); + __kmp_fork_call( + loc, gtid, fork_context_intel, argc, + VOLATILE_CAST(microtask_t) __kmp_teams_master, // "wrapped" task + VOLATILE_CAST(launch_t) __kmp_invoke_teams_master, kmp_va_addr_of(ap)); __kmp_join_call(loc, gtid #if OMPT_SUPPORT , Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp_gsupport.cpp ============================================================================== --- stable/11/contrib/llvm-project/openmp/runtime/src/kmp_gsupport.cpp Mon Sep 7 19:29:06 2020 (r365426) +++ stable/11/contrib/llvm-project/openmp/runtime/src/kmp_gsupport.cpp Mon Sep 7 19:35:30 2020 (r365427) @@ -376,13 +376,7 @@ static va_start(ap, argc); rc = __kmp_fork_call(loc, gtid, fork_context_gnu, argc, wrapper, - __kmp_invoke_task_func, -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - &ap -#else - ap -#endif - ); + __kmp_invoke_task_func, kmp_va_addr_of(ap)); va_end(ap); Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h ============================================================================== --- stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h Mon Sep 7 19:29:06 2020 (r365426) +++ stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h Mon Sep 7 19:35:30 2020 (r365427) @@ -200,6 +200,18 @@ typedef kmp_uint32 kmp_uint; #define KMP_INT_MAX ((kmp_int32)0x7FFFFFFF) #define KMP_INT_MIN ((kmp_int32)0x80000000) +// stdarg handling +#if (KMP_ARCH_ARM || KMP_ARCH_X86_64 || KMP_ARCH_AARCH64) && \ + (KMP_OS_FREEBSD || KMP_OS_LINUX) +typedef va_list *kmp_va_list; +#define kmp_va_deref(ap) (*(ap)) +#define kmp_va_addr_of(ap) (&(ap)) +#else +typedef va_list kmp_va_list; +#define kmp_va_deref(ap) (ap) +#define kmp_va_addr_of(ap) (ap) +#endif + #ifdef __cplusplus // macros to cast out qualifiers and to re-interpret types #define CCAST(type, var) const_cast(var) Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp_runtime.cpp ============================================================================== --- stable/11/contrib/llvm-project/openmp/runtime/src/kmp_runtime.cpp Mon Sep 7 19:29:06 2020 (r365426) +++ stable/11/contrib/llvm-project/openmp/runtime/src/kmp_runtime.cpp Mon Sep 7 19:35:30 2020 (r365427) @@ -1389,13 +1389,7 @@ void __kmp_serialized_parallel(ident_t *loc, kmp_int32 int __kmp_fork_call(ident_t *loc, int gtid, enum fork_context_e call_context, // Intel, GNU, ... kmp_int32 argc, microtask_t microtask, launch_t invoker, -/* TODO: revert workaround for Intel(R) 64 tracker #96 */ -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - va_list *ap -#else - va_list ap -#endif - ) { + kmp_va_list ap) { void **argv; int i; int master_tid; @@ -1505,12 +1499,7 @@ int __kmp_fork_call(ident_t *loc, int gtid, parent_team->t.t_argc = argc; argv = (void **)parent_team->t.t_argv; for (i = argc - 1; i >= 0; --i) -/* TODO: revert workaround for Intel(R) 64 tracker #96 */ -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - *argv++ = va_arg(*ap, void *); -#else - *argv++ = va_arg(ap, void *); -#endif + *argv++ = va_arg(kmp_va_deref(ap), void *); // Increment our nested depth levels, but not increase the serialization if (parent_team == master_th->th.th_serial_team) { // AC: we are in serialized parallel @@ -1804,12 +1793,7 @@ int __kmp_fork_call(ident_t *loc, int gtid, argv = (void **)team->t.t_argv; if (ap) { for (i = argc - 1; i >= 0; --i) -// TODO: revert workaround for Intel(R) 64 tracker #96 -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - *argv++ = va_arg(*ap, void *); -#else - *argv++ = va_arg(ap, void *); -#endif + *argv++ = va_arg(kmp_va_deref(ap), void *); } else { for (i = 0; i < argc; ++i) // Get args from parent team for teams construct @@ -1840,12 +1824,7 @@ int __kmp_fork_call(ident_t *loc, int gtid, } else { argv = args; for (i = argc - 1; i >= 0; --i) -// TODO: revert workaround for Intel(R) 64 tracker #96 -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - *argv++ = va_arg(*ap, void *); -#else - *argv++ = va_arg(ap, void *); -#endif + *argv++ = va_arg(kmp_va_deref(ap), void *); KMP_MB(); #if OMPT_SUPPORT @@ -2130,12 +2109,7 @@ int __kmp_fork_call(ident_t *loc, int gtid, argv = (void **)team->t.t_argv; if (ap) { for (i = argc - 1; i >= 0; --i) { -// TODO: revert workaround for Intel(R) 64 tracker #96 -#if (KMP_ARCH_X86_64 || KMP_ARCH_ARM || KMP_ARCH_AARCH64) && KMP_OS_LINUX - void *new_argv = va_arg(*ap, void *); -#else - void *new_argv = va_arg(ap, void *); -#endif + void *new_argv = va_arg(kmp_va_deref(ap), void *); KMP_CHECK_UPDATE(*argv, new_argv); argv++; } Modified: stable/11/share/mk/src.opts.mk ============================================================================== --- stable/11/share/mk/src.opts.mk Mon Sep 7 19:29:06 2020 (r365426) +++ stable/11/share/mk/src.opts.mk Mon Sep 7 19:35:30 2020 (r365427) @@ -342,7 +342,8 @@ __DEFAULT_NO_OPTIONS+=OFED .endif .if ${COMPILER_FEATURES:Mc++11} && \ - (${__T} == "amd64" || ${__T} == "i386" || ${__T} == "powerpc64") + (${__T} == "aarch64" || ${__T} == "amd64" || ${__T} == "i386" || \ + ${__T} == "powerpc64") __DEFAULT_YES_OPTIONS+=OPENMP .else __DEFAULT_NO_OPTIONS+=OPENMP From owner-svn-src-stable-11@freebsd.org Mon Sep 7 20:17:14 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0D5493D594A; Mon, 7 Sep 2020 20:17:14 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BlfhT6brSz4g7C; Mon, 7 Sep 2020 20:17:13 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C5FF924DAC; Mon, 7 Sep 2020 20:17:13 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 087KHDpt053799; Mon, 7 Sep 2020 20:17:13 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 087KHDGH053798; Mon, 7 Sep 2020 20:17:13 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009072017.087KHDGH053798@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Mon, 7 Sep 2020 20:17:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365430 - in stable: 11/contrib/llvm-project/openmp/runtime/src 12/contrib/llvm-project/openmp/runtime/src X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/llvm-project/openmp/runtime/src 12/contrib/llvm-project/openmp/runtime/src X-SVN-Commit-Revision: 365430 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Sep 2020 20:17:14 -0000 Author: dim Date: Mon Sep 7 20:17:13 2020 New Revision: 365430 URL: https://svnweb.freebsd.org/changeset/base/365430 Log: MFC r365429: Merge commit 47b0262d3 from llvm git (by me): Add include to kmp_os.h, to get the va_list type, required after cde8f4c164a2. Sort system includes, while here. The original merged commit works fine by itself on head, but fails to compile on stable branches because stdarg.h is not implicitly pulled in. PR: 248864 Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h Directory Properties: stable/11/ (props changed) stable/11/contrib/llvm-project/openmp/ (props changed) Changes in other areas also in this revision: Modified: stable/12/contrib/llvm-project/openmp/runtime/src/kmp_os.h Directory Properties: stable/12/ (props changed) Modified: stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h ============================================================================== --- stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h Mon Sep 7 20:10:03 2020 (r365429) +++ stable/11/contrib/llvm-project/openmp/runtime/src/kmp_os.h Mon Sep 7 20:17:13 2020 (r365430) @@ -14,8 +14,9 @@ #define KMP_OS_H #include "kmp_config.h" -#include #include +#include +#include #define KMP_FTN_PLAIN 1 #define KMP_FTN_APPEND 2 From owner-svn-src-stable-11@freebsd.org Tue Sep 8 16:43:34 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2C8DC3CF484; Tue, 8 Sep 2020 16:43:34 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Bm9vV0CJKz41GB; Tue, 8 Sep 2020 16:43:34 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id DE87A137D1; Tue, 8 Sep 2020 16:43:33 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088GhXxZ012092; Tue, 8 Sep 2020 16:43:33 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088GhXAC012090; Tue, 8 Sep 2020 16:43:33 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009081643.088GhXAC012090@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 16:43:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365465 - in stable: 11/share/mk 11/sys/conf 12/share/mk 12/sys/conf X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/share/mk 11/sys/conf 12/share/mk 12/sys/conf X-SVN-Commit-Revision: 365465 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 16:43:34 -0000 Author: jhb Date: Tue Sep 8 16:43:32 2020 New Revision: 365465 URL: https://svnweb.freebsd.org/changeset/base/365465 Log: MFC 354970: Add a kmod.opts.mk. This Makefile sets KERN_OPTS. This permits kernel module Makefiles to use KERN_OPTS to control the value of variables such as SRCS that are used by bsd.kmod.mk for KERN_OPTS values that honor WITH/WITHOUT options for standalone builds. Added: stable/11/share/mk/kmod.opts.mk - copied unchanged from r354970, head/share/mk/kmod.opts.mk stable/11/sys/conf/kmod.opts.mk - copied unchanged from r354970, head/sys/conf/kmod.opts.mk Modified: stable/11/sys/conf/kmod.mk Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Added: stable/12/share/mk/kmod.opts.mk - copied unchanged from r354970, head/share/mk/kmod.opts.mk stable/12/sys/conf/kmod.opts.mk - copied unchanged from r354970, head/sys/conf/kmod.opts.mk Modified: stable/12/sys/conf/kmod.mk Directory Properties: stable/12/ (props changed) Copied: stable/11/share/mk/kmod.opts.mk (from r354970, head/share/mk/kmod.opts.mk) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/share/mk/kmod.opts.mk Tue Sep 8 16:43:32 2020 (r365465, copy of r354970, head/share/mk/kmod.opts.mk) @@ -0,0 +1,4 @@ +# $FreeBSD$ + +.include +.include "${SYSDIR}/conf/kmod.opts.mk" Modified: stable/11/sys/conf/kmod.mk ============================================================================== --- stable/11/sys/conf/kmod.mk Tue Sep 8 16:07:47 2020 (r365464) +++ stable/11/sys/conf/kmod.mk Tue Sep 8 16:43:32 2020 (r365465) @@ -69,12 +69,7 @@ KMODUNLOAD?= /sbin/kldunload KMODISLOADED?= /sbin/kldstat -q -n OBJCOPY?= objcopy -.include -# Grab all the options for a kernel build. For backwards compat, we need to -# do this after bsd.own.mk. -.include "kern.opts.mk" -.include -.include "config.mk" +.include "kmod.opts.mk" # Search for kernel source tree in standard places. .for _dir in ${.CURDIR}/../.. ${.CURDIR}/../../.. /sys /usr/src/sys Copied: stable/11/sys/conf/kmod.opts.mk (from r354970, head/sys/conf/kmod.opts.mk) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/sys/conf/kmod.opts.mk Tue Sep 8 16:43:32 2020 (r365465, copy of r354970, head/sys/conf/kmod.opts.mk) @@ -0,0 +1,16 @@ +# $FreeBSD$ +# +# Handle options (KERN_OPTS) for kernel module options. This can be included earlier in a kmod Makefile +# to allow KERN_OPTS to control SRCS, etc. + +.if !target(____) +____: + +.include +# Grab all the options for a kernel build. For backwards compat, we need to +# do this after bsd.own.mk. +.include "kern.opts.mk" +.include +.include "config.mk" + +.endif # !target(____) From owner-svn-src-stable-11@freebsd.org Tue Sep 8 18:29:21 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 47E513D2D1C; Tue, 8 Sep 2020 18:29:21 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmDFY1Fy9z4FSM; Tue, 8 Sep 2020 18:29:21 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0E5D614A5B; Tue, 8 Sep 2020 18:29:21 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088ITK8r079959; Tue, 8 Sep 2020 18:29:20 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088ITKk0079958; Tue, 8 Sep 2020 18:29:20 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009081829.088ITKk0079958@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 18:29:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365467 - in stable: 11/sys/modules/if_enc 12/sys/modules/if_enc X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/sys/modules/if_enc 12/sys/modules/if_enc X-SVN-Commit-Revision: 365467 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 18:29:21 -0000 Author: jhb Date: Tue Sep 8 18:29:20 2020 New Revision: 365467 URL: https://svnweb.freebsd.org/changeset/base/365467 Log: MFC 361634: Add opt_ipsec.h to fix standalone builds after r361633. Modified: stable/11/sys/modules/if_enc/Makefile Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/sys/modules/if_enc/Makefile Directory Properties: stable/12/ (props changed) Modified: stable/11/sys/modules/if_enc/Makefile ============================================================================== --- stable/11/sys/modules/if_enc/Makefile Tue Sep 8 17:47:30 2020 (r365466) +++ stable/11/sys/modules/if_enc/Makefile Tue Sep 8 18:29:20 2020 (r365467) @@ -6,6 +6,6 @@ SYSDIR?=${SRCTOP}/sys .PATH: ${SYSDIR}/net KMOD= if_enc -SRCS= if_enc.c opt_inet.h opt_inet6.h +SRCS= if_enc.c opt_inet.h opt_inet6.h opt_ipsec.h .include From owner-svn-src-stable-11@freebsd.org Tue Sep 8 18:49:59 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D5C4A3D3334; Tue, 8 Sep 2020 18:49:59 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmDjM5Pqyz4Gtd; Tue, 8 Sep 2020 18:49:59 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 9CA1E14FFE; Tue, 8 Sep 2020 18:49:59 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088InxHE092610; Tue, 8 Sep 2020 18:49:59 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088InxlC092609; Tue, 8 Sep 2020 18:49:59 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009081849.088InxlC092609@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 18:49:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365469 - in stable: 11/sys/modules/tcp 12/sys/modules/tcp X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/sys/modules/tcp 12/sys/modules/tcp X-SVN-Commit-Revision: 365469 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 18:49:59 -0000 Author: jhb Date: Tue Sep 8 18:49:58 2020 New Revision: 365469 URL: https://svnweb.freebsd.org/changeset/base/365469 Log: Use kmod.opts.mk in sys/modules/tcp/Makefile to fix standalone builds. This was included in the original commit to head that added use of KERN_OPTS (r361638) but was left out of the MFC since kmod.opts.mk hadn't been MFC'd at the time. It has since been merged. This is a direct commit to stable/11 and stable/12. Reported by: Eugene Grosbein Modified: stable/11/sys/modules/tcp/Makefile Changes in other areas also in this revision: Modified: stable/12/sys/modules/tcp/Makefile Modified: stable/11/sys/modules/tcp/Makefile ============================================================================== --- stable/11/sys/modules/tcp/Makefile Tue Sep 8 18:33:41 2020 (r365468) +++ stable/11/sys/modules/tcp/Makefile Tue Sep 8 18:49:58 2020 (r365469) @@ -2,8 +2,7 @@ # $FreeBSD$ # -SYSDIR?=${SRCTOP}/sys -.include "${SYSDIR}/conf/kern.opts.mk" +.include SUBDIR= \ ${_tcp_fastpath} \ From owner-svn-src-stable-11@freebsd.org Tue Sep 8 18:58:39 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 522313D3DA3; Tue, 8 Sep 2020 18:58:39 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmDvM1Xc8z4Hl5; Tue, 8 Sep 2020 18:58:39 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 1838914F78; Tue, 8 Sep 2020 18:58:39 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088IwcLf099087; Tue, 8 Sep 2020 18:58:38 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088IwcjU099086; Tue, 8 Sep 2020 18:58:38 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009081858.088IwcjU099086@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 18:58:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365470 - in stable: 11/sys/modules/tcp 12/sys/modules/tcp X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/sys/modules/tcp 12/sys/modules/tcp X-SVN-Commit-Revision: 365470 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 18:58:39 -0000 Author: jhb Date: Tue Sep 8 18:58:38 2020 New Revision: 365470 URL: https://svnweb.freebsd.org/changeset/base/365470 Log: MFC 361764: Revise r361712 to disable tcpmd5.ko for 'options TCP_SIGNATURE' Modified: stable/11/sys/modules/tcp/Makefile Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/sys/modules/tcp/Makefile Directory Properties: stable/12/ (props changed) Modified: stable/11/sys/modules/tcp/Makefile ============================================================================== --- stable/11/sys/modules/tcp/Makefile Tue Sep 8 18:49:58 2020 (r365469) +++ stable/11/sys/modules/tcp/Makefile Tue Sep 8 18:58:38 2020 (r365470) @@ -14,7 +14,7 @@ _tcp_fastpath= fastpath .if (${MK_INET_SUPPORT} != "no" || ${MK_INET6_SUPPORT} != "no") || \ defined(ALL_MODULES) -.if ${KERN_OPTS:MIPSEC_SUPPORT} && !${KERN_OPTS:MIPSEC} +.if ${KERN_OPTS:MIPSEC_SUPPORT} && !${KERN_OPTS:MTCP_SIGNATURE} _tcpmd5= tcpmd5 .endif .endif From owner-svn-src-stable-11@freebsd.org Tue Sep 8 20:02:10 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 22ACE3D5945; Tue, 8 Sep 2020 20:02:10 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmGJd6zDLz4MdS; Tue, 8 Sep 2020 20:02:09 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id D2AB616176; Tue, 8 Sep 2020 20:02:09 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088K29QG040379; Tue, 8 Sep 2020 20:02:09 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088K29sm040376; Tue, 8 Sep 2020 20:02:09 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009082002.088K29sm040376@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Tue, 8 Sep 2020 20:02:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365471 - in stable: 11/contrib/llvm-project/compiler-rt/lib/builtins 11/lib/libcompiler_rt 11/sys/sys 12/contrib/llvm-project/compiler-rt/lib/builtins 12/lib/libcompiler_rt 12/sys/sys X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/llvm-project/compiler-rt/lib/builtins 11/lib/libcompiler_rt 11/sys/sys 12/contrib/llvm-project/compiler-rt/lib/builtins 12/lib/libcompiler_rt 12/sys/sys X-SVN-Commit-Revision: 365471 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 20:02:10 -0000 Author: dim Date: Tue Sep 8 20:02:08 2020 New Revision: 365471 URL: https://svnweb.freebsd.org/changeset/base/365471 Log: MFC r364753: Add atomic and bswap functions to libcompiler_rt There have been several mentions on our mailing lists about missing atomic functions in our system libraries (e.g. __atomic_load_8 and friends), and recently I saw __bswapdi2 and __bswapsi2 mentioned too. To address this, add implementations for the functions from compiler-rt to the system compiler support libraries, e.g. libcompiler_rt.a and and libgcc_s.so. This also needs a small fixup in compiler-rt's atomic.c, to ensure that 32-bit mips can build correctly. Bump __FreeBSD_version to make it easier for port maintainers to detect when these functions were added. PR: 230888 Differential Revision: https://reviews.freebsd.org/D26159 MFC r364782: After r364753, there should be no need to suppress -Watomic-alignment warnings anymore for compiler-rt's atomic.c. This occurred because the IS_LOCK_FREE_8 macro was not correctly defined to 0 for mips, and this caused the compiler to emit a runtime call to __atomic_is_lock_free(), and that triggers the warning. Modified: stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c stable/11/lib/libcompiler_rt/Makefile.inc stable/11/sys/sys/param.h Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c stable/12/lib/libcompiler_rt/Makefile.inc stable/12/sys/sys/param.h Directory Properties: stable/12/ (props changed) Modified: stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c ============================================================================== --- stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c Tue Sep 8 18:58:38 2020 (r365470) +++ stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c Tue Sep 8 20:02:08 2020 (r365471) @@ -124,8 +124,8 @@ static __inline Lock *lock_for_pointer(void *ptr) { #define IS_LOCK_FREE_2 __c11_atomic_is_lock_free(2) #define IS_LOCK_FREE_4 __c11_atomic_is_lock_free(4) -/// 32 bit PowerPC doesn't support 8-byte lock_free atomics -#if !defined(__powerpc64__) && defined(__powerpc__) +/// 32 bit MIPS and PowerPC don't support 8-byte lock_free atomics +#if defined(__mips__) || (!defined(__powerpc64__) && defined(__powerpc__)) #define IS_LOCK_FREE_8 0 #else #define IS_LOCK_FREE_8 __c11_atomic_is_lock_free(8) Modified: stable/11/lib/libcompiler_rt/Makefile.inc ============================================================================== --- stable/11/lib/libcompiler_rt/Makefile.inc Tue Sep 8 18:58:38 2020 (r365470) +++ stable/11/lib/libcompiler_rt/Makefile.inc Tue Sep 8 20:02:08 2020 (r365471) @@ -18,6 +18,9 @@ SRCF+= ashldi3 SRCF+= ashlti3 SRCF+= ashrdi3 SRCF+= ashrti3 +SRCF+= atomic +SRCF+= bswapdi2 +SRCF+= bswapsi2 SRCF+= clear_cache SRCF+= clzdi2 SRCF+= clzsi2 @@ -215,12 +218,6 @@ CFLAGS+= -DEMIT_SYNC_ATOMICS SRCF+= stdatomic .endif -.if "${COMPILER_TYPE}" == "clang" && \ - (${MACHINE_ARCH} == "powerpc" || ${MACHINE_ARCH} == "powerpcspe") -SRCS+= atomic.c -CFLAGS.atomic.c+= -Wno-atomic-alignment -.endif - .for file in ${SRCF} .if ${MACHINE_ARCH:Marmv6*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \ && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S) @@ -242,18 +239,9 @@ SRCS+= aeabi_memmove.S SRCS+= aeabi_memset.S SRCS+= aeabi_uidivmod.S SRCS+= aeabi_uldivmod.S -SRCS+= bswapdi2.S -SRCS+= bswapsi2.S SRCS+= switch16.S SRCS+= switch32.S SRCS+= switch8.S SRCS+= switchu8.S SRCS+= sync_synchronize.S .endif - -# GCC-6.3 on mips32 requires bswap32 built-in. -.if ${MACHINE_CPUARCH} == "mips" -SRCS+= bswapdi2.c -SRCS+= bswapsi2.c -.endif - Modified: stable/11/sys/sys/param.h ============================================================================== --- stable/11/sys/sys/param.h Tue Sep 8 18:58:38 2020 (r365470) +++ stable/11/sys/sys/param.h Tue Sep 8 20:02:08 2020 (r365471) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 1104505 /* Master, propagated to newvers */ +#define __FreeBSD_version 1104506 /* Master, propagated to newvers */ /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, From owner-svn-src-stable-11@freebsd.org Tue Sep 8 20:28:40 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 71D353D6B54; Tue, 8 Sep 2020 20:28:40 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmGvD2Scnz4Q6F; Tue, 8 Sep 2020 20:28:40 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 37B8D16262; Tue, 8 Sep 2020 20:28:40 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088KSevp054367; Tue, 8 Sep 2020 20:28:40 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088KSdHL054366; Tue, 8 Sep 2020 20:28:39 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009082028.088KSdHL054366@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Tue, 8 Sep 2020 20:28:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365472 - in stable: 11/contrib/llvm-project/compiler-rt/lib/builtins 11/lib/libcompiler_rt 12/contrib/llvm-project/compiler-rt/lib/builtins 12/lib/libcompiler_rt X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/llvm-project/compiler-rt/lib/builtins 11/lib/libcompiler_rt 12/contrib/llvm-project/compiler-rt/lib/builtins 12/lib/libcompiler_rt X-SVN-Commit-Revision: 365472 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 20:28:40 -0000 Author: dim Date: Tue Sep 8 20:28:39 2020 New Revision: 365472 URL: https://svnweb.freebsd.org/changeset/base/365472 Log: Revert r365471 as it is breaking with old gcc on various arches: MFC r364753: Add atomic and bswap functions to libcompiler_rt There have been several mentions on our mailing lists about missing atomic functions in our system libraries (e.g. __atomic_load_8 and friends), and recently I saw __bswapdi2 and __bswapsi2 mentioned too. To address this, add implementations for the functions from compiler-rt to the system compiler support libraries, e.g. libcompiler_rt.a and and libgcc_s.so. This also needs a small fixup in compiler-rt's atomic.c, to ensure that 32-bit mips can build correctly. Bump __FreeBSD_version to make it easier for port maintainers to detect when these functions were added. PR: 230888 Differential Revision: https://reviews.freebsd.org/D26159 MFC r364782: After r364753, there should be no need to suppress -Watomic-alignment warnings anymore for compiler-rt's atomic.c. This occurred because the IS_LOCK_FREE_8 macro was not correctly defined to 0 for mips, and this caused the compiler to emit a runtime call to __atomic_is_lock_free(), and that triggers the warning. Modified: stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c stable/11/lib/libcompiler_rt/Makefile.inc Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c stable/12/lib/libcompiler_rt/Makefile.inc Directory Properties: stable/12/ (props changed) Modified: stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c ============================================================================== --- stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c Tue Sep 8 20:02:08 2020 (r365471) +++ stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c Tue Sep 8 20:28:39 2020 (r365472) @@ -124,8 +124,8 @@ static __inline Lock *lock_for_pointer(void *ptr) { #define IS_LOCK_FREE_2 __c11_atomic_is_lock_free(2) #define IS_LOCK_FREE_4 __c11_atomic_is_lock_free(4) -/// 32 bit MIPS and PowerPC don't support 8-byte lock_free atomics -#if defined(__mips__) || (!defined(__powerpc64__) && defined(__powerpc__)) +/// 32 bit PowerPC doesn't support 8-byte lock_free atomics +#if !defined(__powerpc64__) && defined(__powerpc__) #define IS_LOCK_FREE_8 0 #else #define IS_LOCK_FREE_8 __c11_atomic_is_lock_free(8) Modified: stable/11/lib/libcompiler_rt/Makefile.inc ============================================================================== --- stable/11/lib/libcompiler_rt/Makefile.inc Tue Sep 8 20:02:08 2020 (r365471) +++ stable/11/lib/libcompiler_rt/Makefile.inc Tue Sep 8 20:28:39 2020 (r365472) @@ -18,9 +18,6 @@ SRCF+= ashldi3 SRCF+= ashlti3 SRCF+= ashrdi3 SRCF+= ashrti3 -SRCF+= atomic -SRCF+= bswapdi2 -SRCF+= bswapsi2 SRCF+= clear_cache SRCF+= clzdi2 SRCF+= clzsi2 @@ -218,6 +215,12 @@ CFLAGS+= -DEMIT_SYNC_ATOMICS SRCF+= stdatomic .endif +.if "${COMPILER_TYPE}" == "clang" && \ + (${MACHINE_ARCH} == "powerpc" || ${MACHINE_ARCH} == "powerpcspe") +SRCS+= atomic.c +CFLAGS.atomic.c+= -Wno-atomic-alignment +.endif + .for file in ${SRCF} .if ${MACHINE_ARCH:Marmv6*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \ && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S) @@ -239,9 +242,18 @@ SRCS+= aeabi_memmove.S SRCS+= aeabi_memset.S SRCS+= aeabi_uidivmod.S SRCS+= aeabi_uldivmod.S +SRCS+= bswapdi2.S +SRCS+= bswapsi2.S SRCS+= switch16.S SRCS+= switch32.S SRCS+= switch8.S SRCS+= switchu8.S SRCS+= sync_synchronize.S .endif + +# GCC-6.3 on mips32 requires bswap32 built-in. +.if ${MACHINE_CPUARCH} == "mips" +SRCS+= bswapdi2.c +SRCS+= bswapsi2.c +.endif + From owner-svn-src-stable-11@freebsd.org Tue Sep 8 20:53:46 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 10FB63D7A08; Tue, 8 Sep 2020 20:53:46 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmHS96m4Rz4S2c; Tue, 8 Sep 2020 20:53:45 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id CB1E616C38; Tue, 8 Sep 2020 20:53:45 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088Krj3G072461; Tue, 8 Sep 2020 20:53:45 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088Krjn4072459; Tue, 8 Sep 2020 20:53:45 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009082053.088Krjn4072459@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 20:53:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365474 - in stable: 11/lib/libc/sys 12/lib/libc/sys X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/lib/libc/sys 12/lib/libc/sys X-SVN-Commit-Revision: 365474 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 20:53:46 -0000 Author: jhb Date: Tue Sep 8 20:53:44 2020 New Revision: 365474 URL: https://svnweb.freebsd.org/changeset/base/365474 Log: MFC 359467: Trim some duplicate EIO descriptions. While here, drop an extra conjunction from the list of error conditions for the remaining EIO description in symlink(2). Modified: stable/11/lib/libc/sys/mkfifo.2 stable/11/lib/libc/sys/symlink.2 Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/lib/libc/sys/mkfifo.2 stable/12/lib/libc/sys/symlink.2 Directory Properties: stable/12/ (props changed) Modified: stable/11/lib/libc/sys/mkfifo.2 ============================================================================== --- stable/11/lib/libc/sys/mkfifo.2 Tue Sep 8 20:51:19 2020 (r365473) +++ stable/11/lib/libc/sys/mkfifo.2 Tue Sep 8 20:53:44 2020 (r365474) @@ -130,10 +130,6 @@ which the fifo is being created has been exhausted. An .Tn I/O error occurred while making the directory entry or allocating the inode. -.It Bq Er EIO -An -.Tn I/O -error occurred while reading from or writing to the file system. .It Bq Er EFAULT The .Fa path Modified: stable/11/lib/libc/sys/symlink.2 ============================================================================== --- stable/11/lib/libc/sys/symlink.2 Tue Sep 8 20:51:19 2020 (r365473) +++ stable/11/lib/libc/sys/symlink.2 Tue Sep 8 20:53:44 2020 (r365474) @@ -118,7 +118,7 @@ manual page for more information. .It Bq Er EIO An I/O error occurred while making the directory entry for .Fa name2 , -or allocating the inode for +allocating the inode for .Fa name2 , or writing out the link contents of .Fa name2 . @@ -149,8 +149,6 @@ contain the symbolic link has been exhausted. .It Bq Er EDQUOT The user's quota of inodes on the file system on which the symbolic link is being created has been exhausted. -.It Bq Er EIO -An I/O error occurred while making the directory entry or allocating the inode. .It Bq Er EFAULT The .Fa name1 From owner-svn-src-stable-11@freebsd.org Tue Sep 8 22:19:07 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E3E993D9A73; Tue, 8 Sep 2020 22:19:07 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmKLg5nTGz4Xd4; Tue, 8 Sep 2020 22:19:07 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id A9DC017756; Tue, 8 Sep 2020 22:19:07 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088MJ7O0021934; Tue, 8 Sep 2020 22:19:07 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088MJ7C6021933; Tue, 8 Sep 2020 22:19:07 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009082219.088MJ7C6021933@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 22:19:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365476 - in stable: 11/sys/dev/uart 12/sys/dev/uart X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/sys/dev/uart 12/sys/dev/uart X-SVN-Commit-Revision: 365476 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 22:19:08 -0000 Author: jhb Date: Tue Sep 8 22:19:06 2020 New Revision: 365476 URL: https://svnweb.freebsd.org/changeset/base/365476 Log: MFC 359899: Correct baud rate error calculation. Shifting right by 1 is not the same as dividing by 2 for signed values. In particular, dividing a signed value by 2 gives the integer ceiling of the (e.g. -5 / 2 == -2) whereas shifting right by 1 always gives the floor (-5 >> 1 == -3). An embedded board with a 25 Mhz base clock results in an error of -30.5% when used with a baud rate of 115200. Using division, this truncates to -30% and is permitted. Using the shift, this fails and is rejected causing TIOCSETA requests to fail with EINVAL and breaking getty(8). Using division gives the same error range for both over and under baud rates and also makes the code match the behavior documented in the existing comment about supporting boards with 25 Mhz clocks. Modified: stable/11/sys/dev/uart/uart_dev_ns8250.c Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/sys/dev/uart/uart_dev_ns8250.c Directory Properties: stable/12/ (props changed) Modified: stable/11/sys/dev/uart/uart_dev_ns8250.c ============================================================================== --- stable/11/sys/dev/uart/uart_dev_ns8250.c Tue Sep 8 21:39:34 2020 (r365475) +++ stable/11/sys/dev/uart/uart_dev_ns8250.c Tue Sep 8 22:19:06 2020 (r365476) @@ -136,7 +136,7 @@ ns8250_divisor(int rclk, int baudrate) actual_baud = rclk / (divisor << 4); /* 10 times error in percent: */ - error = ((actual_baud - baudrate) * 2000 / baudrate + 1) >> 1; + error = ((actual_baud - baudrate) * 2000 / baudrate + 1) / 2; /* enforce maximum error tolerance: */ if (error < -UART_DEV_TOLERANCE_PCT || error > UART_DEV_TOLERANCE_PCT) From owner-svn-src-stable-11@freebsd.org Tue Sep 8 22:50:25 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E5C383DADDC; Tue, 8 Sep 2020 22:50:25 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BmL2n5rPlz4Zkc; Tue, 8 Sep 2020 22:50:25 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id ABF8D18104; Tue, 8 Sep 2020 22:50:25 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 088MoP4e040315; Tue, 8 Sep 2020 22:50:25 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 088MoP6T040314; Tue, 8 Sep 2020 22:50:25 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <202009082250.088MoP6T040314@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 8 Sep 2020 22:50:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365480 - in stable: 11/sys/dev/uart 12/sys/dev/uart X-SVN-Group: stable-11 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/sys/dev/uart 12/sys/dev/uart X-SVN-Commit-Revision: 365480 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Sep 2020 22:50:26 -0000 Author: jhb Date: Tue Sep 8 22:50:24 2020 New Revision: 365480 URL: https://svnweb.freebsd.org/changeset/base/365480 Log: MFC 359900: Export a sysctl count of RX FIFO overrun events. uart(4) backends currently detect RX FIFO overrun errors and report them to the uart(4) core layer. They are then reported to the generic TTY layer which promptly ignores them. As a result, there is currently no good way to determine if a uart is experiencing RX FIFO overruns. One could add a generic per-tty counter, but there did not appear to be a good way to export those. Instead, add a sysctl under the uart(4) sysctl tree to export the count of overruns. Modified: stable/11/sys/dev/uart/uart_bus.h stable/11/sys/dev/uart/uart_core.c Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/sys/dev/uart/uart_bus.h stable/12/sys/dev/uart/uart_core.c Directory Properties: stable/12/ (props changed) Modified: stable/11/sys/dev/uart/uart_bus.h ============================================================================== --- stable/11/sys/dev/uart/uart_bus.h Tue Sep 8 22:42:41 2020 (r365479) +++ stable/11/sys/dev/uart/uart_bus.h Tue Sep 8 22:50:24 2020 (r365480) @@ -108,6 +108,7 @@ struct uart_softc { int sc_rxput; int sc_rxget; int sc_rxfifosz; /* Size of RX FIFO. */ + int sc_rxoverruns; /* Transmitter data. */ uint8_t *sc_txbuf; Modified: stable/11/sys/dev/uart/uart_core.c ============================================================================== --- stable/11/sys/dev/uart/uart_core.c Tue Sep 8 22:42:41 2020 (r365479) +++ stable/11/sys/dev/uart/uart_core.c Tue Sep 8 22:50:24 2020 (r365480) @@ -327,6 +327,7 @@ uart_intr_overrun(void *arg) sc->sc_rxbuf[sc->sc_rxput] = UART_STAT_OVERRUN; uart_sched_softih(sc, SER_INT_RXREADY); } + sc->sc_rxoverruns++; UART_FLUSH(sc, UART_FLUSH_RECEIVER); return (0); } @@ -735,6 +736,12 @@ uart_bus_attach(device_t dev) if (sc->sc_sysdev != NULL) sc->sc_sysdev->hwmtx = sc->sc_hwmtx; + + if (sc->sc_rxfifosz > 1) + SYSCTL_ADD_INT(device_get_sysctl_ctx(dev), + SYSCTL_CHILDREN(device_get_sysctl_tree(dev)), OID_AUTO, + "rx_overruns", CTLFLAG_RD, &sc->sc_rxoverruns, 0, + "Receive overruns"); return (0); From owner-svn-src-stable-11@freebsd.org Wed Sep 9 22:40:39 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C95AD3DF79D; Wed, 9 Sep 2020 22:40:39 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Bmxn34yBkz41gP; Wed, 9 Sep 2020 22:40:39 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 8D683905A; Wed, 9 Sep 2020 22:40:39 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 089Medh5027405; Wed, 9 Sep 2020 22:40:39 GMT (envelope-from brooks@FreeBSD.org) Received: (from brooks@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 089MedNr027404; Wed, 9 Sep 2020 22:40:39 GMT (envelope-from brooks@FreeBSD.org) Message-Id: <202009092240.089MedNr027404@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: brooks set sender to brooks@FreeBSD.org using -f From: Brooks Davis Date: Wed, 9 Sep 2020 22:40:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365534 - stable/11/sbin/init X-SVN-Group: stable-11 X-SVN-Commit-Author: brooks X-SVN-Commit-Paths: stable/11/sbin/init X-SVN-Commit-Revision: 365534 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 09 Sep 2020 22:40:39 -0000 Author: brooks Date: Wed Sep 9 22:40:39 2020 New Revision: 365534 URL: https://svnweb.freebsd.org/changeset/base/365534 Log: MFC r365279: Remove risky compatability with old kernels The badsys() handler for SIGSYS was added as a transtion aid for kernels lacking sysctl() in 1993. It is unsafe and unsound so remove it rather than running the risk of a privilege-dropping system call being silently omitted. This partially reverts SCCSID 6.12 (Berkeley) 03/03/93 "add code to change the system security level". Reviewed by: mckusick, imp, kevans Obtained from: CheriBSD Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D26289 Modified: stable/11/sbin/init/init.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sbin/init/init.c ============================================================================== --- stable/11/sbin/init/init.c Wed Sep 9 22:40:14 2020 (r365533) +++ stable/11/sbin/init/init.c Wed Sep 9 22:40:39 2020 (r365534) @@ -104,7 +104,6 @@ static void stall(const char *, ...) __printflike(1, 2 static void warning(const char *, ...) __printflike(1, 2); static void emergency(const char *, ...) __printflike(1, 2); static void disaster(int); -static void badsys(int); static void revoke_ttys(void); static int runshutdown(void); static char *strk(char *); @@ -305,9 +304,8 @@ invalid: * We catch or block signals rather than ignore them, * so that they get reset on exec. */ - handle(badsys, SIGSYS, 0); - handle(disaster, SIGABRT, SIGFPE, SIGILL, SIGSEGV, SIGBUS, SIGXCPU, - SIGXFSZ, 0); + handle(disaster, SIGABRT, SIGFPE, SIGILL, SIGSEGV, SIGBUS, SIGSYS, + SIGXCPU, SIGXFSZ, 0); handle(transition_handler, SIGHUP, SIGINT, SIGEMT, SIGTERM, SIGTSTP, SIGUSR1, SIGUSR2, 0); handle(alrm_handler, SIGALRM, 0); @@ -502,22 +500,6 @@ emergency(const char *message, ...) vsyslog(LOG_EMERG, message, ap); va_end(ap); -} - -/* - * Catch a SIGSYS signal. - * - * These may arise if a system does not support sysctl. - * We tolerate up to 25 of these, then throw in the towel. - */ -static void -badsys(int sig) -{ - static int badcount = 0; - - if (badcount++ < 25) - return; - disaster(sig); } /* From owner-svn-src-stable-11@freebsd.org Thu Sep 10 04:17:23 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id ECA113E9C62; Thu, 10 Sep 2020 04:17:23 +0000 (UTC) (envelope-from lwhsu@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Bn5Fb646Sz4QpN; Thu, 10 Sep 2020 04:17:23 +0000 (UTC) (envelope-from lwhsu@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B2730CFB6; Thu, 10 Sep 2020 04:17:23 +0000 (UTC) (envelope-from lwhsu@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08A4HNHp038079; Thu, 10 Sep 2020 04:17:23 GMT (envelope-from lwhsu@FreeBSD.org) Received: (from lwhsu@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08A4HNw4038078; Thu, 10 Sep 2020 04:17:23 GMT (envelope-from lwhsu@FreeBSD.org) Message-Id: <202009100417.08A4HNw4038078@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: lwhsu set sender to lwhsu@FreeBSD.org using -f From: Li-Wen Hsu Date: Thu, 10 Sep 2020 04:17:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365552 - stable/11/share/man/man4 X-SVN-Group: stable-11 X-SVN-Commit-Author: lwhsu X-SVN-Commit-Paths: stable/11/share/man/man4 X-SVN-Commit-Revision: 365552 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 Sep 2020 04:17:24 -0000 Author: lwhsu Date: Thu Sep 10 04:17:23 2020 New Revision: 365552 URL: https://svnweb.freebsd.org/changeset/base/365552 Log: MFC r365403: Slightly improve usb(4) - Mention USB 3.0 - Update links - Fix `mandoc -T lint` warnings Reviewed by: bcr, hselasky Differential Revision: https://reviews.freebsd.org/D26349 Modified: stable/11/share/man/man4/usb.4 Directory Properties: stable/11/ (props changed) Modified: stable/11/share/man/man4/usb.4 ============================================================================== --- stable/11/share/man/man4/usb.4 Thu Sep 10 04:17:05 2020 (r365551) +++ stable/11/share/man/man4/usb.4 Thu Sep 10 04:17:23 2020 (r365552) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 29, 2017 +.Dd September 7, 2020 .Dt USB 4 .Os .Sh NAME @@ -52,8 +52,7 @@ for more information. .Sh DESCRIPTION .Fx provides machine-independent bus support and drivers for -.Tn USB -devices in host and device side mode. +USB devices in host and device side mode. .Pp The .Nm @@ -67,32 +66,25 @@ driver has three layers: The controller attaches to a physical bus like .Xr pci 4 . -The -.Tn USB -bus attaches to the controller, and the root hub attaches +The USB bus attaches to the controller, and the root hub attaches to the controller. Any devices attached to the bus will attach to the root hub -or another hub attached to the -.Tn USB -bus. +or another hub attached to the USB bus. .Pp The .Nm uhub device will always be present as it is needed for the root hub. .Sh INTRODUCTION TO USB -The -.Tn USB -is a system where external devices can be connected to a PC. +The USB is a system where external devices can be connected to a PC. The most common USB speeds are: .Bl -tag -width 6n -offset indent -.It Low Speed (1.5MBit/sec) -.It Full Speed (12MBit/sec) -.It High Speed (480MBit/sec) +.It Low Speed (1.5 MBit/sec) +.It Full Speed (12 MBit/sec) +.It High Speed (480 MBit/sec) +.It SuperSpeed (5 GBit/sec) .El .Pp -Each -.Tn USB -has a USB controller that is the master of the bus. +Each USB has a USB controller that is the master of the bus. The physical communication is simplex which means the host controller only communicates with one USB device at a time. .Pp @@ -122,9 +114,7 @@ A device may operate in different configurations. Depending on the configuration, the device may present different sets of endpoints and interfaces. .Pp -The bus enumeration of the -.Tn USB -bus proceeds in several steps: +The bus enumeration of the USB bus proceeds in several steps: .Bl -enum .It Any interface specific driver can attach to the device. @@ -132,11 +122,9 @@ Any interface specific driver can attach to the device If none is found, generic interface class drivers can attach. .El .Sh SEE ALSO -The -.Tn USB -specifications can be found at: +The USB specifications can be found at: .Pp -.D1 Pa http://www.usb.org/developers/docs/ +.D1 Pa https://www.usb.org/documents .Pp .Xr libusb 3 , .Xr aue 4 , @@ -166,7 +154,7 @@ specifications can be found at: .Sh STANDARDS The .Nm -module complies with the USB 2.0 standard. +module complies with the USB 3.0 standard. .Sh HISTORY The .Nm From owner-svn-src-stable-11@freebsd.org Fri Sep 11 10:11:05 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 455FD3D4933; Fri, 11 Sep 2020 10:11:05 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Bns3F19JLz46mK; Fri, 11 Sep 2020 10:11:05 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0C89D2232D; Fri, 11 Sep 2020 10:11:05 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08BAB4df039844; Fri, 11 Sep 2020 10:11:04 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08BAB4HJ039843; Fri, 11 Sep 2020 10:11:04 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009111011.08BAB4HJ039843@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Fri, 11 Sep 2020 10:11:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365629 - stable/11/libexec/rtld-elf X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/11/libexec/rtld-elf X-SVN-Commit-Revision: 365629 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Sep 2020 10:11:05 -0000 Author: kib Date: Fri Sep 11 10:11:04 2020 New Revision: 365629 URL: https://svnweb.freebsd.org/changeset/base/365629 Log: MFC r365360, r365370: rtld: Handle ELF dso with program headers outside the first page. PR: 229708 Modified: stable/11/libexec/rtld-elf/map_object.c Directory Properties: stable/11/ (props changed) Modified: stable/11/libexec/rtld-elf/map_object.c ============================================================================== --- stable/11/libexec/rtld-elf/map_object.c Fri Sep 11 10:07:09 2020 (r365628) +++ stable/11/libexec/rtld-elf/map_object.c Fri Sep 11 10:11:04 2020 (r365629) @@ -38,11 +38,19 @@ #include "debug.h" #include "rtld.h" -static Elf_Ehdr *get_elf_header(int, const char *, const struct stat *); +static Elf_Ehdr *get_elf_header(int, const char *, const struct stat *, + Elf_Phdr **phdr); static int convert_flags(int); /* Elf flags -> mmap flags */ int __getosreldate(void); +static bool +phdr_in_zero_page(const Elf_Ehdr *hdr) +{ + return (hdr->e_phoff + hdr->e_phnum * sizeof(Elf_Phdr) <= + (size_t)PAGE_SIZE); +} + /* * Map a shared object into memory. The "fd" argument is a file descriptor, * which must be open on the object and positioned at its beginning. @@ -92,17 +100,15 @@ map_object(int fd, const char *path, const struct stat char *note_map; size_t note_map_len; - hdr = get_elf_header(fd, path, sb); + hdr = get_elf_header(fd, path, sb, &phdr); if (hdr == NULL) return (NULL); /* * Scan the program header entries, and save key information. - * * We expect that the loadable segments are ordered by load address. */ - phdr = (Elf_Phdr *) ((char *)hdr + hdr->e_phoff); - phsize = hdr->e_phnum * sizeof (phdr[0]); + phsize = hdr->e_phnum * sizeof(phdr[0]); phlimit = phdr + hdr->e_phnum; nsegs = -1; phdyn = phinterp = phtls = NULL; @@ -324,14 +330,18 @@ error1: error: if (note_map != NULL && note_map != MAP_FAILED) munmap(note_map, note_map_len); + if (!phdr_in_zero_page(hdr)) + munmap(phdr, hdr->e_phnum * sizeof(phdr[0])); munmap(hdr, PAGE_SIZE); return (NULL); } static Elf_Ehdr * -get_elf_header(int fd, const char *path, const struct stat *sbp) +get_elf_header(int fd, const char *path, const struct stat *sbp, + Elf_Phdr **phdr_p) { Elf_Ehdr *hdr; + Elf_Phdr *phdr; /* Make sure file has enough data for the ELF header */ if (sbp != NULL && sbp->st_size < sizeof(Elf_Ehdr)) { @@ -380,11 +390,19 @@ get_elf_header(int fd, const char *path, const struct "%s: invalid shared object: e_phentsize != sizeof(Elf_Phdr)", path); goto error; } - if (hdr->e_phoff + hdr->e_phnum * sizeof(Elf_Phdr) > - (size_t)PAGE_SIZE) { - _rtld_error("%s: program header too large", path); - goto error; + if (phdr_in_zero_page(hdr)) { + phdr = (Elf_Phdr *)((char *)hdr + hdr->e_phoff); + } else { + phdr = mmap(NULL, hdr->e_phnum * sizeof(phdr[0]), + PROT_READ, MAP_PRIVATE | MAP_PREFAULT_READ, fd, + hdr->e_phoff); + if (phdr == MAP_FAILED) { + _rtld_error("%s: error mapping phdr: %s", path, + rtld_strerror(errno)); + goto error; + } } + *phdr_p = phdr; return (hdr); error: From owner-svn-src-stable-11@freebsd.org Sat Sep 12 09:47:26 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 179DD3D20CD; Sat, 12 Sep 2020 09:47:26 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BpSTT6xzPz4fZQ; Sat, 12 Sep 2020 09:47:25 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id D32B81330D; Sat, 12 Sep 2020 09:47:25 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08C9lPM1012682; Sat, 12 Sep 2020 09:47:25 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08C9lPpB012681; Sat, 12 Sep 2020 09:47:25 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009120947.08C9lPpB012681@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sat, 12 Sep 2020 09:47:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365655 - stable/11/libexec/rtld-elf X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/11/libexec/rtld-elf X-SVN-Commit-Revision: 365655 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 09:47:26 -0000 Author: kib Date: Sat Sep 12 09:47:25 2020 New Revision: 365655 URL: https://svnweb.freebsd.org/changeset/base/365655 Log: MFC r365368: rtld: do not process absent dynamic. PR: 249121 Modified: stable/11/libexec/rtld-elf/rtld.c Directory Properties: stable/11/ (props changed) Modified: stable/11/libexec/rtld-elf/rtld.c ============================================================================== --- stable/11/libexec/rtld-elf/rtld.c Sat Sep 12 09:46:14 2020 (r365654) +++ stable/11/libexec/rtld-elf/rtld.c Sat Sep 12 09:47:25 2020 (r365655) @@ -1066,7 +1066,10 @@ digest_dynamic1(Obj_Entry *obj, int early, const Elf_D *dyn_runpath = NULL; obj->bind_now = false; - for (dynp = obj->dynamic; dynp->d_tag != DT_NULL; dynp++) { + dynp = obj->dynamic; + if (dynp == NULL) + return; + for (; dynp->d_tag != DT_NULL; dynp++) { switch (dynp->d_tag) { case DT_REL: From owner-svn-src-stable-11@freebsd.org Sat Sep 12 09:47:59 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 198F93D1F11; Sat, 12 Sep 2020 09:47:59 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BpSV66Xnbz4fbl; Sat, 12 Sep 2020 09:47:58 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C3F2213383; Sat, 12 Sep 2020 09:47:58 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08C9lwbc012772; Sat, 12 Sep 2020 09:47:58 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08C9lwi5012771; Sat, 12 Sep 2020 09:47:58 GMT (envelope-from kib@FreeBSD.org) Message-Id: <202009120947.08C9lwi5012771@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sat, 12 Sep 2020 09:47:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365656 - stable/11/libexec/rtld-elf X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/11/libexec/rtld-elf X-SVN-Commit-Revision: 365656 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 09:47:59 -0000 Author: kib Date: Sat Sep 12 09:47:58 2020 New Revision: 365656 URL: https://svnweb.freebsd.org/changeset/base/365656 Log: MFC r365369: rtld: do not refuse to relocate objects without dynamic symtabs. PR: 249121 Modified: stable/11/libexec/rtld-elf/rtld.c Directory Properties: stable/11/ (props changed) Modified: stable/11/libexec/rtld-elf/rtld.c ============================================================================== --- stable/11/libexec/rtld-elf/rtld.c Sat Sep 12 09:47:25 2020 (r365655) +++ stable/11/libexec/rtld-elf/rtld.c Sat Sep 12 09:47:58 2020 (r365656) @@ -2955,11 +2955,8 @@ relocate_object(Obj_Entry *obj, bool bind_now, Obj_Ent dbg("relocating \"%s\"", obj->path); if (obj->symtab == NULL || obj->strtab == NULL || - !(obj->valid_hash_sysv || obj->valid_hash_gnu)) { - _rtld_error("%s: Shared object has no run-time symbol table", - obj->path); - return (-1); - } + !(obj->valid_hash_sysv || obj->valid_hash_gnu)) + dbg("object %s has no run-time symbol table", obj->path); /* There are relocations to the write-protected text segment. */ if (obj->textrel && reloc_textrel_prot(obj, true) != 0) From owner-svn-src-stable-11@freebsd.org Sat Sep 12 16:33:07 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B384B3DCB75; Sat, 12 Sep 2020 16:33:07 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BpdTb4KW3z4CTJ; Sat, 12 Sep 2020 16:33:07 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 77BE5180A2; Sat, 12 Sep 2020 16:33:07 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08CGX7an072955; Sat, 12 Sep 2020 16:33:07 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08CGX6Pl072952; Sat, 12 Sep 2020 16:33:06 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009121633.08CGX6Pl072952@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sat, 12 Sep 2020 16:33:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365661 - in stable: 11/contrib/llvm-project/compiler-rt/lib/builtins 11/lib/libcompiler_rt 11/sys/sys 12/contrib/llvm-project/compiler-rt/lib/builtins 12/lib/libcompiler_rt 12/sys/sys X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/llvm-project/compiler-rt/lib/builtins 11/lib/libcompiler_rt 11/sys/sys 12/contrib/llvm-project/compiler-rt/lib/builtins 12/lib/libcompiler_rt 12/sys/sys X-SVN-Commit-Revision: 365661 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 16:33:07 -0000 Author: dim Date: Sat Sep 12 16:33:05 2020 New Revision: 365661 URL: https://svnweb.freebsd.org/changeset/base/365661 Log: MFC r364753: Add atomic and bswap functions to libcompiler_rt There have been several mentions on our mailing lists about missing atomic functions in our system libraries (e.g. __atomic_load_8 and friends), and recently I saw __bswapdi2 and __bswapsi2 mentioned too. To address this, add implementations for the functions from compiler-rt to the system compiler support libraries, e.g. libcompiler_rt.a and and libgcc_s.so. This also needs a small fixup in compiler-rt's atomic.c, to ensure that 32-bit mips can build correctly. Bump __FreeBSD_version to make it easier for port maintainers to detect when these functions were added. Differential Revision: https://reviews.freebsd.org/D26159 MFC r364782: After r364753, there should be no need to suppress -Watomic-alignment warnings anymore for compiler-rt's atomic.c. This occurred because the IS_LOCK_FREE_8 macro was not correctly defined to 0 for mips, and this caused the compiler to emit a runtime call to __atomic_is_lock_free(), and that triggers the warning. MFC r365509: Follow-up r364753 by enabling compiler-rt's atomic implementation only for clang, as it uses clang specific builtins, and does not compile correctly with gcc. Note that gcc packages usually come with their own libatomic, providing these primitives. MFC r365588: Follow-up r364753 by only using arm's stdatomic.c implementation, as it already covers the functions in compiler-rt's atomic.c, leading to conflicts when linking. PR: 230888 Modified: stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c stable/11/lib/libcompiler_rt/Makefile.inc stable/11/sys/sys/param.h Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c stable/12/lib/libcompiler_rt/Makefile.inc stable/12/sys/sys/param.h Directory Properties: stable/12/ (props changed) Modified: stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c ============================================================================== --- stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c Sat Sep 12 15:18:52 2020 (r365660) +++ stable/11/contrib/llvm-project/compiler-rt/lib/builtins/atomic.c Sat Sep 12 16:33:05 2020 (r365661) @@ -124,8 +124,8 @@ static __inline Lock *lock_for_pointer(void *ptr) { #define IS_LOCK_FREE_2 __c11_atomic_is_lock_free(2) #define IS_LOCK_FREE_4 __c11_atomic_is_lock_free(4) -/// 32 bit PowerPC doesn't support 8-byte lock_free atomics -#if !defined(__powerpc64__) && defined(__powerpc__) +/// 32 bit MIPS and PowerPC don't support 8-byte lock_free atomics +#if defined(__mips__) || (!defined(__powerpc64__) && defined(__powerpc__)) #define IS_LOCK_FREE_8 0 #else #define IS_LOCK_FREE_8 __c11_atomic_is_lock_free(8) Modified: stable/11/lib/libcompiler_rt/Makefile.inc ============================================================================== --- stable/11/lib/libcompiler_rt/Makefile.inc Sat Sep 12 15:18:52 2020 (r365660) +++ stable/11/lib/libcompiler_rt/Makefile.inc Sat Sep 12 16:33:05 2020 (r365661) @@ -18,6 +18,8 @@ SRCF+= ashldi3 SRCF+= ashlti3 SRCF+= ashrdi3 SRCF+= ashrti3 +SRCF+= bswapdi2 +SRCF+= bswapsi2 SRCF+= clear_cache SRCF+= clzdi2 SRCF+= clzsi2 @@ -117,6 +119,14 @@ SRCF+= udivti3 SRCF+= umoddi3 SRCF+= umodti3 +# Enable compiler-rt's atomic implementation only for clang, as it uses clang +# specific builtins, and gcc packages usually come with their own libatomic. +# Exclude arm which has its own implementations of atomic functions, below. +.if "${COMPILER_TYPE}" == "clang" && \ + !(${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "armv6") +SRCF+= atomic +.endif + # Avoid using SSE2 instructions on i386, if unsupported. .if ${MACHINE_CPUARCH} == "i386" && empty(MACHINE_CPU:Msse2) SRCS+= floatdidf.c @@ -215,12 +225,6 @@ CFLAGS+= -DEMIT_SYNC_ATOMICS SRCF+= stdatomic .endif -.if "${COMPILER_TYPE}" == "clang" && \ - (${MACHINE_ARCH} == "powerpc" || ${MACHINE_ARCH} == "powerpcspe") -SRCS+= atomic.c -CFLAGS.atomic.c+= -Wno-atomic-alignment -.endif - .for file in ${SRCF} .if ${MACHINE_ARCH:Marmv6*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \ && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S) @@ -242,18 +246,9 @@ SRCS+= aeabi_memmove.S SRCS+= aeabi_memset.S SRCS+= aeabi_uidivmod.S SRCS+= aeabi_uldivmod.S -SRCS+= bswapdi2.S -SRCS+= bswapsi2.S SRCS+= switch16.S SRCS+= switch32.S SRCS+= switch8.S SRCS+= switchu8.S SRCS+= sync_synchronize.S .endif - -# GCC-6.3 on mips32 requires bswap32 built-in. -.if ${MACHINE_CPUARCH} == "mips" -SRCS+= bswapdi2.c -SRCS+= bswapsi2.c -.endif - Modified: stable/11/sys/sys/param.h ============================================================================== --- stable/11/sys/sys/param.h Sat Sep 12 15:18:52 2020 (r365660) +++ stable/11/sys/sys/param.h Sat Sep 12 16:33:05 2020 (r365661) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 1104506 /* Master, propagated to newvers */ +#define __FreeBSD_version 1104507 /* Master, propagated to newvers */ /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, From owner-svn-src-stable-11@freebsd.org Sat Sep 12 16:50:08 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A61E33DCFC8; Sat, 12 Sep 2020 16:50:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BpdsD3z0jz4D8F; Sat, 12 Sep 2020 16:50:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 6C25617BE9; Sat, 12 Sep 2020 16:50:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08CGo8kH079775; Sat, 12 Sep 2020 16:50:08 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08CGo6Nh079767; Sat, 12 Sep 2020 16:50:06 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009121650.08CGo6Nh079767@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sat, 12 Sep 2020 16:50:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365662 - in stable: 11/contrib/jemalloc 11/contrib/jemalloc/doc 11/lib/libc/stdlib/jemalloc 11/share/man/man5 11/share/mk 11/tools/build/options 12/contrib/jemalloc 12/contrib/jemalloc... X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/jemalloc 11/contrib/jemalloc/doc 11/lib/libc/stdlib/jemalloc 11/share/man/man5 11/share/mk 11/tools/build/options 12/contrib/jemalloc 12/contrib/jemalloc/doc 12/lib/libc/stdlib/j... X-SVN-Commit-Revision: 365662 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 16:50:08 -0000 Author: dim Date: Sat Sep 12 16:50:04 2020 New Revision: 365662 URL: https://svnweb.freebsd.org/changeset/base/365662 Log: MFC r365371: Turn MALLOC_PRODUCTION into a regular src.conf(5) option For historical reasons, defining MALLOC_PRODUCTION in /etc/make.conf has been used to turn off potentially expensive debug checks and statistics gathering in the implementation of malloc(3). It seems more consistent to turn this into a regular src.conf(5) option, e.g. WITH_MALLOC_PRODUCTION / WITHOUT_MALLOC_PRODUCTION. This can then be toggled similar to any other source build option, and turned on or off by default for e.g. stable branches. Reviewed by: imp, #manpages Differential Revision: https://reviews.freebsd.org/D26337 MFC r365373: Follow-up r365371 by removing sentences which indicate the state of the MK_MALLOC_PRODUCTION option on -CURRENT. Also, for the sake of backwards compatibility, support the old way of enabling 'production malloc', e.g. by adding a define in make.conf(5). Added: stable/11/tools/build/options/WITHOUT_MALLOC_PRODUCTION - copied, changed from r365371, head/tools/build/options/WITHOUT_MALLOC_PRODUCTION stable/11/tools/build/options/WITH_MALLOC_PRODUCTION - copied, changed from r365371, head/tools/build/options/WITH_MALLOC_PRODUCTION Modified: stable/11/contrib/jemalloc/FREEBSD-diffs stable/11/contrib/jemalloc/doc/jemalloc.3 stable/11/lib/libc/stdlib/jemalloc/Makefile.inc stable/11/share/man/man5/make.conf.5 stable/11/share/man/man5/src.conf.5 stable/11/share/mk/src.opts.mk Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Added: stable/12/tools/build/options/WITHOUT_MALLOC_PRODUCTION - copied, changed from r365371, head/tools/build/options/WITHOUT_MALLOC_PRODUCTION stable/12/tools/build/options/WITH_MALLOC_PRODUCTION - copied, changed from r365371, head/tools/build/options/WITH_MALLOC_PRODUCTION Modified: stable/12/contrib/jemalloc/FREEBSD-diffs stable/12/contrib/jemalloc/doc/jemalloc.3 stable/12/lib/libc/stdlib/jemalloc/Makefile.inc stable/12/share/man/man5/make.conf.5 stable/12/share/man/man5/src.conf.5 stable/12/share/mk/src.opts.mk Directory Properties: stable/12/ (props changed) Modified: stable/11/contrib/jemalloc/FREEBSD-diffs ============================================================================== --- stable/11/contrib/jemalloc/FREEBSD-diffs Sat Sep 12 16:33:05 2020 (r365661) +++ stable/11/contrib/jemalloc/FREEBSD-diffs Sat Sep 12 16:50:04 2020 (r365662) @@ -14,7 +14,7 @@ index c4a44e3..4626e9b 100644 + , , and + . Additionally, + is enabled in development versions of -+ FreeBSD (controlled by the MALLOC_PRODUCTION make ++ FreeBSD (controlled by the MK_MALLOC_PRODUCTION make + variable). + Modified: stable/11/contrib/jemalloc/doc/jemalloc.3 ============================================================================== --- stable/11/contrib/jemalloc/doc/jemalloc.3 Sat Sep 12 16:33:05 2020 (r365661) +++ stable/11/contrib/jemalloc/doc/jemalloc.3 Sat Sep 12 16:50:04 2020 (r365662) @@ -45,7 +45,7 @@ The following configuration options are enabled in lib \fB\-\-enable\-xmalloc\fR\&. Additionally, \fB\-\-enable\-debug\fR is enabled in development versions of FreeBSD (controlled by the -\fBMALLOC_PRODUCTION\fR +\fBMK_MALLOC_PRODUCTION\fR make variable)\&. .SH "SYNOPSIS" .sp Modified: stable/11/lib/libc/stdlib/jemalloc/Makefile.inc ============================================================================== --- stable/11/lib/libc/stdlib/jemalloc/Makefile.inc Sat Sep 12 16:33:05 2020 (r365661) +++ stable/11/lib/libc/stdlib/jemalloc/Makefile.inc Sat Sep 12 16:50:04 2020 (r365662) @@ -44,6 +44,6 @@ MLINKS+= \ jemalloc.3 nallocx.3 \ jemalloc.3 malloc.conf.5 -.if defined(MALLOC_PRODUCTION) +.if ${MK_MALLOC_PRODUCTION} != "no" || defined(MALLOC_PRODUCTION) CFLAGS+= -DMALLOC_PRODUCTION .endif Modified: stable/11/share/man/man5/make.conf.5 ============================================================================== --- stable/11/share/man/man5/make.conf.5 Sat Sep 12 16:33:05 2020 (r365661) +++ stable/11/share/man/man5/make.conf.5 Sat Sep 12 16:50:04 2020 (r365662) @@ -388,12 +388,6 @@ console driver to and allow access over FireWire(IEEE1394) using .Xr dconschat 8 . Currently, only i386 and amd64 are supported. -.It Va MALLOC_PRODUCTION -.Pq Vt bool -Set this to disable assertions and statistics gathering in -.Xr malloc 3 . -It also defaults the A and J runtime options to off. -Disabled by default on -CURRENT. .It Va MODULES_WITH_WORLD .Pq Vt bool Set to build modules with the system instead of the kernel. Modified: stable/11/share/man/man5/src.conf.5 ============================================================================== --- stable/11/share/man/man5/src.conf.5 Sat Sep 12 16:33:05 2020 (r365661) +++ stable/11/share/man/man5/src.conf.5 Sat Sep 12 16:50:04 2020 (r365662) @@ -1,6 +1,6 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. .\" $FreeBSD$ -.Dd May 5, 2020 +.Dd September 12, 2020 .Dt SRC.CONF 5 .Os .Sh NAME @@ -315,6 +315,8 @@ When set, it enforces these options: .It .Va WITHOUT_CLANG_EXTRAS .It +.Va WITHOUT_CLANG_FORMAT +.It .Va WITHOUT_CLANG_FULL .It .Va WITHOUT_LLVM_COV @@ -339,6 +341,8 @@ This is a default setting on amd64/amd64, arm/arm, arm/armeb, arm/armv6, arm64/aarch64, i386/i386 and pc98/i386. .It Va WITH_CLANG_EXTRAS Set to build additional clang and llvm tools, such as bugpoint. +.It Va WITH_CLANG_FORMAT +Set to build clang-format. .It Va WITHOUT_CLANG_FULL Set to avoid building the ARCMigrate, Rewriter and StaticAnalyzer components of the Clang C/C++ compiler. @@ -460,6 +464,8 @@ When set, it enforces these options: .It .Va WITHOUT_CLANG_EXTRAS .It +.Va WITHOUT_CLANG_FORMAT +.It .Va WITHOUT_CLANG_FULL .It .Va WITHOUT_GNUCXX @@ -1177,6 +1183,10 @@ MTA selector. Set to not install .Xr make 1 and related support files. +.It Va WITH_MALLOC_PRODUCTION +Set to disable assertions and statistics gathering in +.Xr malloc 3 . +It also defaults the A and J runtime options to off. .It Va WITHOUT_MAN Set to not build manual pages. When set, these options are also in effect: @@ -1356,12 +1366,12 @@ Enable building openldap support for kerberos. Set to not build LLVM's OpenMP runtime. .Pp This is a default setting on -arm/arm, arm/armeb, arm/armv6, arm64/aarch64, mips/mipsel, mips/mips, mips/mips64el, mips/mips64, mips/mipsn32, powerpc/powerpc and sparc64/sparc64. +arm/arm, arm/armeb, arm/armv6, mips/mipsel, mips/mips, mips/mips64el, mips/mips64, mips/mipsn32, powerpc/powerpc and sparc64/sparc64. .It Va WITH_OPENMP Set to build LLVM's OpenMP runtime. .Pp This is a default setting on -amd64/amd64, i386/i386, pc98/i386 and powerpc/powerpc64. +amd64/amd64, arm64/aarch64, i386/i386, pc98/i386 and powerpc/powerpc64. .It Va WITHOUT_OPENSSH Set to not build OpenSSH. .It Va WITHOUT_OPENSSL @@ -1651,6 +1661,8 @@ When set, it enforces these options: .Va WITHOUT_CLANG .It .Va WITHOUT_CLANG_EXTRAS +.It +.Va WITHOUT_CLANG_FORMAT .It .Va WITHOUT_CLANG_FULL .It Modified: stable/11/share/mk/src.opts.mk ============================================================================== --- stable/11/share/mk/src.opts.mk Sat Sep 12 16:33:05 2020 (r365661) +++ stable/11/share/mk/src.opts.mk Sat Sep 12 16:50:04 2020 (r365662) @@ -203,6 +203,7 @@ __DEFAULT_NO_OPTIONS = \ LOADER_FORCE_LE \ LOADER_VERBOSE \ NAND \ + MALLOC_PRODUCTION \ OFED_EXTRA \ OPENLDAP \ REPRODUCIBLE_BUILD \ Copied and modified: stable/11/tools/build/options/WITHOUT_MALLOC_PRODUCTION (from r365371, head/tools/build/options/WITHOUT_MALLOC_PRODUCTION) ============================================================================== --- head/tools/build/options/WITHOUT_MALLOC_PRODUCTION Sat Sep 5 23:30:17 2020 (r365371, copy source) +++ stable/11/tools/build/options/WITHOUT_MALLOC_PRODUCTION Sat Sep 12 16:50:04 2020 (r365662) @@ -2,4 +2,3 @@ Set to enable assertions and statistics gathering in .Xr malloc 3 . It also defaults the A and J runtime options to on. -Enabled by default on -CURRENT. Copied and modified: stable/11/tools/build/options/WITH_MALLOC_PRODUCTION (from r365371, head/tools/build/options/WITH_MALLOC_PRODUCTION) ============================================================================== --- head/tools/build/options/WITH_MALLOC_PRODUCTION Sat Sep 5 23:30:17 2020 (r365371, copy source) +++ stable/11/tools/build/options/WITH_MALLOC_PRODUCTION Sat Sep 12 16:50:04 2020 (r365662) @@ -2,4 +2,3 @@ Set to disable assertions and statistics gathering in .Xr malloc 3 . It also defaults the A and J runtime options to off. -Disabled by default on -CURRENT. From owner-svn-src-stable-11@freebsd.org Sat Sep 12 18:42:15 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3A3D23E003C; Sat, 12 Sep 2020 18:42:15 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BphLb0q3Yz4Mtn; Sat, 12 Sep 2020 18:42:15 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id F36E0196E6; Sat, 12 Sep 2020 18:42:14 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08CIgEAI056404; Sat, 12 Sep 2020 18:42:14 GMT (envelope-from eugen@FreeBSD.org) Received: (from eugen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08CIgEBa056402; Sat, 12 Sep 2020 18:42:14 GMT (envelope-from eugen@FreeBSD.org) Message-Id: <202009121842.08CIgEBa056402@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: eugen set sender to eugen@FreeBSD.org using -f From: Eugene Grosbein Date: Sat, 12 Sep 2020 18:42:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365668 - stable/11/sys/geom/part X-SVN-Group: stable-11 X-SVN-Commit-Author: eugen X-SVN-Commit-Paths: stable/11/sys/geom/part X-SVN-Commit-Revision: 365668 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 18:42:15 -0000 Author: eugen Date: Sat Sep 12 18:42:14 2020 New Revision: 365668 URL: https://svnweb.freebsd.org/changeset/base/365668 Log: MFC r365477: geom_part: extend kern.geom.part.check_integrity to work on GPT In short, this change allows accessing partition and recovering secondary GPT in case it is unaccessible but primary table is fine. Reported by: Alex Korchmar Modified: stable/11/sys/geom/part/g_part.c stable/11/sys/geom/part/g_part_gpt.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/geom/part/g_part.c ============================================================================== --- stable/11/sys/geom/part/g_part.c Sat Sep 12 18:40:39 2020 (r365667) +++ stable/11/sys/geom/part/g_part.c Sat Sep 12 18:42:14 2020 (r365668) @@ -132,9 +132,9 @@ struct g_part_alias_list { SYSCTL_DECL(_kern_geom); SYSCTL_NODE(_kern_geom, OID_AUTO, part, CTLFLAG_RW, 0, "GEOM_PART stuff"); -static u_int check_integrity = 1; +u_int geom_part_check_integrity = 1; SYSCTL_UINT(_kern_geom_part, OID_AUTO, check_integrity, - CTLFLAG_RWTUN, &check_integrity, 1, + CTLFLAG_RWTUN, &geom_part_check_integrity, 1, "Enable integrity checking"); /* @@ -409,7 +409,7 @@ g_part_check_integrity(struct g_part_table *table, str if (failed != 0) { printf("GEOM_PART: integrity check failed (%s, %s)\n", pp->name, table->gpt_scheme->name); - if (check_integrity != 0) + if (geom_part_check_integrity != 0) return (EINVAL); table->gpt_corrupt = 1; } Modified: stable/11/sys/geom/part/g_part_gpt.c ============================================================================== --- stable/11/sys/geom/part/g_part_gpt.c Sat Sep 12 18:40:39 2020 (r365667) +++ stable/11/sys/geom/part/g_part_gpt.c Sat Sep 12 18:42:14 2020 (r365668) @@ -54,6 +54,8 @@ FEATURE(geom_part_gpt, "GEOM partitioning class for GP CTASSERT(offsetof(struct gpt_hdr, padding) == 92); CTASSERT(sizeof(struct gpt_ent) == 128); +extern u_int geom_part_check_integrity; + #define EQUUID(a,b) (memcmp(a, b, sizeof(struct uuid)) == 0) #define MBRSIZE 512 @@ -448,8 +450,9 @@ gpt_read_hdr(struct g_part_gpt_table *table, struct g_ if (hdr->hdr_lba_self != table->lba[elt]) goto fail; hdr->hdr_lba_alt = le64toh(buf->hdr_lba_alt); - if (hdr->hdr_lba_alt == hdr->hdr_lba_self || - hdr->hdr_lba_alt > last) + if (hdr->hdr_lba_alt == hdr->hdr_lba_self) + goto fail; + if (hdr->hdr_lba_alt > last && geom_part_check_integrity) goto fail; /* Check the managed area. */ From owner-svn-src-stable-11@freebsd.org Sat Sep 12 19:40:06 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B2FFE3E16B2; Sat, 12 Sep 2020 19:40:06 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BpjdL4N6Qz4Rcx; Sat, 12 Sep 2020 19:40:06 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 7AD9119E52; Sat, 12 Sep 2020 19:40:06 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08CJe6ad088367; Sat, 12 Sep 2020 19:40:06 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08CJe5GP088364; Sat, 12 Sep 2020 19:40:05 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009121940.08CJe5GP088364@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sat, 12 Sep 2020 19:40:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365671 - in stable: 11 11/share/man/man5 11/share/mk 12 12/share/man/man5 12/share/mk X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11 11/share/man/man5 11/share/mk 12 12/share/man/man5 12/share/mk X-SVN-Commit-Revision: 365671 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 19:40:06 -0000 Author: dim Date: Sat Sep 12 19:40:04 2020 New Revision: 365671 URL: https://svnweb.freebsd.org/changeset/base/365671 Log: Follow-up r365662 (MFC of r365371 and r365373) by correctly setting WITH_MALLOC_PRODUCTION for stable branches. Also add a note to UPDATING, to inform users about the new setting. Direct commit to stable/{11,12} as this does not apply to head. Noticed by: imp, Ronald Klop Modified: stable/11/UPDATING stable/11/share/man/man5/src.conf.5 stable/11/share/mk/src.opts.mk Changes in other areas also in this revision: Modified: stable/12/UPDATING stable/12/share/man/man5/src.conf.5 stable/12/share/mk/src.opts.mk Modified: stable/11/UPDATING ============================================================================== --- stable/11/UPDATING Sat Sep 12 19:33:25 2020 (r365670) +++ stable/11/UPDATING Sat Sep 12 19:40:04 2020 (r365671) @@ -16,6 +16,18 @@ from older versions of FreeBSD, try WITHOUT_CLANG and the tip of head, and then rebuild without this option. The bootstrap process from older version of current across the gcc/clang cutover is a bit fragile. +20200912: + The make.conf(5) MALLOC_PRODUCTION variable, used for disabling and + enabling assertions and statistics gathering in malloc(3), has been + migrated to a src.conf(5) WITH/WITHOUT_MALLOC_PRODUCTION option. + + On stable branches, WITH_MALLOC_PRODUCTION is set by default, which + means that malloc(3) has assertions and statistics gathering disabled, + for improved performance. + + For backwards compatibility, the make.conf(5) MALLOC_PRODUCTION is still + honored, but it is now deprecated and undocumented. + 20200723: Clang, llvm, lld, lldb, compiler-rt, libc++, libunwind and openmp have been upgraded to 10.0.1. Please see the 20141231 entry below for Modified: stable/11/share/man/man5/src.conf.5 ============================================================================== --- stable/11/share/man/man5/src.conf.5 Sat Sep 12 19:33:25 2020 (r365670) +++ stable/11/share/man/man5/src.conf.5 Sat Sep 12 19:40:04 2020 (r365671) @@ -1183,10 +1183,10 @@ MTA selector. Set to not install .Xr make 1 and related support files. -.It Va WITH_MALLOC_PRODUCTION -Set to disable assertions and statistics gathering in +.It Va WITHOUT_MALLOC_PRODUCTION +Set to enable assertions and statistics gathering in .Xr malloc 3 . -It also defaults the A and J runtime options to off. +It also defaults the A and J runtime options to on. .It Va WITHOUT_MAN Set to not build manual pages. When set, these options are also in effect: Modified: stable/11/share/mk/src.opts.mk ============================================================================== --- stable/11/share/mk/src.opts.mk Sat Sep 12 19:33:25 2020 (r365670) +++ stable/11/share/mk/src.opts.mk Sat Sep 12 19:40:04 2020 (r365671) @@ -139,6 +139,7 @@ __DEFAULT_YES_OPTIONS = \ MAIL \ MAILWRAPPER \ MAKE \ + MALLOC_PRODUCTION \ MANDOCDB \ NDIS \ NETCAT \ @@ -203,7 +204,6 @@ __DEFAULT_NO_OPTIONS = \ LOADER_FORCE_LE \ LOADER_VERBOSE \ NAND \ - MALLOC_PRODUCTION \ OFED_EXTRA \ OPENLDAP \ REPRODUCIBLE_BUILD \ From owner-svn-src-stable-11@freebsd.org Sat Sep 12 20:20:56 2020 Return-Path: Delivered-To: svn-src-stable-11@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C15283E1CC0; Sat, 12 Sep 2020 20:20:56 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BpkXS4m89z4TDP; Sat, 12 Sep 2020 20:20:56 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 86CD71A9C5; Sat, 12 Sep 2020 20:20:56 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 08CKKutO014223; Sat, 12 Sep 2020 20:20:56 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 08CKKumn014222; Sat, 12 Sep 2020 20:20:56 GMT (envelope-from dim@FreeBSD.org) Message-Id: <202009122020.08CKKumn014222@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sat, 12 Sep 2020 20:20:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r365672 - in stable: 11/contrib/jemalloc/include/jemalloc 12/contrib/jemalloc/include/jemalloc X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 11/contrib/jemalloc/include/jemalloc 12/contrib/jemalloc/include/jemalloc X-SVN-Commit-Revision: 365672 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2020 20:20:56 -0000 Author: dim Date: Sat Sep 12 20:20:55 2020 New Revision: 365672 URL: https://svnweb.freebsd.org/changeset/base/365672 Log: Follow-up r365662 (MFC of r365371 and r365373) by also removing the header hack from jemalloc_FreeBSD.h, which rendered any make.conf MALLOC_PRODUCTION or src.conf WITH/WITHOUT_MALLOC_PRODUCTION irrelevant. Direct commit to stable/{11,12} as this does not apply to head. Noticed by: kevans Modified: stable/11/contrib/jemalloc/include/jemalloc/jemalloc_FreeBSD.h Changes in other areas also in this revision: Modified: stable/12/contrib/jemalloc/include/jemalloc/jemalloc_FreeBSD.h Modified: stable/11/contrib/jemalloc/include/jemalloc/jemalloc_FreeBSD.h ============================================================================== --- stable/11/contrib/jemalloc/include/jemalloc/jemalloc_FreeBSD.h Sat Sep 12 19:40:04 2020 (r365671) +++ stable/11/contrib/jemalloc/include/jemalloc/jemalloc_FreeBSD.h Sat Sep 12 20:20:55 2020 (r365672) @@ -5,9 +5,6 @@ #undef JEMALLOC_OVERRIDE_VALLOC #ifndef MALLOC_PRODUCTION -#define MALLOC_PRODUCTION -#endif -#ifndef MALLOC_PRODUCTION #define JEMALLOC_DEBUG #endif